You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by sa...@apache.org on 2011/03/24 08:23:50 UTC

svn commit: r1084863 [9/11] - in /ofbiz/branches/jackrabbit20100709: ./ applications/accounting/data/ applications/accounting/src/org/ofbiz/accounting/invoice/ applications/accounting/src/org/ofbiz/accounting/payment/ applications/accounting/src/org/of...

Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/apple/style.css
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/apple/style.css?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/apple/style.css (original)
+++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/apple/style.css Thu Mar 24 07:23:42 2011
@@ -42,9 +42,10 @@
 #vakata-dragged.jstree-apple ins { background:transparent !important; }
 #vakata-dragged.jstree-apple .jstree-ok { background:url("d.png") -2px -53px no-repeat !important; }
 #vakata-dragged.jstree-apple .jstree-invalid { background:url("d.png") -18px -53px no-repeat !important; }
-#jstree-marker.jstree-apple { background:url("d.png") -41px -57px no-repeat !important; }
+#jstree-marker.jstree-apple { background:url("d.png") -41px -57px no-repeat !important; text-indent:-100px; }
 
 .jstree-apple a.jstree-search { color:aqua; }
+.jstree-apple .jstree-locked a { color:silver; cursor:default; }
 
 #vakata-contextmenu.jstree-apple-context, 
 #vakata-contextmenu.jstree-apple-context li ul { background:#f0f0f0; border:1px solid #979797; -moz-box-shadow: 1px 1px 2px #999; -webkit-box-shadow: 1px 1px 2px #999; box-shadow: 1px 1px 2px #999; }

Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/classic/style.css
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/classic/style.css?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/classic/style.css (original)
+++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/classic/style.css Thu Mar 24 07:23:42 2011
@@ -41,9 +41,10 @@
 #vakata-dragged.jstree-classic ins { background:transparent !important; }
 #vakata-dragged.jstree-classic .jstree-ok { background:url("d.png") -2px -53px no-repeat !important; }
 #vakata-dragged.jstree-classic .jstree-invalid { background:url("d.png") -18px -53px no-repeat !important; }
-#jstree-marker.jstree-classic { background:url("d.png") -41px -57px no-repeat !important; }
+#jstree-marker.jstree-classic { background:url("d.png") -41px -57px no-repeat !important; text-indent:-100px; }
 
 .jstree-classic a.jstree-search { color:aqua; }
+.jstree-classic .jstree-locked a { color:silver; cursor:default; }
 
 #vakata-contextmenu.jstree-classic-context, 
 #vakata-contextmenu.jstree-classic-context li ul { background:#f0f0f0; border:1px solid #979797; -moz-box-shadow: 1px 1px 2px #999; -webkit-box-shadow: 1px 1px 2px #999; box-shadow: 1px 1px 2px #999; }
@@ -56,4 +57,21 @@
 #vakata-contextmenu.jstree-classic-context li.vakata-separator { background:white; border-top:1px solid #e0e0e0; margin:0; }
 #vakata-contextmenu.jstree-classic-context li ul { margin-left:-4px; }
 
-/* TODO: IE6 support - the `>` selectors */
\ No newline at end of file
+/* IE6 BEGIN */
+.jstree-classic li, 
+.jstree-classic ins,
+#vakata-dragged.jstree-classic .jstree-invalid, 
+#vakata-dragged.jstree-classic .jstree-ok, 
+#jstree-marker.jstree-classic { _background-image:url("d.gif"); }
+.jstree-classic .jstree-open ins { _background-position:-72px 0; }
+.jstree-classic .jstree-closed ins { _background-position:-54px 0; }
+.jstree-classic .jstree-leaf ins { _background-position:-36px 0; }
+.jstree-classic .jstree-open a ins.jstree-icon { _background-position:-56px -36px; }
+.jstree-classic .jstree-closed a ins.jstree-icon { _background-position:-56px -19px; }
+.jstree-classic .jstree-leaf a ins.jstree-icon { _background-position:-56px -19px; }
+#vakata-contextmenu.jstree-classic-context ins { _display:none; }
+#vakata-contextmenu.jstree-classic-context li { _zoom:1; }
+.jstree-classic .jstree-undetermined a .jstree-checkbox { _background-position:-20px -19px; }
+.jstree-classic .jstree-checked a .jstree-checkbox { _background-position:-38px -19px; }
+.jstree-classic .jstree-unchecked a .jstree-checkbox { _background-position:-2px -19px; }
+/* IE6 END */
\ No newline at end of file

Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default-rtl/style.css
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default-rtl/style.css?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default-rtl/style.css (original)
+++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default-rtl/style.css Thu Mar 24 07:23:42 2011
@@ -40,9 +40,10 @@
 #vakata-dragged.jstree-default-rtl ins { background:transparent !important; }
 #vakata-dragged.jstree-default-rtl .jstree-ok { background:url("d.png") -2px -53px no-repeat !important; }
 #vakata-dragged.jstree-default-rtl .jstree-invalid { background:url("d.png") -18px -53px no-repeat !important; }
-#jstree-marker.jstree-default-rtl { background:url("d.png") -41px -57px no-repeat !important; }
+#jstree-marker.jstree-default-rtl { background:url("d.png") -41px -57px no-repeat !important; text-indent:-100px; }
 
 .jstree-default-rtl a.jstree-search { color:aqua; }
+.jstree-default-rtl .jstree-locked a { color:silver; cursor:default; }
 
 #vakata-contextmenu.jstree-default-rtl-context, 
 #vakata-contextmenu.jstree-default-rtl-context li ul { background:#f0f0f0; border:1px solid #979797; -moz-box-shadow: 1px 1px 2px #999; -webkit-box-shadow: 1px 1px 2px #999; box-shadow: 1px 1px 2px #999; }

Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default/style.css
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default/style.css?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default/style.css (original)
+++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/jquery/plugins/jsTree/themes/default/style.css Thu Mar 24 07:23:42 2011
@@ -40,9 +40,10 @@
 #vakata-dragged.jstree-default ins { background:transparent !important; }
 #vakata-dragged.jstree-default .jstree-ok { background:url("d.png") -2px -53px no-repeat !important; }
 #vakata-dragged.jstree-default .jstree-invalid { background:url("d.png") -18px -53px no-repeat !important; }
-#jstree-marker.jstree-default { background:url("d.png") -41px -57px no-repeat !important; }
+#jstree-marker.jstree-default { background:url("d.png") -41px -57px no-repeat !important; text-indent:-100px; }
 
 .jstree-default a.jstree-search { color:aqua; }
