Split up form into three forms to have default buttons work sensibly.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Mon, 30 Jul 2012 09:59:19 +0000 (11:59 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Mon, 30 Jul 2012 09:59:19 +0000 (11:59 +0200)
src/main/resources/templates/admin.edit-track

index ccd3b92..c03d01d 100644 (file)
 
 <%foreach track.derivatives derivative>
 
-       <form action="admin.edit-derivative" method="post" accept-charset="utf-8">
-
-               <input type="hidden" name="track" value="<%track.id|html>"/>
-               <input type="hidden" name="derivative" value="<%derivative.id|html>"/>
-
                <div>
                        Path:
                        <%derivative.path|html>
                        <%derivative.size|html>
                </div>
 
+       <form action="admin.edit-derivative" method="post" accept-charset="utf-8">
+               <input type="hidden" name="track" value="<%track.id|html>"/>
+               <input type="hidden" name="derivative" value="<%derivative.id|html>"/>
                <button type="submit" name="delete" value="true">Delete Derivative</button>
+       </form>
+
+       <form action="admin.edit-derivative" method="post" accept-charset="utf-8">
+
+               <input type="hidden" name="track" value="<%track.id|html>"/>
+               <input type="hidden" name="derivative" value="<%derivative.id|html>"/>
 
                <%foreach derivative.properties property>
                        <div>
                        <%/last>
                <%/foreach>
 
+       </form>
+
+       <form action="admin.edit-derivative" method="post" accept-charset="utf-8">
+
+               <input type="hidden" name="track" value="<%track.id|html>"/>
+               <input type="hidden" name="derivative" value="<%derivative.id|html>"/>
+
                <div>
                        New Property:
                        <input type="text" name="property" value="">