svn commit: r900950 - in /ofbiz/trunk: framework/common/widget/ framework/example/webapp/example/WEB-INF/ framework/example/widget/example/ framework/images/webapp/images/ framework/images/webapp/images/prototypejs/ framework/widget/dtd/ framework/widg...

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r900950 - in /ofbiz/trunk: framework/common/widget/ framework/example/webapp/example/WEB-INF/ framework/example/widget/example/ framework/images/webapp/images/ framework/images/webapp/images/prototypejs/ framework/widget/dtd/ framework/widg...

jleroux@apache.org
Author: jleroux
Date: Tue Jan 19 20:48:13 2010
New Revision: 900950

URL: http://svn.apache.org/viewvc?rev=900950&view=rev
Log:
A patch from Sascha Rodekamp "THanks" (https://issues.apache.org/jira/browse/OFBIZ-3374) - OFBIZ-3374
A great enhancement IMO (like the calendar some time ago)



Added:
    ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml   (with props)
    ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml   (with props)
    ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js   (with props)
Modified:
    ofbiz/trunk/framework/common/widget/CommonScreens.xml
    ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml
    ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml
    ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml
    ofbiz/trunk/framework/images/webapp/images/fieldlookup.js
    ofbiz/trunk/framework/widget/dtd/widget-form.xsd
    ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java
    ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java
    ofbiz/trunk/framework/widget/templates/csvFormMacroLibrary.ftl
    ofbiz/trunk/framework/widget/templates/foFormMacroLibrary.ftl
    ofbiz/trunk/framework/widget/templates/htmlFormMacroLibrary.ftl
    ofbiz/trunk/framework/widget/templates/textFormMacroLibrary.ftl
    ofbiz/trunk/framework/widget/templates/xmlFormMacroLibrary.ftl
    ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/css/style.css
    ofbiz/trunk/themes/bluelight/webapp/bluelight/style.css
    ofbiz/trunk/themes/droppingcrumbs/webapp/droppingcrumbs/css/style.css
    ofbiz/trunk/themes/flatgrey/webapp/flatgrey/maincss.css

Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
+++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Tue Jan 19 20:48:13 2010
@@ -112,10 +112,11 @@
     <!-- Global decorator for General Screens/Pages -->
     <screen name="GlobalDecorator">
         <section>
-            <actions>                
+            <actions>
                 <!-- The default (global) java scripts -->
                 <set field="layoutSettings.javaScripts[+0]" value="/images/prototypejs/scriptaculous.js" global="true"/>
                 <set field="layoutSettings.javaScripts[+0]" value="/images/prototypejs/prototype.js" global="true"/>
+                <set field="layoutSettings.javaScripts[]" value="/images/prototypejs/resize.js" global="true"/>
                 <set field="layoutSettings.javaScripts[]" value="/images/selectall.js" global="true"/>
                 <set field="layoutSettings.javaScripts[]" value="/images/fieldlookup.js" global="true"/>
                 <set field="layoutSettings.javaScripts[]" value="/images/calendarDateSelect/calendar_date_select.js" global="true"/>
@@ -282,13 +283,58 @@
                         <script location="component://common/webcommon/WEB-INF/actions/includes/FindAutocompleteOptions.groovy"/>
                     </actions>
                     <widgets>
-                        <platform-specific><html><html-template location="component://common/webcommon/includes/ajaxAutocompleteOptions.ftl"/></html></platform-specific>                
+                        <platform-specific><html><html-template location="component://common/webcommon/includes/ajaxAutocompleteOptions.ftl"/></html></platform-specific>
                     </widgets>
                 </section>
             </fail-widgets>
         </section>
     </screen>
 
+    <!-- Global decorator for Lookup layer pop-up windows -->
+    <screen name="LookupLayerPopupDecorator">
+        <section>
+            <actions>
+                <property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
+                <service service-name="getUserPreferenceGroup" result-map="prefResult">
+                    <field-map field-name="userPrefGroupTypeId" value="GLOBAL_PREFERENCES"/>
+                </service>
+                <set field="userPreferences" from-field="prefResult.userPrefMap" global="true"/>
+
+                <property-map resource="general" map-name="generalProperties" global="true"/>
+                <set field="visualThemeId" from-field="userPreferences.VISUAL_THEME" default-value="BIZZNESS_TIME" global="true"/>
+                <service service-name="getVisualThemeResources">
+                    <field-map field-name="visualThemeId"/>
+                    <field-map field-name="themeResources" from-field="layoutSettings"/>
+                </service>
+                <set field="layoutSettings" from-field="themeResources" default-value="${layoutSettings}" global="true"/>
+                <set field="messagesTemplateLocation" from-field="layoutSettings.VT_MSG_TMPLT_LOC[0]" default-value="component://common/webcommon/includes/messages.ftl"/>
+            </actions>
+            <widgets>
+                <platform-specific><html><html-template location="${messagesTemplateLocation}"/></html></platform-specific>
+                <section>
+                    <condition>
+                        <not><if-empty-section section-name="body"/></not>
+                    </condition>
+                    <widgets>
+                        <decorator-section-include name="body"/>
+                    </widgets>
+                    <fail-widgets>
+                        <screenlet title="${title}" id="findScreenlet" collapsible="false" padded="false">
+                            <container id="search-options">
+                                <decorator-section-include name="search-options"/>
+                            </container>
+                        </screenlet>
+                        <screenlet>
+                            <container id="search-results">
+                                <decorator-section-include name="search-results"/>
+                            </container>
+                        </screenlet>
+                    </fail-widgets>
+                </section>
+            </widgets>
+        </section>
+    </screen>
+
     <!-- Simple decorator (no application and menu bars); it can be used:
          * for printer friendly html screens (no logo and no application bar, header and footer); a print button is also available at the top of the screen
          * for simple PDF report (a simple header with the logo/date is rendered and a footer with page numbers)

Modified: ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml (original)
+++ ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml Tue Jan 19 20:48:13 2010
@@ -193,6 +193,7 @@
     <request-map uri="FormWidgetExamples"><security https="true" auth="true"/><response name="success" type="view" value="FormWidgetExamples"/></request-map>
 
     <request-map uri="LookupExampleFeature"><security https="true" auth="true"/><response name="success" type="view" value="LookupExampleFeature"/></request-map>
+    <request-map uri="LookupPartyNameExamplePopup"><security https="true" auth="true"/><response name="success" type="view" value="LookupPartyNameExamplePopup"/></request-map>
 
     <request-map uri="ListExampleFormOnly"><security https="true" auth="false"/><response name="success" type="view" value="ListExampleFormOnly"/></request-map>
     <request-map uri="CreateExampleFormOnly"><security https="true" auth="false"/><response name="success" type="view" value="CreateExampleFormOnly"/></request-map>
@@ -260,6 +261,8 @@
     <view-map name="FormWidgetExamples" type="screen" page="component://example/widget/example/FormWidgetExampleScreens.xml#FormWidgetExamples"/>
 
     <view-map name="LookupExampleFeature" type="screen" page="component://example/widget/example/ExampleFeatureScreens.xml#LookupExampleFeature"/>
+    <view-map name="LookupPartyNameExamplePopup" type="screen" page="component://example/widget/example/FormWidgetExampleLookupScreens.xml#LookupPartyName"/>
+
     <!-- ajax view mappings -->
     <view-map name="findExampleAjax" type="screen" page="component://example/widget/example/ExampleAjaxScreens.xml#AjaxExample"/>
     <view-map name="ListExampleFormOnly" type="screen" page="component://example/widget/example/ExampleAjaxScreens.xml#ListExampleFormOnly"/>
@@ -290,6 +293,6 @@
         application/vnd.ms-word
         application/vnd.ms-powerpoint
      -->
-  
-    <!-- end of view mappings -->  
+
+    <!-- end of view mappings -->
 </site-conf>

Modified: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml (original)
+++ ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml Tue Jan 19 20:48:13 2010
@@ -280,6 +280,12 @@
 
     </form>
 
+    <!-- Lookup Layer Example -->
+    <form name="ExampleLookupFields" type="single" title="">
+        <field name="partyIdFrom" position="1" title="${uiLabelMap.CommonPartyID} ${uiLabelMap.CommonFrom}"><lookup target-form-name="LookupPartyNameExamplePopup" description-field-name="LookupPartyNameExamplePopup" lookup-presentation="layer" lookup-position="normal"/></field>
+        <field name="partyIdTo" position="2" title="${uiLabelMap.CommonPartyID} ${uiLabelMap.CommonTo}"><lookup target-form-name="LookupPartyNameExamplePopup" lookup-presentation="layer" lookup-position="center" lookup-height="580px" lookup-width="450px"/></field>
+    </form>
+
     <form name="SelectionBoxesExampleForm" type="single">
         <field name="ExampleTypeId">
            <check>

Added: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml?rev=900950&view=auto
==============================================================================
--- ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml (added)
+++ ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml Tue Jan 19 20:48:13 2010
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+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
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<forms xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+        xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-form.xsd">
+
+    <form name="lookupPartyName" target="LookupPartyNameExamplePopup" type="single"
+        header-row-style="header-row" default-table-style="basic-table">
+        <!--<auto-fields-entity entity-name="PartyNameView" default-field-type="find"/>-->
+        <field name="partyId" title="${uiLabelMap.PartyPartyId}"><text-find/></field>
+        <field name="partyTypeId" title="${uiLabelMap.PartyTypeId}">
+            <drop-down allow-empty="true">
+                <entity-options description="${description}" entity-name="PartyType"/>
+            </drop-down>
+        </field>
+        <field name="firstName" title="${uiLabelMap.PartyFirstName}"><text-find/></field>
+        <field name="lastName"  title="${uiLabelMap.PartyLastName}"><text-find/></field>
+        <field name="groupName" title="${uiLabelMap.PartyGroupName}"><text-find/></field>
+        <field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
+        <field name="submitButton" title="${uiLabelMap.CommonFind}"><submit button-type="button"/></field>
+    </form>
+    <form name="listLookupPartyName" type="list" list-name="listIt" paginate-target="LookupPartyName"
+        odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
+        <actions>
+            <set field="inputFields" from-field="parameters"/>
+            <set field="orderBy" value="partyId"/>
+            <set field="entityName" value="PartyNameView"/>
+            <script location="component://party/webapp/partymgr/WEB-INF/actions/party/FindLookUp.groovy"/>
+        </actions>
+        <!--<auto-fields-entity entity-name="PartyNameView" default-field-type="display"/>-->
+        <field name="partyId" title="${uiLabelMap.PartyPartyId}"  widget-style="smallSubmit">
+            <hyperlink also-hidden="false" target-type="plain" description="${partyId}" target="javascript:set_value('${partyId}')"/>
+        </field>
+        <field name="partyTypeId" title="${uiLabelMap.PartyTypeId}">
+            <display-entity also-hidden="false" entity-name="PartyType" description="${description}"/>
+        </field>
+        <field name="firstName" title="${uiLabelMap.PartyFirstName}"><display/></field>
+        <field name="lastName"  title="${uiLabelMap.PartyLastName}"><display/></field>
+        <field name="groupName" title="${uiLabelMap.PartyGroupName}"><display/></field>
+    </form>
+
+</forms>
\ No newline at end of file

Propchange: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml
------------------------------------------------------------------------------
    svn:keywords = "Date Rev Author URL Id"

Propchange: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupForms.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml?rev=900950&view=auto
==============================================================================
--- ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml (added)
+++ ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml Tue Jan 19 20:48:13 2010
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+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
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+        xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-screen.xsd">
+    <screen name="LookupPartyName">
+        <section>
+            <condition>
+                <if-service-permission service-name="partyBasePermissionCheck" main-action="VIEW"/>
+            </condition>
+            <actions>
+                <property-map resource="PartyUiLabels" map-name="uiLabelMap" global="true"/>
+                <set field="title" value="${uiLabelMap.PartyLookupPartyByName}"/>
+                <set field="queryString" from-field="result.queryString"/>
+                <set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer" default-value="0"/>
+                <set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="20"/>
+
+                <!-- entries needed for lookup ajax auto completer -->
+                <!-- required: entity to search in -->
+                <set field="entityName" value="PartyNameView"/>
+
+                <!-- required: fields to search a match -->
+                <!-- the first element from searchFields is returned after user selection -->
+                <!-- it might be hidden based on widget.autocompleter.displayReturnField property in widget.properties -->
+                <set field="searchFields" value="[partyId, firstName, middleName, lastName, groupName]"/>
+
+                <!-- optional: fields to display in the given order, default is searchFields -->
+                <set field="displayFields" value="[firstName, lastName, groupName]"/>
+
+                <!-- optional: additional entity condition (named andCondition) added to search query -->
+                <script location="component://party/webapp/partymgr/WEB-INF/actions/party/StatusCondition.groovy"/>
+            </actions>
+            <widgets>
+                <decorator-screen name="LookupLayerPopupDecorator" location="component://common/widget/CommonScreens.xml">
+                    <decorator-section name="search-options">
+                        <include-form name="lookupPartyName" location="component://example/widget/example/FormWidgetExampleLookupForms.xml"/>
+                    </decorator-section>
+                    <decorator-section name="search-results">
+                        <include-form name="listLookupPartyName" location="component://example/widget/example/FormWidgetExampleLookupForms.xml"/>
+                    </decorator-section>
+                </decorator-screen>
+            </widgets>
+        </section>
+    </screen>
+</screens>
\ No newline at end of file

Propchange: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml
------------------------------------------------------------------------------
    svn:keywords = "Date Rev Author URL Id"

Propchange: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleLookupScreens.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml (original)
+++ ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml Tue Jan 19 20:48:13 2010
@@ -78,6 +78,13 @@
                                     </container>
                                     <include-form name="FOPFontsExampleForm" location="component://example/widget/example/FormWidgetExampleForms.xml"/>
                                 </container>
+                                <container style="screenlet-body">
+                                    <container style="button-bar"><label style="h2">${uiLabelMap.ExampleLookupFields}</label></container>
+                                    <container style="screenlet-body">
+                                        <label>${uiLabelMap.ExampleLookupFields}</label>
+                                    </container>
+                                    <include-form name="ExampleLookupFields" location="component://example/widget/example/FormWidgetExampleForms.xml"/>
+                                </container>
                             </widgets>
                             <fail-widgets>
                                 <label style="h3">${uiLabelMap.ExampleViewPermissionError}</label>

Modified: ofbiz/trunk/framework/images/webapp/images/fieldlookup.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/fieldlookup.js?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/images/webapp/images/fieldlookup.js (original)
+++ ofbiz/trunk/framework/images/webapp/images/fieldlookup.js Tue Jan 19 20:48:13 2010
@@ -23,14 +23,15 @@
 var IE5 = (document.getElementById && document.all)? true : false;
 var NS6 = (document.getElementById && navigator.appName.indexOf("Netscape")>=0 )? true: false;
 var mx, my;
+var CURRENT_LOOKUP = null;
 
 function moveobj(evt) {
     if (NS4 || NS6) {
     mx=evt.screenX;
-     my=evt.screenY;
+        my=evt.screenY;
     } else if (IE5 || IE4) {
-     mx=event.screenX;
-     my=event.screenY;
+        mx=event.screenX;
+        my=event.screenY;
     }
 }
 
@@ -44,6 +45,18 @@
     if (! viewheight) viewheight = 200;
     fieldLookup.popup(viewName, formName, viewWidth, viewheight);
 }
