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.

65 lines
2.0 KiB

6 years ago
  1. {% extends "base.html" %}
  2. {% load compress static hc_extras %}
  3. {% block title %}{% site_name %}{% endblock %}
  4. {% block content %}
  5. <div class="row">
  6. <div class="col-sm-12">
  7. <h1 class="settings-title">
  8. My Projects
  9. <div class="pull-right">
  10. <button
  11. class="btn btn-primary"
  12. data-toggle="modal"
  13. data-target="#add-project-modal">Create New Project</button>
  14. </div>
  15. </h1>
  16. <div id="project-selector" class="row">
  17. {% for project in projects %}
  18. <a href="{% url 'hc-checks' project.code %}">
  19. <div class="col-sm-6 col-md-4">
  20. <div class="panel project {% if project == request.profile.current_project %}selected{% endif %}">
  21. <div class="status icon-{{ project.overall_status }}"></div>
  22. <h4>{{ project }}</h4>
  23. <div>
  24. {% with project.check_set.count as n %}
  25. {{ n }} check{{ n|pluralize }},
  26. {% endwith %}
  27. {% with project.channel_set.count as n %}
  28. {{ n }} integration{{ n|pluralize }}
  29. {% endwith %}
  30. </div>
  31. <div class="text-muted">
  32. {{ project.owner.email }}
  33. </div>
  34. </div>
  35. </div>
  36. </a>
  37. {% empty %}
  38. <div class="col-sm-12">
  39. <p>You do not have any projects.</p>
  40. </div>
  41. {% endfor %}
  42. </div>
  43. </div>
  44. </div>
  45. {% include "accounts/add_project_modal.html" %}
  46. {% endblock %}
  47. {% block scripts %}
  48. {% compress js %}
  49. <script src="{% static 'js/jquery-2.1.4.min.js' %}"></script>
  50. <script src="{% static 'js/bootstrap.min.js' %}"></script>
  51. <script src="{% static 'js/project.js' %}"></script>
  52. {% endcompress %}
  53. {% endblock %}