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.

93 lines
3.4 KiB

8 years ago
8 years ago
  1. {% extends "base.html" %}
  2. {% load compress static 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">Settings <small>{{ request.user.email }}</small></h1>
  8. </div>
  9. </div>
  10. <div class="row">
  11. <div class="col-sm-2">
  12. <ul class="nav nav-pills nav-stacked">
  13. <li><a href="{% url 'hc-profile' %}">Account</a></li>
  14. {% if show_pricing %}
  15. <li><a href="{% url 'hc-billing' %}">Billing</a></li>
  16. {% endif %}
  17. <li><a href="{% url 'hc-notifications' %}">Email Reports</a></li>
  18. <li class="active"><a href="{% url 'hc-badges' %}">Badges</a></li>
  19. </ul>
  20. </div>
  21. <div class="col-sm-10">
  22. <div class="panel panel-default">
  23. <div class="panel-body settings-block">
  24. <h2 class="settings-title">Status Badges</h2>
  25. <p id="badges-description">
  26. {% site_name %} provides status badges for each of the tags
  27. you have used. Additionally, the "{% site_name %}"
  28. badge shows the overall status of all checks in a
  29. project. The badges have public, but hard-to-guess
  30. URLs. You can use them in your READMEs,
  31. dashboards or status pages.
  32. </p>
  33. <div id="b-format" class="btn-group" data-toggle="buttons">
  34. <label id="show-svg" class="btn btn-default active">
  35. <input type="radio" autocomplete="off" checked> SVG
  36. </label>
  37. <label id="show-json" class="btn btn-default">
  38. <input type="radio" autocomplete="off"> JSON
  39. </label>
  40. </div>
  41. <table id="badges-svg" class="badges table">
  42. {% for badge_set in badges %}
  43. <tr>
  44. <th colspan="2">{{ badge_set.project }}</th>
  45. </tr>
  46. {% for urldict in badge_set.urls %}
  47. <tr>
  48. <td>
  49. <img src="{{ urldict.svg }}" alt="" />
  50. </td>
  51. <td class="svg-url">
  52. <code>{{ urldict.svg }}</code>
  53. </td>
  54. </tr>
  55. {% endfor %}
  56. {% endfor %}
  57. </table>
  58. <table id="badges-json" class="badges table">
  59. {% for badge_set in badges %}
  60. <tr>
  61. <th colspan="2">{{ badge_set.project }}</th>
  62. </tr>
  63. {% for urldict in badge_set.urls %}
  64. <tr>
  65. <td class="json-response" data-url="{{ urldict.json }}">
  66. </td>
  67. <td class="json-url">
  68. <code>{{ urldict.json }}</code>
  69. </td>
  70. </tr>
  71. {% endfor %}
  72. {% endfor %}
  73. </table>
  74. </div>
  75. </div>
  76. </div>
  77. </div>
  78. {% endblock %}
  79. {% block scripts %}
  80. {% compress js %}
  81. <script src="{% static 'js/jquery-2.1.4.min.js' %}"></script>
  82. <script src="{% static 'js/bootstrap.min.js' %}"></script>
  83. <script src="{% static 'js/badges.js' %}"></script>
  84. {% endcompress %}
  85. {% endblock %}