+function call_fieldlookupLayer(target, viewName, lookupWidth, lookupHeight, lookupPosition) {
+    if(CURRENT_LOOKUP != null){
+        if(CURRENT_LOOKUP.parentTarget == target){
+            CURRENT_LOOKUP.closeLookup();
+            return;
+        }
+    }
+
+    var fieldLookupPopup = new FieldLookupPopup(target, viewName, lookupWidth, lookupHeight, lookupPosition);
+    fieldLookupPopup.showLookup();
+    this.target = target;
+}
 function call_fieldlookup2(target, viewName) {
     var fieldLookup = new fieldLookup1(target, arguments);
     fieldLookup.popup2(viewName);
@@ -55,21 +68,21 @@
 
 function fieldLookup1(obj_target, args) {
     this.args = args;
- // passing methods
- this.popup = lookup_popup1;
- this.popup2 = lookup_popup2;
-
- // validate input parameters
- if (!obj_target)
- return lookup_error("Error calling the field lookup: no target control specified");
- if (obj_target.value == null)
- return lookup_error("Error calling the field lookup: parameter specified is not valid target control");
+    // passing methods
+    this.popup = lookup_popup1;
+    this.popup2 = lookup_popup2;
+
+    // validate input parameters
+    if (!obj_target)
+        return lookup_error("Error calling the field lookup: no target control specified");
+    if (obj_target.value == null)
+        return lookup_error("Error calling the field lookup: parameter specified is not valid target control");
     //this.target = obj_target;
     target = obj_target;
 
- // register in global collections
- //this.id = lookups.length;
- //lookups[this.id] = this;
+    // register in global collections
+    //this.id = lookups.length;
+    //lookups[this.id] = this;
 }
 function fieldLookup2(obj_target, obj_target2) {
     // passing methods
@@ -95,30 +108,433 @@
 }
 
 function lookup_popup1 (view_name, form_name, viewWidth, viewheight) {
- var obj_lookupwindow = window.open(view_name + '?formName=' + form_name + '&id=' + this.id,'_blank', 'width='+viewWidth+',height='+viewheight+',scrollbars=yes,status=no,resizable=yes,top='+my+',left='+mx+',dependent=yes,alwaysRaised=yes');
- obj_lookupwindow.opener = window;
- obj_lookupwindow.focus();
+    var obj_lookupwindow = window.open(view_name + '?formName=' + form_name + '&id=' + this.id,'_blank', 'width='+viewWidth+',height='+viewheight+',scrollbars=yes,status=no,resizable=yes,top='+my+',left='+mx+',dependent=yes,alwaysRaised=yes');
+    obj_lookupwindow.opener = window;
+    obj_lookupwindow.focus();
 }
 function lookup_popup2 (view_name) {
     var argString = "";
     if (this.args != null) {
-    if (this.args.length > 2) {
-        for(var i=2; i < this.args.length; i++) {
-            argString += "&parm" + (i-2) + "=" + this.args[i];
-        }
-    }
+        if (this.args.length > 2) {
+            for(var i=2; i < this.args.length; i++) {
+                argString += "&parm" + (i-2) + "=" + this.args[i];
+            }
+        }
     }
     var sep = "?";
     if (view_name.indexOf("?") >= 0) {
         sep = "&";
     }
- var obj_lookupwindow = window.open(view_name + sep + 'id=' + this.id + argString,'_blank', 'width=700,height=550,scrollbars=yes,status=no,resizable=yes,top='+my+',left='+mx+',dependent=yes,alwaysRaised=yes');
- obj_lookupwindow.opener = window;
- obj_lookupwindow.focus();
+    var obj_lookupwindow = window.open(view_name + sep + 'id=' + this.id + argString,'_blank', 'width=700,height=550,scrollbars=yes,status=no,resizable=yes,top='+my+',left='+mx+',dependent=yes,alwaysRaised=yes');
+    obj_lookupwindow.opener = window;
+    obj_lookupwindow.focus();
 }
 function lookup_error (str_message) {
- alert (str_message);
- return null;
+    alert (str_message);
+    return null;
+}
+
+/*************************************
+ * Fieldlookup Class & Methods
+ *************************************/
+
+//init KeyListener
+window.onload=function(){
+    //Observe
+    Event.observe(document, "keypress", key_event);
 }
 
+//if ESC is pressed, remove draged portlet + hoverDiv
+function key_event(evt)
+{
+    if(evt.keyCode == 27)  {
+        //removes the hover div after the portlet is moved to another position
+        if(CURRENT_LOOKUP != null){
+            lookupHide();
+        }
+    }
+}
 
+/**
+ * Class to create a lookup layer
+ * target - target where the value should be passed
+ * viewName - view name which will be opened
+ * lookupWidth - layer width i.e. 500px, 27% ... [default: 700px]
+ * lookupHeight - layer height i.e. 500px, 27% ... [default: 550px]
+ * position - normal (under the target field), center (layer is centered) [default: normal] -- !work still in process
+ */
+var FieldLookupPopup = Class.create({
+    initialize: function(target, viewName, lookupWidth, lookupHeight, position){
+        if(isEmpty(target) || isEmpty(viewName)){
+            return lookup_error("Lookup can't created, variabels missing");
+        }
+
+        //removes a existing Lookup
+        if(CURRENT_LOOKUP != null){
+            CURRENT_LOOKUP.removeLayer();
+        }
+
+
+        if(isEmpty(lookupWidth)){
+            lookupWidth = '700px';
+        }
+        this.lookupWidth = lookupWidth;
+
+        if(isEmpty(lookupHeight)){
+            lookupHeight = '550px';
+        }
+        this.lookupHeight = lookupHeight;
+
+        this.parentTarget = target;
+        this.viewName = viewName;
+        this.position = position;
+
+        this.createElement();
+        CURRENT_LOOKUP = this;
+    },
+
+    showLookup: function(){
+        if($('fieldLookup') != null){
+            Effect.Appear('fieldLookup',{duration: 0.3});
+        }
+    },
+
+    closeLookup: function(){
+        if($('fieldLookup') != null){
+            Effect.Fade('fieldLookup',{duration: 0.3});
+        }
+        // removes the layer after fading
+        window.setTimeout('CURRENT_LOOKUP.removeLayer()', 400);
+
+
+    },
+
+    createElement: function(){
+        var parent = this.parentTarget;
+
+        //creates the lookup dom element
+        var lookupDiv = new Element('DIV', {
+            id: "fieldLookup",
+            style: "width: " + this.lookupWidth + "; height: " + this.lookupHeight + ""
+            });
+        lookupDiv.setAttribute("class", "fieldLookup");
+        lookupDiv.setAttribute("className", "fieldLookup"); //IE7 Hack
+
+        //creates lookupHeader
+        var headerDiv = new Element('DIV', {
+            id: "fieldLookupHeader"
+            });
+        headerDiv.setAttribute("class", "fieldLookupHeader");
+        headerDiv.setAttribute("className", "fieldLookupHeader"); // IE 7 Hack
+
+        //create close Button
+        var closeButton = new Element('SPAN', {});
+        var closeButtonImg = new Element('DIV', {
+            onClick: "lookupHide()"
+            });
+        closeButtonImg.onclick = function(){ lookupHide(); };
+
+        closeButton.appendChild(closeButtonImg);
+        headerDiv.appendChild(closeButton);
+        lookupDiv.appendChild(headerDiv);
+
+        //get the lookup from an anjax request
+        this.loadContent(lookupDiv);
+
+        lookupDiv.style.display = "none";
+        //creates the div as child of the form element (parent --> input field; parentNode --> form)
+        var pn = parent.parentNode;
+
+        //set layer position
+        var bdy = document.body;
+        if(this.position == "center"){
+            bdy.appendChild(lookupDiv);
+            var dimensions = lookupDiv.getDimensions();
+            lookupLeft = (bdy.offsetWidth/2) - (dimensions.width/2);
+            lookupTop = ((bdy.offsetHeight/2) - (dimensions.height/2)) + window.pageYOffset;
+            lookupDiv.style.left = lookupLeft + "px";
+            lookupDiv.style.top = lookupTop + "px";
+
+        }else if(this.position == "right"){
+            bdy.appendChild(lookupDiv);
+            var dimensions = lookupDiv.getDimensions();
+            lookupLeft = (bdy.offsetWidth) - (dimensions.width + 5);
+            lookupTop = (bdy.offsetHeight/2) - (dimensions.height/2);
+            lookupDiv.style.left = lookupLeft + "px";
+            lookupDiv.style.top = lookupTop + "px";
+
+        }else if(this.position == "left"){
+            bdy.appendChild(lookupDiv);
+            var dimensions = lookupDiv.getDimensions();
+            lookupLeft = 5;
+            lookupTop = (bdy.offsetHeight/2) - (dimensions.height/2);
+            lookupDiv.style.left = lookupLeft + "px";
+            lookupDiv.style.top = lookupTop + "px";
+
+        }else if(this.position == "topright"){
+            bdy.appendChild(lookupDiv);
+            var dimensions = lookupDiv.getDimensions();
+            lookupLeft = (bdy.offsetWidth) - (dimensions.width + 5);
+            lookupTop = 5;
+            lookupDiv.style.left = lookupLeft + "px";
+            lookupDiv.style.top = lookupTop + "px";
+
+        }else if(this.position == "topleft"){
+            bdy.appendChild(lookupDiv);
+            var dimensions = lookupDiv.getDimensions();
+            lookupLeft = 5;
+            lookupTop = 5;
+            lookupDiv.style.left = lookupLeft + "px";
+            lookupDiv.style.top = lookupTop + "px";
+
+        }else{
+            //for 'normal', empty etc.
+            if(pn != null){ // IE Fix
+                pn.appendChild(lookupDiv);
+            }
+        }
+        this.divRef = lookupDiv;
+
+        //make layer draggable
+        this.makeDraggable(lookupDiv);
+
+        //make the window resiable
+        this.makeResizeable(lookupDiv);
+
+    },
+
+    loadContent: function(lookupDiv){
+        new Ajax.Request(this.viewName,{
+            onSuccess: function(transport){
+                var lookupContent = transport.responseText;
+                lookupDiv.insert({bottom: "<div id='fieldLookupContent'>" + lookupContent + "</div>"});
+                modifySubmitButton();
+            }
+        });
+    },
+
+    makeDraggable: function(lookupDiv){
+        this.loopupDrag = new Draggable(lookupDiv,
+                {handle: 'fieldLookupHeader',revert: false, ghosting: false}
+                );
+    },
+
+    makeResizeable: function(lookupDiv){
+        new Resizeable(lookupDiv,
+                {top: 0,
+                left: 50,
+                resize: function(el){
+                    $('fieldLookupContent').setStyle({
+                        width: "100%",
+                        height: "90%"
+                    });
+                }
+            });
+    },
+
+    removeLayer: function(){
+         this.loopupDrag.destroy();
+         CURRENT_LOOKUP.divRef.parentNode.removeChild(CURRENT_LOOKUP.divRef);
+         CURRENT_LOOKUP = null;
+         this.target = null;
+    }
+
+});
+
+function lookupHide(){
+    if(CURRENT_LOOKUP != null){
+        CURRENT_LOOKUP.closeLookup();
+    }
+}
+
+/**
+ * returns true if a Stirng is empty
+ * @param value - String value
+ * @return
+ */
+function isEmpty(value){
+    if(value == null || value == ""){
+        return true;
+    }
+    return false;
+}
+
+/**
+ * Modify the Submit Button for the new lookup layer
+ * @return
+ */
+function modifySubmitButton(){
+    /* changes form/submit behavior for Lookup Layer */
+    if($('fieldLookup')) {
+         //find the lookup form
+         var forms = $('fieldLookup').getElementsByTagName('form');
+         for(var i =0; i<forms.length; i++){
+             if(!isEmpty(forms[i].getAttribute('id'))){
+                 var lookupForm = $(forms[i].getAttribute('id'));
+             }
+         }
+
+         //diable the form action
+         var formAction = lookupForm.getAttribute('action');
+         lookupForm.setAttribute('action','');
+
+         //modify the form submit button
+         for (var i=0;i<lookupForm.length;i++) {
+             var ele = lookupForm.elements[i];
+             if ((ele.getAttribute('type')) == "submit") {
+               ele.style.display = "none";
+               var txt = ele.value;
+                  var submit = new Element('A',{
+
+                  });
+                  submit.onclick = function(){
+                                                  lookupFormAjaxRequest(formAction, lookupForm.getAttribute('id'));return false;
+                                               };
+                  submit.setAttribute("class", "smallSubmit");
+                  submit.setAttribute("className", "smallSubmit"); // IE 7 Hack
+                  submit.href = "";
+
+                  var textNode = document.createTextNode(txt);
+                  submit.appendChild(textNode);
+                  ele.parentNode.appendChild(submit);
+
+                  //modifay nav-pager
+                  var navPager = $('fieldLookup').getElementsByClassName("nav-pager");
+                  if(navPager.length > 0){
+
+                      for (var j=0;j<navPager.length;j++) {
+                          var eleChild = navPager[j].getElementsByTagName("ul")[0].getElementsByTagName("li");
+                          for (var k=0;k<eleChild.length;k++) {
+                              var link = eleChild[k].getElementsByTagName("A");
+                              var select = eleChild[k].getElementsByTagName("SELECT");
+
+                              if(link.length > 0){
+                                  link[0].href = "javascript:lookupPaginationAjaxRequest('" + link[0].href + "', '" + lookupForm.getAttribute('id') + "', 'link')";
+                              }else if(select.length > 0){
+                                  try{
+                                      var oc = select[0].getAttribute("onchange");
+                                      if((typeof oc) == "function"){ // IE6/7 Fix
+                                          oc = oc.toString();
+                                          var ocSub = oc.substring((oc.indexOf('=')+2),(oc.length - 4));
+                                          var searchPattern = /'\+this.value\+'/g;
+                                          var searchPattern2 = /'\+this.valu/g;
+
+                                          if(searchPattern.test(ocSub)){
+                                              var viewSize = select[0].value;
+                                              var spl = ocSub.split(searchPattern);
+                                              select[0].onchange = function(){lookupPaginationAjaxRequest(spl[0] + this.value + spl[1], lookupForm.getAttribute('id'), 'select');};
+                                          }else if(searchPattern2.test(ocSub)){
+                                              ocSub = ocSub.replace(searchPattern2, "");
+                                              if(searchPattern.test(ocSub)){
+                                                  ocSub.replace(searchPattern, viewSize);
+                                              }
+                                              select[0].onchange = function(){lookupPaginationAjaxRequest(ocSub + this.value, lookupForm.getAttribute('id'), 'select');};
+                                          }
+                                      }else{
+                                          var ocSub = oc.substring((oc.indexOf('=')+1),(oc.length - 1));
+                                          select[0].setAttribute("onchange", "lookupPaginationAjaxRequest(" + ocSub + ", '" + lookupForm.getAttribute('id') + "')");
+                                      }
+                                  }catch(ex){}
+                              }
+                          }
+                      }
+
+                  }
+
+            }
+        }
+    }
+}
+
+/**
+ * Create an ajax request to get the search results
+ * @param formAction - action target
+ * @param form - formId
+ * @return
+ */
+function lookupFormAjaxRequest(formAction, form){
+    new Ajax.Request(formAction,{
+        method: 'post',
+        parameters: $(form).serialize(), requestHeaders: {Accept: 'application/json'},
+        onSuccess: function(transport){
+            var formRequest = transport.responseText;
+            $('fieldLookupContent').remove();
+            $('fieldLookup').insert({bottom: "<div id='fieldLookupContent'>" + formRequest + "</div>"});
+            modifySubmitButton();
+        }
+    });
+}
+
+function lookupPaginationAjaxRequest(navAction, form, type){
+    if(type == 'link'){
+        navAction = navAction.substring(0, navAction.length-1);
+    }
+    new Ajax.Request(navAction,{
+        method: 'get',
+        requestHeaders: {Accept: 'application/json'},
+        onSuccess: function(transport){
+            var formRequest = transport.responseText;
+            $('fieldLookupContent').remove();
+            $('fieldLookup').insert({bottom: "<div id='fieldLookupContent'>" + formRequest + "</div>"});
+            modifySubmitButton();
+        }
+    });
+}
+
+/*******************************************************************************************************
+ * This code inserts the value lookedup by a popup window back into the associated form element
+ *******************************************************************************************************/
+var re_id = new RegExp('id=(\\d+)');
+var num_id = (re_id.exec(String(window.location))
+        ? new Number(RegExp.$1) : 0);
+var obj_caller = (window.opener ? window.opener.lookups[num_id] : null);
+if (obj_caller == null && window.opener != null){
+    obj_caller = window.opener;
+}
+else if(obj_caller == null && window.opener == null){
+    obj_caller = parent;
+}
+
+var bkColor = "yellow";
+function setSourceColor(src){
+if(src != null)
+     src.style.backgroundColor = bkColor;
+ }
+// function passing selected value to calling window
+function set_value(value) {
+        if (!obj_caller) return;
+        setSourceColor(obj_caller.target);
+        obj_caller.target.value = value;
+        closeLookup();
+}
+// function passing selected value to calling window
+function set_values(value, value2) {
+        set_value(value);
+        if (!obj_caller.target2) return;
+        if (obj_caller.target2 == null) return;
+        setSourceColor(obj_caller.target2);
+        obj_caller.target2.value = value2;
+}
+function set_multivalues(value) {
+    obj_caller.target.value = value;
+    var thisForm = obj_caller.target.form;
+    var evalString = "";
+
+    if (arguments.length > 2 ) {
+        for(var i=1; i < arguments.length; i=i+2) {
+            evalString = "setSourceColor(thisForm." + arguments[i] + ")";
+            eval(evalString);
+            evalString = "thisForm." + arguments[i] + ".value='" + arguments[i+1] + "'";
+            eval(evalString);
+        }
+    }
+    closeLookup();
+ }
+//close the window after passing the value
+function closeLookup(){
+     if(window.opener != null){
+         window.close();
+     } else {
+         parent.lookupHide();
+     }
+}

Added: ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js?rev=900950&view=auto
==============================================================================
--- ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js (added)
+++ ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js Tue Jan 19 20:48:13 2010
@@ -0,0 +1,216 @@
+// Copyright (c) 2005 Thomas Fakes (http://craz8.com)
+//
+// This code is substantially based on code from script.aculo.us which has the
+// following copyright and permission notice
+//
+// Copyright (c) 2005 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+var Resizeable = Class.create();
+Resizeable.prototype = {
+  initialize: function(element) {
+    var options = Object.extend({
+      top: 6,
+      bottom: 6,
+      left: 6,
+      right: 6,
+      minHeight: 0,
+      minWidth: 0,
+      zindex: 1000,
+      resize: null,
+      duringresize: null
+    }, arguments[1] || {});
+
+    this.element      = $(element);
+    this.handle  = this.element;
+
+    Element.makePositioned(this.element); // fix IE    
+
+    this.options      = options;
+
+    this.active       = false;
+    this.resizing     = false;  
+    this.currentDirection = '';
+
+    this.eventMouseDown = this.startResize.bindAsEventListener(this);
+    this.eventMouseUp   = this.endResize.bindAsEventListener(this);
+    this.eventMouseMove = this.update.bindAsEventListener(this);
+    this.eventCursorCheck = this.cursor.bindAsEventListener(this);
+    this.eventKeypress  = this.keyPress.bindAsEventListener(this);
+    
+    this.registerEvents();
+  },
+  destroy: function() {
+    Event.stopObserving(this.handle, "mousedown", this.eventMouseDown);
+    this.unregisterEvents();
+  },
+  registerEvents: function() {
+    Event.observe(document, "mouseup", this.eventMouseUp);
+    Event.observe(document, "mousemove", this.eventMouseMove);
+    Event.observe(document, "keypress", this.eventKeypress);
+    Event.observe(this.handle, "mousedown", this.eventMouseDown);
+    Event.observe(this.element, "mousemove", this.eventCursorCheck);
+  },
+  unregisterEvents: function() {
+    //if(!this.active) return;
+    //Event.stopObserving(document, "mouseup", this.eventMouseUp);
+    //Event.stopObserving(document, "mousemove", this.eventMouseMove);
+    //Event.stopObserving(document, "mousemove", this.eventCursorCheck);
+    //Event.stopObserving(document, "keypress", this.eventKeypress);
+  },
+  startResize: function(event) {
+    if(Event.isLeftClick(event)) {
+      
+      // abort on form elements, fixes a Firefox issue
+      var src = Event.element(event);
+      if(src.tagName && (
+        src.tagName=='INPUT' ||
+        src.tagName=='SELECT' ||
+        src.tagName=='BUTTON' ||
+        src.tagName=='TEXTAREA')) return;
+
+  var dir = this.directions(event);
+  if (dir.length > 0) {      
+      this.active = true;
+      var offsets = Position.cumulativeOffset(this.element);
+      this.startTop = offsets[1];
+      this.startLeft = offsets[0];
+      this.startWidth = parseInt(Element.getStyle(this.element, 'width'));
+      this.startHeight = parseInt(Element.getStyle(this.element, 'height'));
+      this.startX = event.clientX + document.body.scrollLeft + document.documentElement.scrollLeft;
+      this.startY = event.clientY + document.body.scrollTop + document.documentElement.scrollTop;
+      
+      this.currentDirection = dir;
+      Event.stop(event);
+  }
+    }
+  },
+  finishResize: function(event, success) {
+    // this.unregisterEvents();
+
+    this.active = false;
+    this.resizing = false;
+
+    if(this.options.zindex)
+      this.element.style.zIndex = this.originalZ;
+      
+    if (this.options.resize) {
+     this.options.resize(this.element);
+    }
+  },
+  keyPress: function(event) {
+    if(this.active) {
+      if(event.keyCode==Event.KEY_ESC) {
+        this.finishResize(event, false);
+        Event.stop(event);
+      }
+    }
+  },
+  endResize: function(event) {
+    if(this.active && this.resizing) {
+      this.finishResize(event, true);
+      Event.stop(event);
+    }
+    this.active = false;
+    this.resizing = false;
+  },
+  draw: function(event) {
+    var pointer = [Event.pointerX(event), Event.pointerY(event)];
+    var style = this.element.style;
+    if (this.currentDirection.indexOf('n') != -1) {
+     var pointerMoved = this.startY - pointer[1];
+     var margin = Element.getStyle(this.element, 'margin-top') || "0";
+     var newHeight = this.startHeight + pointerMoved;
+     if (newHeight > this.options.minHeight) {
+     style.height = newHeight + "px";
+     style.top = (this.startTop - pointerMoved - parseInt(margin)) + "px";
+     }
+    }
+    if (this.currentDirection.indexOf('w') != -1) {
+     var pointerMoved = this.startX - pointer[0];
+     var margin = Element.getStyle(this.element, 'margin-left') || "0";
+     var newWidth = this.startWidth + pointerMoved;
+     if (newWidth > this.options.minWidth) {
+     style.left = (this.startLeft - pointerMoved - parseInt(margin))  + "px";
+     style.width = newWidth + "px";
+     }
+    }
+    if (this.currentDirection.indexOf('s') != -1) {
+     var newHeight = this.startHeight + pointer[1] - this.startY;
+     if (newHeight > this.options.minHeight) {
+     style.height = newHeight + "px";
+     }
+    }
+    if (this.currentDirection.indexOf('e') != -1) {
+     var newWidth = this.startWidth + pointer[0] - this.startX;
+     if (newWidth > this.options.minWidth) {
+     style.width = newWidth + "px";
+     }
+    }
+    if(style.visibility=="hidden") style.visibility = ""; // fix gecko rendering
+  },
+  between: function(val, low, high) {
+   return (val >= low && val < high);
+  },
+  directions: function(event) {
+    var pointer = [Event.pointerX(event), Event.pointerY(event)];
+    var offsets = Position.cumulativeOffset(this.element);
+    
+ var cursor = '';
+ if (this.between(pointer[1] - offsets[1], 0, this.options.top)) cursor += 'n';
+ if (this.between((offsets[1] + this.element.offsetHeight) - pointer[1], 0, this.options.bottom)) cursor += 's';
+ if (this.between(pointer[0] - offsets[0], 0, this.options.left)) cursor += 'w';
+ if (this.between((offsets[0] + this.element.offsetWidth) - pointer[0], 0, this.options.right)) cursor += 'e';
+
+ return cursor;
+  },
+  cursor: function(event) {
+   var cursor = this.directions(event);
+ if (cursor.length > 0) {
+ cursor += '-resize';
+ } else {
+ cursor = '';
+ }
+ this.element.style.cursor = cursor;
+  },
+  update: function(event) {
+   if(this.active) {
+      if(!this.resizing) {
+        var style = this.element.style;
+        this.resizing = true;
+        
+        if(Element.getStyle(this.element,'position')=='')
+          style.position = "relative";
+        
+        if(this.options.zindex) {
+          this.originalZ = parseInt(Element.getStyle(this.element,'z-index') || 0);
+          style.zIndex = this.options.zindex;
+        }
+      }
+      this.draw(event);
+      if(this.options.duringresize) { this.options.duringresize(this.element); }
+      // fix AppleWebKit rendering
+      if(navigator.appVersion.indexOf('AppleWebKit')>0) window.scrollBy(0,0);
+      Event.stop(event);
+      return false;
+   }
+  }
+}

Propchange: ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js
------------------------------------------------------------------------------
    svn:keywords = "Date Rev Author URL Id"

Propchange: ofbiz/trunk/framework/images/webapp/images/prototypejs/resize.js
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: ofbiz/trunk/framework/widget/dtd/widget-form.xsd
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/dtd/widget-form.xsd?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/dtd/widget-form.xsd (original)
+++ ofbiz/trunk/framework/widget/dtd/widget-form.xsd Tue Jan 19 20:48:13 2010
@@ -903,6 +903,34 @@
                 </xs:restriction>
             </xs:simpleType>
         </xs:attribute>
+        <xs:attribute name="lookup-presentation" default="window">
+            <xs:annotation><xs:documentation>Shows the lookup as moveable and resizable layer or window. For layer lookups use the 'LookupLayerPopupDecorator'</xs:documentation></xs:annotation>
+            <xs:simpleType>
+                <xs:restriction base="xs:string">
+                    <xs:enumeration value="layer"/>
+                    <xs:enumeration value="window"/>
+                </xs:restriction>
+            </xs:simpleType>
+        </xs:attribute>
+        <xs:attribute type="xs:string" name="lookup-height">
+            <xs:annotation><xs:documentation>Only layer height. I.e. 250px, 12%</xs:documentation></xs:annotation>
+        </xs:attribute>
+        <xs:attribute type="xs:string" name="lookup-width">
+            <xs:annotation><xs:documentation>Only layer width. I.e. 250px, 12%</xs:documentation></xs:annotation>
+        </xs:attribute>
+        <xs:attribute name="lookup-position" default="normal">
+            <xs:annotation><xs:documentation>Only layer position. Normal sets the layer under the target field.</xs:documentation></xs:annotation>
+            <xs:simpleType>
+                <xs:restriction base="xs:string">
+                    <xs:enumeration value="normal"/>
+                    <xs:enumeration value="center"/>
+                    <xs:enumeration value="left"/>
+                    <xs:enumeration value="right"/>
+                    <xs:enumeration value="topleft"/>
+                    <xs:enumeration value="topright"/>
+                </xs:restriction>
+            </xs:simpleType>
+        </xs:attribute>
     </xs:attributeGroup>
     <xs:element name="password" substitutionGroup="AllFields">
         <xs:complexType>

Modified: ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java (original)
+++ ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java Tue Jan 19 20:48:13 2010
@@ -1931,6 +1931,26 @@
             ajaxUrl = createAjaxParamsFromUpdateAreas(updateAreas, null, context);
         }
 
