Author: jleroux
Date: Sat Apr 30 18:43:10 2016 New Revision: 1741789 URL: http://svn.apache.org/viewvc?rev=1741789&view=rev Log: An enhanced patch from Christian Carlow for "Add ability to change Routing statuses" - https://issues.apache.org/jira/browse/OFBIZ-6307 Only ROU_ACTIVE statusItem exists for statusTypeId ROUTING_STATUS. Adding another such as ROU_INACTIVE would allow for more control over routings. Doing so entails adding the statusId to the find and edit screens. ROU_INACTIVE was add as a StatusItem and currentStatusId was added to the routing find form as a multi-drop down jleroux: I added use of common/webcommon/includes/setMultipleSelectJs.ftl and French labels Modified: ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingScreens.xml ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingTaskForms.xml ofbiz/trunk/applications/workeffort/data/WorkEffortTypeData.xml ofbiz/trunk/framework/common/config/CommonEntityLabels.xml Modified: ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingScreens.xml?rev=1741789&r1=1741788&r2=1741789&view=diff ============================================================================== --- ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingScreens.xml (original) +++ ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingScreens.xml Sat Apr 30 18:43:10 2016 @@ -90,13 +90,18 @@ under the License. <set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer"/> <property-to-field resource="widget" property="widget.form.defaultViewSize" field="viewSizeDefaultValue"/> <set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="${viewSizeDefaultValue}"/> - + + <set field="asm_multipleSelectForm" value="FindRoutings"/> + <set field="asm_formSize" value="700"/> + <set field="asm_multipleSelect" value="FindRoutings_currentStatusId"/> + <set field="asm_sortable" value="false"/> + <set field="asm_title" value=" "/> <set field="requestParameters.workEffortTypeId" to-scope="screen" default-value="ROUTING"/> - <set field="requestParameters.currentStatusId" to-scope="screen" default-value="ROU_ACTIVE"/> </actions> <widgets> <decorator-screen name="CommonManufacturingDecorator" location="${parameters.commonManufacturingDecoratorLocation}"> <decorator-section name="body"> + <platform-specific><html><html-template location="component://common/webcommon/includes/setMultipleSelectJs.ftl"/></html></platform-specific> <section> <widgets> <decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml"> Modified: ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingTaskForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingTaskForms.xml?rev=1741789&r1=1741788&r2=1741789&view=diff ============================================================================== --- ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingTaskForms.xml (original) +++ ofbiz/trunk/applications/manufacturing/widget/manufacturing/RoutingTaskForms.xml Sat Apr 30 18:43:10 2016 @@ -29,6 +29,13 @@ under the License. <field name="workEffortName" title="${uiLabelMap.ManufacturingRoutingName}"> <text-find/> </field> + <field name="currentStatusId"> + <drop-down allow-multiple="true"> + <entity-options description="${description}" entity-name="StatusItem" key-field-name="statusId"> + <entity-constraint name="statusTypeId" value="ROUTING_STATUS"/> + </entity-options> + </drop-down> + </field> <field name="submitButton" title="${uiLabelMap.CommonFind}"> <submit button-type="button"/> </field> @@ -52,16 +59,23 @@ under the License. <field name="workEffortName" title="${uiLabelMap.ManufacturingRoutingName}"><display/></field> <field name="description"><display/></field> <field name="quantityToProduce" title="${uiLabelMap.ManufacturingQuantityToProduce}"><display/></field> + <field name="currentStatusId"><display-entity entity-name="StatusItem" description="${description}" key-field-name="statusId"/></field> </form> <form name="EditRouting" type="single" target="UpdateRouting" title="" default-map-name="routing" header-row-style="header-row" default-table-style="basic-table"> <alt-target use-when="routing==null" target="CreateRouting"/> <field name="workEffortTypeId" use-when="routing==null"><hidden value="ROUTING"/></field> - <field name="currentStatusId" use-when="routing==null"><hidden value="ROU_ACTIVE"/></field> <field name="workEffortId" use-when="routing!=null"><hidden/></field> <field name="workEffortName" title="${uiLabelMap.ManufacturingRoutingName}"><text/></field> <field name="description"><text/></field> <field name="quantityToProduce" title="${uiLabelMap.ManufacturingQuantityToProduce}"><text/></field> + <field name="currentStatusId"> + <drop-down> + <entity-options description="${description}" entity-name="StatusItem" key-field-name="statusId"> + <entity-constraint name="statusTypeId" value="ROUTING_STATUS"/> + </entity-options> + </drop-down> + </field> <field name="submitButton" title="${uiLabelMap.CommonSubmit}"> <submit button-type="button"/> </field> Modified: ofbiz/trunk/applications/workeffort/data/WorkEffortTypeData.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/data/WorkEffortTypeData.xml?rev=1741789&r1=1741788&r2=1741789&view=diff ============================================================================== --- ofbiz/trunk/applications/workeffort/data/WorkEffortTypeData.xml (original) +++ ofbiz/trunk/applications/workeffort/data/WorkEffortTypeData.xml Sat Apr 30 18:43:10 2016 @@ -191,6 +191,7 @@ under the License. <StatusType description="Manufacturing Task and Routing status" hasTable="N" parentTypeId="WORK_EFFORT_STATUS" statusTypeId="ROUTING_STATUS"/> <StatusItem description="Well defined and usable" sequenceId="01" statusCode="ACTIVE" statusId="ROU_ACTIVE" statusTypeId="ROUTING_STATUS"/> + <StatusItem description="Not well defined and unusable" sequenceId="02" statusCode="INACTIVE" statusId="ROU_INACTIVE" statusTypeId="ROUTING_STATUS"/> <!-- Production Run status --> <StatusType description="Production Run Status" hasTable="N" parentTypeId="WORK_EFFORT_STATUS" statusTypeId="PRODUCTION_RUN"/> @@ -213,6 +214,9 @@ under the License. <StatusValidChange statusId="PRUN_RUNNING" statusIdTo="PRUN_COMPLETED" transitionName="Complete"/> <StatusValidChange statusId="PRUN_COMPLETED" statusIdTo="PRUN_CLOSED" transitionName="Close"/> <StatusValidChange statusId="PRUN_CREATED" statusIdTo="PRUN_CANCELLED" transitionName="Cancel"/> + + <StatusValidChange statusId="ROU_ACTIVE" statusIdTo="ROU_INACTIVE" transitionName="Inactive"/> + <StatusValidChange statusId="ROU_INACTIVE" statusIdTo="ROU_ACTIVE" transitionName="Active"/> <!-- ProductionRun Inventory assignement status --> <WorkEffortGoodStandardType workEffortGoodStdTypeId="ROU_PROD_TEMPLATE" description="Product and Routing Association" hasTable="N" parentTypeId=""/> Modified: ofbiz/trunk/framework/common/config/CommonEntityLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonEntityLabels.xml?rev=1741789&r1=1741788&r2=1741789&view=diff ============================================================================== --- ofbiz/trunk/framework/common/config/CommonEntityLabels.xml (original) +++ ofbiz/trunk/framework/common/config/CommonEntityLabels.xml Sat Apr 30 18:43:10 2016 @@ -12660,7 +12660,7 @@ <property key="StatusItem.description.ROU_ACTIVE"> <value xml:lang="en">Active</value> <value xml:lang="es">Ruta activa</value> - <value xml:lang="fr">Bien défini et utilisable</value> + <value xml:lang="fr">Défini et utilisable</value> <value xml:lang="it">Attiva</value> <value xml:lang="ja">æå¹</value> <value xml:lang="nl">Actief</value> @@ -12671,6 +12671,10 @@ <value xml:lang="zh">ææ</value> <value xml:lang="zh-TW">ææ</value> </property> + <property key="StatusItem.description.ROU_INACTIVE"> + <value xml:lang="en">Inactive</value> + <value xml:lang="fr">Inutilisable</value> + </property> <property key="StatusItem.description.ROU_PROD_TEMPLATE"> <value xml:lang="en">Production Template</value> <value xml:lang="es">Ruta plantilla de producto</value> |
Free forum by Nabble | Edit this page |