svn commit: r915258 - in /ofbiz/trunk/applications/accounting: data/AccountingTypeData.xml widget/FixedAssetForms.xml

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

svn commit: r915258 - in /ofbiz/trunk/applications/accounting: data/AccountingTypeData.xml widget/FixedAssetForms.xml

mor-2
Author: mor
Date: Tue Feb 23 09:35:22 2010
New Revision: 915258

URL: http://svn.apache.org/viewvc?rev=915258&view=rev
Log:
Added missing StatusValidChange data for fixed asset maintenance status and done corresponding changes to the fixed asset maintenance form definition.

Modified:
    ofbiz/trunk/applications/accounting/data/AccountingTypeData.xml
    ofbiz/trunk/applications/accounting/widget/FixedAssetForms.xml

Modified: ofbiz/trunk/applications/accounting/data/AccountingTypeData.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/data/AccountingTypeData.xml?rev=915258&r1=915257&r2=915258&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/data/AccountingTypeData.xml (original)
+++ ofbiz/trunk/applications/accounting/data/AccountingTypeData.xml Tue Feb 23 09:35:22 2010
@@ -181,6 +181,12 @@
     <StatusItem description="In Process" sequenceId="05" statusCode="IN_PROCESS" statusId="FAM_IN_PROCESS" statusTypeId="FIXEDAST_MNT_STATUS"/>
     <StatusItem description="Completed" sequenceId="10" statusCode="COMPLETED" statusId="FAM_COMPLETED" statusTypeId="FIXEDAST_MNT_STATUS"/>
     <StatusItem description="Cancelled" sequenceId="99" statusCode="CANCELLED" statusId="FAM_CANCELLED" statusTypeId="FIXEDAST_MNT_STATUS"/>
+    <StatusValidChange condition="" statusId="FAM_CREATED" statusIdTo="FAM_SCHEDULED" transitionName="Created Maintenance Scheduled"/>
+    <StatusValidChange condition="" statusId="FAM_CREATED" statusIdTo="FAM_IN_PROCESS" transitionName="Created Maintenance In-Process"/>
+    <StatusValidChange condition="" statusId="FAM_CREATED" statusIdTo="FAM_CANCELLED" transitionName="Created Maintenace Cancelled"/>
+    <StatusValidChange condition="" statusId="FAM_SCHEDULED" statusIdTo="FAM_IN_PROCESS" transitionName="Scheduled Maintenace In-Process"/>
+    <StatusValidChange condition="" statusId="FAM_SCHEDULED" statusIdTo="FAM_CANCELLED" transitionName="Scheduled Maintenace Cancelled"/>
+    <StatusValidChange condition="" statusId="FAM_IN_PROCESS" statusIdTo="FAM_COMPLETED" transitionName="In-Process Maintenance Completed"/>
 
     <!-- The following three elements set up a regularly scheduled job that will automatically create
         fixed asset maintenances from ProductMaint time intervals. -->

Modified: ofbiz/trunk/applications/accounting/widget/FixedAssetForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/FixedAssetForms.xml?rev=915258&r1=915257&r2=915258&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/widget/FixedAssetForms.xml (original)
+++ ofbiz/trunk/applications/accounting/widget/FixedAssetForms.xml Tue Feb 23 09:35:22 2010
@@ -355,6 +355,11 @@
 
     <form name="EditFixedAssetMaint" type="single" default-map-name="fixedAssetMaint" target="updateFixedAssetMaint" title=""
         header-row-style="header-row" default-table-style="basic-table">
+        <actions>
+            <entity-one entity-name="StatusItem" value-field="currentStatus" auto-field-map="false">
+                <field-map field-name="statusId" from-field="fixedAssetMaint.statusId"/>
+            </entity-one>
+        </actions>
         <alt-target use-when="fixedAssetMaint==null" target="createFixedAssetMaint"/>
         <field name="fixedAssetId"><hidden/></field>
         <field name="estimatedStartDate"><hidden value="${parameters.estimatedStartDate}"/></field>
@@ -362,7 +367,7 @@
         <field use-when="fixedAssetMaint==null" name="maintHistSeqId"><ignored/></field>
         <field use-when="fixedAssetMaint!=null" name="maintHistSeqId"><display/></field>
         <field use-when="fixedAssetMaint!=null" title="${uiLabelMap.CommonCreated}" name="createdStamp"><display/></field>
-        <field name="statusId" title="${uiLabelMap.CommonStatus}">
+        <field name="statusId" use-when="fixedAssetMaint==null" title="${uiLabelMap.CommonStatus}">
             <drop-down allow-empty="false">
                 <entity-options description="${description}" entity-name="StatusItem">
                     <entity-constraint name="statusTypeId" operator="equals" value="FIXEDAST_MNT_STATUS"/>
@@ -370,6 +375,14 @@
                 </entity-options>
             </drop-down>
         </field>
+        <field name="statusId" use-when="fixedAssetMaint!=null" title="${uiLabelMap.CommonStatus}">
+            <drop-down allow-empty="false" current-description="${currentStatus.description}">
+                <entity-options entity-name="StatusValidChangeToDetail" key-field-name="statusIdTo" description="${transitionName} (${description})">
+                    <entity-constraint name="statusId" env-name="fixedAssetMaint.statusId"/>
+                    <entity-order-by field-name="sequenceId"/>
+                </entity-options>
+            </drop-down>
+        </field>
         <field name="productMaintTypeId" title="${uiLabelMap.AccountingFixedAssetMaintType}" tooltip="${uiLabelMap.AccountingFixedAssetMaintMessage1}">
             <drop-down allow-empty="true">
                 <entity-options description="${description}" entity-name="ProductMaintType">