+        String lookupPresentation = lookupField.getLookupPresentation();
+        if(UtilValidate.isEmpty(lookupPresentation)){
+            lookupPresentation = "";
+        }
+
+        String lookupHeight = lookupField.getLookupHeight();
+        if(UtilValidate.isEmpty(lookupHeight)){
+            lookupHeight = "";
+        }
+
+        String lookupWidth = lookupField.getLookupWidth();
+        if(UtilValidate.isEmpty(lookupWidth)){
+            lookupWidth = "";
+        }
+
+        String lookupPosition = lookupField.getLookupPosition();
+        if(UtilValidate.isEmpty(lookupPosition)){
+            lookupPosition = "";
+        }
+
         StringWriter sr = new StringWriter();
         sr.append("<@renderLookupField ");
         sr.append(" className=\"");
@@ -1974,7 +1994,15 @@
         sr.append(ajaxUrl);
         sr.append("\" ajaxEnabled=");
         sr.append(Boolean.toString(ajaxEnabled));
-        sr.append(" />");
+        sr.append(" lookupPresentation=\"");
+        sr.append(lookupPresentation);
+        sr.append("\" lookupHeight=\"");
+        sr.append(lookupHeight);
+        sr.append("\" lookupWidth=\"");
+        sr.append(lookupWidth);
+        sr.append("\" lookupPosition=\"");
+        sr.append(lookupPosition);
+        sr.append("\" />");
         executeMacro(sr.toString());
 
         this.addAsterisks(writer, context, modelFormField);