+.jstree-default .jstree-locked a { color:silver; cursor:default; }
 
 #vakata-contextmenu.jstree-default-context, 
 #vakata-contextmenu.jstree-default-context li ul { background:#f0f0f0; border:1px solid #979797; -moz-box-shadow: 1px 1px 2px #999; -webkit-box-shadow: 1px 1px 2px #999; box-shadow: 1px 1px 2px #999; }

Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/myportal.js
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/myportal.js?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/myportal.js (original)
+++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/myportal.js Thu Mar 24 07:23:42 2011
@@ -149,7 +149,6 @@ function updatePortletOrder(currentItem,
     jQuery.ajax({
         url: "/myportal/control/updatePortalPagePortletSeqAjax",
         data: requestData,
-        dataType: "JSON",
         type: "POST",
         success: function(data){
             onCompleteRequest();

Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js (original)
+++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js Thu Mar 24 07:23:42 2011
@@ -378,7 +378,6 @@ function ajaxSubmitFormUpdateAreas(form,
        type: "POST",
        url: jQuery("#" + form).attr("action"),
        data: jQuery("#" + form).serialize(),
-       dataType: "json",
        success: function(data) {
                updateFunction(data);
        }
@@ -410,6 +409,9 @@ function ajaxAutoCompleter(areaCsvString
                     async: false,
                     data: {term : request.term},
                     success: function(data) {
+                    	// reset the autocomp field
+                    	autocomp = undefined;
+                    	
                         //update the result div
                         jQuery("#" + div + "_auto").html(data);
                         if (typeof autocomp != 'undefined') {
@@ -654,7 +656,8 @@ function ajaxInPlaceEditDisplayField(ele
 
     jElement.editable(function(value, settings){
         // removes all line breaks from the value param, because the parseJSON Function can't work with line breaks
-        value = value.replace("\n", " ");
+    	value = value.replace(/\n/g, " ");
+
         var resultField = jQuery.parseJSON('{"' + settings.name + '":"' + value + '"}');
         // merge both parameter objects together
         jQuery.extend(settings.submitdata, resultField);

Modified: ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml (original)
+++ ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml Thu Mar 24 07:23:42 2011
@@ -9,8 +9,8 @@
 
     <property environment="env"/>
     <property name="desc" value="@component-resource-name@ Component"/>
-    <property name="name" value="ofbiz-@component-name@"/>
-    <property name="component-name" value="ofbiz-@component-name@"/>
+    <property name="name" value="@component-name@"/>
+    <property name="component-name" value="@component-name@"/>
     <property name="ofbiz.home.dir" value="../.."/>
     <property name="src.dir" value="src"/>
     <property name="dtd.dir" value="dtd"/>
@@ -38,6 +38,10 @@
     <!-- ================================================================= -->
 
     <target name="create-ofbiz-patches" description="Creates patch for framework, application, specialpurpose components">
+        <exec executable="svn" output="patches/root.patch" dir="${ofbiz.home.dir}">
+            <arg value="diff"/>
+            <arg value="--depth=files"/>
+        </exec>
         <exec executable="svn" output="patches/framework.patch" dir="${ofbiz.home.dir}">
             <arg value="diff"/>
             <arg value="framework"/>
@@ -50,11 +54,18 @@
             <arg value="diff"/>
             <arg value="specialpurpose"/>
         </exec>
+        <!-- this allow to work correctly on Windows machines without issues on Linux machines -->
+        <fixcrlf srcdir="patches" includes="**/*.patch" eol="crlf" />
     </target>
 
     <target name="revert-ofbiz-patches" description="Remove any local change in the files or any previously applied local patch.">
         <exec executable="svn" dir="${ofbiz.home.dir}">
             <arg value="revert"/>
+          <arg value="--depth=files"/>
+            <arg value="${ofbiz.home.dir}"/>
+        </exec>
+        <exec executable="svn" dir="${ofbiz.home.dir}">
+            <arg value="revert"/>
             <arg value="-R"/>
             <arg value="framework"/>
         </exec>
@@ -76,13 +87,14 @@
                 <or>
                     <not><isset property="component-name"/></not>
                     <not>
-                        <resourcecount count="3">
+                        <resourcecount count="3" when="gt">
                             <fileset dir="patches" includes="*.patch"/>
                         </resourcecount>
                     </not>
                 </or>
             </condition>
         </fail>
+        <patch strip="0" patchfile="patches/root.patch" dir="${ofbiz.home.dir}"/>
         <patch strip="0" patchfile="patches/framework.patch" dir="${ofbiz.home.dir}"/>
         <patch strip="0" patchfile="patches/applications.patch" dir="${ofbiz.home.dir}"/>
         <patch strip="0" patchfile="patches/specialpurpose.patch" dir="${ofbiz.home.dir}"/>
@@ -94,7 +106,7 @@
                 <or>
                     <not><isset property="component-name"/></not>
                     <not>
-                        <resourcecount count="3">
+                        <resourcecount count="3" when="gt">
                             <fileset dir="patches" includes="*.patch"/>
                         </resourcecount>
                     </not>
@@ -104,4 +116,4 @@
         <antcall target="revert-ofbiz-patches"/>
         <antcall target="apply-ofbiz-patches"/>
     </target>
-</project>
\ No newline at end of file
+</project>

Propchange: ofbiz/branches/jackrabbit20100709/framework/security/data/PasswordSecurityData.xml
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Mar 24 07:23:42 2011
@@ -2,3 +2,4 @@
 /ofbiz/branches/dojo1.4/applications/securityext/data/PasswordSecurityData.xml:951708-952957
 /ofbiz/branches/jquery/applications/securityext/data/PasswordSecurityData.xml:952958-1044489
 /ofbiz/branches/multitenant20100310/applications/securityext/data/PasswordSecurityData.xml:921280-927264
+/ofbiz/trunk/framework/security/data/PasswordSecurityData.xml:962442-1084618

Modified: ofbiz/branches/jackrabbit20100709/framework/sql/src/org/ofbiz/sql/Planner.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/sql/src/org/ofbiz/sql/Planner.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/sql/src/org/ofbiz/sql/Planner.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/sql/src/org/ofbiz/sql/Planner.java Thu Mar 24 07:23:42 2011
@@ -37,7 +37,7 @@ public abstract class Planner<P extends 
         }
     }
 
-    public SQLPlan<?> plan(SQLStatement<?> statement) {
+    public <STMNT extends SQLStatement<?>> SQLPlan<?> plan(STMNT statement) {
         if (statement instanceof SQLDelete) return planDelete((SQLDelete) statement);
         if (statement instanceof SQLInsert) return planInsert((SQLInsert) statement);
         if (statement instanceof SQLSelect) return planSelect((SQLSelect) statement);

Modified: ofbiz/branches/jackrabbit20100709/framework/start/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/start/build.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/start/build.xml (original)
+++ ofbiz/branches/jackrabbit20100709/framework/start/build.xml Thu Mar 24 07:23:42 2011
@@ -34,7 +34,7 @@ under the License.
 
     <target name="classes" depends="prepare">
         <!-- compile start -->
-    <javac16 destdir="${build.dir}/classes" srcdir="${src.dir}"/>
+        <javac16 destdir="${build.dir}/classes" srcdir="${src.dir}"/>
     </target>
 
     <target name="jar" depends="classes">

Modified: ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Classpath.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Classpath.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Classpath.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Classpath.java Thu Mar 24 07:23:42 2011
@@ -133,12 +133,36 @@ public class Classpath {
     }
 
     public ClassLoader getClassLoader(ClassLoader parent) {
-        URL[] urls = getUrls();
-
-        return new URLClassLoader(urls, parent);
+        return new NativeLibClassLoader(getUrls(), parent);
     }
 
     public List<File> getElements() {
         return _elements;
     }
+
+    /*
+     * Native library class loader. This class is necessary because the
+     * bootstrap ClassLoader caches the native library path - so any
+     * changes to the library path are ignored (changes that might have
+     * been made by loading OFBiz components). 
+     */
+    private class NativeLibClassLoader extends URLClassLoader {
+
+        private NativeLibClassLoader(URL[] urls, ClassLoader parent) {
+            super(urls, parent);
+        }
+        
+        @Override
+        protected String findLibrary(String libname) {
+            String[] libPaths = System.getProperty("java.library.path").split(File.pathSeparator);
+            String libFileName = System.mapLibraryName(libname);
+            for (String path : libPaths) {
+                File libFile = new File(path, libFileName);
+                if (libFile.exists()) {
+                    return libFile.getAbsolutePath();
+                }
+            }
+            return null;
+        }
+    }
 }

Modified: ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Start.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Start.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Start.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/Start.java Thu Mar 24 07:23:42 2011
@@ -50,7 +50,7 @@ public class Start implements Runnable {
     private boolean serverStarted = false;
     private boolean serverStopping = false;
     private boolean serverRunning = true;
-    private List<StartupLoader> loaders = null;
+    private List<StartupLoader> loaders = new ArrayList<StartupLoader>();
     private Config config = null;
     private String[] loaderArgs = null;
 
@@ -70,16 +70,15 @@ public class Start implements Runnable {
         String firstArg = args.length > 0 ? args[0] : "";
         String cfgFile = Start.getConfigFileName(firstArg);
 
-        this.loaders = new ArrayList<StartupLoader>();
         this.config = new Config();
 
         // read the default properties first
         config.readConfig(cfgFile);
 
         // parse the startup arguments
-        if (args.length > 1) {
-            this.loaderArgs = new String[args.length - 1];
-            System.arraycopy(args, 1, this.loaderArgs, 0, this.loaderArgs.length);
+        if (args.length > 0) {
+            this.loaderArgs = new String[args.length];
+            System.arraycopy(args, 0, this.loaderArgs, 0, this.loaderArgs.length);
         }
 
         if (fullInit) {
@@ -92,15 +91,15 @@ public class Start implements Runnable {
             // initialize the listener thread
             initListenerThread();
 
-            // initialize the startup loaders
-            initStartLoaders();
-
             // set the shutdown hook
             if (config.useShutdownHook) {
                 setShutdownHook();
             } else {
                 System.out.println("Shutdown hook disabled");
             }
+
+            // initialize the startup loaders
+            initStartLoaders();
         }
     }
 
@@ -251,31 +250,41 @@ public class Start implements Runnable {
     }
 
     private void initStartLoaders() {
-        // initialize the loaders
-        for (String loaderClassName: config.loaders) {
-            try {
-                Class<?> loaderClass = classloader.loadClass(loaderClassName);
-                StartupLoader loader = (StartupLoader) loaderClass.newInstance();
-                loader.load(config, loaderArgs);
-                loaders.add(loader);
-            } catch (Exception e) {
-                e.printStackTrace();
-                System.exit(99);
+        synchronized (this.loaders) {
+            // initialize the loaders
+            for (String loaderClassName: config.loaders) {
+                if (this.serverStopping) {
+                    return;
+                }
+                try {
+                    Class<?> loaderClass = classloader.loadClass(loaderClassName);
+                    StartupLoader loader = (StartupLoader) loaderClass.newInstance();
+                    loader.load(config, loaderArgs);
+                    this.loaders.add(loader);
+                } catch (Exception e) {
+                    e.printStackTrace();
+                    System.exit(99);
+                }
             }
         }
     }
 
     private void startStartLoaders() {
-        // start the loaders
-        for (StartupLoader loader: loaders) {
-            try {
-                loader.start();
-            } catch (StartupException e) {
-                e.printStackTrace();
-                System.exit(99);
+        synchronized (this.loaders) {
+            // start the loaders
+            for (StartupLoader loader: this.loaders) {
+                if (this.serverStopping) {
+                    return;
+                }
+                try {
+                    loader.start();
+                } catch (StartupException e) {
+                    e.printStackTrace();
+                    System.exit(99);
+                }
             }
+            serverStarted = true;
         }
-        serverStarted = true;
     }
 
     private void setShutdownHook() {
@@ -305,8 +314,10 @@ public class Start implements Runnable {
     private void shutdownServer() {
         if (serverStopping) return;
         serverStopping = true;
-        if (loaders != null && loaders.size() > 0) {
-            for (StartupLoader loader: loaders) {
+        synchronized (this.loaders) {
+            // Unload in reverse order
+            for (int i = this.loaders.size(); i > 0; i--) {
+                StartupLoader loader = this.loaders.get(i - 1);
                 try {
                     loader.unload();
                 } catch (Exception e) {
@@ -334,6 +345,7 @@ public class Start implements Runnable {
         shutdownServer();
     }
 
+    /* This method is a bad idea.
     public void destroy() {
         this.serverSocket = null;
         this.serverThread = null;
@@ -341,6 +353,7 @@ public class Start implements Runnable {
         this.config = null;
         this.loaderArgs = null;
     }
+    */
 
     public String shutdown() throws IOException {
         return sendSocketCommand(Start.SHUTDOWN_COMMAND);

Modified: ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/StartupLoader.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/StartupLoader.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/StartupLoader.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/start/src/org/ofbiz/base/start/StartupLoader.java Thu Mar 24 07:23:42 2011
@@ -19,30 +19,44 @@
 package org.ofbiz.base.start;
 
 /**
- * StartupLoader - Interface for loading server startup classes
- *
+ * An object that loads server startup classes.
+ * <p>
+ * When OFBiz starts, the main thread will create the <code>StartupLoader</code> instance and
+ * then call the loader's <code>load</code> method. If the method returns without
+ * throwing an exception the loader will be added to a list of initialized loaders.
+ * After all instances have been created and initialized, the main thread will call the
+ * <code>start</code> method of each loader in the list. When OFBiz shuts down, a
+ * separate shutdown thread will call the <code>unload</code> method of each loader.
+ * Implementations should anticipate asynchronous calls to the methods by different
+ * threads.
+ * </p>
+ * 
  */
 public interface StartupLoader {
 
     /**
-     * Load a startup class
+     * Load a startup class.
      *
-     * @param config Startup config
-     * @param args Input arguments
-     * @throws StartupException
+     * @param config Startup config.
+     * @param args Command-line arguments.
+     * @throws StartupException If an error was encountered. Throwing this exception
+     * will halt loader loading, so it should be thrown only when OFBiz can't
+     * operate without it.
      */
     public void load(Start.Config config, String args[]) throws StartupException;
 
     /**
-     * Start the startup class
-     * @throws StartupException
+     * Start the startup class. This method must not block - implementations
+     * that require thread blocking must create a separate thread and then return.
+     * 
+     * @throws StartupException If an error was encountered.
      */
     public void start() throws StartupException;
 
     /**
-     * Stop the container
+     * Stop the startup class. This method must not block.
      *
-     * @throws StartupException
+     * @throws StartupException If an error was encountered.
      */
     public void unload() throws StartupException;
 }

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/build.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/build.xml (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/build.xml Thu Mar 24 07:23:42 2011
@@ -81,9 +81,20 @@ under the License.
     </target>
     
     <target name="install-seleniumxml" depends="init" description="Download the selenium files">
-        <!--mkdir dir="${selenium.lib.dir}"/-->
-        <!-- Note: If the download path changes please also update the urlSite field in VerifySeleniumSteups.java -->
-        <get src="http://downloads.sourceforge.net/seleniumxml/selenium-server-1.0.2-SNAPSHOT-standalone.jar?use_mirror="
-            dest="${selenium.lib.dir}/selenium-server.jar" usetimestamp="true" />
+        <!--
+            Quick way to download and extract the selenium-server.jar
+            If someone has a better way to do the same, please suggest !
+        -->
+        <get src="http://selenium.googlecode.com/files/selenium-remote-control-1.0.3.zip"
+             dest="${selenium.lib.dir}/selenium-remote-control-1.0.3.zip" usetimestamp="true" verbose="true"/>
+        <unzip src="${selenium.lib.dir}/selenium-remote-control-1.0.3.zip"
+                dest="${selenium.lib.dir}">
+            <patternset>
+                <include name="selenium-server-1.0.3/selenium-server.jar"/>
+            </patternset>
+        </unzip>
+        <move file="${selenium.lib.dir}/selenium-server-1.0.3/selenium-server.jar" todir="${selenium.lib.dir}"/>
+        <delete dir="${selenium.lib.dir}/selenium-server-1.0.3"/>
+        <delete file="${selenium.lib.dir}/selenium-remote-control-1.0.3.zip"/>
     </target>
 </project>

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/config/seleniumXml.properties
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/config/seleniumXml.properties?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/config/seleniumXml.properties (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/config/seleniumXml.properties Thu Mar 24 07:23:42 2011
@@ -18,8 +18,13 @@
 ###############################################################################
 serverHost=localhost
 proxyPort=4444
-#for debian, use the following line
+#for Debian, use the following line
 #browser=*firefox /usr/lib/iceweasel/firefox-bin
+#for Windows (default install, you can override by setting the Java system property firefoxDefaultPath to the correct path to Firefox)
+#browser=*firefox
 browser=*firefox /usr/lib/firefox-3.0.8/firefox
 startUrl=http://localhost:8080/
 log4jFile=./config/log4j.properties
+
+# --- Allow to use Selenium in Webtools with or without Internet access
+internet.access=true

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/data/helpdata/HELP_WEBTOOLS_selenium.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/data/helpdata/HELP_WEBTOOLS_selenium.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/data/helpdata/HELP_WEBTOOLS_selenium.xml (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/data/helpdata/HELP_WEBTOOLS_selenium.xml Thu Mar 24 07:23:42 2011
@@ -7,9 +7,9 @@
     to you under the Apache License, Version 2.0 (the
     "License"); you may not use this file except in compliance
     with the License.  You may obtain a copy of the License at
-    
+
     http://www.apache.org/licenses/LICENSE-2.0
-    
+
     Unless required by applicable law or agreed to in writing,
     software distributed under the License is distributed on an
     "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -19,7 +19,7 @@
 -->
 <section xmlns="http://docbook.org/ns/docbook" xmlns:xl="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://docbook.org/ns/docbook ../../../../applications/content/dtd/docbook.xsd">
-    <title>OFBiz SeleniumXml</title>
+    <title><anchor xml:id="OFBizSeleniumXml"/>OFBiz SeleniumXml</title>
     <para> This is a short document to help you get started using SeleniumXml to test your OFBiz application. Here is a <link
             xl:href="http://us.apachecon.com/presentation/materials/118/ApacheCon2008_SeleniumXml.pdf">copy of the presentation</link> that was given
         at the ApacheCon2008 OFBiz Conference that describes more about the project. </para>

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/entitydef/entitymodel.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/entitydef/entitymodel.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/entitydef/entitymodel.xml (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/entitydef/entitymodel.xml Thu Mar 24 07:23:42 2011
@@ -31,10 +31,11 @@
         package-name="org.ofbiz.selenium.test"
         default-resource-name="ExampleEntityLabels"
         title="Selenium Test suite file">
-        <field name="testSuiteId" type="id-ne"></field>
-        <field name="testSuiteName" type="name"></field>
-        <field name="testSuitePath" type="description"></field>
-        <field name="description" type="very-long"></field>
+        <field name="testSuiteId" type="id-ne"/>
+        <field name="testSuiteName" type="name"/>
+        <field name="testSuiteType" type="id"/>
+        <field name="testSuitePath" type="description"/>
+        <field name="description" type="very-long"/>
         <prim-key field="testSuiteId"/>
     </entity>
 </entitymodel>

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/VerifySeleniumSetups.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/VerifySeleniumSetups.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/VerifySeleniumSetups.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/VerifySeleniumSetups.java Thu Mar 24 07:23:42 2011
@@ -69,24 +69,43 @@ public class VerifySeleniumSetups {
     public static String verifyConfig(HttpServletRequest request, HttpServletResponse response){
         boolean lib = false;
         boolean urlset = false;
+        boolean internetAccess = false;
         Map<String,Object> msgMap = FastMap.newInstance();
         Properties urlProps = null;
+        Properties testProps = null;
         try{
-            /* Check and down load selenium-server.jar */
-            File file = new File(libPath);
-            URL url = new URL(urlSite);
-            URLConnection connection = url.openConnection();
-            contentLength = connection.getContentLength();
-            if (contentLength == -1) {
-                request.setAttribute("_ERROR_MESSAGE_", "can not conect to the internet");
+            /* Check and download selenium-server.jar */
+            URL testProp = UtilURL.fromResource("seleniumXml.properties");
+            if (testProps == null) {
+                testProps = new Properties();
+                if (testProp == null) {
+                    String errMsg = "Cannot resolve location from test.properties.";
+                    throw new MalformedURLException(errMsg);
+                }
             }
-            Debug.log("file size. "+contentLength,module);
-            if (file.exists()) {
-                if (contentLength == file.length()) {
-                    lib = true;
-                } else lib = false;
+            internetAccess = UtilProperties.getPropertyAsBoolean("seleniumXml", "internet.access", true);
+            File file = new File(libPath);
+            if (internetAccess) {
+                URL url = new URL(urlSite);
+                URLConnection connection = url.openConnection();
+                contentLength = connection.getContentLength();
+                if (contentLength == -1) {
+                    request.setAttribute("_ERROR_MESSAGE_", "can not conect to the internet");
+                }
+                Debug.log("file size. "+contentLength,module);
+                if (file.exists()) {
+                    if (contentLength == file.length()) {
+                        lib = true;
+                    } else lib = false;
+                    msgMap.put("LIBFLAG",lib);
+                }
+            } else {
+                if (file.exists()) {
+                    msgMap.put("LIBFLAG",true);
+                } else {
+                    msgMap.put("LIBFLAG", "noInternet");
+                }
             }
-            msgMap.put("LIBFLAG",lib);
 
             /* Check a change use HTTP as the default */
             String httpStatus = null;

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/SeleniumXml.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/SeleniumXml.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/SeleniumXml.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/SeleniumXml.java Thu Mar 24 07:23:42 2011
@@ -356,7 +356,7 @@ public class SeleniumXml {
 
         Method m;
         try {
-            m = (Method) this.sel.getClass().getDeclaredMethod(methodName, paramTypes);
+            m = this.sel.getClass().getDeclaredMethod(methodName, paramTypes);
             Object results = m.invoke(this.sel, args);
 
             //Add output parameter to common map

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/TestCaseException.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/TestCaseException.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/TestCaseException.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/src/org/ofbiz/testtools/seleniumxml/TestCaseException.java Thu Mar 24 07:23:42 2011
@@ -24,6 +24,7 @@ import org.ofbiz.base.util.GeneralExcept
  * GenericConfigException
  *
  */
+@SuppressWarnings("serial")
 public class TestCaseException extends GeneralException {
 
     public TestCaseException() {

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/testdef/seleniumxml/example/recorded/NewExample.html
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/testdef/seleniumxml/example/recorded/NewExample.html?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/testdef/seleniumxml/example/recorded/NewExample.html (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/testdef/seleniumxml/example/recorded/NewExample.html Thu Mar 24 07:23:42 2011
@@ -41,6 +41,11 @@
 </tr>
 <tr>
     <td>type</td>
+    <td>USERNAME</td>
+    <td>admin</td>
+</tr>
+<tr>
+    <td>type</td>
     <td>PASSWORD</td>
     <td>ofbiz</td>
 </tr>
@@ -50,83 +55,78 @@
     <td></td>
 </tr>
 <tr>
-    <td>clickAndWait</td>
+    <td>click</td>
     <td>link=New Example</td>
     <td></td>
 </tr>
 <tr>
+    <td>waitForElementPresent</td>
+    <td>EditExample_statusId</td>
+    <td></td>
+</tr>
+<tr>
     <td>select</td>
-    <td>statusId</td>
+    <td>EditExample_statusId</td>
     <td>label=Defined</td>
 </tr>
 <tr>
     <td>type</td>
-    <td>exampleName</td>
+    <td>EditExample_exampleName</td>
     <td>New Example 1</td>
 </tr>
 <tr>
     <td>type</td>
-    <td>description</td>
+    <td>EditExample_description</td>
     <td>This is a description</td>
 </tr>
 <tr>
     <td>type</td>
-    <td>longDescription</td>
+    <td>EditExample_longDescription</td>
     <td>Long description goes here</td>
 </tr>
 <tr>
     <td>type</td>
-    <td>comments</td>
+    <td>EditExample_comments</td>
     <td>comments go here</td>
 </tr>
 <tr>
     <td>type</td>
-    <td>exampleSize</td>
+    <td>EditExample_exampleSize</td>
     <td>10</td>
 </tr>
 <tr>
     <td>click</td>
-    <td>//img[@alt='View Calendar']</td>
+    <td>//button[@class='ui-datepicker-trigger'][1]</td>
     <td></td>
 </tr>
 <tr>
     <td>click</td>
-    <td>//tr[2]/td[5]/div</td>
+    <td>//button[contains(text(),'Now')]</td>
     <td></td>
 </tr>
 <tr>
     <td>click</td>
-    <td>//tr[2]/td[5]/div</td>
+    <td>//button[contains(text(),'Done')]</td>
     <td></td>
 </tr>
 <tr>
-    <td>click</td>
-    <td>//div[@id='_G152__body']/table/tbody/tr[9]/td[2]/a/img</td>
-    <td></td>
-</tr>
-<tr>
-    <td>click</td>
-    <td>//tr[3]/td[2]/div</td>
-    <td></td>
+    <td>select</td>
+    <td>EditExample_anotherText</td>
+    <td>label=Contrived</td>
 </tr>
 <tr>
-    <td>click</td>
-    <td>//tr[3]/td[2]/div</td>
+    <td>clickAndWait</td>
+    <td>submitButton</td>
     <td></td>
 </tr>
 <tr>
-    <td>click</td>
-    <td>link=OK</td>
+    <td>waitForElementPresent</td>
+    <td>//div[@id='search-results']//a[@class='buttontext']</td>
     <td></td>
 </tr>
 <tr>
-    <td>select</td>
-    <td>anotherText</td>
-    <td>label=Good</td>
-</tr>
-<tr>
     <td>clickAndWait</td>
-    <td>submitButton</td>
+    <td>//div[@id='search-results']//a[@class='buttontext']</td>
     <td></td>
 </tr>
 <tr>
@@ -151,15 +151,14 @@
 </tr>
 <tr>
     <td>clickAndWait</td>
-    <td>submitButton</td>
+    <td>//input[@name='submitButton' and @value='Add']</td>
     <td></td>
 </tr>
 <tr>
-    <td>clickAndWait</td>
-    <td>link=New Example</td>
+    <td>assertConfirmation</td>
+    <td>Do you confirm ?</td>
     <td></td>
 </tr>
-
 </tbody></table>
 </body>
 </html>

Modified: ofbiz/branches/jackrabbit20100709/framework/testtools/webapp/testtools/SeleniumTest.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/testtools/webapp/testtools/SeleniumTest.ftl?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/testtools/webapp/testtools/SeleniumTest.ftl (original)
+++ ofbiz/branches/jackrabbit20100709/framework/testtools/webapp/testtools/SeleniumTest.ftl Thu Mar 24 07:23:42 2011
@@ -34,7 +34,9 @@ under the License.
           <td>- selenium_server.jar </td>
           <td>
                 <#if libcheck == "true">
-                    success
+                    Success
+                <#elseif libcheck == "noInternet">
+                    Download and install selenium-server.jar in framework/testtools/lib (see in VerifySeleniumSetups.java)
                 <#else>
                     <div style="color:red;" id="message">please click download this lib for run the selenium application!</div>
                     <div id="loadpercent"><a id="download" href="javascript:clickDownLoad('<@o...@ofbizUrl>');" class="buttontext">download</a></div>
@@ -47,14 +49,14 @@ under the License.
           <td>- Changes ofbiz to use HTTP as the default at file (framework/webapp/config/url.properties)</td>
           <td>
                 <#if  urlcheck == "true">
-                    success
+                    Success
                 <#else>
                     <div style="color:red;">Not success!</div>
                 </#if>
           </td>
         </tr>
         <tr>
-          <td> 
+          <td>
             <ol>
             <li>Edit 'framework/testtools/config/seleniumXml.properties' and  add your firefox path, replace the example in the file</li>
             <li>Then save and restart ofbiz.</li>
@@ -112,4 +114,4 @@ under the License.
             }
         });
     }
-</script>
\ No newline at end of file
+</script>

Modified: ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java Thu Mar 24 07:23:42 2011
@@ -490,14 +490,7 @@ public class ContextFilter implements Fi
     }
 
     protected Container getContainers() throws ServletException {
-        Container rmiLoadedContainer = null;
-        try {
-            rmiLoadedContainer = ContainerLoader.loadContainers(CONTAINER_CONFIG, null); // used in Geronimo/WASCE to allow to unregister
-        } catch (StartupException e) {
-            Debug.logError(e, module);
-            throw new ServletException("Unable to load containers; cannot start ContextFilter");
-        }
-        return rmiLoadedContainer;
+        return ContainerLoader.getContainer("rmi-dispatcher");
     }
 
     // used in Geronimo/WASCE to allow to deregister

Modified: ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ProtectViewWorker.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ProtectViewWorker.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ProtectViewWorker.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/ProtectViewWorker.java Thu Mar 24 07:23:42 2011
@@ -94,7 +94,7 @@ public class ProtectViewWorker {
                         durationByViewAccessed.put(viewNameUserLoginId, now + maxHitsDuration);
                     } else {
                         Long maxDuration = durationByViewAccessed.get(viewNameUserLoginId);
-                        Long newMaxHits = (Long) curMaxHits + one;
+                        Long newMaxHits = curMaxHits + one;
                         hitsByViewAccessed.put(viewNameUserLoginId, newMaxHits);
                         // Are we in a period of time where we need to check if there was too much hits ?
                         if (now < maxDuration) {

Modified: ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java Thu Mar 24 07:23:42 2011
@@ -700,7 +700,7 @@ public class RequestHandler {
         Enumeration<String> attributeNameEnum = UtilGenerics.cast(req.getAttributeNames());
         Map<String, Object> reqAttrMap = FastMap.newInstance();
         while (attributeNameEnum.hasMoreElements()) {
-            String name = (String) attributeNameEnum.nextElement();
+            String name = attributeNameEnum.nextElement();
             Object obj = req.getAttribute(name);
             if (obj instanceof Serializable) {
                 reqAttrMap.put(name, obj);

Modified: ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/event/SOAPEventHandler.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/event/SOAPEventHandler.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/event/SOAPEventHandler.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/event/SOAPEventHandler.java Thu Mar 24 07:23:42 2011
@@ -48,14 +48,14 @@ import org.ofbiz.base.util.Debug;
 import org.ofbiz.base.util.UtilGenerics;
 import org.ofbiz.base.util.UtilXml;
 import org.ofbiz.entity.GenericDelegator;
-import org.ofbiz.service.engine.SoapSerializer;
 import org.ofbiz.service.DispatchContext;
 import org.ofbiz.service.GenericServiceException;
 import org.ofbiz.service.LocalDispatcher;
 import org.ofbiz.service.ModelService;
-import org.ofbiz.webapp.control.RequestHandler;
+import org.ofbiz.service.engine.SoapSerializer;
 import org.ofbiz.webapp.control.ConfigXMLReader.Event;
 import org.ofbiz.webapp.control.ConfigXMLReader.RequestMap;
+import org.ofbiz.webapp.control.RequestHandler;
 import org.w3c.dom.Document;
 
 /**
@@ -168,72 +168,100 @@ public class SOAPEventHandler implements
         Debug.logVerbose("[Processing]: SOAP Event", module);
 
         try {
-            // each is a different service call
             SOAPBody reqBody = reqEnv.getBody();
-            Iterator<Object> serviceIter = UtilGenerics.cast(reqBody.getChildElements());
-            while (serviceIter.hasNext()) {
-                Object serviceObj = serviceIter.next();
-                if (serviceObj instanceof OMElement) {
-                    OMElement serviceElement = (OMElement) serviceObj;
-                    String serviceName = serviceElement.getLocalName();
-                    Map<String, Object> parameters = UtilGenerics.cast(SoapSerializer.deserialize(serviceElement.toString(), delegator));
-                    try {
-                        // verify the service is exported for remote execution and invoke it
-                        ModelService model = dispatcher.getDispatchContext().getModelService(serviceName);
+            validateSOAPBody(reqBody);
+            OMElement serviceElement = reqBody.getFirstElement();
+            String serviceName = serviceElement.getLocalName();
+            Map<String, Object> parameters = UtilGenerics.cast(SoapSerializer.deserialize(serviceElement.toString(), delegator));
+            try {
+                // verify the service is exported for remote execution and invoke it
+                ModelService model = dispatcher.getDispatchContext().getModelService(serviceName);
+
+                if (model == null) {
+                    sendError(response, "Problem processing the service");
+                    Debug.logError("Could not find Service [" + serviceName + "].", module);
+                    return null;
+                }
 
-                        if (model != null && model.export) {
-                            Map<String, Object> results = dispatcher.runSync(serviceName, parameters);
-                            Debug.logVerbose("[EventHandler] : Service invoked", module);
-
-                            // setup the response
-                            Debug.logVerbose("[EventHandler] : Setting up response message", module);
-                            String xmlResults = SoapSerializer.serialize(results);
-                            XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(new StringReader(xmlResults));
-                            StAXOMBuilder resultsBuilder = new StAXOMBuilder(reader);
-                            OMElement resultSer = resultsBuilder.getDocumentElement();
-
-                            // create the response soap
-                            SOAPFactory factory = OMAbstractFactory.getSOAP11Factory();
-                            SOAPEnvelope resEnv = factory.createSOAPEnvelope();
-                            SOAPBody resBody = factory.createSOAPBody();
-                            OMElement resService = factory.createOMElement(new QName(serviceName + "Response"));
-                            resService.addChild(resultSer.getFirstElement());
-                            resBody.addChild(resService);
-                            resEnv.addChild(resBody);
-
-                            // The declareDefaultNamespace method doesn't work see (https://issues.apache.org/jira/browse/AXIS2-3156)
-                            // so the following doesn't work:
-                            // resService.declareDefaultNamespace(ModelService.TNS);
-                            // instead, create the xmlns attribute directly:
-                            OMAttribute defaultNS = factory.createOMAttribute("xmlns", null, ModelService.TNS);
-                            resService.addAttribute(defaultNS);
-
-                            // log the response message
-                            if (Debug.verboseOn()) {
-                                try {
-                                    Debug.log("Response Message:\n" + resEnv + "\n", module);
-                                } catch (Throwable t) {
-                                }
-                            }
+                if (!model.export) {
+                    sendError(response, "Problem processing the service");
+                    Debug.logError("Trying to call Service [" + serviceName + "] that is not exported.", module);
+                    return null;
+                }
 
-                            resEnv.serialize(response.getOutputStream());
-                            response.getOutputStream().flush();
-                        }
+                Map<String, Object> serviceResults = dispatcher.runSync(serviceName, parameters);
+                Debug.logVerbose("[EventHandler] : Service invoked", module);
 
-                    } catch (GenericServiceException e) {
-                        //sendError(response, "Problem processing the service"); this causes a not a valid XML response. See https://issues.apache.org/jira/browse/OFBIZ-4207
-                        throw new EventHandlerException(e.getMessage(), e);
-                    }
-                }
+                createAndSendSOAPResponse(serviceResults, serviceName, response);
+
+            } catch (GenericServiceException e) {
+                sendError(response, "Problem processing the service");
+                Debug.logError(e, module);
+                return null;
             }
         } catch (Exception e) {
             sendError(response, e.getMessage());
-            throw new EventHandlerException(e.getMessage(), e);
+            Debug.logError(e, module);
+            return null;
         }
 
         return null;
     }
 
+    private void validateSOAPBody(SOAPBody reqBody) throws EventHandlerException {
+        // ensure the SOAPBody contains only one service call request
+        Integer numServiceCallRequests = 0;
+        Iterator<Object> serviceIter = UtilGenerics.cast(reqBody.getChildElements());
+        while (serviceIter.hasNext()) {
+            numServiceCallRequests++;
+            serviceIter.next();
+        }
+        if (numServiceCallRequests != 1) {
+            throw new EventHandlerException("One service call expected, but received: " + numServiceCallRequests.toString());
+        }
+    }
+
+    private void createAndSendSOAPResponse(Map<String, Object> serviceResults, String serviceName, HttpServletResponse response) throws EventHandlerException {
+        try {
+        // setup the response
+            Debug.logVerbose("[EventHandler] : Setting up response message", module);
+            String xmlResults = SoapSerializer.serialize(serviceResults);
+            XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(new StringReader(xmlResults));
+            StAXOMBuilder resultsBuilder = new StAXOMBuilder(reader);
+            OMElement resultSer = resultsBuilder.getDocumentElement();
+
+            // create the response soap
+            SOAPFactory factory = OMAbstractFactory.getSOAP11Factory();
+            SOAPEnvelope resEnv = factory.createSOAPEnvelope();
+            SOAPBody resBody = factory.createSOAPBody();
+            OMElement resService = factory.createOMElement(new QName(serviceName + "Response"));
+            resService.addChild(resultSer.getFirstElement());
+            resBody.addChild(resService);
+            resEnv.addChild(resBody);
+
+            // The declareDefaultNamespace method doesn't work see (https://issues.apache.org/jira/browse/AXIS2-3156)
+            // so the following doesn't work:
+            // resService.declareDefaultNamespace(ModelService.TNS);
+            // instead, create the xmlns attribute directly:
+            OMAttribute defaultNS = factory.createOMAttribute("xmlns", null, ModelService.TNS);
+            resService.addAttribute(defaultNS);
+            
+            // log the response message
+            if (Debug.verboseOn()) {
+                try {
+                    Debug.log("Response Message:\n" + resEnv + "\n", module);
+                } catch (Throwable t) {
+                }
+            }
+
+            resEnv.serialize(response.getOutputStream());
+            response.getOutputStream().flush();
+        } catch (Exception e) {
+            Debug.logError(e, module);
+            throw new EventHandlerException(e.getMessage(), e);
+        }
+    }
+
     private void sendError(HttpServletResponse res, String errorMessage) throws EventHandlerException {
         try {
             // setup the response

Modified: ofbiz/branches/jackrabbit20100709/framework/webtools/widget/CommonScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/webtools/widget/CommonScreens.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/webtools/widget/CommonScreens.xml (original)
+++ ofbiz/branches/jackrabbit20100709/framework/webtools/widget/CommonScreens.xml Thu Mar 24 07:23:42 2011
@@ -43,19 +43,7 @@ under the License.
                 <set field="applicationTitle" value="${uiLabelMap.FrameworkWebTools}" global="true"/>
             </actions>
             <widgets>
-                <decorator-screen name="GlobalDecorator" location="component://common/widget/CommonScreens.xml">
-                    <decorator-section name="pre-body">
-                        <decorator-section-include name="pre-body"/>
-                    </decorator-section>
-                    <decorator-section name="body">
-                        <container id="column-container">
-                            <container id="content-main-section">
-                                <decorator-section-include name="body"/>
-                            </container>
-                            <container style="clear"></container>
-                        </container>
-                    </decorator-section>
-                </decorator-screen>                
+                <include-screen name="GlobalDecorator" location="component://common/widget/CommonScreens.xml"/>
             </widgets>
         </section>
     </screen>

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/dtd/widget-form.xsd
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/dtd/widget-form.xsd?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/dtd/widget-form.xsd (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/dtd/widget-form.xsd Thu Mar 24 07:23:42 2011
@@ -656,6 +656,15 @@ under the License.
                 </xs:restriction>
             </xs:simpleType>
         </xs:attribute>
+        <xs:attribute name="mask" default="N">
+            <xs:annotation><xs:documentation>Will use the type value if set to yes, add a masked input</xs:documentation></xs:annotation>
+            <xs:simpleType>
+                <xs:restriction base="xs:token">
+                    <xs:enumeration value="Y"/>
+                    <xs:enumeration value="N"/>
+                </xs:restriction>
+            </xs:simpleType>
+        </xs:attribute>
     </xs:attributeGroup>
     <xs:element name="display" substitutionGroup="AllFields">
         <xs:complexType>
@@ -707,7 +716,7 @@ under the License.
         <xs:attribute type="xs:string" name="image-location">
             <xs:annotation><xs:documentation>Specifies the image to display.</xs:documentation></xs:annotation>
         </xs:attribute>
-        <xs:attribute type="xs:string" name="default-value">        
+        <xs:attribute type="xs:string" name="default-value">
             <xs:annotation><xs:documentation>Specifies a string to be displayed if the field is empty.</xs:documentation></xs:annotation>
         </xs:attribute>
     </xs:attributeGroup>
@@ -945,10 +954,10 @@ under the License.
         <xs:attribute type="xs:positiveInteger" name="maxlength"/>
         <xs:attribute type="xs:string" name="default-value"/>
         <xs:attribute type="xs:string" name="description-field-name">
-            <xs:annotation><xs:documentation>The name of a field whose value is also filled when coming back from lookup selection.</xs:documentation></xs:annotation>            
+            <xs:annotation><xs:documentation>The name of a field whose value is also filled when coming back from lookup selection.</xs:documentation></xs:annotation>
         </xs:attribute>
         <xs:attribute type="xs:string" name="target-parameter">
-            <xs:annotation><xs:documentation>The name of a field whose value is passed in as a parameter to the lookup target form. Can be a comma separated list. You need to affect it the value using parameters.parmI (where I is the position number in the list) in the related lookup screen. See LookupPreferredContactMech as example</xs:documentation></xs:annotation>
+            <xs:annotation><xs:documentation>The name of a field whose value is passed in as a parameter to the lookup target form. Can be a comma separated list. You need to affect it the value using parameters.parmI (where I is the position number in the list, begins at 1) in the related lookup screen. See LookupPreferredContactMech as example</xs:documentation></xs:annotation>
         </xs:attribute>
         <xs:attribute name="client-autocomplete-field" default="true">
             <xs:annotation><xs:documentation>Tells the browser whether or not to try and autocomplete with values previously entered. Default to true.</xs:documentation></xs:annotation>
@@ -1151,6 +1160,9 @@ under the License.
                 </xs:restriction>
             </xs:simpleType>
         </xs:attribute>
+        <xs:attribute name="mask" type="xs:string">
+            <xs:annotation><xs:documentation>Defines a customized input mask. Use 9 for numeric, a for alpha and * for alphanumeric character.</xs:documentation></xs:annotation>
+        </xs:attribute>
     </xs:attributeGroup>
     <xs:element name="textarea" substitutionGroup="AllFields">
         <xs:complexType>

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java Thu Mar 24 07:23:42 2011
@@ -333,6 +333,7 @@ public class MacroFormRenderer implement
         String name = modelFormField.getParameterName(context);
         String className = "";
         String alert = "false";
+        String mask = "";
         if (UtilValidate.isNotEmpty(modelFormField.getWidgetStyle())) {
             className = modelFormField.getWidgetStyle();
             if (modelFormField.shouldBeRed(context)) {
@@ -357,6 +358,10 @@ public class MacroFormRenderer implement
             clientAutocomplete = "true";
         }
 
+        if (UtilValidate.isNotEmpty(textField.getMask())) {
+            mask = textField.getMask();
+        }
+
         String ajaxUrl = createAjaxParamsFromUpdateAreas(updateAreas, null, context);
         boolean disabled = textField.disabled;
 
@@ -393,7 +398,9 @@ public class MacroFormRenderer implement
         sr.append(ajaxUrl);
         sr.append("\" ajaxEnabled=");
         sr.append(Boolean.toString(ajaxEnabled));
-        sr.append(" />");
+        sr.append(" mask=\"");
+        sr.append(mask);
+        sr.append("\" />");
         executeMacro(writer, sr.toString());
 
         ModelFormField.SubHyperlink subHyperlink = textField.getSubHyperlink();
@@ -474,6 +481,7 @@ public class MacroFormRenderer implement
         String className = "";
         String alert = "false";
         String name = "";
+        String formattedMask = "";
         String event = modelFormField.getEvent();
         String action = modelFormField.getAction(context);
         if (UtilValidate.isNotEmpty(modelFormField.getWidgetStyle())) {
@@ -610,6 +618,16 @@ public class MacroFormRenderer implement
                 ampmName = UtilHttp.makeCompositeParam(paramName, "ampm");
             }
         }
+        String mask = dateTimeField.getMask();
+        if ("Y".equals(mask)) {
+            if ("date".equals(dateTimeField.getType())) {
+                formattedMask = "9999-99-99";
+            } else if ("time".equals(dateTimeField.getType())) {
+                formattedMask = "99:99:99";
+            } else if ("timestamp".equals(dateTimeField.getType())) {
+                formattedMask = "9999-99-99 99:99:99";
+            }
+        }
         StringWriter sr = new StringWriter();
         sr.append("<@renderDateTimeField ");
         sr.append("name=\"");
@@ -676,6 +694,8 @@ public class MacroFormRenderer implement
         sr.append(compositeType);
         sr.append("\" formName=\"");
         sr.append(formName);
+        sr.append("\" mask=\"");
+        sr.append(formattedMask);
         sr.append("\" />");
         executeMacro(writer, sr.toString());
         this.addAsterisks(writer, context, modelFormField);
@@ -2214,7 +2234,7 @@ public class MacroFormRenderer implement
 
         String anchor = "";
         String paginateAnchor = modelForm.getPaginateTargetAnchor();
-        if (paginateAnchor != null) anchor = "#" + paginateAnchor;
+        if (UtilValidate.isNotEmpty(paginateAnchor)) anchor = "#" + paginateAnchor;
 
         // Create separate url path String and request parameters String,
         // add viewIndex/viewSize parameters to request parameter String

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelForm.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelForm.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelForm.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelForm.java Thu Mar 24 07:23:42 2011
@@ -315,6 +315,10 @@ public class ModelForm extends ModelWidg
                     this.fieldList.add(childField);
                     this.fieldMap.put(childField.getName(), childField);
                 }
+
+                this.fieldGroupMap = parent.fieldGroupMap;
+                this.fieldGroupList = parent.fieldGroupList;
+
             }
         }
 

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java Thu Mar 24 07:23:42 2011
@@ -2833,6 +2833,7 @@ public class ModelFormField {
         protected SubHyperlink subHyperlink;
         protected boolean disabled;
         protected boolean clientAutocompleteField;
+        protected String mask;
 
         protected TextField() {
             super();
@@ -2849,6 +2850,7 @@ public class ModelFormField {
         public TextField(Element element, ModelFormField modelFormField) {
             super(element, modelFormField);
             this.setDefaultValue(element.getAttribute("default-value"));
+            this.mask = element.getAttribute("mask");
 
             String sizeStr = element.getAttribute("size");
             try {
@@ -2943,6 +2945,10 @@ public class ModelFormField {
         public void setSubHyperlink(SubHyperlink newSubHyperlink) {
             this.subHyperlink = newSubHyperlink;
         }
+
+        public String getMask() {
+            return this.mask;
+        }
     }
 
     public static class TextareaField extends FieldInfo {
@@ -3074,6 +3080,7 @@ public class ModelFormField {
         protected String inputMethod;
         protected String clock;
         protected String step;
+        protected String mask;
 
         protected DateTimeField() {
             super();
@@ -3093,6 +3100,7 @@ public class ModelFormField {
             type = element.getAttribute("type");
             inputMethod = element.getAttribute("input-method");
             clock = element.getAttribute("clock");
+            mask = element.getAttribute("mask");
             if (UtilValidate.isNotEmpty(element.getAttribute("step"))) {
                 this.setStep(element.getAttribute("step"));
             }
@@ -3126,6 +3134,10 @@ public class ModelFormField {
             return this.clock;
         }
 
+        public String getMask() {
+            return this.mask;
+        }
+
         public String getStep() {
             return this.step;
         }

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/screen/ModelScreenWidget.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/screen/ModelScreenWidget.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/screen/ModelScreenWidget.java (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/src/org/ofbiz/widget/screen/ModelScreenWidget.java Thu Mar 24 07:23:42 2011
@@ -1635,7 +1635,7 @@ public abstract class ModelScreenWidget 
                     } else {
                         actualPortalPageId = portalPage.getString("portalPageId");
                         originalPortalPageId = portalPage.getString("originalPortalPageId");
-                        portalPageColumns = delegator.getRelatedCache("PortalPageColumn", portalPage);
+                        portalPageColumns = delegator.findByAndCache("PortalPageColumn", UtilMisc.toMap("portalPageId", actualPortalPageId), UtilMisc.toList("columnSeqId"));
                     }
                 } else {
                     String errMsg = "portalPageId is empty.";

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/templates/csvFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/templates/csvFormMacroLibrary.ftl?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/templates/csvFormMacroLibrary.ftl (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/templates/csvFormMacroLibrary.ftl Thu Mar 24 07:23:42 2011
@@ -24,11 +24,11 @@ under the License.
 </#macro>
 <#macro renderHyperlinkField></#macro>
 
-<#macro renderTextField name className alert value textSize maxlength id event action disabled clientAutocomplete ajaxUrl ajaxEnabled><@renderField value /></#macro>
+<#macro renderTextField name className alert value textSize maxlength id event action disabled clientAutocomplete ajaxUrl ajaxEnabled mask><@renderField value /></#macro>
 
 <#macro renderTextareaField name className alert cols rows id readonly value visualEditorEnable language buttons><@renderField value /></#macro>
 
-<#macro renderDateTimeField name className alert title value size maxlength step timeValues id dateType shortDateInput timeDropdownParamName defaultDateTimeString localizedIconTitle timeDropdown timeHourName classString hour1 hour2 timeMinutesName minutes isTwelveHour ampmName amSelected pmSelected compositeType formName><@renderField value /></#macro>
+<#macro renderDateTimeField name className alert title value size maxlength step timeValues id dateType shortDateInput timeDropdownParamName defaultDateTimeString localizedIconTitle timeDropdown timeHourName classString hour1 hour2 timeMinutesName minutes isTwelveHour ampmName amSelected pmSelected compositeType formName mask><@renderField value /></#macro>
 
 <#macro renderDropDownField name className alert id multiple formName otherFieldName event action size firstInList currentValue explicitDescription allowEmpty options fieldName otherFieldName otherValue otherFieldSize dDFCurrent ajaxEnabled noCurrentSelectedKey ajaxOptions frequency minChars choices autoSelect partialSearch partialChars ignoreCase fullSearch>
 <#if currentValue?has_content && firstInList?has_content>
@@ -116,4 +116,4 @@ under the License.
 <#macro renderSortField style title linkUrl ajaxEnabled><@renderFieldTitle style title /></#macro>
 <#macro formatBoundaryComment boundaryType widgetType widgetName></#macro>
 <#macro makeHiddenFormLinkAnchor linkStyle hiddenFormName event action imgSrc description><@renderField description /></#macro>
-<#macro makeHyperlinkString linkStyle hiddenFormName event action imgSrc title alternate linkUrl targetWindow description confirmation><@renderField description /></#macro>
+<#macro makeHyperlinkString linkStyle hiddenFormName event action imgSrc title alternate linkUrl targetWindow description confirmation><@renderField description />,<#rt/></#macro>

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/templates/foFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/templates/foFormMacroLibrary.ftl?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/templates/foFormMacroLibrary.ftl (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/templates/foFormMacroLibrary.ftl Thu Mar 24 07:23:42 2011
@@ -48,11 +48,11 @@ under the License.
 </#macro>
 <#macro renderHyperlinkField></#macro>
 
-<#macro renderTextField name className alert value textSize maxlength id event action disabled clientAutocomplete ajaxUrl ajaxEnabled><@makeBlock className value /></#macro>
+<#macro renderTextField name className alert value textSize maxlength id event action disabled clientAutocomplete ajaxUrl ajaxEnabled mask><@makeBlock className value /></#macro>
 
 <#macro renderTextareaField name className alert cols rows id readonly value visualEditorEnable language buttons><@makeBlock className value /></#macro>
 
-<#macro renderDateTimeField name className alert title value size maxlength step timeValues id event action dateType shortDateInput timeDropdownParamName defaultDateTimeString localizedIconTitle timeDropdown timeHourName classString hour1 hour2 timeMinutesName minutes isTwelveHour ampmName amSelected pmSelected compositeType formName><@makeBlock className value /></#macro>
+<#macro renderDateTimeField name className alert title value size maxlength step timeValues id event action dateType shortDateInput timeDropdownParamName defaultDateTimeString localizedIconTitle timeDropdown timeHourName classString hour1 hour2 timeMinutesName minutes isTwelveHour ampmName amSelected pmSelected compositeType formName mask><@makeBlock className value /></#macro>
 
 <#macro renderDropDownField name className alert id multiple formName otherFieldName event action size firstInList currentValue explicitDescription allowEmpty options fieldName otherFieldName otherValue otherFieldSize dDFCurrent ajaxEnabled noCurrentSelectedKey ajaxOptions frequency minChars choices autoSelect partialSearch partialChars ignoreCase fullSearch>
 <#if currentValue?has_content && firstInList?has_content>

Modified: ofbiz/branches/jackrabbit20100709/framework/widget/templates/htmlFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/widget/templates/htmlFormMacroLibrary.ftl?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/framework/widget/templates/htmlFormMacroLibrary.ftl (original)
+++ ofbiz/branches/jackrabbit20100709/framework/widget/templates/htmlFormMacroLibrary.ftl Thu Mar 24 07:23:42 2011
@@ -48,7 +48,12 @@ under the License.
 </#macro>
 <#macro renderHyperlinkField></#macro>
 
-<#macro renderTextField name className alert value textSize maxlength id event action disabled clientAutocomplete ajaxUrl ajaxEnabled>
+<#macro renderTextField name className alert value textSize maxlength id event action disabled clientAutocomplete ajaxUrl ajaxEnabled mask>
+    <#if mask?has_content>
+      <script type="text/javascript">
+        jQuery(function($){jQuery("#${id}").mask("${mask}");});
+      </script>
+    </#if>
     <input type="text" name="${name?default("")?html}"<#t/>
     <@renderClass className alert />
     <#if value?has_content> value="${value}"</#if><#rt/>
@@ -95,7 +100,7 @@ under the License.
     </#if>
 </#macro>
 
-<#macro renderDateTimeField name className alert title value size maxlength id dateType shortDateInput timeDropdownParamName defaultDateTimeString localizedIconTitle timeDropdown timeHourName classString hour1 hour2 timeMinutesName minutes isTwelveHour ampmName amSelected pmSelected compositeType formName event="" action="" step="" timeValues="">
+<#macro renderDateTimeField name className alert title value size maxlength id dateType shortDateInput timeDropdownParamName defaultDateTimeString localizedIconTitle timeDropdown timeHourName classString hour1 hour2 timeMinutesName minutes isTwelveHour ampmName amSelected pmSelected compositeType formName mask="" event="" action="" step="" timeValues="">
   <span class="view-calendar">
       <input type="text" name="${name}" <#if event?has_content && action?has_content> ${event}="${action}"</#if> <@renderClass className alert /><#rt/>
         <#if title?has_content> title="${title}"</#if>
@@ -120,7 +125,9 @@ under the License.
                     buttonText: '',
                     buttonImageOnly: false,
                     dateFormat: 'yy-mm-dd'
-                  });
+                  })
+              <#if mask?has_content>.mask("${mask}")</#if>
+              ;
           </script>
       </#if>
       <#if timeDropdown?has_content && timeDropdown=="time-dropdown">

Modified: ofbiz/branches/jackrabbit20100709/macros.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/macros.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/macros.xml (original)
+++ ofbiz/branches/jackrabbit20100709/macros.xml Thu Mar 24 07:23:42 2011
@@ -73,9 +73,7 @@ under the License.
 
  <presetdef name="javac16">
   <default-javac compiler="javac1.6" target="1.6" source="1.6" encoding="UTF-8" sourcepathref="src-path" includeantruntime="false">
-   <!--
-   <compilerarg value="-Xlint:unchecked"/>
-   -->
+   <compilerarg value="-Xlint:-path"/>
   </default-javac>
  </presetdef>
 

Modified: ofbiz/branches/jackrabbit20100709/specialpurpose/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/specialpurpose/build.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/specialpurpose/build.xml (original)
+++ ofbiz/branches/jackrabbit20100709/specialpurpose/build.xml Thu Mar 24 07:23:42 2011
@@ -33,8 +33,8 @@
         projectmgr/build.xml,
         ldap/build.xml,
         crowd/build.xml,
+        webpos/build.xml
         googlecheckout/build.xml"/>
-    <!-- For the Web POS add "webpos/build.xml" to the list above -->
     <!-- For the old OFBiz Workflow Engine add "workflow/build.xml" to the list above -->
     <!-- For Shark add "shark/build.xml" to the list above, in the specialpurpose-builds list (after workflow) -->
 

Modified: ofbiz/branches/jackrabbit20100709/specialpurpose/component-load.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/specialpurpose/component-load.xml?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/specialpurpose/component-load.xml (original)
+++ ofbiz/branches/jackrabbit20100709/specialpurpose/component-load.xml Thu Mar 24 07:23:42 2011
@@ -35,10 +35,10 @@ under the License.
     <load-component component-location="myportal"/>
     <load-component component-location="crowd"/>
     <load-component component-location="ldap"/>
+    <load-component component-location="webpos"/>
     <!-- The component below are not maintained by the community, or at least not very actively
         Still they are functional (or at least should be). 
         So if you need them simply uncomment and have a look also in the build file -->
-    <!-- <load-component component-location="webpos"/>-->
     <!-- <load-component component-location="workflow"/> -->
     <!-- <load-component component-location="shark"/> -->
 </component-loader>

Modified: ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/ApplicationAuthenticationContext.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/ApplicationAuthenticationContext.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/ApplicationAuthenticationContext.java (original)
+++ ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/ApplicationAuthenticationContext.java Thu Mar 24 07:23:42 2011
@@ -25,6 +25,7 @@
 
 package com.atlassian.crowd.integration.authentication;
 
+@SuppressWarnings("serial")
 public class ApplicationAuthenticationContext  implements java.io.Serializable {
     private com.atlassian.crowd.integration.authentication.PasswordCredential credential;
 
@@ -199,7 +200,7 @@ public class ApplicationAuthenticationCo
      */
     public static org.apache.axis.encoding.Serializer getSerializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanSerializer(
@@ -211,7 +212,7 @@ public class ApplicationAuthenticationCo
      */
     public static org.apache.axis.encoding.Deserializer getDeserializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanDeserializer(

Modified: ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/AuthenticatedToken.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/AuthenticatedToken.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/AuthenticatedToken.java (original)
+++ ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/AuthenticatedToken.java Thu Mar 24 07:23:42 2011
@@ -25,6 +25,7 @@
 
 package com.atlassian.crowd.integration.authentication;
 
+@SuppressWarnings("serial")
 public class AuthenticatedToken  implements java.io.Serializable {
     private java.lang.String name;
 
@@ -153,7 +154,7 @@ public class AuthenticatedToken  impleme
      */
     public static org.apache.axis.encoding.Serializer getSerializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanSerializer(
@@ -165,7 +166,7 @@ public class AuthenticatedToken  impleme
      */
     public static org.apache.axis.encoding.Deserializer getDeserializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanDeserializer(

Modified: ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PasswordCredential.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PasswordCredential.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PasswordCredential.java (original)
+++ ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PasswordCredential.java Thu Mar 24 07:23:42 2011
@@ -25,6 +25,7 @@
 
 package com.atlassian.crowd.integration.authentication;
 
+@SuppressWarnings("serial")
 public class PasswordCredential  implements java.io.Serializable {
     private java.lang.String credential;
 
@@ -153,7 +154,7 @@ public class PasswordCredential  impleme
      */
     public static org.apache.axis.encoding.Serializer getSerializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanSerializer(
@@ -165,7 +166,7 @@ public class PasswordCredential  impleme
      */
     public static org.apache.axis.encoding.Deserializer getDeserializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanDeserializer(

Modified: ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PrincipalAuthenticationContext.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PrincipalAuthenticationContext.java?rev=1084863&r1=1084862&r2=1084863&view=diff
==============================================================================
--- ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PrincipalAuthenticationContext.java (original)
+++ ofbiz/branches/jackrabbit20100709/specialpurpose/crowd/src/com/atlassian/crowd/integration/authentication/PrincipalAuthenticationContext.java Thu Mar 24 07:23:42 2011
@@ -25,6 +25,7 @@
 
 package com.atlassian.crowd.integration.authentication;
 
+@SuppressWarnings("serial")
 public class PrincipalAuthenticationContext  implements java.io.Serializable {
     private java.lang.String application;
 
@@ -236,7 +237,7 @@ public class PrincipalAuthenticationCont
      */
     public static org.apache.axis.encoding.Serializer getSerializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanSerializer(
@@ -248,7 +249,7 @@ public class PrincipalAuthenticationCont
      */
     public static org.apache.axis.encoding.Deserializer getDeserializer(
            java.lang.String mechType,
-           java.lang.Class _javaType,
+           java.lang.Class<?> _javaType,
            javax.xml.namespace.QName _xmlType) {
         return
           new  org.apache.axis.encoding.ser.BeanDeserializer(