Update of /var/cvs/contributions/didactor2/src/core/templates/cockpit
In directory james.mmbase.org:/tmp/cvs-serv10326

Modified Files:
        educationbar.jsp providerbar.jsp 
Log Message:
jspx


See also: 
http://cvs.mmbase.org/viewcvs/contributions/didactor2/src/core/templates/cockpit


Index: educationbar.jsp
===================================================================
RCS file: 
/var/cvs/contributions/didactor2/src/core/templates/cockpit/educationbar.jsp,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -b -r1.19 -r1.20
--- educationbar.jsp    18 Oct 2007 14:26:27 -0000      1.19
+++ educationbar.jsp    17 Jan 2008 10:53:32 -0000      1.20
@@ -1,11 +1,12 @@
-<[EMAIL PROTECTED] uri="http://www.mmbase.org/mmbase-taglib-2.0"; prefix="mm"
-%><[EMAIL PROTECTED] uri="http://www.didactor.nl/ditaglib_1.0"; prefix="di"
-%><%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core";
-%><[EMAIL PROTECTED] import="nl.didactor.component.Component, 
java.util.TreeMap, java.util.Iterator"
-%><mm:cloud method="asis">
-<jsp:directive.include file="/shared/setImports.jsp" />
-<div class="educationMenubar">
-<mm:isgreaterthan referid="user" value="0">
+<jsp:root version="2.0"
+          xmlns:jsp="http://java.sun.com/JSP/Page";
+          xmlns:c="http://java.sun.com/jsp/jstl/core";
+          xmlns:mm="http://www.mmbase.org/mmbase-taglib-2.0";
+          xmlns:di="http://www.didactor.nl/ditaglib_1.0";>
+  <jsp:directive.page import="java.util.*,nl.didactor.component.*" />
+  <mm:cloud method="asis">
+    <div class="educationMenubar">
+      <mm:isgreaterthan referid="user" value="0">
 
   <mm:present referid="education">
     <mm:hasnode number="component.progress">
@@ -22,9 +23,11 @@
 
     </mm:hasnode>
   </mm:present>
-  <%
+        <jsp:scriptlet>
+          // Too much java code in this JSP
+          //  This stuff must be gone.
     TreeMap tm = new TreeMap();
-  %>
+        </jsp:scriptlet>
 
   <div class="educationMenubarNav">
   <mm:present referid="education">
@@ -32,7 +35,7 @@
       <mm:related path="settingrel,components">
         <mm:node element="components">
           <mm:field jspvar="cname" name="name" write="false" vartype="String">
-            <%
+                    <jsp:scriptlet>
               Component c = Component.getComponent(cname);
               if ("education".equals(c.getTemplateBar())) {
                   int a = c.getBarPosition() * 100;
@@ -41,29 +44,32 @@
                   }
                   tm.put(new Integer(a), c);
               }
-            %>
+                    </jsp:scriptlet>%>
           </mm:field>
         </mm:node>
       </mm:related>
     </mm:node>
-    <%
+            <jsp:scriptlet>
       Iterator i = tm.values().iterator();
       while (i.hasNext()) {
           Component c = (Component)i.next();
-      %>
-      <mm:import id="componentname" reset="true"><%=c.getName()%></mm:import>
+            </jsp:scriptlet>
+            <mm:import id="componentname" reset="true">
+              <jsp:expression>c.getName()</jsp:expression>
+            </mm:import>
       <c:catch var="ex">
         <mm:treeinclude page="/$componentname/cockpit/menuitem.jsp" 
objectlist="$includePath" referids="$referids">
-          <mm:param name="name"><%=c.getName()%></mm:param>
-          <mm:param name="number"><%=c.getNumber()%></mm:param>
+                <mm:param 
name="name"><jsp:expression>c.getName()</jsp:expression></mm:param>
+                <mm:param 
name="number"><jsp:expression>c.getNumber()</jsp:expression></mm:param>
           <mm:param name="type">div</mm:param>
           <mm:param name="scope">education</mm:param>
         </mm:treeinclude>
       </c:catch>
       ${ex.message}
-    <% } %>
+            <jsp:scriptlet>}</jsp:scriptlet>
   </mm:present>
   </div>
-</mm:isgreaterthan>
-</div>
-</mm:cloud>
+      </mm:isgreaterthan>
+    </div>
+  </mm:cloud>
+</jsp:root>


Index: providerbar.jsp
===================================================================
RCS file: 
/var/cvs/contributions/didactor2/src/core/templates/cockpit/providerbar.jsp,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -b -r1.29 -r1.30
--- providerbar.jsp     15 Jan 2008 10:10:12 -0000      1.29
+++ providerbar.jsp     17 Jan 2008 10:53:32 -0000      1.30
@@ -65,9 +65,9 @@
 
         <jsp:scriptlet>}</jsp:scriptlet>
 
-        <!-- If the user has the rights, then always show the management link. 
That allows us to enable/disable components after
-             install on an empty database -->
-        <mm:treeinclude page="/education/cockpit/menuitem.jsp" 
objectlist="$includePath" referids="$referids">
+        <!-- If the user has the rights, then always show the management link. 
That allows us to enable/disable components after install on an empty database 
-->
+        <mm:treeinclude page="/education/cockpit/menuitem.jsp"
+                        objectlist="$includePath" referids="$referids">
           <mm:param name="name">education</mm:param>
           <mm:param name="type">div</mm:param>
           <mm:param name="scope">provider</mm:param>
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to