Author: ashish
Date: Mon Aug 18 04:47:14 2008 New Revision: 686731 URL: http://svn.apache.org/viewvc?rev=686731&view=rev Log: Patch from JIRA issue https://issues.apache.org/jira/browse/OFBIZ-1910 "Add support of fromDate & thruDate in CustRequestRole entity". Slight change in Entity name in this commit. In the attached patch the name of entity was "CustomerRequestRole" but in this commit the name of new entity is "CustRequestParty"(Looked more close to the data model pattern). Thanks Bilgin for your valuable Input on this. I have also written the Migration service for providing the Backward compatibility. Special thanks to Ratnesh & Jacopo in discussing with me on this work. Modified: ofbiz/trunk/applications/ecommerce/widget/RequestScreens.xml ofbiz/trunk/applications/order/entitydef/entitymodel.xml ofbiz/trunk/applications/order/entitydef/entitymodel_old.xml ofbiz/trunk/applications/order/entitydef/entitymodel_view.xml ofbiz/trunk/applications/order/script/org/ofbiz/order/UpgradeServices.xml ofbiz/trunk/applications/order/script/org/ofbiz/order/quote/QuoteServices.xml ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestServices.xml ofbiz/trunk/applications/order/servicedef/services_request.xml ofbiz/trunk/applications/order/servicedef/services_upgrade.xml ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/controller.xml ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml ofbiz/trunk/applications/order/webapp/ordermgr/request/requestRoles.ftl ofbiz/trunk/applications/order/widget/ordermgr/RequestScreens.xml ofbiz/trunk/specialpurpose/mypage/widget/MyPageScreens.xml ofbiz/trunk/specialpurpose/projectmgr/widget/RequestScreens.xml ofbiz/trunk/specialpurpose/projectmgr/widget/forms/RequestForms.xml Modified: ofbiz/trunk/applications/ecommerce/widget/RequestScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/widget/RequestScreens.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/ecommerce/widget/RequestScreens.xml (original) +++ ofbiz/trunk/applications/ecommerce/widget/RequestScreens.xml Mon Aug 18 04:47:14 2008 @@ -75,7 +75,7 @@ <get-related-one value-name="custRequest" relation-name="ProductStore" to-value-name="store"/> <get-related value-name="custRequest" relation-name="CustRequestItem" list-name="requestItems"/> - <get-related value-name="custRequest" relation-name="CustRequestRole" list-name="requestRoles"/> + <get-related value-name="custRequest" relation-name="CustRequestParty" list-name="requestParties"/> </actions> <widgets> Modified: ofbiz/trunk/applications/order/entitydef/entitymodel.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/entitydef/entitymodel.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/entitydef/entitymodel.xml (original) +++ ofbiz/trunk/applications/order/entitydef/entitymodel.xml Mon Aug 18 04:47:14 2008 @@ -1832,25 +1832,28 @@ <key-map field-name="custRequestTypeId"/> </relation> </entity> - <entity entity-name="CustRequestRole" + <entity entity-name="CustRequestParty" package-name="org.ofbiz.order.request" title="Customer Request Role Entity"> <field name="custRequestId" type="id-ne"></field> <field name="partyId" type="id-ne"></field> <field name="roleTypeId" type="id-ne"></field> + <field name="fromDate" type="date-time"></field> + <field name="thruDate" type="date-time"></field> <prim-key field="custRequestId"/> <prim-key field="partyId"/> <prim-key field="roleTypeId"/> - <relation type="one" fk-name="CUSTREQ_RL_CRQST" rel-entity-name="CustRequest"> + <prim-key field="fromDate"/> + <relation type="one" fk-name="CREQ_RL_CRQST" rel-entity-name="CustRequest"> <key-map field-name="custRequestId"/> </relation> - <relation type="one" fk-name="CUSTREQ_RL_PARTY" rel-entity-name="Party"> + <relation type="one" fk-name="CREQ_RL_PARTY" rel-entity-name="Party"> <key-map field-name="partyId"/> </relation> <relation type="one-nofk" rel-entity-name="RoleType"> <key-map field-name="roleTypeId"/> </relation> - <relation type="one" fk-name="CUSTREQ_RL_PROLE" rel-entity-name="PartyRole"> + <relation type="one" fk-name="CREQ_RL_PROLE" rel-entity-name="PartyRole"> <key-map field-name="partyId"/> <key-map field-name="roleTypeId"/> </relation> Modified: ofbiz/trunk/applications/order/entitydef/entitymodel_old.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/entitydef/entitymodel_old.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/entitydef/entitymodel_old.xml (original) +++ ofbiz/trunk/applications/order/entitydef/entitymodel_old.xml Mon Aug 18 04:47:14 2008 @@ -137,4 +137,29 @@ <key-map field-name="shipmentMethodTypeId"/> </relation> </entity> + + <entity entity-name="OldCustRequestRole" table-name="CUST_REQUEST_ROLE" + package-name="org.ofbiz.order.request" + title="Old Customer Request Role Entity"> + <field name="custRequestId" type="id-ne"></field> + <field name="partyId" type="id-ne"></field> + <field name="roleTypeId" type="id-ne"></field> + <prim-key field="custRequestId"/> + <prim-key field="partyId"/> + <prim-key field="roleTypeId"/> + <relation type="one" fk-name="CUSTREQ_RL_CRQST" rel-entity-name="CustRequest"> + <key-map field-name="custRequestId"/> + </relation> + <relation type="one" fk-name="CUSTREQ_RL_PARTY" rel-entity-name="Party"> + <key-map field-name="partyId"/> + </relation> + <relation type="one-nofk" rel-entity-name="RoleType"> + <key-map field-name="roleTypeId"/> + </relation> + <relation type="one" fk-name="CUSTREQ_RL_PROLE" rel-entity-name="PartyRole"> + <key-map field-name="partyId"/> + <key-map field-name="roleTypeId"/> + </relation> + </entity> + </entitymodel> Modified: ofbiz/trunk/applications/order/entitydef/entitymodel_view.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/entitydef/entitymodel_view.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/entitydef/entitymodel_view.xml (original) +++ ofbiz/trunk/applications/order/entitydef/entitymodel_view.xml Mon Aug 18 04:47:14 2008 @@ -1168,7 +1168,7 @@ title="Customer Request And Role View Entity"> <description>See CustRequest for descriptions of date fields</description> <member-entity entity-alias="CR" entity-name="CustRequest"/> - <member-entity entity-alias="CRR" entity-name="CustRequestRole"/> + <member-entity entity-alias="CRP" entity-name="CustRequestParty"/> <alias entity-alias="CR" name="custRequestId"/> <alias entity-alias="CR" name="custRequestTypeId"/> <alias entity-alias="CR" name="statusId"/> @@ -1181,18 +1181,21 @@ <alias entity-alias="CR" name="createdDate"/> <alias entity-alias="CR" name="lastModifiedDate"/> <alias entity-alias="CR" name="lastModifiedByUserLogin"/> - <alias entity-alias="CRR" name="partyId"/> - <alias entity-alias="CRR" name="roleTypeId"/> - <view-link entity-alias="CR" rel-entity-alias="CRR"> + <alias entity-alias="CRP" name="partyId"/> + <alias entity-alias="CRP" name="roleTypeId"/> + <alias entity-alias="CRP" name="fromDate"/> + <alias entity-alias="CRP" name="thruDate"/> + <view-link entity-alias="CR" rel-entity-alias="CRP"> <key-map field-name="custRequestId"/> </view-link> <relation type="one-nofk" rel-entity-name="CustRequest"> <key-map field-name="custRequestId"/> </relation> - <relation type="one-nofk" rel-entity-name="CustRequestRole"> + <relation type="one-nofk" rel-entity-name="CustRequestParty"> <key-map field-name="custRequestId"/> <key-map field-name="partyId"/> <key-map field-name="roleTypeId"/> + <key-map field-name="fromDate"/> </relation> <relation type="one-nofk" rel-entity-name="Party"> <key-map field-name="partyId"/> Modified: ofbiz/trunk/applications/order/script/org/ofbiz/order/UpgradeServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/script/org/ofbiz/order/UpgradeServices.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/script/org/ofbiz/order/UpgradeServices.xml (original) +++ ofbiz/trunk/applications/order/script/org/ofbiz/order/UpgradeServices.xml Mon Aug 18 04:47:14 2008 @@ -35,5 +35,18 @@ <create-value value-name="orderItemAssoc"/> </iterate> </simple-method> + + <simple-method method-name="migrateCustRequestRole" short-description="Migrate data from OldCustRequestRole to CustRequestParty"> + <entity-condition entity-name="OldCustRequestRole" list-name="oldCustRequestRoles"/> + <now-timestamp-to-env env-name="fromDate"/> + <iterate list-name="oldCustRequestRoles" entry-name="oldCustRequestRole"> + <make-value entity-name="CustRequestParty" value-name="custRequestParty"/> + <set field="custRequestParty.custRequestId" from-field="oldCustRequestRole.custRequestId"/> + <set field="custRequestParty.partyId" from-field="oldCustRequestRole.partyId"/> + <set field="custRequestParty.roleTypeId" from-field="oldCustRequestRole.roleTypeId"/> + <set field="custRequestParty.fromDate" from-field="fromDate"/> + <create-value value-name="custRequestParty"/> + </iterate> + </simple-method> </simple-methods> Modified: ofbiz/trunk/applications/order/script/org/ofbiz/order/quote/QuoteServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/script/org/ofbiz/order/quote/QuoteServices.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/script/org/ofbiz/order/quote/QuoteServices.xml (original) +++ ofbiz/trunk/applications/order/script/org/ofbiz/order/quote/QuoteServices.xml Mon Aug 18 04:47:14 2008 @@ -527,9 +527,9 @@ <create-value value-name="newQuote"/> <create-value value-name="newQuoteItem"/> <!-- copy the roles from the request to the quote--> - <make-value value-name="lookupRequestRole" entity-name="CustRequestRole"/> + <make-value value-name="lookupRequestRole" entity-name="CustRequestParty"/> <set from-field="parameters.custRequestId" field="lookupRequestRole.custRequestId"/> - <find-by-and entity-name="CustRequestRole" map-name="lookupRequestRole" list-name="roles"/> + <find-by-and entity-name="CustRequestParty" map-name="lookupRequestRole" list-name="roles"/> <iterate entry-name="role" list-name="roles"> <clear-field field-name="cqrContext"/> <set from-field="quoteId" field="cqrContext.quoteId"/> @@ -848,14 +848,14 @@ <call-service service-name="createQuoteItem" in-map-name="createQuoteItemInMap"/> </iterate> <!-- roles --> - <get-related value-name="custRequest" relation-name="CustRequestRole" list-name="custRequestRoles"/> - <iterate list-name="custRequestRoles" entry-name="custRequestRole"> + <get-related value-name="custRequest" relation-name="CustRequestParty" list-name="custRequestParties"/> + <iterate list-name="custRequestParties" entry-name="custRequestParty"> <clear-field field-name="createQuoteRoleInMap"/> <!-- The REQ_TAKER role is automatically added by the createQuote service --> - <if-compare field="custRequestRole.roleTypeId" value="REQ_TAKER" operator="not-equals"> + <if-compare field="custRequestParty.roleTypeId" value="REQ_TAKER" operator="not-equals"> <set field="createQuoteRoleInMap.quoteId" from-field="quoteId"/> - <set field="createQuoteRoleInMap.partyId" from-field="custRequestRole.partyId"/> - <set field="createQuoteRoleInMap.roleTypeId" from-field="custRequestRole.roleTypeId"/> + <set field="createQuoteRoleInMap.partyId" from-field="custRequestParty.partyId"/> + <set field="createQuoteRoleInMap.roleTypeId" from-field="custRequestParty.roleTypeId"/> <call-service service-name="createQuoteRole" in-map-name="createQuoteRoleInMap"/> </if-compare> </iterate> Modified: ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestServices.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestServices.xml (original) +++ ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestServices.xml Mon Aug 18 04:47:14 2008 @@ -62,7 +62,7 @@ <set from-field="newEntity.custRequestId" field="takerMap.custRequestId"/> <set from-field="userLogin.partyId" field="takerMap.partyId"/> <set value="REQ_TAKER" field="takerMap.roleTypeId"/> - <call-service service-name="createCustRequestRole" in-map-name="takerMap"/> + <call-service service-name="createCustRequestParty" in-map-name="takerMap"/> </if-compare-field> </if-not-empty> @@ -70,7 +70,7 @@ <set-service-fields to-map-name="statusMap" service-name="createCustRequestStatus" map-name="newEntity"/> <call-service service-name="createCustRequestStatus" in-map-name="statusMap"/> - <!-- This code is commented because the requester party is no more maintained in the CustRequestRole entity. + <!-- This code is commented because the requester party is no more maintained in the CustRequestParty entity. There is now the fromPartyId field in the CustRequest entity for this. --> <!-- <field-to-field field-name="custRequestId" map-name="newEntity" to-map-name="requesterMap"/> @@ -81,7 +81,7 @@ </else> </if-not-empty> <string-to-field string="REQ_REQUESTER" map-name="requesterMap" field-name="roleTypeId"/> - <call-service service-name="createCustRequestRole" in-map-name="requesterMap"/> + <call-service service-name="createCustRequestParty" in-map-name="requesterMap"/> --> <!-- create also the item if key fields are provided --> @@ -153,7 +153,7 @@ <store-value value-name="custRequestItem"/> </simple-method> - <simple-method method-name="createCustRequestRole" short-description="Create Customer RequestRole"> + <simple-method method-name="createCustRequestParty" short-description="Create Customer RequestParty"> <set from-field="parameters.partyId" field="lookupPKMap.partyId"/> <set from-field="parameters.roleTypeId" field="lookupPKMap.roleTypeId"/> <find-by-primary-key entity-name="PartyRole" map-name="lookupPKMap" value-name="partyRole"/> @@ -162,18 +162,25 @@ <set-pk-fields map-name="lookupPKMap" value-name="partyRole"/> <create-value value-name="partyRole"/> </if-empty> - <make-value value-name="newEntity" entity-name="CustRequestRole"/> + <make-value value-name="newEntity" entity-name="CustRequestParty"/> <set-pk-fields map-name="parameters" value-name="newEntity"/> + <set-nonpk-fields map-name="parameters" value-name="newEntity"/> + <if-empty field="newEntity.fromDate"> + <now-timestamp-to-env env-name="newEntity.fromDate"/> + </if-empty> <create-value value-name="newEntity"/> </simple-method> - <simple-method method-name="removeCustRequestRole" short-description="Remove Customer RequestRole"> - <set from-field="parameters.custRequestId" field="lookupPKMap.custRequestId"/> - <set from-field="parameters.partyId" field="lookupPKMap.partyId"/> - <set from-field="parameters.roleTypeId" field="lookupPKMap.roleTypeId"/> - <find-by-primary-key entity-name="CustRequestRole" map-name="lookupPKMap" value-name="custRequestRole"/> - <remove-value value-name="custRequestRole"/> + <simple-method method-name="updateCustRequestParty" short-description="Update an existing CustRequestParty"> + <entity-one entity-name="CustRequestParty" value-name="lookedUpValue"/> + <set-nonpk-fields map-name="parameters" value-name="lookedUpValue"/> + <store-value value-name="lookedUpValue"/> + </simple-method> + <simple-method method-name="deleteCustRequestParty" short-description="Delete Customer CustRequestParty"> + <entity-one entity-name="CustRequestParty" value-name="lookedUpValue"/> + <now-timestamp-to-env env-name="thruDate"/> + <set field="lookedUpValue.thruDate" from-field="thruDate"/> + <store-value value-name="lookedUpValue"/> </simple-method> - <simple-method method-name="createCustRequestNote" short-description="Create Customer Request Note"> <make-value value-name="newEntity" entity-name="CustRequestNote"/> <set from-field="parameters.custRequestId" field="newEntity.custRequestId"/> Modified: ofbiz/trunk/applications/order/servicedef/services_request.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/servicedef/services_request.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/servicedef/services_request.xml (original) +++ ofbiz/trunk/applications/order/servicedef/services_request.xml Mon Aug 18 04:47:14 2008 @@ -78,22 +78,25 @@ <attribute name="copyLinkedQuotes" type="String" mode="IN" optional="true"/> </service> - <service name="createCustRequestRole" engine="simple" - location="org/ofbiz/order/request/CustRequestServices.xml" invoke="createCustRequestRole" auth="true"> - <description>Create a CustRequestRole record</description> - <attribute name="custRequestId" type="String" mode="IN" optional="false"/> - <attribute name="partyId" type="String" mode="IN" optional="false"/> - <attribute name="roleTypeId" type="String" mode="IN" optional="false"/> + <service name="createCustRequestParty" engine="simple" default-entity-name="CustRequestParty" + location="org/ofbiz/order/request/CustRequestServices.xml" invoke="createCustRequestParty" auth="true"> + <description>Create a CustRequestParty record</description> + <auto-attributes mode="IN" include="pk" optional="false"/> + <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="fromDate" mode="IN" type="Timestamp" optional="true"/> </service> - <service name="removeCustRequestRole" engine="simple" - location="org/ofbiz/order/request/CustRequestServices.xml" invoke="removeCustRequestRole" auth="true"> - <description>Remove a CustRequestRole record</description> - <attribute name="custRequestId" type="String" mode="IN" optional="false"/> - <attribute name="partyId" type="String" mode="IN" optional="false"/> - <attribute name="roleTypeId" type="String" mode="IN" optional="false"/> + <service name="updateCustRequestParty" engine="simple" default-entity-name="CustRequestParty" + location="org/ofbiz/order/request/CustRequestServices.xml" invoke="updateCustRequestParty" auth="true"> + <description>Update CustRequestParty record</description> + <auto-attributes mode="IN" include="pk" optional="true"/> + <auto-attributes mode="IN" include="nonpk" optional="true"/> </service> - - <service name="createCustRequestNote" engine="simple" + <service name="deleteCustRequestParty" engine="simple" default-entity-name="CustRequestParty" + location="org/ofbiz/order/request/CustRequestServices.xml" invoke="deleteCustRequestParty" auth="true"> + <description>Delete a CustRequestParty record</description> + <auto-attributes mode="IN" include="pk" optional="false"/> + </service> + <service name="createCustRequestNote" engine="simple" location="org/ofbiz/order/request/CustRequestServices.xml" invoke="createCustRequestNote" auth="true"> <description>Create a note for a CustRequest</description> <attribute name="custRequestId" type="String" mode="IN" optional="false"/> Modified: ofbiz/trunk/applications/order/servicedef/services_upgrade.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/servicedef/services_upgrade.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/servicedef/services_upgrade.xml (original) +++ ofbiz/trunk/applications/order/servicedef/services_upgrade.xml Mon Aug 18 04:47:14 2008 @@ -34,4 +34,15 @@ order/data/OrderTypeData.xml </description> </service> + <service name="migrateCustRequestRole" engine="simple" + location="org/ofbiz/order/UpgradeServices.xml" invoke="migrateCustRequestRole"> + <description> + Migrate data from OldCustRequestRole to CustRequestParty. + Since revision 684647 (2008-08-11) the entity CustRequestRole has been deprecated. + This service can be used to upgrade existing data from the OldCustRequestRole entity to the new + CustRequestParty entity. + Before running this service, load the seed data for the RoleType entity from the file: + party/data/PartyTypeData.xml + </description> + </service> </services> Modified: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/controller.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/controller.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/controller.xml (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/controller.xml Mon Aug 18 04:47:14 2008 @@ -1119,15 +1119,21 @@ </request-map> <request-map uri="requestroles"><security https="true" auth="true"/><response name="success" type="view" value="RequestRoles"/></request-map> - <request-map uri="createrequestrole"> + <request-map uri="createCustRequestParty"> <security https="true" auth="true"/> - <event type="service" invoke="createCustRequestRole"/> + <event type="service" invoke="createCustRequestParty"/> <response name="success" type="view" value="RequestRoles"/> <response name="error" type="view" value="RequestRoles"/> </request-map> - <request-map uri="removerequestrole"> + <request-map uri="updateCustRequestParty"> <security https="true" auth="true"/> - <event type="service" invoke="removeCustRequestRole"/> + <event type="service" invoke="updateCustRequestParty"/> + <response name="success" type="view" value="RequestRoles"/> + <response name="error" type="view" value="RequestRoles"/> + </request-map> + <request-map uri="deleteCustRequestParty"> + <security https="true" auth="true"/> + <event type="service" invoke="deleteCustRequestParty"/> <response name="success" type="view" value="RequestRoles"/> <response name="error" type="view" value="RequestRoles"/> </request-map> Modified: ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml Mon Aug 18 04:47:14 2008 @@ -382,9 +382,9 @@ </field> </form> - <form name="ListRequestRoles" type="list" use-row-submit="true" title="" list-name="custRequestRoles" + <form name="ListRequestParty" type="list" use-row-submit="true" title="" list-name="custRequestParties" target="updateCustRequestParty" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar" paginate-target="RequestRoles"> - <auto-fields-entity entity-name="CustRequestRole" default-field-type="display"/> + <auto-fields-entity entity-name="CustRequestParty" default-field-type="display"/> <field name="custRequestId"><hidden/></field> <field name="partyId" widget-style="buttontext"> <hyperlink description="${partyId}" target-type="inter-app" target="/partymgr/control/viewprofile?partyId=${partyId}"/> @@ -393,14 +393,16 @@ <display-entity also-hidden="false" entity-name="PartyNameView" key-field-name="partyId" description="${groupName}${firstName} ${lastName}"/> </field> <field name="roleTypeId" title="${uiLabelMap.PartyRoleType}"> - <display-entity also-hidden="false" entity-name="RoleType"/> - </field> - <field name="remove" widget-style="buttontext"> - <hyperlink description="${uiLabelMap.CommonDelete}" target="removerequestrole?custRequestId=${custRequestId}&partyId=${partyId}&roleTypeId=${roleTypeId}"/> + <display-entity also-hidden="true" entity-name="RoleType"/> </field> + <field name="thruDate" title="${uiLabelMap.CommonThruDate}"><date-time/></field> + <field name="submitButton" title="${uiLabelMap.CommonUpdate}" widget-style="smallSubmit"><submit button-type="button"/></field> + <field name="deleteLink" widget-style="buttontext"> + <hyperlink description="${uiLabelMap.CommonDelete}" target="deleteCustRequestParty?custRequestId=${custRequestId}&partyId=${partyId}&roleTypeId=${roleTypeId}&fromDate=${fromDate}"/> + </field> </form> - <form name="EditRequestRole" type="single" target="createrequestrole" title="" + <form name="EditRequestRole" type="single" target="createCustRequestParty" title="" header-row-style="header-row" default-table-style="basic-table"> <field name="custRequestId"><hidden/></field> <field name="partyId"><lookup target-form-name="LookupPartyName"/></field> @@ -412,6 +414,8 @@ <option key="REQ_MANAGER" description="${uiLabelMap.WorkEffortRequestManager}"/> </drop-down> </field> + <field name="fromDate" title="${uiLabelMap.CommonFromDate}"><date-time/></field> + <field name="thruDate" title="${uiLabelMap.CommonThruDate}"><date-time/></field> <field name="submitButton" title="${uiLabelMap.CommonSubmit}" widget-style="smallSubmit"><submit button-type="button"/></field> </form> <form name="ListRequestItemRequirements" type="list" title="" list-name="custRequestRequirements" Modified: ofbiz/trunk/applications/order/webapp/ordermgr/request/requestRoles.ftl URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/request/requestRoles.ftl?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/request/requestRoles.ftl (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/request/requestRoles.ftl Mon Aug 18 04:47:14 2008 @@ -23,9 +23,9 @@ <div class="screenlet-body"> <table cellspacing="0" class="basic-table"> <#assign row = 1> - <#list requestRoles as requestRole> - <#assign roleType = requestRole.getRelatedOne("RoleType")> - <#assign party = requestRole.getRelatedOne("Party")> + <#list requestParties as requestParty> + <#assign roleType = requestParty.getRelatedOne("RoleType")> + <#assign party = requestParty.getRelatedOne("Party")> <tr> <td align="right" valign="top" width="15%" class="label"> ${roleType.get("description", locale)?if_exists} @@ -35,7 +35,7 @@ ${Static["org.ofbiz.party.party.PartyHelper"].getPartyName(party)} </td> </tr> - <#if requestRoles.size() != row> + <#if requestParties.size() != row> <tr><td colspan="3"><hr/></td></tr> </#if> <#assign row = row + 1> Modified: ofbiz/trunk/applications/order/widget/ordermgr/RequestScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/widget/ordermgr/RequestScreens.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/applications/order/widget/ordermgr/RequestScreens.xml (original) +++ ofbiz/trunk/applications/order/widget/ordermgr/RequestScreens.xml Mon Aug 18 04:47:14 2008 @@ -61,7 +61,7 @@ <entity-and list-name="requestWorkEfforts" entity-name="CustRequestAndWorkEffort"> <field-map field-name="custRequestId" env-name="parameters.custRequestId"/> </entity-and> - <get-related value-name="custRequest" relation-name="CustRequestRole" list-name="requestRoles"/> + <get-related value-name="custRequest" relation-name="CustRequestParty" list-name="requestParties"/> <set field="orderBy[]" value="sequenceNum"/> <get-related value-name="custRequest" relation-name="CustRequestItem" list-name="custRequestItems" order-by-list-name="orderBy"/> <entity-and list-name="commEvents" entity-name="CommunicationEventAndCustRequest"> @@ -131,7 +131,7 @@ <set field="headerItem" value="request"/> <set field="custRequestId" from-field="parameters.custRequestId"/> <entity-one entity-name="CustRequest" value-name="custRequest"/> - <entity-and entity-name="CustRequestRole" list-name="custRequestRoles"> + <entity-and entity-name="CustRequestParty" list-name="custRequestParties"> <field-map env-name="custRequestId" field-name="custRequestId"/> </entity-and> </actions> @@ -141,7 +141,7 @@ <screenlet id="EditRequestRolePanel" title="${uiLabelMap.PageTitleEditRequestRoles}" collapsible="true"> <include-form name="EditRequestRole" location="component://order/webapp/ordermgr/request/RequestForms.xml"/> </screenlet> - <include-form name="ListRequestRoles" location="component://order/webapp/ordermgr/request/RequestForms.xml"/> + <include-form name="ListRequestParty" location="component://order/webapp/ordermgr/request/RequestForms.xml"/> </decorator-section> </decorator-screen> </widgets> Modified: ofbiz/trunk/specialpurpose/mypage/widget/MyPageScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/mypage/widget/MyPageScreens.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/mypage/widget/MyPageScreens.xml (original) +++ ofbiz/trunk/specialpurpose/mypage/widget/MyPageScreens.xml Mon Aug 18 04:47:14 2008 @@ -394,7 +394,7 @@ <entity-and list-name="requestWorkEfforts" entity-name="CustRequestAndWorkEffort"> <field-map field-name="custRequestId" env-name="parameters.custRequestId"/> </entity-and> - <get-related value-name="custRequest" relation-name="CustRequestRole" list-name="requestRoles"/> + <get-related value-name="custRequest" relation-name="CustRequestParty" list-name="requestParties"/> <set field="orderBy[]" value="sequenceNum"/> <get-related value-name="custRequest" relation-name="CustRequestItem" list-name="custRequestItems" order-by-list-name="orderBy"/> <entity-and list-name="commEvents" entity-name="CommunicationEventAndCustRequest"> Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/RequestScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/RequestScreens.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/RequestScreens.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/RequestScreens.xml Mon Aug 18 04:47:14 2008 @@ -100,7 +100,7 @@ <entity-and list-name="requestWorkEfforts" entity-name="CustRequestAndWorkEffort"> <field-map field-name="custRequestId" env-name="parameters.custRequestId"/> </entity-and> - <get-related value-name="custRequest" relation-name="CustRequestRole" list-name="requestRoles"/> + <get-related value-name="custRequest" relation-name="CustRequestParty" list-name="requestParties"/> <set field="orderBy[]" value="sequenceNum"/> <get-related value-name="custRequest" relation-name="CustRequestItem" list-name="custRequestItems" order-by-list-name="orderBy"/> <entity-and list-name="commEvents" entity-name="CommunicationEventAndCustRequest"> Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/forms/RequestForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/forms/RequestForms.xml?rev=686731&r1=686730&r2=686731&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/forms/RequestForms.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/forms/RequestForms.xml Mon Aug 18 04:47:14 2008 @@ -92,7 +92,7 @@ <form name="RequestRolesInfo" type="list" odd-row-style="alternate-row" default-table-style="basic-table hover-bar"> <actions> - <entity-and entity-name="CustRequestRole"> + <entity-and entity-name="CustRequestParty"> <field-map field-name="custRequestId" env-name="custRequestId"/> </entity-and> </actions> |
Free forum by Nabble | Edit this page |