Modified: ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java (original)
+++ ofbiz/trunk/framework/widget/src/org/ofbiz/widget/form/ModelFormField.java Tue Jan 19 20:48:13 2010
@@ -3462,12 +3462,20 @@
         protected String descriptionFieldName;
         protected String targetParameter;
         protected SubHyperlink subHyperlink;
+        protected String lookupPresentation;
+        protected String lookupWidth;
+        protected String lookupHeight;
+        protected String lookupPosition;
 
         public LookupField(Element element, ModelFormField modelFormField) {
             super(element, modelFormField);
             this.formName = FlexibleStringExpander.getInstance(element.getAttribute("target-form-name"));
             this.descriptionFieldName = element.getAttribute("description-field-name");
             this.targetParameter = element.getAttribute("target-parameter");
+            this.lookupPresentation = element.getAttribute("lookup-presentation");
+            this.lookupHeight = element.getAttribute("lookup-height");
+            this.lookupWidth = element.getAttribute("lookup-width");
+            this.lookupPosition = element.getAttribute("lookup-position");
 
             Element subHyperlinkElement = UtilXml.firstChildElement(element, "sub-hyperlink");
             if (subHyperlinkElement != null) {
@@ -3515,6 +3523,38 @@
         public SubHyperlink getSubHyperlink() {
             return this.subHyperlink;
         }
+
+        public String getLookupPresentation() {
+            return this.lookupPresentation;
+        }
+
+        public void setLookupPresentation(String str) {
+            this.lookupPresentation = str;
+        }
+
+        public String getLookupWidth() {
+            return this.lookupWidth;
+        }
+
+        public void setLookupWidth(String str) {
+            this.lookupWidth = str;
+        }
+
+        public String getLookupHeight() {
+            return this.lookupHeight;
+        }
+
+        public void setLookupHeight(String str) {
+            this.lookupHeight = str;
+        }
+
+        public String getLookupPosition() {
+            return this.lookupPosition;
+        }
+
+        public void setLookupPosition(String str) {
+            this.lookupPosition = str;
+        }
     }
 
     public static class FileField extends TextField {

Modified: ofbiz/trunk/framework/widget/templates/csvFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/templates/csvFormMacroLibrary.ftl?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/templates/csvFormMacroLibrary.ftl (original)
+++ ofbiz/trunk/framework/widget/templates/csvFormMacroLibrary.ftl Tue Jan 19 20:48:13 2010
@@ -103,7 +103,7 @@
 <@renderField value />
 </#macro>
 
-<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled></#macro>
+<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled lookupPresentation lookupWidth lookupHeight lookupPosition></#macro>
 <#macro renderNextPrev paginateStyle paginateFirstStyle viewIndex highIndex listSize viewSize ajaxEnabled javaScriptEnabled ajaxFirstUrl firstUrl paginateFirstLabel paginatePreviousStyle ajaxPreviousUrl previousUrl paginatePreviousLabel pageLabel ajaxSelectUrl selectUrl ajaxSelectSizeUrl selectSizeUrl commonDisplaying paginateNextStyle ajaxNextUrl nextUrl paginateNextLabel paginateLastStyle ajaxLastUrl lastUrl paginateLastLabel paginateViewSizeLabel></#macro>
 <#macro renderFileField className alert name value size maxlength autocomplete><@renderField value /></#macro>
 <#macro renderPasswordField className alert name value size maxlength id autocomplete></#macro>

Modified: ofbiz/trunk/framework/widget/templates/foFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/templates/foFormMacroLibrary.ftl?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/templates/foFormMacroLibrary.ftl (original)
+++ ofbiz/trunk/framework/widget/templates/foFormMacroLibrary.ftl Tue Jan 19 20:48:13 2010
@@ -122,7 +122,7 @@
 <@makeBlock className value />
 </#macro>
 
-<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled></#macro>
+<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled lookupPresentation lookupWidth lookupHeight lookupPosition></#macro>
 <#macro renderNextPrev paginateStyle paginateFirstStyle viewIndex highIndex listSize viewSize ajaxEnabled javaScriptEnabled ajaxFirstUrl firstUrl paginateFirstLabel paginatePreviousStyle ajaxPreviousUrl previousUrl paginatePreviousLabel pageLabel ajaxSelectUrl selectUrl ajaxSelectSizeUrl selectSizeUrl commonDisplaying paginateNextStyle ajaxNextUrl nextUrl paginateNextLabel paginateLastStyle ajaxLastUrl lastUrl paginateLastLabel paginateViewSizeLabel></#macro>
 <#macro renderFileField className alert name value size maxlength autocomplete><@makeBlock className value /></#macro>
 <#macro renderPasswordField className alert name value size maxlength id autocomplete><@makeBlock className "" /></#macro>

Modified: ofbiz/trunk/framework/widget/templates/htmlFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/templates/htmlFormMacroLibrary.ftl?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/templates/htmlFormMacroLibrary.ftl (original)
+++ ofbiz/trunk/framework/widget/templates/htmlFormMacroLibrary.ftl Tue Jan 19 20:48:13 2010
@@ -408,14 +408,16 @@
 </#if>
 </#macro>
 
-<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled>
+<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled lookupPresentation lookupWidth lookupHeight lookupPosition>
 <div class="field-lookup"><ul>
 <li><input type="text" <@renderClass className alert /><#if name?has_content> name="${name}"</#if><#if value?has_content> value="${value}"</#if><#if size?has_content> size="${size}"</#if><#if maxlength?has_content> maxlength="${maxlength}"</#if><#if id?has_content> id="${id}"</#if><#rt/><#if disabled?has_content && disabled> disabled="disabled"</#if><#rt/><#if event?has_content && action?has_content> ${event}="${action}"</#if><#rt/><#if autocomplete?has_content> autocomplete="off"</#if>/><#rt/></li>
-<li><#if descriptionFieldName?has_content>
- <a href="javascript:call_fieldlookup3(document.${formName?html}.${name?html}, document.${formName?html}.${descriptionFieldName},<#rt/>
- <#else>
- <a href="javascript:call_fieldlookup2(document.${formName}.${name},<#rt/>
-</#if>'${lookupFieldFormName}'<#rt>
+<li><#if lookupPresentation?has_content && lookupPresentation == "layer">
+ <a href="javascript:call_fieldlookupLayer(document.${formName?html}.${name?html},'${lookupFieldFormName}','${lookupWidth}','${lookupHeight}','${lookupPosition}'<#rt/>
+<#elseif descriptionFieldName?has_content>
+ <a href="javascript:call_fieldlookup3(document.${formName?html}.${name?html},'${descriptionFieldName}','${lookupFieldFormName}'<#rt/>
+<#else>
+ <a href="javascript:call_fieldlookup2(document.${formName}.${name},'${lookupFieldFormName}'<#rt/>
+</#if>
 <#if targetParameterIter?exists>
  <#list targetParameterIter as item>
   ,document.${formName}.${item}.value<#rt>

Modified: ofbiz/trunk/framework/widget/templates/textFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/templates/textFormMacroLibrary.ftl?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/templates/textFormMacroLibrary.ftl (original)
+++ ofbiz/trunk/framework/widget/templates/textFormMacroLibrary.ftl Tue Jan 19 20:48:13 2010
@@ -103,7 +103,7 @@
 <@renderField value />
 </#macro>
 
-<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled><@renderField value /></#macro>
+<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled lookupPresentation lookupWidth lookupHeight lookupPosition><@renderField value /></#macro>
 <#macro renderNextPrev paginateStyle paginateFirstStyle viewIndex highIndex listSize viewSize ajaxEnabled javaScriptEnabled ajaxFirstUrl firstUrl paginateFirstLabel paginatePreviousStyle ajaxPreviousUrl previousUrl paginatePreviousLabel pageLabel ajaxSelectUrl selectUrl ajaxSelectSizeUrl selectSizeUrl commonDisplaying paginateNextStyle ajaxNextUrl nextUrl paginateNextLabel paginateLastStyle ajaxLastUrl lastUrl paginateLastLabel paginateViewSizeLabel></#macro>
 <#macro renderFileField className alert name value size maxlength autocomplete><@renderField value /></#macro>
 <#macro renderPasswordField className alert name value size maxlength id autocomplete></#macro>

Modified: ofbiz/trunk/framework/widget/templates/xmlFormMacroLibrary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/widget/templates/xmlFormMacroLibrary.ftl?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/framework/widget/templates/xmlFormMacroLibrary.ftl (original)
+++ ofbiz/trunk/framework/widget/templates/xmlFormMacroLibrary.ftl Tue Jan 19 20:48:13 2010
@@ -101,7 +101,7 @@
 <#macro renderRangeFindField className alert name value size maxlength autocomplete titleStyle defaultOptionFrom opEquals opGreaterThan opGreaterThanEquals opLessThan opLessThanEquals value2 defaultOptionThru>
 </#macro>
 
-<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled></#macro>
+<#macro renderLookupField className alert name value size maxlength id event action disabled autocomplete descriptionFieldName formName lookupFieldFormName targetParameterIter imgSrc ajaxUrl ajaxEnabled lookupPresentation lookupWidth lookupHeight lookupPosition></#macro>
 <#macro renderNextPrev paginateStyle paginateFirstStyle viewIndex highIndex listSize viewSize ajaxEnabled javaScriptEnabled ajaxFirstUrl firstUrl paginateFirstLabel paginatePreviousStyle ajaxPreviousUrl previousUrl paginatePreviousLabel pageLabel ajaxSelectUrl selectUrl ajaxSelectSizeUrl selectSizeUrl commonDisplaying paginateNextStyle ajaxNextUrl nextUrl paginateNextLabel paginateLastStyle ajaxLastUrl lastUrl paginateLastLabel paginateViewSizeLabel></#macro>
 <#macro renderFileField className alert name value size maxlength autocomplete></#macro>
 <#macro renderPasswordField className alert name value size maxlength id autocomplete></#macro>

Modified: ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/css/style.css
URL: http://svn.apache.org/viewvc/ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/css/style.css?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/css/style.css (original)
+++ ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/css/style.css Tue Jan 19 20:48:13 2010
@@ -1448,3 +1448,75 @@
     width:45%;
     float:left;
 }
+
+
+/***********************************************
+Lookups
+***********************************************/
+ .fieldLookup{
+    background: #ffffff;
+    border-right: 2px solid #999;
+    border-left: 2px solid #999;
+    border-bottom: 3px solid #999;
+    position: absolute;
+    padding: 3px 1 1 1;
+    overflow: visible;
+    z-index: 1000;
+    visibility: visible;
+ }
+
+ .fieldLookupHeader{
+    border-bottom: 1px solid #aaa;
+    border-top: 1px solid #999;
+    margin: 0;
+    height: 18px;
+    font-size: 12px;
+    padding: 3px 0;
+    color: #333;
+    background-image: url(../images/header_bg.gif);
+    cursor: move;
+ }
+
+ .fieldLookupHeader span{
+     text-align: right;
+     cursor: pointer;
+ }
+
+ .fieldLookupHeader span div{
+     background-image: url(../images/header_close_button.png);
+     float: right;
+     width: 16px;
+     height: 16px;
+ }
+
+ #fieldLookupContent{
+     background-color: #ffffff;
+     margin: 0;
+     padding: 0;
+     border: 0;
+     overflow: auto;
+     width:100%;
+     height:95%;
+ }
+
+/* overwrite */
+ #fieldLookupContent ul li a{
+     display: inherit;
+     padding: 2px 3px 2px 3px;
+     margin: 0;
+     cursor: pointer;
+     height: auto;
+     width: auto;
+     background-image: none;
+ }
+
+/* overwrite*/
+ #fieldLookupContent a{
+     display: inherit;
+     cursor: pointer;
+ }
+
+/* overwrite*/
+ #findScreenlet{
+     margin-top: 0;
+ }

