contract_source_list.html 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <!--
  2. This file is part of DarkFi (https://dark.fi)
  3. Copyright (C) 2020-2026 Dyne.org foundation
  4. This program is free software: you can redistribute it and/or modify
  5. it under the terms of the GNU Affero General Public License as
  6. published by the Free Software Foundation, either version 3 of the
  7. License, or (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU Affero General Public License for more details.
  12. You should have received a copy of the GNU Affero General Public License
  13. along with this program. If not, see <https://www.gnu.org/licenses/>.
  14. -->
  15. {% extends "base.html" %}
  16. {% block title %}Contract {{ contract_id }}{% endblock %}
  17. {% block content %}
  18. <div class="content-container">
  19. <!-- Page Content Header -->
  20. <div class="content-header">
  21. <h2 class="content-section-header">{{ contract_name }} Contract Source Code</h2>
  22. <div>{{ contract_id }}</div>
  23. </div>
  24. <!-- Source File List -->
  25. <div>
  26. {% if source_paths %}
  27. <!-- Source Code List -->
  28. <ul class="source-code-list">
  29. {% for path in source_paths %}
  30. <li class="source-code-list-item">
  31. <a href="/contract/source/{{ contract_id }}/{{ path }}?name={{ contract_name|urlencode }}"
  32. class="source-file-link">
  33. {{ path }}
  34. </a>
  35. </li>
  36. {% endfor %}
  37. </ul>
  38. {% else %}
  39. <!-- No source code associated with contract -->
  40. <div>
  41. There is no source files are associated with this contract.
  42. </div>
  43. {% endif %}
  44. </div>
  45. </div>
  46. {% endblock %}