|
Author: jleroux
Date: Sun Jul 29 21:51:21 2012 New Revision: 1366962 URL: http://svn.apache.org/viewvc?rev=1366962&view=rev Log: "Applied fix from trunk for revision: 1366960" ------------------------------------------------------------------------ r1366960 | jleroux | 2012-07-29 23:49:52 +0200 (dim., 29 juil. 2012) | 13 lines This closes "Price rule add not correctly" https://issues.apache.org/jira/browse/OFBIZ-4978 steps: 1.login and goto price rule tab 2.add a rule 3.add a condition for the rule The issue is, the added condition is not my selection. I add condition "Party is Fanse Fan", then add, after success, in the detail list, the last party of the select box be shown on the condition , not the one which I choosed. jleroux: * The problem reported by Fanse is now corrected * Fixes an issue when updating a condition (check is now done on input types and not only on value as in creation where it's not a problem, the copy and adaptation from creation to update service implementation was the reason of this bug I'm in the process of adding some more check for condition creation, but will do that later (ne feature not only fixes as here) ------------------------------------------------------------------------ Modified: ofbiz/branches/release12.04/ (props changed) ofbiz/branches/release12.04/applications/product/script/org/ofbiz/product/price/PriceServices.xml ofbiz/branches/release12.04/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl ofbiz/branches/release12.04/applications/product/widget/catalog/PriceForms.xml Propchange: ofbiz/branches/release12.04/ ------------------------------------------------------------------------------ Merged /ofbiz/trunk:r1366960 Modified: ofbiz/branches/release12.04/applications/product/script/org/ofbiz/product/price/PriceServices.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/applications/product/script/org/ofbiz/product/price/PriceServices.xml?rev=1366962&r1=1366961&r2=1366962&view=diff ============================================================================== --- ofbiz/branches/release12.04/applications/product/script/org/ofbiz/product/price/PriceServices.xml (original) +++ ofbiz/branches/release12.04/applications/product/script/org/ofbiz/product/price/PriceServices.xml Sun Jul 29 21:51:21 2012 @@ -307,9 +307,12 @@ under the License. </check-permission> <check-errors/> - <if-not-empty field="parameters.condValueInput"> + <if-compare field="parameters.inputParamEnumId" operator="equals" value="PRIP_QUANTITY"> <set field="parameters.condValue" from-field="parameters.condValueInput"/> - </if-not-empty> + </if-compare> + <if-compare field="parameters.inputParamEnumId" operator="equals" value="PRIP_LIST_PRICE"> + <set field="parameters.condValue" from-field="parameters.condValueInput"/> + </if-compare> <make-value entity-name="ProductPriceCond" value-field="lookupPKMap"/> <set-pk-fields map="parameters" value-field="lookupPKMap"/> <find-by-primary-key entity-name="ProductPriceCond" map="lookupPKMap" value-field="lookedUpValue"/> Modified: ofbiz/branches/release12.04/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl?rev=1366962&r1=1366961&r2=1366962&view=diff ============================================================================== --- ofbiz/branches/release12.04/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl (original) +++ ofbiz/branches/release12.04/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl Sun Jul 29 21:51:21 2012 @@ -23,9 +23,9 @@ jQuery(document).ready( function() { if (document.getElementById('EditProductPriceRulesCond_o_${i}')) { jQuery('#EditProductPriceRulesCond_condValueInput_o_${i}').hide(); jQuery('#EditProductPriceRulesCond_inputParamEnumId_o_${i}').change( function() { - getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); + getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '${productPriceConds[i].condValue}', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); }); - getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); + getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '${productPriceConds[i].condValue}', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); } </#list> </#if> Modified: ofbiz/branches/release12.04/applications/product/widget/catalog/PriceForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/release12.04/applications/product/widget/catalog/PriceForms.xml?rev=1366962&r1=1366961&r2=1366962&view=diff ============================================================================== --- ofbiz/branches/release12.04/applications/product/widget/catalog/PriceForms.xml (original) +++ ofbiz/branches/release12.04/applications/product/widget/catalog/PriceForms.xml Sun Jul 29 21:51:21 2012 @@ -94,11 +94,11 @@ </field> <field name="condValueInput" title="${uiLabelMap.ProductValue}" entry-name="condValue"><text size="10"/></field> <field name="condValue" title="${uiLabelMap.CommonEmptyHeader}"> - <drop-down allow-empty="false"> - <list-options list-name="productPriceRulesCondValues" key-name="condValue"/> + <drop-down allow-empty="false" current="selected"> + <list-options list-name="productPriceRulesCondValues" key-name="condValue"/> </drop-down> </field> - <field name="submitButton" title="${uiLabelMap.CommonUpdate}" widget-style="smallSubmit"><submit/></field> + <field name="submitButton" title="${uiLabelMap.CommonUpdate}" widget-style="smallSubmit"><submit/></field> <field name="deleteLink" title="${uiLabelMap.CommonEmptyHeader}" widget-style="buttontext" widget-area-style="align-text"> <hyperlink target="deleteProductPriceCond" description="${uiLabelMap.CommonRemove}"> <parameter param-name="productPriceRuleId" from-field="productPriceCond.productPriceRuleId"/> |
| Free forum by Nabble | Edit this page |