Modified: ofbiz/trunk/themes/bluelight/webapp/bluelight/style.css
URL: http://svn.apache.org/viewvc/ofbiz/trunk/themes/bluelight/webapp/bluelight/style.css?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/themes/bluelight/webapp/bluelight/style.css (original)
+++ ofbiz/trunk/themes/bluelight/webapp/bluelight/style.css Tue Jan 19 20:48:13 2010
@@ -2176,3 +2176,71 @@
   margin:0.75em 0 0.09em 0;
   text-transform:uppercase;
 }
+
+/***********************************************
+Lookups
+***********************************************/
+ .fieldLookup{
+    background: #ffffff;
+    border-right: 2px solid #999;
+    border-left: 2px solid #999;
+    border-bottom: 3px solid #999;
+    position: absolute;
+    padding: 3px 1 1 1;
+    overflow: visible;
+    z-index: 1000;
+    visibility: visible;
+ }
+
+ .fieldLookupHeader{
+    border-bottom: 1px solid #aaa;
+    border-top: 1px solid #999;
+    margin: 0;
+    height: 18px;
+    font-size: 12px;
+    padding: 3px 0;
+    color: #333;
+    background-image: url(images/header_bg.gif);
+    cursor: move;
+ }
+
+ .fieldLookupHeader span{
+     text-align: right;
+     cursor: pointer;
+ }
+
+ .fieldLookupHeader span div{
+     background-image: url(images/header_close_button.png);
+     float: right;
+     width: 16px;
+     height: 16px;
+ }
+
+ #fieldLookupContent{
+     background-color: #ffffff;
+     margin: 0;
+     padding: 0;
+     border: 0;
+     overflow: auto;
+     width:100%;
+     height:95%;
+ }
+
+/* overwrite*/
+ #fieldLookup ul li a{
+     display: inherit;
+     padding: 2px 3px 2px 3px;
+     margin: 0;
+     cursor: pointer;
+ }
+
+ #fieldLookup td a{
+     display: inherit;
+     cursor: pointer;
+     background-image: none;
+ }
+
+/* overwrite*/
+ #findScreenlet{
+     margin-top: 0;
+ }

