You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

101 lines
3.7 KiB

  1. {% extends "base.html" %}
  2. {% load hc_extras %}
  3. {% block title %}Account Settings - {% site_name %}{% endblock %}
  4. {% block content %}
  5. <div class="row">
  6. <div class="col-sm-12">
  7. <h1 class="settings-title">
  8. Settings
  9. <small>{{ request.user.email }}</small>
  10. </h1>
  11. </div>
  12. </div>
  13. <div class="row">
  14. <div class="col-sm-3">
  15. <ul class="nav nav-pills nav-stacked">
  16. <li><a href="{% url 'hc-profile' %}">Account</a></li>
  17. {% if show_pricing %}
  18. <li><a href="{% url 'hc-billing' %}">Billing</a></li>
  19. {% endif %}
  20. <li class="active"><a href="{% url 'hc-notifications' %}">Email Reports</a></li>
  21. <li><a href="{% url 'hc-badges' %}">Badges</a></li>
  22. </ul>
  23. </div>
  24. <div class="col-sm-9 col-md-6">
  25. <div class="panel panel-{{ status }}">
  26. <div class="panel-body settings-block">
  27. <form method="post">
  28. {% csrf_token %}
  29. <h2>Email Reports</h2>
  30. <p>Send me monthly emails about:</p>
  31. <label class="checkbox-container">
  32. <input
  33. name="reports_allowed"
  34. type="checkbox"
  35. {% if profile.reports_allowed %} checked {% endif %}>
  36. <span class="checkmark"></span>
  37. The status of checks in all teams I belong to
  38. </label>
  39. <br>
  40. <p>If any checks are down:</p>
  41. <label class="radio-container">
  42. <input
  43. type="radio"
  44. name="nag_period"
  45. value="0"
  46. {% if profile.nag_period.total_seconds == 0 %} checked {% endif %}>
  47. <span class="radiomark"></span>
  48. Do not remind me
  49. </label>
  50. <label class="radio-container">
  51. <input
  52. type="radio"
  53. name="nag_period"
  54. value="86400"
  55. {% if profile.nag_period.total_seconds == 86400 %} checked {% endif %}>
  56. <span class="radiomark"></span>
  57. Remind me daily
  58. </label>
  59. <label class="radio-container">
  60. <input
  61. type="radio"
  62. name="nag_period"
  63. value="3600"
  64. {% if profile.nag_period.total_seconds == 3600 %} checked {% endif %}>
  65. <span class="radiomark"></span>
  66. Remind me hourly
  67. </label>
  68. <br />
  69. <p style="color: #888">
  70. Reports will be delivered to {{ profile.user.email }}. <br />
  71. {% if profile.next_report_date %}
  72. Next monthly report date is
  73. {{ profile.next_report_date.date }}.
  74. {% endif %}
  75. </p>
  76. <br />
  77. <button
  78. name="update_reports_allowed"
  79. type="submit"
  80. class="btn btn-default pull-right">Save Changes</button>
  81. </form>
  82. </div>
  83. {% if status == "info" %}
  84. <div class="panel-footer">
  85. Your settings have been updated!
  86. </div>
  87. {% endif %}
  88. </div>
  89. </div>
  90. </div>
  91. {% endblock %}