[Zope-CVS] SVN: zversioning/trunk/src/versioning/demo/browser/ schema-based editview customized

Volker Bachschneider vbachs at dzug.org
Tue Oct 12 14:36:24 EDT 2004


Log message for revision 28026:
  schema-based editview customized
  


Changed:
  U   zversioning/trunk/src/versioning/demo/browser/configure.zcml
  A   zversioning/trunk/src/versioning/demo/browser/edit.pt
  U   zversioning/trunk/src/versioning/demo/browser/proposal.css


-=-
Modified: zversioning/trunk/src/versioning/demo/browser/configure.zcml
===================================================================
--- zversioning/trunk/src/versioning/demo/browser/configure.zcml	2004-10-12 18:15:29 UTC (rev 28025)
+++ zversioning/trunk/src/versioning/demo/browser/configure.zcml	2004-10-12 18:36:23 UTC (rev 28026)
@@ -67,6 +67,7 @@
     label="Edit UseCase"
     name="EditUseCase.html"
     title="Edit Use Case"
+    template="edit.pt"
     fields = "usecase"
     permission="zope.ManageContent"
     />
@@ -76,6 +77,7 @@
     label="Edit Concept"
     name="EditConcept.html"
     title="Edit Concept"
+    template="edit.pt"
     fields = "concept"
     permission="zope.ManageContent"
     />
@@ -85,6 +87,7 @@
     label="Edit Todo"
     name="EditTodo.html"
     title="Edit Todo"
+    template="edit.pt"
     fields = "todo"
     permission="zope.ManageContent"
     />
@@ -94,6 +97,7 @@
     label="Edit Issues"
     name="EditIssues.html"
     title="Edit Issues"
+    template="edit.pt"
     fields = "issues"
     permission="zope.ManageContent"
     />

Added: zversioning/trunk/src/versioning/demo/browser/edit.pt
===================================================================
--- zversioning/trunk/src/versioning/demo/browser/edit.pt	2004-10-12 18:15:29 UTC (rev 28025)
+++ zversioning/trunk/src/versioning/demo/browser/edit.pt	2004-10-12 18:36:23 UTC (rev 28026)
@@ -0,0 +1,87 @@
+<tal:tag condition="view/update"/>
+<html metal:use-macro="context/@@standard_macros/view">
+  <body>
+  <div metal:fill-slot="body">
+
+  <div metal:define-macro="body">
+
+    <form action="." tal:attributes="action request/URL" method="POST"
+          enctype="multipart/form-data">
+
+      <div metal:define-macro="formbody">
+
+        <h3 tal:condition="view/label"
+            tal:content="view/label"
+            metal:define-slot="heading"
+            >Edit something</h3><br>
+
+        <p tal:define="status view/update"
+           tal:condition="status"
+           tal:content="status" />
+
+        <p tal:condition="view/errors" i18n:translate="">
+          There are <strong tal:content="python:len(view.errors)"
+                            i18n:name="num_errors">6</strong> input errors.
+        </p>
+
+        <div metal:define-slot="extra_info" tal:replace="nothing">
+        </div>
+
+        <div class="row"
+             metal:define-slot="extra_top" tal:replace="nothing">
+          <div class="label">Extra top</div>
+          <div class="field"><input type="text" style="width:100%" /></div>
+        </div>
+<!--        
+        <div metal:use-macro="context/@@form_macros/widget_rows" />
+-->        
+
+<!-- Modified -->
+        <div tal:repeat="widget view/widgets">  
+<!--
+          <div>
+            <b><p 
+              tal:content="widget/label">The Label</p></b>
+          </div>
+-->
+          <div tal:content="structure widget">
+            <input type="text" style="width:100%"/>
+          </div>
+          <div class="error" tal:define="error widget/error"
+            tal:condition="error" tal:content="structure error">
+            The Error
+          </div>
+        </div>
+<!-- End of Modiefied -->
+
+        <div class="separator"></div>
+        
+        <div class="row"
+             metal:define-slot="extra_bottom" tal:replace="nothing">
+          <div class="label">Extra bottom</div>
+          <div class="field"><input type="text" style="width:100%" /></div>
+        </div>
+        <div class="separator"></div>
+      </div>
+
+      <div class="row">
+        <div class="controls">
+          <input type="submit" value="Refresh" 
+              i18n:attributes="value refresh-button" />
+          <input type="submit" name="UPDATE_SUBMIT" value="Change" 
+              i18n:attributes="value submit-button"/>
+        </div>
+      </div>
+      <div class="row" metal:define-slot="extra_buttons" tal:replace="nothing">
+      </div>
+
+      <div class="separator"></div>
+
+    </form>
+
+  </div>
+
+  </div>
+  </body>
+
+</html>

Modified: zversioning/trunk/src/versioning/demo/browser/proposal.css
===================================================================
--- zversioning/trunk/src/versioning/demo/browser/proposal.css	2004-10-12 18:15:29 UTC (rev 28025)
+++ zversioning/trunk/src/versioning/demo/browser/proposal.css	2004-10-12 18:36:23 UTC (rev 28026)
@@ -1,3 +1,7 @@
+div.field {
+  display:block;
+}
+
 div.cblock {
   border-width:1px; 
   border-style:solid;margin-top:6px; 



More information about the Zope-CVS mailing list