Modified: ofbiz/trunk/themes/droppingcrumbs/webapp/droppingcrumbs/css/style.css
URL: http://svn.apache.org/viewvc/ofbiz/trunk/themes/droppingcrumbs/webapp/droppingcrumbs/css/style.css?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/themes/droppingcrumbs/webapp/droppingcrumbs/css/style.css (original)
+++ ofbiz/trunk/themes/droppingcrumbs/webapp/droppingcrumbs/css/style.css Tue Jan 19 20:48:13 2010
@@ -2154,3 +2154,72 @@
 margin:0.75em 0 0.09em 0;
 text-transform:uppercase;
 }
+
+/***********************************************
+Lookups
+***********************************************/
+ .fieldLookup{
+    background: #ffffff;
+    border-right: 2px solid #999;
+    border-left: 2px solid #999;
+    border-bottom: 3px solid #999;
+    position: absolute;
+    padding: 3px 1 1 1;
+    overflow: visible;
+    z-index: 1000;
+    visibility: visible;
+ }
+
+ .fieldLookupHeader{
+    border-bottom: 1px solid #aaa;
+    border-top: 1px solid #999;
+    margin: 0;
+    height: 18px;
+    font-size: 12px;
+    padding: 3px 0;
+    color: #333;
+    background-image: url(../images/header_bg.gif);
+    cursor: move;
+ }
+
+ .fieldLookupHeader span{
+     text-align: right;
+     cursor: pointer;
+ }
+
+ .fieldLookupHeader span div{
+     background-image: url(../images/header_close_button.png);
+     float: right;
+     width: 16px;
+     height: 16px;
+ }
+
+ #fieldLookupContent{
+     background-color: #ffffff;
+     margin: 0;
+     padding: 0;
+     border: 0;
+     overflow: auto;
+     width:100%;
+     height:95%;
+ }
+
+/* overwrite */
+ #fieldLookupContent ul li a{
+     display: inherit;
+     padding: 2px 3px 2px 3px;
+     margin: 0;
+     cursor: pointer;
+
+ }
+
+ #fieldLookupContent td a{
+     display: inherit;
+     cursor: pointer;
+     background-image: none;
+ }
+
+/* overwrite*/
+ #findScreenlet{
+     margin-top: 0;
+ }
\ No newline at end of file

