diff options
author | Jonathan Tschanter <jmtw@tutanota.de> | 2022-01-21 00:14:34 +0100 |
---|---|---|
committer | Jonathan Tschanter <jmtw@tutanota.de> | 2022-01-21 00:14:34 +0100 |
commit | 2bde1b0660585e16116fbd12c86b53e886b6f3be (patch) | |
tree | 8c23fbad83e8b947c60a50b7af6be2c8b0d4867a /templates/card/card_list.twig | |
parent | c2b0ebcdbb23a38a31b4d8c9e39f2a2be4cc862b (diff) |
Add first layout with simplecss
Diffstat (limited to 'templates/card/card_list.twig')
-rw-r--r-- | templates/card/card_list.twig | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/templates/card/card_list.twig b/templates/card/card_list.twig new file mode 100644 index 0000000..1714fc8 --- /dev/null +++ b/templates/card/card_list.twig @@ -0,0 +1,38 @@ +{% extends 'card/card.twig' %} + +{% block pagetitle %} +List +{% endblock %} +{% block pagecontent %} + <table> + <thead> + <tr> + <th>ID</th> + {% for meta in cards[0].getAllMeta() %} + <th>{{ meta.key }}</th> + {% endfor %} + <th>Votes</th> + <th></th> + </tr> + </thead> + <tbody> + {% for card in cards %} + <tr> + <td>{{ card.id }}</td> + {% for meta in card.getAllMeta() %} + <td>{{ meta.value }}</td> + {% endfor %} + <td> + {{ card.getVotesTotal() }} + <button>Up</button> + <button>Down</button> + </td> + <td> + <button onclick="location.href='/card/{{ card.id }}'">Card</button> + <button onclick="location.href='/card/{{ card.id }}/artworks'">Artworks</button> + </td> + </tr> + {% endfor %} + </tbody> + </table> +{% endblock %} |