]> git.sesse.net Git - ccbs/blobdiff - html/templates/registration.tmpl
Add an option for un-registering people.
[ccbs] / html / templates / registration.tmpl
index 33b416220a6c9e7580da30aa0051fc1f8ee0c947..5a2239f9ad944c2e8026454cdd22806f5dd81aee 100644 (file)
@@ -3,7 +3,6 @@
 
 <div>
 <form method="post" action="do-registration.pl">
-  <input type="hidden" name="tournament" value="[% tournament.tournament %]" />
   <table>
     <tr>
       <th>Spiller</th>
@@ -26,6 +25,7 @@
     </tr>
     <tr>
       <th colspan="2">
+        <input type="hidden" name="tournament" value="[% tournament.tournament %]" />
         <input type="submit" value="Legg til" />
       </th>
     </tr>
 <h2>PĆ„meldte</h2>
 
 <div>
-  <ul>
+  <table>
 [% FOR r = registered %]
-    <li>
-      [% r.nick %] - 
+    <tr>
+      <td>[% r.nick %]</td>
 [% IF r.paid %]
-      betalt
+      <td>betalt</td>
 [% ELSE %]
-      <span class="notpaid">ikke betalt</span>
+      <td class="notpaid">ikke betalt</td>
 [% END %]
-    </li>
+      <td>
+        <form method="post" action="do-set-paid.pl">
+          <p class="button">
+            <input type="hidden" name="tournament" value="[% tournament.tournament %]" />
+            <input type="hidden" name="player" value="[% r.player %]" />
+[% IF r.paid %]
+            <input type="hidden" name="paid" value="f" />
+           <input type="submit" value="Sett som ikke betalt" />
+[% ELSE %]
+            <input type="hidden" name="paid" value="t" />
+           <input type="submit" value="Sett som betalt" />
 [% END %]
-  </ul>
+          </p>
+        </form>
+      </td>
+      <td>
+        <form method="post" action="do-unregister.pl">
+          <p class="button">
+            <input type="hidden" name="tournament" value="[% tournament.tournament %]" />
+            <input type="hidden" name="player" value="[% r.player %]" />
+           <input type="submit" value="Fjern" />
+          </p>
+        </form>
+      </td>
+    </tr>
+[% END %]
+  </table>
 </div>