Author: andre
Date: 2010-03-18 10:49:38 +0100 (Thu, 18 Mar 2010)
New Revision: 41490

Added:
   
mmbase/branches/MMBase-1_9/applications/searchrelate/example-webapp/src/main/webapp/relate-edit-relations.jspx
Log:
new example


Added: 
mmbase/branches/MMBase-1_9/applications/searchrelate/example-webapp/src/main/webapp/relate-edit-relations.jspx
===================================================================
--- 
mmbase/branches/MMBase-1_9/applications/searchrelate/example-webapp/src/main/webapp/relate-edit-relations.jspx
                              (rev 0)
+++ 
mmbase/branches/MMBase-1_9/applications/searchrelate/example-webapp/src/main/webapp/relate-edit-relations.jspx
      2010-03-18 09:49:38 UTC (rev 41490)
@@ -0,0 +1,50 @@
+<?xml version="1.0" ?>
+<mm-sre:html
+    styleClass="search"
+    xmlns:jsp="http://java.sun.com/JSP/Page";
+    xmlns:c="http://java.sun.com/jsp/jstl/core";
+    xmlns:mm-sre="urn:jsptagdir:/WEB-INF/tags/mm/searchrelateexample"
+    xmlns:mm-srt="urn:jsptagdir:/WEB-INF/tags/mm/searchrelate"
+    xmlns:mm-sr="http://www.mmbase.org/tags/mm/searchrelate";
+    xmlns:mm="http://www.mmbase.org/mmbase-taglib-2.0";>
+
+  <h2>mm-sr:relate with editable relations</h2>
+
+  <p>
+    In this example the relations and their values are visible and editable.
+    Make a selection in the 'current' or 'repository' list and press the 
button to submit the changes
+    and vise versa. 
+  </p>
+
+  <mm:node number="default.mags">
+    <mm:relatednodescontainer type="news" id="current"  role="posrel">
+      <mm:sortorder field="number" direction="down" />
+      <mm:relatednodes id="related" />
+    </mm:relatednodescontainer>
+
+
+    <mm:listnodescontainer type="news" id="repository">
+      <mm:sortorder field="number" direction="down" />
+      <mm:constraint field="number" operator="IN" referid="related" 
inverse="true" />
+    </mm:listnodescontainer>
+    <form>
+      <mm-srt:relate
+          current="${current}" repository="${repository}"
+          maxpages="10"
+          pagesize="5"
+          unrelate="true"
+          create="true"
+          relations="true"
+          select="true"
+          submit="#save"
+          extracreate="">
+        <jsp:attribute name="currentTitle"><b>News</b></jsp:attribute>
+        <jsp:attribute name="repositoryTitle"><b>Add other 
news</b></jsp:attribute>
+      </mm-srt:relate>
+      <input id="save" type="submit" value="Save" />
+    </form>
+  </mm:node>
+
+  <mm:escape escape="links">$URL: 
https://an...@scm.mmbase.org/mmbase/branches/MMBase-1_9/applications/searchrelate/example-webapp/src/main/webapp/relate.jspx
 $</mm:escape>
+
+</mm-sre:html>

_______________________________________________
Cvs mailing list
Cvs@lists.mmbase.org
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to