Modified: ofbiz/trunk/themes/flatgrey/webapp/flatgrey/maincss.css
URL: http://svn.apache.org/viewvc/ofbiz/trunk/themes/flatgrey/webapp/flatgrey/maincss.css?rev=900950&r1=900949&r2=900950&view=diff
==============================================================================
--- ofbiz/trunk/themes/flatgrey/webapp/flatgrey/maincss.css (original)
+++ ofbiz/trunk/themes/flatgrey/webapp/flatgrey/maincss.css Tue Jan 19 20:48:13 2010
@@ -2205,3 +2205,74 @@
   margin:0.75em 0 0.09em 0;
   text-transform:uppercase;
 }
+
+/***********************************************
+Lookups
+***********************************************/
+ .fieldLookup{
+    background: #ffffff;
+    border-right: 2px solid #999;
+    border-left: 2px solid #999;
+    border-bottom: 3px solid #999;
+    position: absolute;
+    padding: 3px 1 1 1;
+    overflow: visible;
+    z-index: 1000;
+    visibility: visible;
+ }
+
+ .fieldLookupHeader{
+    border-bottom: 1px solid #aaa;
+    border-top: 1px solid #999;
+    margin: 0;
+    height: 18px;
+    font-size: 12px;
+    padding: 3px 0;
+    color: #333;
+    background-image: url(header_bg.gif);
+    cursor: move;
+ }
+
+ .fieldLookupHeader span{
+     text-align: right;
+     cursor: pointer;
+ }
+
+ .fieldLookupHeader span div{
+     background-image: url(header_close_button.png);
+     float: right;
+     width: 16px;
+     height: 16px;
+ }
+
+ #fieldLookupContent{
+     background-color: #ffffff;
+     margin: 0;
+     padding: 0;
+     border: 0;
+     overflow: auto;
+     width:100%;
+     height:95%;
+ }
+
+/* overwrite */
+ #fieldLookupContent ul li a{
+     display: inherit;
+     padding: 2px 3px 2px 3px;
+     margin: 0;
+     cursor: pointer;
+     height: auto;
+     width: auto;
+     background-image: none;
+ }
+
+ #fieldLookupContent a{
+     display: inherit;
+     cursor: pointer;
+     background-image: none;
+ }
+
+/* overwrite*/
+ #findScreenlet{
+     margin-top: 0;
+ }