Author: diveshdutta
Date: Sat Jun 18 19:39:58 2016 New Revision: 1749088 URL: http://svn.apache.org/viewvc?rev=1749088&view=rev Log: [OFBIZ-7173] Now product added for any task from Actual Material screen will be consumed/issued in production run declaration screen. This is done by creating WorkEffortGoodStandard for specified task and product when issuing inventory for production run task. Thanks Anuj Jain for your patch and thanks Swapnil Shah for suggesting this improvment. Modified: ofbiz/trunk/applications/manufacturing/minilang/jobshopmgt/ProductionRunServices.xml ofbiz/trunk/applications/manufacturing/widget/manufacturing/ProductionRunForms.xml Modified: ofbiz/trunk/applications/manufacturing/minilang/jobshopmgt/ProductionRunServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/minilang/jobshopmgt/ProductionRunServices.xml?rev=1749088&r1=1749087&r2=1749088&view=diff ============================================================================== --- ofbiz/trunk/applications/manufacturing/minilang/jobshopmgt/ProductionRunServices.xml (original) +++ ofbiz/trunk/applications/manufacturing/minilang/jobshopmgt/ProductionRunServices.xml Sat Jun 18 19:39:58 2016 @@ -101,7 +101,6 @@ under the License. </simple-method> <simple-method method-name="issueProductionRunTaskComponent" short-description="Issues the Inventory for a Production Run Task Component" login-required="false"> <if-empty field="parameters.fromDate"> - <set from-field="parameters.productId" field="productId"/> <set from-field="parameters.quantity" field="estimatedQuantity" default-value="0.0" type="BigDecimal"/> <else> <entity-one entity-name="WorkEffortGoodStandard" value-field="workEffortGoodStandard" auto-field-map="false"> @@ -117,6 +116,17 @@ under the License. <set from-field="parameters.quantity" field="estimatedQuantity" default-value="0.0" type="BigDecimal"/> </else> </if-empty> + <!-- If no product found in the workEffortGoodStandard then create the entry in workEffortGoodStandard--> + <if-empty field="productId"> + <set field="createWorkEffortGoodStdMap.workEffortId" from-field="parameters.workEffortId" /> + <set field="createWorkEffortGoodStdMap.productId" from-field="parameters.productId"/> + <set field="createWorkEffortGoodStdMap.workEffortGoodStdTypeId" value="PRUNT_PROD_NEEDED"/> + <set field="createWorkEffortGoodStdMap.fromDate" from-field="parameters.fromDate" /> + <set field="createWorkEffortGoodStdMap.estimatedQuantity" from-field="parameters.quantity"/> + <set field="createWorkEffortGoodStdMap.statusId" value="WEGS_CREATED"/> + <call-service service-name="createWorkEffortGoodStandard" in-map-name="createWorkEffortGoodStdMap"/> + <set field="productId" from-field="parameters.productId"/> + </if-empty> </else> </if-empty> Modified: ofbiz/trunk/applications/manufacturing/widget/manufacturing/ProductionRunForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/widget/manufacturing/ProductionRunForms.xml?rev=1749088&r1=1749087&r2=1749088&view=diff ============================================================================== --- ofbiz/trunk/applications/manufacturing/widget/manufacturing/ProductionRunForms.xml (original) +++ ofbiz/trunk/applications/manufacturing/widget/manufacturing/ProductionRunForms.xml Sat Jun 18 19:39:58 2016 @@ -999,7 +999,7 @@ under the License. header-row-style="header-row" default-table-style="basic-table"> <auto-fields-service service-name="issueProductionRunTaskComponent"/> <field name="productionRunId"><hidden/></field> - <field name="fromDate"><ignored/></field> + <field name="fromDate"><date-time default-value="${nowTimestamp}"/></field> <field name="reserveOrderEnumId"><ignored/></field> <field name="workEffortId" title="${uiLabelMap.ManufacturingTaskId}"> <drop-down allow-empty="false"> |
Free forum by Nabble | Edit this page |