]> git.decadent.org.uk Git - maypole.git/blobdiff - templates/factory/addnew
Fix to check that a has_a points to another Model object.
[maypole.git] / templates / factory / addnew
index 9345c78b0adbc8d1fdca7d1661089f3c137e6c23..a6027ce2de4ddbd71731f0886526cfa6bd1ac7ca 100644 (file)
@@ -10,17 +10,18 @@ table.
 =cut
 
 #%]
-<h3>Add a new [% classmetadata.moniker %]</h3>
+
+<div id="addnew">
 <form method="post" action="[% base %]/[% classmetadata.table %]/do_edit/">
-    <input type="hidden" name="action" value="create"/>
-    <table class="view">
+    <fieldset>
+<legend>Add a new [% classmetadata.moniker %]</legend>
     [% FOR col = classmetadata.columns %]
         [% NEXT IF col == "id" %]
-        <tr>
-            <td>[% classmetadata.colnames.$col %]</td>
-            <td>[% classmetadata.cgi.$col.as_HTML; %]</td>
-        </tr>
+            <label><span class="field">[% classmetadata.colnames.$col %]</span>
+            [% classmetadata.cgi.$col.as_XML; %]
+           </label>
     [% END; %]
-    </table>
     <input type="submit" name="create" value="create"/>
+</fieldset>
 </form>
+</div>