pages.go 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. package pages
  2. import (
  3. "gitote/gitote/pkg/context"
  4. )
  5. const (
  6. ABOUT = "pages/about"
  7. FAQ = "pages/faq"
  8. PRIVACY = "pages/privacy"
  9. TOS = "pages/tos"
  10. DEVELOPERS = "pages/developers"
  11. BRAND = "pages/brand"
  12. CONTACT = "pages/contact"
  13. CONTRIBUTE = "pages/contribute"
  14. SECURITY = "pages/security"
  15. VERIFIED = "pages/verified"
  16. MAKERS = "pages/makers"
  17. HELP = "pages/help"
  18. FEATURES = "pages/features"
  19. FEATUREREQUEST = "pages/request"
  20. SPONSORSHIP = "pages/sponsorship"
  21. SITEMAP = "pages/sitemap"
  22. DONATE = "pages/donate"
  23. )
  24. func About(c *context.Context) {
  25. c.Data["Title"] = "About"
  26. c.HTML(200, ABOUT)
  27. }
  28. func Faq(c *context.Context) {
  29. c.Data["Title"] = "FAQ"
  30. c.HTML(200, FAQ)
  31. }
  32. func Privacy(c *context.Context) {
  33. c.Data["Title"] = "Privacy Policy"
  34. c.HTML(200, PRIVACY)
  35. }
  36. func Tos(c *context.Context) {
  37. c.Data["Title"] = "Terms of Service"
  38. c.HTML(200, TOS)
  39. }
  40. func Developers(c *context.Context) {
  41. c.Data["Title"] = "Gitote Developers"
  42. c.HTML(200, DEVELOPERS)
  43. }
  44. func Brand(c *context.Context) {
  45. c.Data["Title"] = "Gitote Brand"
  46. c.HTML(200, BRAND)
  47. }
  48. func Contribute(c *context.Context) {
  49. c.Data["PageIsContribute"] = true
  50. c.Data["Title"] = "Contribute"
  51. c.HTML(200, CONTRIBUTE)
  52. }
  53. func Security(c *context.Context) {
  54. c.Data["Title"] = "Security"
  55. c.HTML(200, SECURITY)
  56. }
  57. func Verified(c *context.Context) {
  58. c.Data["Title"] = "Verified"
  59. c.HTML(200, VERIFIED)
  60. }
  61. func Makers(c *context.Context) {
  62. c.Data["Title"] = "Makers"
  63. c.HTML(200, MAKERS)
  64. }
  65. func Help(c *context.Context) {
  66. c.Data["Title"] = "Help"
  67. c.Data["PageIsHelp"] = true
  68. c.HTML(200, HELP)
  69. }
  70. func Contact(c *context.Context) {
  71. c.Data["Title"] = "Contact"
  72. c.HTML(200, CONTACT)
  73. }
  74. func Features(c *context.Context) {
  75. c.Data["Title"] = "Features"
  76. c.Data["PageIsFeatures"] = true
  77. c.HTML(200, FEATURES)
  78. }
  79. func FeatureRequest(c *context.Context) {
  80. c.Data["Title"] = "Feature Request"
  81. c.HTML(200, FEATUREREQUEST)
  82. }
  83. func Sponsorship(c *context.Context) {
  84. c.Data["Title"] = "Sponsorship"
  85. c.HTML(200, SPONSORSHIP)
  86. }
  87. func Donate(c *context.Context) {
  88. c.Data["Title"] = "Donate"
  89. c.HTML(200, DONATE)
  90. }