svn commit: r952249 - in /ofbiz/trunk: applications/workeffort/widget/WorkEffortRequestForms.xml framework/images/webapp/images/fieldlookup.js

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

svn commit: r952249 - in /ofbiz/trunk: applications/workeffort/widget/WorkEffortRequestForms.xml framework/images/webapp/images/fieldlookup.js

jleroux@apache.org
Author: jleroux
Date: Mon Jun  7 14:36:33 2010
New Revision: 952249

URL: http://svn.apache.org/viewvc?rev=952249&view=rev
Log:
Fixes "Lookup LookupCustRequestItem goes wrong when layered" (https://issues.apache.org/jira/browse/OFBIZ-3813) - OFBIZ-3813

The line bypassed was specifically added for "Lookup Layer Search of a Variant Product" (https://issues.apache.org/jira/browse/OFBIZ-3746) - OFBIZ-3746
But it did not was generalized enough, this should handle all the other cases where a link is in a cell of the result list that is not the 1st one cell


Modified:
    ofbiz/trunk/applications/workeffort/widget/WorkEffortRequestForms.xml
    ofbiz/trunk/framework/images/webapp/images/fieldlookup.js

Modified: ofbiz/trunk/applications/workeffort/widget/WorkEffortRequestForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/widget/WorkEffortRequestForms.xml?rev=952249&r1=952248&r2=952249&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/widget/WorkEffortRequestForms.xml (original)
+++ ofbiz/trunk/applications/workeffort/widget/WorkEffortRequestForms.xml Mon Jun  7 14:36:33 2010
@@ -82,7 +82,7 @@ under the License.
         header-row-style="header-row" default-table-style="basic-table">
         <field name="workEffortId"><hidden/></field>
         <field name="custRequestId"><lookup target-form-name="LookupCustRequest"/></field>
-        <field name="custRequestItemSeqId"><lookup presentation="window" target-form-name="LookupCustRequestItem" target-parameter="custRequestId"/></field>
+        <field name="custRequestItemSeqId"><lookup target-form-name="LookupCustRequestItem" target-parameter="custRequestId"/></field>
         <field name="submitButton" title="${uiLabelMap.CommonAdd}" widget-style="smallSubmit"><submit button-type="button"/></field>
     </form>
 </forms>
\ No newline at end of file

Modified: ofbiz/trunk/framework/images/webapp/images/fieldlookup.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/fieldlookup.js?rev=952249&r1=952248&r2=952249&view=diff
==============================================================================
--- ofbiz/trunk/framework/images/webapp/images/fieldlookup.js (original)
+++ ofbiz/trunk/framework/images/webapp/images/fieldlookup.js Mon Jun  7 14:36:33 2010
@@ -785,7 +785,11 @@ function modifySubmitButton (lookupDiv)
                                 if (cellElement.tagName == 'A') {
                                     var link = cellElement.href;
                                     var liSub = link.substring(link.lastIndexOf('/')+1,(link.length));
-                                    cellElement.href = "javascript:lookupAjaxRequest('" + liSub + "')";
+                                    if (liSub.contains("javascript:set_value(")) {
+                                        cellElement.href = liSub;
+                                    } else {
+                                        cellElement.href = 'javascript:lookupAjaxRequest("' + liSub + '")';
+                                    }
                                 }
                             }
                         }