Hi Rishi/Ratnesh,
IMO relationship should be one-nofk, as website can be empty. Thanks & Regards -- Deepak Dixit www.hotwaxsystems.com www.hotwax.co On Tue, Sep 26, 2017 at 8:03 PM, <[hidden email]> wrote: > Author: rishi > Date: Tue Sep 26 14:33:05 2017 > New Revision: 1809749 > > URL: http://svn.apache.org/viewvc?rev=1809749&view=rev > Log: > Improvement: Missing Relationship from OrderHeader to WebSite > (OFBIZ-9647). Added relationship from order header to website entity. And > removed wrong data. > Applied patch from (OFBIZ-9647). Thanks Ratnesh Upadhyay for your > contribution. > > Modified: > ofbiz/ofbiz-framework/trunk/applications/datamodel/ > entitydef/order-entitymodel.xml > ofbiz/ofbiz-framework/trunk/applications/order/data/ > DemoOrderTestData.xml > ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml > ofbiz/ofbiz-framework/trunk/applications/order/testdef/ > data/OrderTestData.xml > > Modified: ofbiz/ofbiz-framework/trunk/applications/datamodel/ > entitydef/order-entitymodel.xml > URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > applications/datamodel/entitydef/order-entitymodel. > xml?rev=1809749&r1=1809748&r2=1809749&view=diff > ============================================================ > ================== > --- ofbiz/ofbiz-framework/trunk/applications/datamodel/ > entitydef/order-entitymodel.xml (original) > +++ ofbiz/ofbiz-framework/trunk/applications/datamodel/ > entitydef/order-entitymodel.xml Tue Sep 26 14:33:05 2017 > @@ -432,6 +432,9 @@ under the License. > <relation type="one" fk-name="ORDER_HDR_CUOM" rel-entity-name="Uom"> > <key-map field-name="currencyUom" rel-field-name="uomId"/> > </relation> > + <relation type="one" fk-name="ORDER_HDR_WS" > rel-entity-name="WebSite"> > + <key-map field-name="webSiteId"/> > + </relation> > <index name="ORDEREXT_ID_IDX"> > <index-field name="externalId"/> > </index> > > Modified: ofbiz/ofbiz-framework/trunk/applications/order/data/ > DemoOrderTestData.xml > URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > applications/order/data/DemoOrderTestData.xml?rev= > 1809749&r1=1809748&r2=1809749&view=diff > ============================================================ > ================== > --- ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrderTestData.xml > (original) > +++ ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrderTestData.xml > Tue Sep 26 14:33:05 2017 > @@ -20,7 +20,7 @@ under the License. > > <entity-engine-xml> > <!--Demo data for a sales order --> > - <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" > orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 > 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" > currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > remainingSubTotal="38.40" grandTotal="50.85" invoicePerShipment="Y"/> > + <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" > orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 > 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" > currencyUom="USD" productStoreId="9000" remainingSubTotal="38.40" > grandTotal="50.85" invoicePerShipment="Y"/> > <OrderItem orderId="DEMO10090" orderItemSeqId="00001" > orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" selectedAmount="0.0" > unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" > itemDescription="Round Gizmo" correspondingPoId="" > statusId="ITEM_APPROVED"/> > <OrderItemPriceInfo orderItemPriceInfoId="9000" orderId="DEMO10090" > orderItemSeqId="00001" productPriceRuleId="9000" > productPriceActionSeqId="01" modifyAmount="-9.600" description="[PRODUCT_CATEGORY_IDIsPROMOTIONS] > [list:48.0;avgCost:48.0;margin:0.0] [type:PRICE_POL]"/> > > @@ -59,7 +59,7 @@ under the License. > > <!-- Purchase order test data --> > <!--for jira issue - 1782--> > - <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" > orderName="New Purchase Order" salesChannelEnumId="UNKNWN_SALES_CHANNEL" > orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" > visitId="10000" statusId="ORDER_CREATED" createdBy="admin" > currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > remainingSubTotal="108.0" grandTotal="108.0"/> > + <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" > orderName="New Purchase Order" salesChannelEnumId="UNKNWN_SALES_CHANNEL" > orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" > visitId="10000" statusId="ORDER_CREATED" createdBy="admin" > currencyUom="USD" productStoreId="9000" remainingSubTotal="108.0" > grandTotal="108.0"/> > <OrderItem orderId="DEMO10091" orderItemSeqId="00001" > orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > prodCatalogId="DemoCatalog" isPromo="N" quantity="5.0" selectedAmount="0.0" > unitPrice="21.6" unitListPrice="0.0" isModifiedPrice="N" > itemDescription="GZ-2644-5 Round Gizmo" statusId="ITEM_CREATED"/> > <OrderItemPriceInfo orderItemPriceInfoId="10001" orderId="DEMO10091" > orderItemSeqId="00001" description="SupplierProduct > [minimumOrderQuantity:5.0, lastPrice: 21.6]"/> > <OrderItemPriceInfo orderItemPriceInfoId="10002" orderId="DEMO10091" > orderItemSeqId="00001" description="SupplierProduct > [minimumOrderQuantity:0.0, lastPrice: 24.0]"/> > @@ -82,7 +82,7 @@ under the License. > <ItemIssuance itemIssuanceId="9003" orderId="DEMO10091" > orderItemSeqId="00001" shipGroupSeqId="00001" shipmentId="9999" > shipmentItemSeqId="00001" issuedDateTime="2009-08-13 17:46:29.603" > quantity="5"/> > > <!--Demo Purchase Order data for Accounting--> > - <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" > orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SALES_CHANNEL" > orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 > 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" > webSiteId="OrderEntry" remainingSubTotal="48.00" grandTotal="48.00"/> > + <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" > orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SALES_CHANNEL" > orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 > 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" > remainingSubTotal="48.00" grandTotal="48.00"/> > <OrderItem orderId="Demo1001" orderItemSeqId="00001" > orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" > selectedAmount="0.000000" unitPrice="24.00" unitListPrice="0.00" > isModifiedPrice="N" itemDescription="GZ-2644-0 Round Gizmo" > statusId="ITEM_COMPLETED" estimatedDeliveryDate="2009-08-13 17:43:53.0"/> > <OrderItemPriceInfo orderItemPriceInfoId="9001" orderId="Demo1001" > orderItemSeqId="00001" description="SupplierProduct [minimumOrderQuantity:0.000000, > lastPrice: 24.000]"/> > <OrderRole orderId="Demo1001" partyId="Company" > roleTypeId="BILL_TO_CUSTOMER" /> > @@ -126,7 +126,7 @@ under the License. > <AcctgTransEntry acctgTransId="9001" acctgTransEntrySeqId="00002" > acctgTransEntryTypeId="_NA_" partyId="DemoSupplier" > roleTypeId="BILL_FROM_VENDOR" glAccountTypeId="ACCOUNTS_PAYABLE" > glAccountId="210000" organizationPartyId="Company" amount="48.00" > currencyUomId="USD" origAmount="48.00" origCurrencyUomId="USD" > debitCreditFlag="C" reconcileStatusId="AES_NOT_RECONCILED"/> > > <!--Demo Sales Order for Accounting--> > - <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" > orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" > orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 > 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" createdBy="admin" > currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > remainingSubTotal="107.98" grandTotal="127.09"/> > + <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" > orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" > orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 > 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" createdBy="admin" > currencyUom="USD" productStoreId="9000" remainingSubTotal="107.98" > grandTotal="127.09"/> > <OrderItem orderId="Demo1002" orderItemSeqId="00001" > orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" > prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" > selectedAmount="0.000000" unitPrice="59.99" unitListPrice="60.00" > isModifiedPrice="N" itemDescription="Micro Chrome Widget" > correspondingPoId="" statusId="ITEM_COMPLETED"/> > <OrderItem orderId="Demo1002" orderItemSeqId="00004" > orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" isPromo="Y" > quantity="1.000000" selectedAmount="0.000000" unitPrice="59.99" > unitListPrice="60.00" isModifiedPrice="N" itemDescription="Micro Chrome > Widget" correspondingPoId="" statusId="ITEM_COMPLETED"/> > <PartyRole partyId="DemoCustomer" roleTypeId="END_USER_CUSTOMER"/> > > Modified: ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > secas.xml > URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > applications/order/servicedef/secas.xml?rev=1809749&r1= > 1809748&r2=1809749&view=diff > ============================================================ > ================== > --- ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml > (original) > +++ ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml > Tue Sep 26 14:33:05 2017 > @@ -401,7 +401,6 @@ under the License. > <condition field-name="oldStatusId" operator="not-equals" > value="CRQ_ACCEPTED"/> > <condition field-name="oldStatusId" operator="not-equals" > value="CRQ_PENDING"/> > <condition field-name="statusId" operator="equals" > value="CRQ_ACCEPTED"/> > - <condition field-name="webSiteId" operator="equals" > value="OrderEntry"/> > <set field-name="bodyParameters.custRequestId" > env-name="custRequestId"/> > <set field-name="bodyParameters.custRequestName" > env-name="custRequestName"/> > <set field-name="partyIdTo" env-name="fromPartyId"/> > @@ -412,7 +411,6 @@ under the License. > <eca service="setCustRequestStatus" event="commit"> > <condition field-name="oldStatusId" operator="not-equals" > value="CRQ_COMPLETED"/> > <condition field-name="statusId" operator="equals" > value="CRQ_COMPLETED"/> > - <condition field-name="webSiteId" operator="equals" > value="OrderEntry"/> > <set field-name="bodyParameters.custRequestId" > env-name="custRequestId"/> > <set field-name="partyIdTo" env-name="fromPartyId"/> > <set field-name="emailTemplateSettingId" > value="CUST_REQ_COMPLETED"/> > > Modified: ofbiz/ofbiz-framework/trunk/applications/order/testdef/ > data/OrderTestData.xml > URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > applications/order/testdef/data/OrderTestData.xml?rev= > 1809749&r1=1809748&r2=1809749&view=diff > ============================================================ > ================== > --- ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/OrderTestData.xml > (original) > +++ ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/OrderTestData.xml > Tue Sep 26 14:33:05 2017 > @@ -30,7 +30,7 @@ under the License. > <ProductStoreEmailSetting productStoreId="9000" > emailType="PRDS_ODR_CONFIRM" bodyScreenLocation="component: > //ecommerce/widget/EmailOrderScreens.xml#OrderConfirmNotice" > xslfoAttachScreenLocation="component://ecommerce/widget/ > EmailOrderScreens.xml#OrderConfirmNoticePdf" subject="OFBiz Demo - Order > Confirmation #${orderId}" bccAddress="[hidden email]" fromAddress=" > [hidden email]"/> > > <!--Demo data for a sales order --> > - <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" > orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 > 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" > webSiteId="OrderEntry" productStoreId="9000" remainingSubTotal="38.40" > grandTotal="50.85" invoicePerShipment="Y"/> > + <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" > orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 > 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" > productStoreId="9000" remainingSubTotal="38.40" grandTotal="50.85" > invoicePerShipment="Y"/> > <OrderItem orderId="TEST_DEMO10090" orderItemSeqId="00001" > orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" selectedAmount="0.0" > unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" > itemDescription="Round Gizmo" correspondingPoId="" > statusId="ITEM_APPROVED"/> > > <Party partyId="TestDemoCustomer" partyTypeId="PERSON" > statusId="PARTY_ENABLED"/> > > > |
Administrator
|
Good catch Deepak!
Jacques Le 27/09/2017 à 08:07, Deepak Dixit a écrit : > Hi Rishi/Ratnesh, > > IMO relationship should be one-nofk, as website can be empty. > > Thanks & Regards > -- > Deepak Dixit > www.hotwaxsystems.com > www.hotwax.co > > On Tue, Sep 26, 2017 at 8:03 PM, <[hidden email]> wrote: > >> Author: rishi >> Date: Tue Sep 26 14:33:05 2017 >> New Revision: 1809749 >> >> URL: http://svn.apache.org/viewvc?rev=1809749&view=rev >> Log: >> Improvement: Missing Relationship from OrderHeader to WebSite >> (OFBIZ-9647). Added relationship from order header to website entity. And >> removed wrong data. >> Applied patch from (OFBIZ-9647). Thanks Ratnesh Upadhyay for your >> contribution. >> >> Modified: >> ofbiz/ofbiz-framework/trunk/applications/datamodel/ >> entitydef/order-entitymodel.xml >> ofbiz/ofbiz-framework/trunk/applications/order/data/ >> DemoOrderTestData.xml >> ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml >> ofbiz/ofbiz-framework/trunk/applications/order/testdef/ >> data/OrderTestData.xml >> >> Modified: ofbiz/ofbiz-framework/trunk/applications/datamodel/ >> entitydef/order-entitymodel.xml >> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >> applications/datamodel/entitydef/order-entitymodel. >> xml?rev=1809749&r1=1809748&r2=1809749&view=diff >> ============================================================ >> ================== >> --- ofbiz/ofbiz-framework/trunk/applications/datamodel/ >> entitydef/order-entitymodel.xml (original) >> +++ ofbiz/ofbiz-framework/trunk/applications/datamodel/ >> entitydef/order-entitymodel.xml Tue Sep 26 14:33:05 2017 >> @@ -432,6 +432,9 @@ under the License. >> <relation type="one" fk-name="ORDER_HDR_CUOM" rel-entity-name="Uom"> >> <key-map field-name="currencyUom" rel-field-name="uomId"/> >> </relation> >> + <relation type="one" fk-name="ORDER_HDR_WS" >> rel-entity-name="WebSite"> >> + <key-map field-name="webSiteId"/> >> + </relation> >> <index name="ORDEREXT_ID_IDX"> >> <index-field name="externalId"/> >> </index> >> >> Modified: ofbiz/ofbiz-framework/trunk/applications/order/data/ >> DemoOrderTestData.xml >> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >> applications/order/data/DemoOrderTestData.xml?rev= >> 1809749&r1=1809748&r2=1809749&view=diff >> ============================================================ >> ================== >> --- ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrderTestData.xml >> (original) >> +++ ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrderTestData.xml >> Tue Sep 26 14:33:05 2017 >> @@ -20,7 +20,7 @@ under the License. >> >> <entity-engine-xml> >> <!--Demo data for a sales order --> >> - <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" >> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 >> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" >> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >> remainingSubTotal="38.40" grandTotal="50.85" invoicePerShipment="Y"/> >> + <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" >> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 >> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" >> currencyUom="USD" productStoreId="9000" remainingSubTotal="38.40" >> grandTotal="50.85" invoicePerShipment="Y"/> >> <OrderItem orderId="DEMO10090" orderItemSeqId="00001" >> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" selectedAmount="0.0" >> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" >> itemDescription="Round Gizmo" correspondingPoId="" >> statusId="ITEM_APPROVED"/> >> <OrderItemPriceInfo orderItemPriceInfoId="9000" orderId="DEMO10090" >> orderItemSeqId="00001" productPriceRuleId="9000" >> productPriceActionSeqId="01" modifyAmount="-9.600" description="[PRODUCT_CATEGORY_IDIsPROMOTIONS] >> [list:48.0;avgCost:48.0;margin:0.0] [type:PRICE_POL]"/> >> >> @@ -59,7 +59,7 @@ under the License. >> >> <!-- Purchase order test data --> >> <!--for jira issue - 1782--> >> - <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" >> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_SALES_CHANNEL" >> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" >> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" >> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >> remainingSubTotal="108.0" grandTotal="108.0"/> >> + <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" >> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_SALES_CHANNEL" >> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" >> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" >> currencyUom="USD" productStoreId="9000" remainingSubTotal="108.0" >> grandTotal="108.0"/> >> <OrderItem orderId="DEMO10091" orderItemSeqId="00001" >> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >> prodCatalogId="DemoCatalog" isPromo="N" quantity="5.0" selectedAmount="0.0" >> unitPrice="21.6" unitListPrice="0.0" isModifiedPrice="N" >> itemDescription="GZ-2644-5 Round Gizmo" statusId="ITEM_CREATED"/> >> <OrderItemPriceInfo orderItemPriceInfoId="10001" orderId="DEMO10091" >> orderItemSeqId="00001" description="SupplierProduct >> [minimumOrderQuantity:5.0, lastPrice: 21.6]"/> >> <OrderItemPriceInfo orderItemPriceInfoId="10002" orderId="DEMO10091" >> orderItemSeqId="00001" description="SupplierProduct >> [minimumOrderQuantity:0.0, lastPrice: 24.0]"/> >> @@ -82,7 +82,7 @@ under the License. >> <ItemIssuance itemIssuanceId="9003" orderId="DEMO10091" >> orderItemSeqId="00001" shipGroupSeqId="00001" shipmentId="9999" >> shipmentItemSeqId="00001" issuedDateTime="2009-08-13 17:46:29.603" >> quantity="5"/> >> >> <!--Demo Purchase Order data for Accounting--> >> - <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" >> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SALES_CHANNEL" >> orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 >> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" >> webSiteId="OrderEntry" remainingSubTotal="48.00" grandTotal="48.00"/> >> + <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" >> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SALES_CHANNEL" >> orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 >> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" >> remainingSubTotal="48.00" grandTotal="48.00"/> >> <OrderItem orderId="Demo1001" orderItemSeqId="00001" >> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" >> selectedAmount="0.000000" unitPrice="24.00" unitListPrice="0.00" >> isModifiedPrice="N" itemDescription="GZ-2644-0 Round Gizmo" >> statusId="ITEM_COMPLETED" estimatedDeliveryDate="2009-08-13 17:43:53.0"/> >> <OrderItemPriceInfo orderItemPriceInfoId="9001" orderId="Demo1001" >> orderItemSeqId="00001" description="SupplierProduct [minimumOrderQuantity:0.000000, >> lastPrice: 24.000]"/> >> <OrderRole orderId="Demo1001" partyId="Company" >> roleTypeId="BILL_TO_CUSTOMER" /> >> @@ -126,7 +126,7 @@ under the License. >> <AcctgTransEntry acctgTransId="9001" acctgTransEntrySeqId="00002" >> acctgTransEntryTypeId="_NA_" partyId="DemoSupplier" >> roleTypeId="BILL_FROM_VENDOR" glAccountTypeId="ACCOUNTS_PAYABLE" >> glAccountId="210000" organizationPartyId="Company" amount="48.00" >> currencyUomId="USD" origAmount="48.00" origCurrencyUomId="USD" >> debitCreditFlag="C" reconcileStatusId="AES_NOT_RECONCILED"/> >> >> <!--Demo Sales Order for Accounting--> >> - <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" >> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" >> orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 >> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" createdBy="admin" >> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >> remainingSubTotal="107.98" grandTotal="127.09"/> >> + <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" >> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" >> orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 >> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" createdBy="admin" >> currencyUom="USD" productStoreId="9000" remainingSubTotal="107.98" >> grandTotal="127.09"/> >> <OrderItem orderId="Demo1002" orderItemSeqId="00001" >> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" >> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" >> selectedAmount="0.000000" unitPrice="59.99" unitListPrice="60.00" >> isModifiedPrice="N" itemDescription="Micro Chrome Widget" >> correspondingPoId="" statusId="ITEM_COMPLETED"/> >> <OrderItem orderId="Demo1002" orderItemSeqId="00004" >> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" isPromo="Y" >> quantity="1.000000" selectedAmount="0.000000" unitPrice="59.99" >> unitListPrice="60.00" isModifiedPrice="N" itemDescription="Micro Chrome >> Widget" correspondingPoId="" statusId="ITEM_COMPLETED"/> >> <PartyRole partyId="DemoCustomer" roleTypeId="END_USER_CUSTOMER"/> >> >> Modified: ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ >> secas.xml >> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >> applications/order/servicedef/secas.xml?rev=1809749&r1= >> 1809748&r2=1809749&view=diff >> ============================================================ >> ================== >> --- ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml >> (original) >> +++ ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml >> Tue Sep 26 14:33:05 2017 >> @@ -401,7 +401,6 @@ under the License. >> <condition field-name="oldStatusId" operator="not-equals" >> value="CRQ_ACCEPTED"/> >> <condition field-name="oldStatusId" operator="not-equals" >> value="CRQ_PENDING"/> >> <condition field-name="statusId" operator="equals" >> value="CRQ_ACCEPTED"/> >> - <condition field-name="webSiteId" operator="equals" >> value="OrderEntry"/> >> <set field-name="bodyParameters.custRequestId" >> env-name="custRequestId"/> >> <set field-name="bodyParameters.custRequestName" >> env-name="custRequestName"/> >> <set field-name="partyIdTo" env-name="fromPartyId"/> >> @@ -412,7 +411,6 @@ under the License. >> <eca service="setCustRequestStatus" event="commit"> >> <condition field-name="oldStatusId" operator="not-equals" >> value="CRQ_COMPLETED"/> >> <condition field-name="statusId" operator="equals" >> value="CRQ_COMPLETED"/> >> - <condition field-name="webSiteId" operator="equals" >> value="OrderEntry"/> >> <set field-name="bodyParameters.custRequestId" >> env-name="custRequestId"/> >> <set field-name="partyIdTo" env-name="fromPartyId"/> >> <set field-name="emailTemplateSettingId" >> value="CUST_REQ_COMPLETED"/> >> >> Modified: ofbiz/ofbiz-framework/trunk/applications/order/testdef/ >> data/OrderTestData.xml >> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >> applications/order/testdef/data/OrderTestData.xml?rev= >> 1809749&r1=1809748&r2=1809749&view=diff >> ============================================================ >> ================== >> --- ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/OrderTestData.xml >> (original) >> +++ ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/OrderTestData.xml >> Tue Sep 26 14:33:05 2017 >> @@ -30,7 +30,7 @@ under the License. >> <ProductStoreEmailSetting productStoreId="9000" >> emailType="PRDS_ODR_CONFIRM" bodyScreenLocation="component: >> //ecommerce/widget/EmailOrderScreens.xml#OrderConfirmNotice" >> xslfoAttachScreenLocation="component://ecommerce/widget/ >> EmailOrderScreens.xml#OrderConfirmNoticePdf" subject="OFBiz Demo - Order >> Confirmation #${orderId}" bccAddress="[hidden email]" fromAddress=" >> [hidden email]"/> >> >> <!--Demo data for a sales order --> >> - <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" >> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 >> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" >> webSiteId="OrderEntry" productStoreId="9000" remainingSubTotal="38.40" >> grandTotal="50.85" invoicePerShipment="Y"/> >> + <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" >> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" orderDate="2008-04-23 >> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" >> productStoreId="9000" remainingSubTotal="38.40" grandTotal="50.85" >> invoicePerShipment="Y"/> >> <OrderItem orderId="TEST_DEMO10090" orderItemSeqId="00001" >> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" selectedAmount="0.0" >> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" >> itemDescription="Round Gizmo" correspondingPoId="" >> statusId="ITEM_APPROVED"/> >> >> <Party partyId="TestDemoCustomer" partyTypeId="PERSON" >> statusId="PARTY_ENABLED"/> >> >> >> |
Deepak/Jacques,
Thanks for the review and feedback. I propose the same in the email thread where this issue was discussed. Also we have consider the empty website case as well. Verified and Tested, we can create order header with empty values. There are many similar relations uses the one relationship. Even with Order Header we have product store id, order type id, sales channel enum id etc and we can set all these values as empty while creating the Order Header record. I propose the 'one-nofk' in email thread so that we can keep the data of orders will have the incorrect website id, and now we have decided to remove all incorrect data and ECAs conditions. Let me know if I missed something you guys wanted to point out. Thanks! Rishi Solanki Sr Manager, Enterprise Software Development HotWax Systems Pvt. Ltd. Direct: +91-9893287847 http://www.hotwaxsystems.com www.hotwax.co On Wed, Sep 27, 2017 at 12:36 PM, Jacques Le Roux < [hidden email]> wrote: > Good catch Deepak! > > Jacques > > > > Le 27/09/2017 à 08:07, Deepak Dixit a écrit : > >> Hi Rishi/Ratnesh, >> >> IMO relationship should be one-nofk, as website can be empty. >> >> Thanks & Regards >> -- >> Deepak Dixit >> www.hotwaxsystems.com >> www.hotwax.co >> >> On Tue, Sep 26, 2017 at 8:03 PM, <[hidden email]> wrote: >> >> Author: rishi >>> Date: Tue Sep 26 14:33:05 2017 >>> New Revision: 1809749 >>> >>> URL: http://svn.apache.org/viewvc?rev=1809749&view=rev >>> Log: >>> Improvement: Missing Relationship from OrderHeader to WebSite >>> (OFBIZ-9647). Added relationship from order header to website entity. And >>> removed wrong data. >>> Applied patch from (OFBIZ-9647). Thanks Ratnesh Upadhyay for your >>> contribution. >>> >>> Modified: >>> ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>> entitydef/order-entitymodel.xml >>> ofbiz/ofbiz-framework/trunk/applications/order/data/ >>> DemoOrderTestData.xml >>> ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml >>> ofbiz/ofbiz-framework/trunk/applications/order/testdef/ >>> data/OrderTestData.xml >>> >>> Modified: ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>> entitydef/order-entitymodel.xml >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>> applications/datamodel/entitydef/order-entitymodel. >>> xml?rev=1809749&r1=1809748&r2=1809749&view=diff >>> ============================================================ >>> ================== >>> --- ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>> entitydef/order-entitymodel.xml (original) >>> +++ ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>> entitydef/order-entitymodel.xml Tue Sep 26 14:33:05 2017 >>> @@ -432,6 +432,9 @@ under the License. >>> <relation type="one" fk-name="ORDER_HDR_CUOM" >>> rel-entity-name="Uom"> >>> <key-map field-name="currencyUom" rel-field-name="uomId"/> >>> </relation> >>> + <relation type="one" fk-name="ORDER_HDR_WS" >>> rel-entity-name="WebSite"> >>> + <key-map field-name="webSiteId"/> >>> + </relation> >>> <index name="ORDEREXT_ID_IDX"> >>> <index-field name="externalId"/> >>> </index> >>> >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/data/ >>> DemoOrderTestData.xml >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>> applications/order/data/DemoOrderTestData.xml?rev= >>> 1809749&r1=1809748&r2=1809749&view=diff >>> ============================================================ >>> ================== >>> --- ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde >>> rTestData.xml >>> (original) >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde >>> rTestData.xml >>> Tue Sep 26 14:33:05 2017 >>> @@ -20,7 +20,7 @@ under the License. >>> >>> <entity-engine-xml> >>> <!--Demo data for a sales order --> >>> - <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>> orderDate="2008-04-23 >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >>> remainingSubTotal="38.40" grandTotal="50.85" invoicePerShipment="Y"/> >>> + <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>> orderDate="2008-04-23 >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="38.40" >>> grandTotal="50.85" invoicePerShipment="Y"/> >>> <OrderItem orderId="DEMO10090" orderItemSeqId="00001" >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" >>> selectedAmount="0.0" >>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" >>> itemDescription="Round Gizmo" correspondingPoId="" >>> statusId="ITEM_APPROVED"/> >>> <OrderItemPriceInfo orderItemPriceInfoId="9000" orderId="DEMO10090" >>> orderItemSeqId="00001" productPriceRuleId="9000" >>> productPriceActionSeqId="01" modifyAmount="-9.600" >>> description="[PRODUCT_CATEGORY_IDIsPROMOTIONS] >>> [list:48.0;avgCost:48.0;margin:0.0] [type:PRICE_POL]"/> >>> >>> @@ -59,7 +59,7 @@ under the License. >>> >>> <!-- Purchase order test data --> >>> <!--for jira issue - 1782--> >>> - <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" >>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_SALES_CHANNEL" >>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" >>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >>> remainingSubTotal="108.0" grandTotal="108.0"/> >>> + <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" >>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_SALES_CHANNEL" >>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" >>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="108.0" >>> grandTotal="108.0"/> >>> <OrderItem orderId="DEMO10091" orderItemSeqId="00001" >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="5.0" >>> selectedAmount="0.0" >>> unitPrice="21.6" unitListPrice="0.0" isModifiedPrice="N" >>> itemDescription="GZ-2644-5 Round Gizmo" statusId="ITEM_CREATED"/> >>> <OrderItemPriceInfo orderItemPriceInfoId="10001" >>> orderId="DEMO10091" >>> orderItemSeqId="00001" description="SupplierProduct >>> [minimumOrderQuantity:5.0, lastPrice: 21.6]"/> >>> <OrderItemPriceInfo orderItemPriceInfoId="10002" >>> orderId="DEMO10091" >>> orderItemSeqId="00001" description="SupplierProduct >>> [minimumOrderQuantity:0.0, lastPrice: 24.0]"/> >>> @@ -82,7 +82,7 @@ under the License. >>> <ItemIssuance itemIssuanceId="9003" orderId="DEMO10091" >>> orderItemSeqId="00001" shipGroupSeqId="00001" shipmentId="9999" >>> shipmentItemSeqId="00001" issuedDateTime="2009-08-13 17:46:29.603" >>> quantity="5"/> >>> >>> <!--Demo Purchase Order data for Accounting--> >>> - <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" >>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL >>> ES_CHANNEL" >>> orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 >>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" >>> webSiteId="OrderEntry" remainingSubTotal="48.00" grandTotal="48.00"/> >>> + <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" >>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL >>> ES_CHANNEL" >>> orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 >>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" >>> remainingSubTotal="48.00" grandTotal="48.00"/> >>> <OrderItem orderId="Demo1001" orderItemSeqId="00001" >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" >>> selectedAmount="0.000000" unitPrice="24.00" unitListPrice="0.00" >>> isModifiedPrice="N" itemDescription="GZ-2644-0 Round Gizmo" >>> statusId="ITEM_COMPLETED" estimatedDeliveryDate="2009-08-13 >>> 17:43:53.0"/> >>> <OrderItemPriceInfo orderItemPriceInfoId="9001" orderId="Demo1001" >>> orderItemSeqId="00001" description="SupplierProduct >>> [minimumOrderQuantity:0.000000, >>> lastPrice: 24.000]"/> >>> <OrderRole orderId="Demo1001" partyId="Company" >>> roleTypeId="BILL_TO_CUSTOMER" /> >>> @@ -126,7 +126,7 @@ under the License. >>> <AcctgTransEntry acctgTransId="9001" acctgTransEntrySeqId="00002" >>> acctgTransEntryTypeId="_NA_" partyId="DemoSupplier" >>> roleTypeId="BILL_FROM_VENDOR" glAccountTypeId="ACCOUNTS_PAYABLE" >>> glAccountId="210000" organizationPartyId="Company" amount="48.00" >>> currencyUomId="USD" origAmount="48.00" origCurrencyUomId="USD" >>> debitCreditFlag="C" reconcileStatusId="AES_NOT_RECONCILED"/> >>> >>> <!--Demo Sales Order for Accounting--> >>> - <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" >>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" >>> orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 >>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" >>> createdBy="admin" >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >>> remainingSubTotal="107.98" grandTotal="127.09"/> >>> + <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" >>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" >>> orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 >>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" >>> createdBy="admin" >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="107.98" >>> grandTotal="127.09"/> >>> <OrderItem orderId="Demo1002" orderItemSeqId="00001" >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" >>> selectedAmount="0.000000" unitPrice="59.99" unitListPrice="60.00" >>> isModifiedPrice="N" itemDescription="Micro Chrome Widget" >>> correspondingPoId="" statusId="ITEM_COMPLETED"/> >>> <OrderItem orderId="Demo1002" orderItemSeqId="00004" >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" isPromo="Y" >>> quantity="1.000000" selectedAmount="0.000000" unitPrice="59.99" >>> unitListPrice="60.00" isModifiedPrice="N" itemDescription="Micro Chrome >>> Widget" correspondingPoId="" statusId="ITEM_COMPLETED"/> >>> <PartyRole partyId="DemoCustomer" roleTypeId="END_USER_CUSTOMER"/> >>> >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ >>> secas.xml >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>> applications/order/servicedef/secas.xml?rev=1809749&r1= >>> 1809748&r2=1809749&view=diff >>> ============================================================ >>> ================== >>> --- ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml >>> (original) >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/servicedef/secas.xml >>> Tue Sep 26 14:33:05 2017 >>> @@ -401,7 +401,6 @@ under the License. >>> <condition field-name="oldStatusId" operator="not-equals" >>> value="CRQ_ACCEPTED"/> >>> <condition field-name="oldStatusId" operator="not-equals" >>> value="CRQ_PENDING"/> >>> <condition field-name="statusId" operator="equals" >>> value="CRQ_ACCEPTED"/> >>> - <condition field-name="webSiteId" operator="equals" >>> value="OrderEntry"/> >>> <set field-name="bodyParameters.custRequestId" >>> env-name="custRequestId"/> >>> <set field-name="bodyParameters.custRequestName" >>> env-name="custRequestName"/> >>> <set field-name="partyIdTo" env-name="fromPartyId"/> >>> @@ -412,7 +411,6 @@ under the License. >>> <eca service="setCustRequestStatus" event="commit"> >>> <condition field-name="oldStatusId" operator="not-equals" >>> value="CRQ_COMPLETED"/> >>> <condition field-name="statusId" operator="equals" >>> value="CRQ_COMPLETED"/> >>> - <condition field-name="webSiteId" operator="equals" >>> value="OrderEntry"/> >>> <set field-name="bodyParameters.custRequestId" >>> env-name="custRequestId"/> >>> <set field-name="partyIdTo" env-name="fromPartyId"/> >>> <set field-name="emailTemplateSettingId" >>> value="CUST_REQ_COMPLETED"/> >>> >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/testdef/ >>> data/OrderTestData.xml >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>> applications/order/testdef/data/OrderTestData.xml?rev= >>> 1809749&r1=1809748&r2=1809749&view=diff >>> ============================================================ >>> ================== >>> --- ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ >>> OrderTestData.xml >>> (original) >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ >>> OrderTestData.xml >>> Tue Sep 26 14:33:05 2017 >>> @@ -30,7 +30,7 @@ under the License. >>> <ProductStoreEmailSetting productStoreId="9000" >>> emailType="PRDS_ODR_CONFIRM" bodyScreenLocation="component: >>> //ecommerce/widget/EmailOrderScreens.xml#OrderConfirmNotice" >>> xslfoAttachScreenLocation="component://ecommerce/widget/ >>> EmailOrderScreens.xml#OrderConfirmNoticePdf" subject="OFBiz Demo - Order >>> Confirmation #${orderId}" bccAddress="[hidden email]" >>> fromAddress=" >>> [hidden email]"/> >>> >>> <!--Demo data for a sales order --> >>> - <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>> orderDate="2008-04-23 >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" >>> webSiteId="OrderEntry" productStoreId="9000" remainingSubTotal="38.40" >>> grandTotal="50.85" invoicePerShipment="Y"/> >>> + <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>> orderDate="2008-04-23 >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" >>> productStoreId="9000" remainingSubTotal="38.40" grandTotal="50.85" >>> invoicePerShipment="Y"/> >>> <OrderItem orderId="TEST_DEMO10090" orderItemSeqId="00001" >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" >>> selectedAmount="0.0" >>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" >>> itemDescription="Round Gizmo" correspondingPoId="" >>> statusId="ITEM_APPROVED"/> >>> >>> <Party partyId="TestDemoCustomer" partyTypeId="PERSON" >>> statusId="PARTY_ENABLED"/> >>> >>> >>> >>> > |
On Wed, Sep 27, 2017 at 1:24 PM, Rishi Solanki <[hidden email]>
wrote: > Deepak/Jacques, > > Thanks for the review and feedback. > > I propose the same in the email thread where this issue was discussed. Also > we have consider the empty website case as well. Verified and Tested, we > can create order header with empty values. There are many similar relations > uses the one relationship. > > Even with Order Header we have product store id, order type id, sales > channel enum id etc and we can set all these values as empty while creating > the Order Header record. > Hi Rishi, https://cwiki.apache.org/confluence/display/OFBIZ/Entity+Engine+Guide *Foreign keys and indexes on foreign keys can be created automatically by the Entity Engine. This is only done for type 'one' relations, not for 'one-nofk' or 'many' type relations.* > > I propose the 'one-nofk' in email thread so that we can keep the data of > orders will have the incorrect website id, and now we have decided to > remove all incorrect data and ECAs conditions. Let me know if I missed something you guys wanted to point out. Thanks! > > > Rishi Solanki > Sr Manager, Enterprise Software Development > HotWax Systems Pvt. Ltd. > Direct: +91-9893287847 > http://www.hotwaxsystems.com > www.hotwax.co > > On Wed, Sep 27, 2017 at 12:36 PM, Jacques Le Roux < > [hidden email]> wrote: > > > Good catch Deepak! > > > > Jacques > > > > > > > > Le 27/09/2017 à 08:07, Deepak Dixit a écrit : > > > >> Hi Rishi/Ratnesh, > >> > >> IMO relationship should be one-nofk, as website can be empty. > >> > >> Thanks & Regards > >> -- > >> Deepak Dixit > >> www.hotwaxsystems.com > >> www.hotwax.co > >> > >> On Tue, Sep 26, 2017 at 8:03 PM, <[hidden email]> wrote: > >> > >> Author: rishi > >>> Date: Tue Sep 26 14:33:05 2017 > >>> New Revision: 1809749 > >>> > >>> URL: http://svn.apache.org/viewvc?rev=1809749&view=rev > >>> Log: > >>> Improvement: Missing Relationship from OrderHeader to WebSite > >>> (OFBIZ-9647). Added relationship from order header to website entity. > And > >>> removed wrong data. > >>> Applied patch from (OFBIZ-9647). Thanks Ratnesh Upadhyay for your > >>> contribution. > >>> > >>> Modified: > >>> ofbiz/ofbiz-framework/trunk/applications/datamodel/ > >>> entitydef/order-entitymodel.xml > >>> ofbiz/ofbiz-framework/trunk/applications/order/data/ > >>> DemoOrderTestData.xml > >>> ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > secas.xml > >>> ofbiz/ofbiz-framework/trunk/applications/order/testdef/ > >>> data/OrderTestData.xml > >>> > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/datamodel/ > >>> entitydef/order-entitymodel.xml > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > >>> applications/datamodel/entitydef/order-entitymodel. > >>> xml?rev=1809749&r1=1809748&r2=1809749&view=diff > >>> ============================================================ > >>> ================== > >>> --- ofbiz/ofbiz-framework/trunk/applications/datamodel/ > >>> entitydef/order-entitymodel.xml (original) > >>> +++ ofbiz/ofbiz-framework/trunk/applications/datamodel/ > >>> entitydef/order-entitymodel.xml Tue Sep 26 14:33:05 2017 > >>> @@ -432,6 +432,9 @@ under the License. > >>> <relation type="one" fk-name="ORDER_HDR_CUOM" > >>> rel-entity-name="Uom"> > >>> <key-map field-name="currencyUom" rel-field-name="uomId"/> > >>> </relation> > >>> + <relation type="one" fk-name="ORDER_HDR_WS" > >>> rel-entity-name="WebSite"> > >>> + <key-map field-name="webSiteId"/> > >>> + </relation> > >>> <index name="ORDEREXT_ID_IDX"> > >>> <index-field name="externalId"/> > >>> </index> > >>> > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/data/ > >>> DemoOrderTestData.xml > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > >>> applications/order/data/DemoOrderTestData.xml?rev= > >>> 1809749&r1=1809748&r2=1809749&view=diff > >>> ============================================================ > >>> ================== > >>> --- ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde > >>> rTestData.xml > >>> (original) > >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde > >>> rTestData.xml > >>> Tue Sep 26 14:33:05 2017 > >>> @@ -20,7 +20,7 @@ under the License. > >>> > >>> <entity-engine-xml> > >>> <!--Demo data for a sales order --> > >>> - <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > >>> orderDate="2008-04-23 > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > >>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" > >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > >>> remainingSubTotal="38.40" grandTotal="50.85" invoicePerShipment="Y"/> > >>> + <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > >>> orderDate="2008-04-23 > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > >>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" > >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="38.40" > >>> grandTotal="50.85" invoicePerShipment="Y"/> > >>> <OrderItem orderId="DEMO10090" orderItemSeqId="00001" > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" > >>> selectedAmount="0.0" > >>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" > >>> itemDescription="Round Gizmo" correspondingPoId="" > >>> statusId="ITEM_APPROVED"/> > >>> <OrderItemPriceInfo orderItemPriceInfoId="9000" > orderId="DEMO10090" > >>> orderItemSeqId="00001" productPriceRuleId="9000" > >>> productPriceActionSeqId="01" modifyAmount="-9.600" > >>> description="[PRODUCT_CATEGORY_IDIsPROMOTIONS] > >>> [list:48.0;avgCost:48.0;margin:0.0] [type:PRICE_POL]"/> > >>> > >>> @@ -59,7 +59,7 @@ under the License. > >>> > >>> <!-- Purchase order test data --> > >>> <!--for jira issue - 1782--> > >>> - <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" > >>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_ > SALES_CHANNEL" > >>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" > >>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" > >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > >>> remainingSubTotal="108.0" grandTotal="108.0"/> > >>> + <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" > >>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_ > SALES_CHANNEL" > >>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 13:27:07.024" > >>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" > >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="108.0" > >>> grandTotal="108.0"/> > >>> <OrderItem orderId="DEMO10091" orderItemSeqId="00001" > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="5.0" > >>> selectedAmount="0.0" > >>> unitPrice="21.6" unitListPrice="0.0" isModifiedPrice="N" > >>> itemDescription="GZ-2644-5 Round Gizmo" statusId="ITEM_CREATED"/> > >>> <OrderItemPriceInfo orderItemPriceInfoId="10001" > >>> orderId="DEMO10091" > >>> orderItemSeqId="00001" description="SupplierProduct > >>> [minimumOrderQuantity:5.0, lastPrice: 21.6]"/> > >>> <OrderItemPriceInfo orderItemPriceInfoId="10002" > >>> orderId="DEMO10091" > >>> orderItemSeqId="00001" description="SupplierProduct > >>> [minimumOrderQuantity:0.0, lastPrice: 24.0]"/> > >>> @@ -82,7 +82,7 @@ under the License. > >>> <ItemIssuance itemIssuanceId="9003" orderId="DEMO10091" > >>> orderItemSeqId="00001" shipGroupSeqId="00001" shipmentId="9999" > >>> shipmentItemSeqId="00001" issuedDateTime="2009-08-13 17:46:29.603" > >>> quantity="5"/> > >>> > >>> <!--Demo Purchase Order data for Accounting--> > >>> - <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" > >>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL > >>> ES_CHANNEL" > >>> orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 > >>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" > >>> webSiteId="OrderEntry" remainingSubTotal="48.00" grandTotal="48.00"/> > >>> + <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" > >>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL > >>> ES_CHANNEL" > >>> orderDate="2009-08-13 17:45:50.419" priority="2" entryDate="2009-08-13 > >>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" > >>> remainingSubTotal="48.00" grandTotal="48.00"/> > >>> <OrderItem orderId="Demo1001" orderItemSeqId="00001" > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" > >>> selectedAmount="0.000000" unitPrice="24.00" unitListPrice="0.00" > >>> isModifiedPrice="N" itemDescription="GZ-2644-0 Round Gizmo" > >>> statusId="ITEM_COMPLETED" estimatedDeliveryDate="2009-08-13 > >>> 17:43:53.0"/> > >>> <OrderItemPriceInfo orderItemPriceInfoId="9001" > orderId="Demo1001" > >>> orderItemSeqId="00001" description="SupplierProduct > >>> [minimumOrderQuantity:0.000000, > >>> lastPrice: 24.000]"/> > >>> <OrderRole orderId="Demo1001" partyId="Company" > >>> roleTypeId="BILL_TO_CUSTOMER" /> > >>> @@ -126,7 +126,7 @@ under the License. > >>> <AcctgTransEntry acctgTransId="9001" acctgTransEntrySeqId="00002" > >>> acctgTransEntryTypeId="_NA_" partyId="DemoSupplier" > >>> roleTypeId="BILL_FROM_VENDOR" glAccountTypeId="ACCOUNTS_PAYABLE" > >>> glAccountId="210000" organizationPartyId="Company" amount="48.00" > >>> currencyUomId="USD" origAmount="48.00" origCurrencyUomId="USD" > >>> debitCreditFlag="C" reconcileStatusId="AES_NOT_RECONCILED"/> > >>> > >>> <!--Demo Sales Order for Accounting--> > >>> - <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" > >>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" > >>> orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 > >>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" > >>> createdBy="admin" > >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > >>> remainingSubTotal="107.98" grandTotal="127.09"/> > >>> + <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" > >>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" > >>> orderDate="2009-08-17 14:23:49.475" priority="2" entryDate="2009-08-17 > >>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" > >>> createdBy="admin" > >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="107.98" > >>> grandTotal="127.09"/> > >>> <OrderItem orderId="Demo1002" orderItemSeqId="00001" > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" > >>> selectedAmount="0.000000" unitPrice="59.99" unitListPrice="60.00" > >>> isModifiedPrice="N" itemDescription="Micro Chrome Widget" > >>> correspondingPoId="" statusId="ITEM_COMPLETED"/> > >>> <OrderItem orderId="Demo1002" orderItemSeqId="00004" > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" isPromo="Y" > >>> quantity="1.000000" selectedAmount="0.000000" unitPrice="59.99" > >>> unitListPrice="60.00" isModifiedPrice="N" itemDescription="Micro Chrome > >>> Widget" correspondingPoId="" statusId="ITEM_COMPLETED"/> > >>> <PartyRole partyId="DemoCustomer" roleTypeId="END_USER_CUSTOMER" > /> > >>> > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > >>> secas.xml > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > >>> applications/order/servicedef/secas.xml?rev=1809749&r1= > >>> 1809748&r2=1809749&view=diff > >>> ============================================================ > >>> ================== > >>> --- ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > secas.xml > >>> (original) > >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > secas.xml > >>> Tue Sep 26 14:33:05 2017 > >>> @@ -401,7 +401,6 @@ under the License. > >>> <condition field-name="oldStatusId" operator="not-equals" > >>> value="CRQ_ACCEPTED"/> > >>> <condition field-name="oldStatusId" operator="not-equals" > >>> value="CRQ_PENDING"/> > >>> <condition field-name="statusId" operator="equals" > >>> value="CRQ_ACCEPTED"/> > >>> - <condition field-name="webSiteId" operator="equals" > >>> value="OrderEntry"/> > >>> <set field-name="bodyParameters.custRequestId" > >>> env-name="custRequestId"/> > >>> <set field-name="bodyParameters.custRequestName" > >>> env-name="custRequestName"/> > >>> <set field-name="partyIdTo" env-name="fromPartyId"/> > >>> @@ -412,7 +411,6 @@ under the License. > >>> <eca service="setCustRequestStatus" event="commit"> > >>> <condition field-name="oldStatusId" operator="not-equals" > >>> value="CRQ_COMPLETED"/> > >>> <condition field-name="statusId" operator="equals" > >>> value="CRQ_COMPLETED"/> > >>> - <condition field-name="webSiteId" operator="equals" > >>> value="OrderEntry"/> > >>> <set field-name="bodyParameters.custRequestId" > >>> env-name="custRequestId"/> > >>> <set field-name="partyIdTo" env-name="fromPartyId"/> > >>> <set field-name="emailTemplateSettingId" > >>> value="CUST_REQ_COMPLETED"/> > >>> > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/testdef/ > >>> data/OrderTestData.xml > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > >>> applications/order/testdef/data/OrderTestData.xml?rev= > >>> 1809749&r1=1809748&r2=1809749&view=diff > >>> ============================================================ > >>> ================== > >>> --- ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ > >>> OrderTestData.xml > >>> (original) > >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ > >>> OrderTestData.xml > >>> Tue Sep 26 14:33:05 2017 > >>> @@ -30,7 +30,7 @@ under the License. > >>> <ProductStoreEmailSetting productStoreId="9000" > >>> emailType="PRDS_ODR_CONFIRM" bodyScreenLocation="component: > >>> //ecommerce/widget/EmailOrderScreens.xml#OrderConfirmNotice" > >>> xslfoAttachScreenLocation="component://ecommerce/widget/ > >>> EmailOrderScreens.xml#OrderConfirmNoticePdf" subject="OFBiz Demo - > Order > >>> Confirmation #${orderId}" bccAddress="[hidden email]" > >>> fromAddress=" > >>> [hidden email]"/> > >>> > >>> <!--Demo data for a sales order --> > >>> - <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > >>> orderDate="2008-04-23 > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > >>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" > >>> webSiteId="OrderEntry" productStoreId="9000" remainingSubTotal="38.40" > >>> grandTotal="50.85" invoicePerShipment="Y"/> > >>> + <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > >>> orderDate="2008-04-23 > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > >>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" > >>> productStoreId="9000" remainingSubTotal="38.40" grandTotal="50.85" > >>> invoicePerShipment="Y"/> > >>> <OrderItem orderId="TEST_DEMO10090" orderItemSeqId="00001" > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" > >>> selectedAmount="0.0" > >>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" > >>> itemDescription="Round Gizmo" correspondingPoId="" > >>> statusId="ITEM_APPROVED"/> > >>> > >>> <Party partyId="TestDemoCustomer" partyTypeId="PERSON" > >>> statusId="PARTY_ENABLED"/> > >>> > >>> > >>> > >>> > > > |
Thank you Deepak for the reference link, and yes it matches with my
understanding of one and one-nofk relations. With respect to same information, we found website is eligible candidate for maintaining the indexes and fks for order header. So concluded to use one relation for the field. I think we can consider website as candidate to have 'one' relation with order. Thanks! Best Regards, Rishi Solanki Sr Manager, Enterprise Software Development HotWax Systems Pvt. Ltd. Direct: +91-9893287847 http://www.hotwaxsystems.com www.hotwax.co On Wed, Sep 27, 2017 at 1:59 PM, Deepak Dixit < [hidden email]> wrote: > On Wed, Sep 27, 2017 at 1:24 PM, Rishi Solanki <[hidden email]> > wrote: > > > Deepak/Jacques, > > > > Thanks for the review and feedback. > > > > I propose the same in the email thread where this issue was discussed. > Also > > we have consider the empty website case as well. Verified and Tested, we > > can create order header with empty values. There are many similar > relations > > uses the one relationship. > > > > Even with Order Header we have product store id, order type id, sales > > channel enum id etc and we can set all these values as empty while > creating > > the Order Header record. > > > > > Hi Rishi, > > > https://cwiki.apache.org/confluence/display/OFBIZ/Entity+Engine+Guide > > *Foreign keys and indexes on foreign keys can be created automatically by > the Entity Engine. This is only done for type 'one' relations, not for > 'one-nofk' or 'many' type relations.* > > > > > > > I propose the 'one-nofk' in email thread so that we can keep the data of > > orders will have the incorrect website id, and now we have decided to > > remove all incorrect data and ECAs conditions. > > Let me know if I missed something you guys wanted to point out. Thanks! > > > > > > Rishi Solanki > > Sr Manager, Enterprise Software Development > > HotWax Systems Pvt. Ltd. > > Direct: +91-9893287847 > > http://www.hotwaxsystems.com > > www.hotwax.co > > > > On Wed, Sep 27, 2017 at 12:36 PM, Jacques Le Roux < > > [hidden email]> wrote: > > > > > Good catch Deepak! > > > > > > Jacques > > > > > > > > > > > > Le 27/09/2017 à 08:07, Deepak Dixit a écrit : > > > > > >> Hi Rishi/Ratnesh, > > >> > > >> IMO relationship should be one-nofk, as website can be empty. > > >> > > >> Thanks & Regards > > >> -- > > >> Deepak Dixit > > >> www.hotwaxsystems.com > > >> www.hotwax.co > > >> > > >> On Tue, Sep 26, 2017 at 8:03 PM, <[hidden email]> wrote: > > >> > > >> Author: rishi > > >>> Date: Tue Sep 26 14:33:05 2017 > > >>> New Revision: 1809749 > > >>> > > >>> URL: http://svn.apache.org/viewvc?rev=1809749&view=rev > > >>> Log: > > >>> Improvement: Missing Relationship from OrderHeader to WebSite > > >>> (OFBIZ-9647). Added relationship from order header to website entity. > > And > > >>> removed wrong data. > > >>> Applied patch from (OFBIZ-9647). Thanks Ratnesh Upadhyay for your > > >>> contribution. > > >>> > > >>> Modified: > > >>> ofbiz/ofbiz-framework/trunk/applications/datamodel/ > > >>> entitydef/order-entitymodel.xml > > >>> ofbiz/ofbiz-framework/trunk/applications/order/data/ > > >>> DemoOrderTestData.xml > > >>> ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > > secas.xml > > >>> ofbiz/ofbiz-framework/trunk/applications/order/testdef/ > > >>> data/OrderTestData.xml > > >>> > > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/datamodel/ > > >>> entitydef/order-entitymodel.xml > > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > > >>> applications/datamodel/entitydef/order-entitymodel. > > >>> xml?rev=1809749&r1=1809748&r2=1809749&view=diff > > >>> ============================================================ > > >>> ================== > > >>> --- ofbiz/ofbiz-framework/trunk/applications/datamodel/ > > >>> entitydef/order-entitymodel.xml (original) > > >>> +++ ofbiz/ofbiz-framework/trunk/applications/datamodel/ > > >>> entitydef/order-entitymodel.xml Tue Sep 26 14:33:05 2017 > > >>> @@ -432,6 +432,9 @@ under the License. > > >>> <relation type="one" fk-name="ORDER_HDR_CUOM" > > >>> rel-entity-name="Uom"> > > >>> <key-map field-name="currencyUom" rel-field-name="uomId"/> > > >>> </relation> > > >>> + <relation type="one" fk-name="ORDER_HDR_WS" > > >>> rel-entity-name="WebSite"> > > >>> + <key-map field-name="webSiteId"/> > > >>> + </relation> > > >>> <index name="ORDEREXT_ID_IDX"> > > >>> <index-field name="externalId"/> > > >>> </index> > > >>> > > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/data/ > > >>> DemoOrderTestData.xml > > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > > >>> applications/order/data/DemoOrderTestData.xml?rev= > > >>> 1809749&r1=1809748&r2=1809749&view=diff > > >>> ============================================================ > > >>> ================== > > >>> --- ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde > > >>> rTestData.xml > > >>> (original) > > >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde > > >>> rTestData.xml > > >>> Tue Sep 26 14:33:05 2017 > > >>> @@ -20,7 +20,7 @@ under the License. > > >>> > > >>> <entity-engine-xml> > > >>> <!--Demo data for a sales order --> > > >>> - <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" > > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > > >>> orderDate="2008-04-23 > > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > > >>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" > > >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > > >>> remainingSubTotal="38.40" grandTotal="50.85" > invoicePerShipment="Y"/> > > >>> + <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" > > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > > >>> orderDate="2008-04-23 > > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > > >>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" > > >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="38.40" > > >>> grandTotal="50.85" invoicePerShipment="Y"/> > > >>> <OrderItem orderId="DEMO10090" orderItemSeqId="00001" > > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" > > >>> selectedAmount="0.0" > > >>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" > > >>> itemDescription="Round Gizmo" correspondingPoId="" > > >>> statusId="ITEM_APPROVED"/> > > >>> <OrderItemPriceInfo orderItemPriceInfoId="9000" > > orderId="DEMO10090" > > >>> orderItemSeqId="00001" productPriceRuleId="9000" > > >>> productPriceActionSeqId="01" modifyAmount="-9.600" > > >>> description="[PRODUCT_CATEGORY_IDIsPROMOTIONS] > > >>> [list:48.0;avgCost:48.0;margin:0.0] [type:PRICE_POL]"/> > > >>> > > >>> @@ -59,7 +59,7 @@ under the License. > > >>> > > >>> <!-- Purchase order test data --> > > >>> <!--for jira issue - 1782--> > > >>> - <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" > > >>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_ > > SALES_CHANNEL" > > >>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 > 13:27:07.024" > > >>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" > > >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > > >>> remainingSubTotal="108.0" grandTotal="108.0"/> > > >>> + <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" > > >>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_ > > SALES_CHANNEL" > > >>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 > 13:27:07.024" > > >>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" > > >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="108.0" > > >>> grandTotal="108.0"/> > > >>> <OrderItem orderId="DEMO10091" orderItemSeqId="00001" > > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="5.0" > > >>> selectedAmount="0.0" > > >>> unitPrice="21.6" unitListPrice="0.0" isModifiedPrice="N" > > >>> itemDescription="GZ-2644-5 Round Gizmo" statusId="ITEM_CREATED"/> > > >>> <OrderItemPriceInfo orderItemPriceInfoId="10001" > > >>> orderId="DEMO10091" > > >>> orderItemSeqId="00001" description="SupplierProduct > > >>> [minimumOrderQuantity:5.0, lastPrice: 21.6]"/> > > >>> <OrderItemPriceInfo orderItemPriceInfoId="10002" > > >>> orderId="DEMO10091" > > >>> orderItemSeqId="00001" description="SupplierProduct > > >>> [minimumOrderQuantity:0.0, lastPrice: 24.0]"/> > > >>> @@ -82,7 +82,7 @@ under the License. > > >>> <ItemIssuance itemIssuanceId="9003" orderId="DEMO10091" > > >>> orderItemSeqId="00001" shipGroupSeqId="00001" shipmentId="9999" > > >>> shipmentItemSeqId="00001" issuedDateTime="2009-08-13 17:46:29.603" > > >>> quantity="5"/> > > >>> > > >>> <!--Demo Purchase Order data for Accounting--> > > >>> - <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" > > >>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL > > >>> ES_CHANNEL" > > >>> orderDate="2009-08-13 17:45:50.419" priority="2" > entryDate="2009-08-13 > > >>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" > > >>> webSiteId="OrderEntry" remainingSubTotal="48.00" grandTotal="48.00"/> > > >>> + <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" > > >>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL > > >>> ES_CHANNEL" > > >>> orderDate="2009-08-13 17:45:50.419" priority="2" > entryDate="2009-08-13 > > >>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" > > >>> remainingSubTotal="48.00" grandTotal="48.00"/> > > >>> <OrderItem orderId="Demo1001" orderItemSeqId="00001" > > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" > > >>> selectedAmount="0.000000" unitPrice="24.00" unitListPrice="0.00" > > >>> isModifiedPrice="N" itemDescription="GZ-2644-0 Round Gizmo" > > >>> statusId="ITEM_COMPLETED" estimatedDeliveryDate="2009-08-13 > > >>> 17:43:53.0"/> > > >>> <OrderItemPriceInfo orderItemPriceInfoId="9001" > > orderId="Demo1001" > > >>> orderItemSeqId="00001" description="SupplierProduct > > >>> [minimumOrderQuantity:0.000000, > > >>> lastPrice: 24.000]"/> > > >>> <OrderRole orderId="Demo1001" partyId="Company" > > >>> roleTypeId="BILL_TO_CUSTOMER" /> > > >>> @@ -126,7 +126,7 @@ under the License. > > >>> <AcctgTransEntry acctgTransId="9001" > acctgTransEntrySeqId="00002" > > >>> acctgTransEntryTypeId="_NA_" partyId="DemoSupplier" > > >>> roleTypeId="BILL_FROM_VENDOR" glAccountTypeId="ACCOUNTS_PAYABLE" > > >>> glAccountId="210000" organizationPartyId="Company" amount="48.00" > > >>> currencyUomId="USD" origAmount="48.00" origCurrencyUomId="USD" > > >>> debitCreditFlag="C" reconcileStatusId="AES_NOT_RECONCILED"/> > > >>> > > >>> <!--Demo Sales Order for Accounting--> > > >>> - <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" > > >>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" > > >>> orderDate="2009-08-17 14:23:49.475" priority="2" > entryDate="2009-08-17 > > >>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" > > >>> createdBy="admin" > > >>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" > > >>> remainingSubTotal="107.98" grandTotal="127.09"/> > > >>> + <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" > > >>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" > > >>> orderDate="2009-08-17 14:23:49.475" priority="2" > entryDate="2009-08-17 > > >>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" > > >>> createdBy="admin" > > >>> currencyUom="USD" productStoreId="9000" remainingSubTotal="107.98" > > >>> grandTotal="127.09"/> > > >>> <OrderItem orderId="Demo1002" orderItemSeqId="00001" > > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" > > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" > > >>> selectedAmount="0.000000" unitPrice="59.99" unitListPrice="60.00" > > >>> isModifiedPrice="N" itemDescription="Micro Chrome Widget" > > >>> correspondingPoId="" statusId="ITEM_COMPLETED"/> > > >>> <OrderItem orderId="Demo1002" orderItemSeqId="00004" > > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" isPromo="Y" > > >>> quantity="1.000000" selectedAmount="0.000000" unitPrice="59.99" > > >>> unitListPrice="60.00" isModifiedPrice="N" itemDescription="Micro > Chrome > > >>> Widget" correspondingPoId="" statusId="ITEM_COMPLETED"/> > > >>> <PartyRole partyId="DemoCustomer" > roleTypeId="END_USER_CUSTOMER" > > /> > > >>> > > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > > >>> secas.xml > > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > > >>> applications/order/servicedef/secas.xml?rev=1809749&r1= > > >>> 1809748&r2=1809749&view=diff > > >>> ============================================================ > > >>> ================== > > >>> --- ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > > secas.xml > > >>> (original) > > >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ > > secas.xml > > >>> Tue Sep 26 14:33:05 2017 > > >>> @@ -401,7 +401,6 @@ under the License. > > >>> <condition field-name="oldStatusId" operator="not-equals" > > >>> value="CRQ_ACCEPTED"/> > > >>> <condition field-name="oldStatusId" operator="not-equals" > > >>> value="CRQ_PENDING"/> > > >>> <condition field-name="statusId" operator="equals" > > >>> value="CRQ_ACCEPTED"/> > > >>> - <condition field-name="webSiteId" operator="equals" > > >>> value="OrderEntry"/> > > >>> <set field-name="bodyParameters.custRequestId" > > >>> env-name="custRequestId"/> > > >>> <set field-name="bodyParameters.custRequestName" > > >>> env-name="custRequestName"/> > > >>> <set field-name="partyIdTo" env-name="fromPartyId"/> > > >>> @@ -412,7 +411,6 @@ under the License. > > >>> <eca service="setCustRequestStatus" event="commit"> > > >>> <condition field-name="oldStatusId" operator="not-equals" > > >>> value="CRQ_COMPLETED"/> > > >>> <condition field-name="statusId" operator="equals" > > >>> value="CRQ_COMPLETED"/> > > >>> - <condition field-name="webSiteId" operator="equals" > > >>> value="OrderEntry"/> > > >>> <set field-name="bodyParameters.custRequestId" > > >>> env-name="custRequestId"/> > > >>> <set field-name="partyIdTo" env-name="fromPartyId"/> > > >>> <set field-name="emailTemplateSettingId" > > >>> value="CUST_REQ_COMPLETED"/> > > >>> > > >>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/testdef/ > > >>> data/OrderTestData.xml > > >>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ > > >>> applications/order/testdef/data/OrderTestData.xml?rev= > > >>> 1809749&r1=1809748&r2=1809749&view=diff > > >>> ============================================================ > > >>> ================== > > >>> --- ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ > > >>> OrderTestData.xml > > >>> (original) > > >>> +++ ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ > > >>> OrderTestData.xml > > >>> Tue Sep 26 14:33:05 2017 > > >>> @@ -30,7 +30,7 @@ under the License. > > >>> <ProductStoreEmailSetting productStoreId="9000" > > >>> emailType="PRDS_ODR_CONFIRM" bodyScreenLocation="component: > > >>> //ecommerce/widget/EmailOrderScreens.xml#OrderConfirmNotice" > > >>> xslfoAttachScreenLocation="component://ecommerce/widget/ > > >>> EmailOrderScreens.xml#OrderConfirmNoticePdf" subject="OFBiz Demo - > > Order > > >>> Confirmation #${orderId}" bccAddress="[hidden email]" > > >>> fromAddress=" > > >>> [hidden email]"/> > > >>> > > >>> <!--Demo data for a sales order --> > > >>> - <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" > > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > > >>> orderDate="2008-04-23 > > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > > >>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" > > >>> webSiteId="OrderEntry" productStoreId="9000" > remainingSubTotal="38.40" > > >>> grandTotal="50.85" invoicePerShipment="Y"/> > > >>> + <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" > > >>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" > > >>> orderDate="2008-04-23 > > >>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" > > >>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" > > >>> productStoreId="9000" remainingSubTotal="38.40" grandTotal="50.85" > > >>> invoicePerShipment="Y"/> > > >>> <OrderItem orderId="TEST_DEMO10090" orderItemSeqId="00001" > > >>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" > > >>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" > > >>> selectedAmount="0.0" > > >>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" > > >>> itemDescription="Round Gizmo" correspondingPoId="" > > >>> statusId="ITEM_APPROVED"/> > > >>> > > >>> <Party partyId="TestDemoCustomer" partyTypeId="PERSON" > > >>> statusId="PARTY_ENABLED"/> > > >>> > > >>> > > >>> > > >>> > > > > > > |
Administrator
|
Thanks Rishi,
Makes sense Jacques Le 28/09/2017 à 06:16, Rishi Solanki a écrit : > Thank you Deepak for the reference link, and yes it matches with my > understanding of one and one-nofk relations. With respect to same > information, we found website is eligible candidate for maintaining the > indexes and fks for order header. So concluded to use one relation for the > field. > > I think we can consider website as candidate to have 'one' relation with > order. > > Thanks! > > Best Regards, > > > > Rishi Solanki > Sr Manager, Enterprise Software Development > HotWax Systems Pvt. Ltd. > Direct: +91-9893287847 > http://www.hotwaxsystems.com > www.hotwax.co > > On Wed, Sep 27, 2017 at 1:59 PM, Deepak Dixit < > [hidden email]> wrote: > >> On Wed, Sep 27, 2017 at 1:24 PM, Rishi Solanki <[hidden email]> >> wrote: >> >>> Deepak/Jacques, >>> >>> Thanks for the review and feedback. >>> >>> I propose the same in the email thread where this issue was discussed. >> Also >>> we have consider the empty website case as well. Verified and Tested, we >>> can create order header with empty values. There are many similar >> relations >>> uses the one relationship. >>> >>> Even with Order Header we have product store id, order type id, sales >>> channel enum id etc and we can set all these values as empty while >> creating >>> the Order Header record. >>> >> >> Hi Rishi, >> >> >> https://cwiki.apache.org/confluence/display/OFBIZ/Entity+Engine+Guide >> >> *Foreign keys and indexes on foreign keys can be created automatically by >> the Entity Engine. This is only done for type 'one' relations, not for >> 'one-nofk' or 'many' type relations.* >> >> >> >>> I propose the 'one-nofk' in email thread so that we can keep the data of >>> orders will have the incorrect website id, and now we have decided to >>> remove all incorrect data and ECAs conditions. >> Let me know if I missed something you guys wanted to point out. Thanks! >>> >>> Rishi Solanki >>> Sr Manager, Enterprise Software Development >>> HotWax Systems Pvt. Ltd. >>> Direct: +91-9893287847 >>> http://www.hotwaxsystems.com >>> www.hotwax.co >>> >>> On Wed, Sep 27, 2017 at 12:36 PM, Jacques Le Roux < >>> [hidden email]> wrote: >>> >>>> Good catch Deepak! >>>> >>>> Jacques >>>> >>>> >>>> >>>> Le 27/09/2017 à 08:07, Deepak Dixit a écrit : >>>> >>>>> Hi Rishi/Ratnesh, >>>>> >>>>> IMO relationship should be one-nofk, as website can be empty. >>>>> >>>>> Thanks & Regards >>>>> -- >>>>> Deepak Dixit >>>>> www.hotwaxsystems.com >>>>> www.hotwax.co >>>>> >>>>> On Tue, Sep 26, 2017 at 8:03 PM, <[hidden email]> wrote: >>>>> >>>>> Author: rishi >>>>>> Date: Tue Sep 26 14:33:05 2017 >>>>>> New Revision: 1809749 >>>>>> >>>>>> URL: http://svn.apache.org/viewvc?rev=1809749&view=rev >>>>>> Log: >>>>>> Improvement: Missing Relationship from OrderHeader to WebSite >>>>>> (OFBIZ-9647). Added relationship from order header to website entity. >>> And >>>>>> removed wrong data. >>>>>> Applied patch from (OFBIZ-9647). Thanks Ratnesh Upadhyay for your >>>>>> contribution. >>>>>> >>>>>> Modified: >>>>>> ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>>>>> entitydef/order-entitymodel.xml >>>>>> ofbiz/ofbiz-framework/trunk/applications/order/data/ >>>>>> DemoOrderTestData.xml >>>>>> ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ >>> secas.xml >>>>>> ofbiz/ofbiz-framework/trunk/applications/order/testdef/ >>>>>> data/OrderTestData.xml >>>>>> >>>>>> Modified: ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>>>>> entitydef/order-entitymodel.xml >>>>>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>>>>> applications/datamodel/entitydef/order-entitymodel. >>>>>> xml?rev=1809749&r1=1809748&r2=1809749&view=diff >>>>>> ============================================================ >>>>>> ================== >>>>>> --- ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>>>>> entitydef/order-entitymodel.xml (original) >>>>>> +++ ofbiz/ofbiz-framework/trunk/applications/datamodel/ >>>>>> entitydef/order-entitymodel.xml Tue Sep 26 14:33:05 2017 >>>>>> @@ -432,6 +432,9 @@ under the License. >>>>>> <relation type="one" fk-name="ORDER_HDR_CUOM" >>>>>> rel-entity-name="Uom"> >>>>>> <key-map field-name="currencyUom" rel-field-name="uomId"/> >>>>>> </relation> >>>>>> + <relation type="one" fk-name="ORDER_HDR_WS" >>>>>> rel-entity-name="WebSite"> >>>>>> + <key-map field-name="webSiteId"/> >>>>>> + </relation> >>>>>> <index name="ORDEREXT_ID_IDX"> >>>>>> <index-field name="externalId"/> >>>>>> </index> >>>>>> >>>>>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/data/ >>>>>> DemoOrderTestData.xml >>>>>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>>>>> applications/order/data/DemoOrderTestData.xml?rev= >>>>>> 1809749&r1=1809748&r2=1809749&view=diff >>>>>> ============================================================ >>>>>> ================== >>>>>> --- ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde >>>>>> rTestData.xml >>>>>> (original) >>>>>> +++ ofbiz/ofbiz-framework/trunk/applications/order/data/DemoOrde >>>>>> rTestData.xml >>>>>> Tue Sep 26 14:33:05 2017 >>>>>> @@ -20,7 +20,7 @@ under the License. >>>>>> >>>>>> <entity-engine-xml> >>>>>> <!--Demo data for a sales order --> >>>>>> - <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" >>>>>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>>>>> orderDate="2008-04-23 >>>>>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>>>>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" >>>>>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >>>>>> remainingSubTotal="38.40" grandTotal="50.85" >> invoicePerShipment="Y"/> >>>>>> + <OrderHeader orderId="DEMO10090" orderTypeId="SALES_ORDER" >>>>>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>>>>> orderDate="2008-04-23 >>>>>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>>>>> visitId="10002" statusId="ORDER_APPROVED" createdBy="admin" >>>>>> currencyUom="USD" productStoreId="9000" remainingSubTotal="38.40" >>>>>> grandTotal="50.85" invoicePerShipment="Y"/> >>>>>> <OrderItem orderId="DEMO10090" orderItemSeqId="00001" >>>>>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>>>>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" >>>>>> selectedAmount="0.0" >>>>>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" >>>>>> itemDescription="Round Gizmo" correspondingPoId="" >>>>>> statusId="ITEM_APPROVED"/> >>>>>> <OrderItemPriceInfo orderItemPriceInfoId="9000" >>> orderId="DEMO10090" >>>>>> orderItemSeqId="00001" productPriceRuleId="9000" >>>>>> productPriceActionSeqId="01" modifyAmount="-9.600" >>>>>> description="[PRODUCT_CATEGORY_IDIsPROMOTIONS] >>>>>> [list:48.0;avgCost:48.0;margin:0.0] [type:PRICE_POL]"/> >>>>>> >>>>>> @@ -59,7 +59,7 @@ under the License. >>>>>> >>>>>> <!-- Purchase order test data --> >>>>>> <!--for jira issue - 1782--> >>>>>> - <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" >>>>>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_ >>> SALES_CHANNEL" >>>>>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 >> 13:27:07.024" >>>>>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" >>>>>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >>>>>> remainingSubTotal="108.0" grandTotal="108.0"/> >>>>>> + <OrderHeader orderId="DEMO10091" orderTypeId="PURCHASE_ORDER" >>>>>> orderName="New Purchase Order" salesChannelEnumId="UNKNWN_ >>> SALES_CHANNEL" >>>>>> orderDate="2008-06-10 13:27:07.024" entryDate="2008-06-10 >> 13:27:07.024" >>>>>> visitId="10000" statusId="ORDER_CREATED" createdBy="admin" >>>>>> currencyUom="USD" productStoreId="9000" remainingSubTotal="108.0" >>>>>> grandTotal="108.0"/> >>>>>> <OrderItem orderId="DEMO10091" orderItemSeqId="00001" >>>>>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>>>>> prodCatalogId="DemoCatalog" isPromo="N" quantity="5.0" >>>>>> selectedAmount="0.0" >>>>>> unitPrice="21.6" unitListPrice="0.0" isModifiedPrice="N" >>>>>> itemDescription="GZ-2644-5 Round Gizmo" statusId="ITEM_CREATED"/> >>>>>> <OrderItemPriceInfo orderItemPriceInfoId="10001" >>>>>> orderId="DEMO10091" >>>>>> orderItemSeqId="00001" description="SupplierProduct >>>>>> [minimumOrderQuantity:5.0, lastPrice: 21.6]"/> >>>>>> <OrderItemPriceInfo orderItemPriceInfoId="10002" >>>>>> orderId="DEMO10091" >>>>>> orderItemSeqId="00001" description="SupplierProduct >>>>>> [minimumOrderQuantity:0.0, lastPrice: 24.0]"/> >>>>>> @@ -82,7 +82,7 @@ under the License. >>>>>> <ItemIssuance itemIssuanceId="9003" orderId="DEMO10091" >>>>>> orderItemSeqId="00001" shipGroupSeqId="00001" shipmentId="9999" >>>>>> shipmentItemSeqId="00001" issuedDateTime="2009-08-13 17:46:29.603" >>>>>> quantity="5"/> >>>>>> >>>>>> <!--Demo Purchase Order data for Accounting--> >>>>>> - <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" >>>>>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL >>>>>> ES_CHANNEL" >>>>>> orderDate="2009-08-13 17:45:50.419" priority="2" >> entryDate="2009-08-13 >>>>>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" >>>>>> webSiteId="OrderEntry" remainingSubTotal="48.00" grandTotal="48.00"/> >>>>>> + <OrderHeader orderId="Demo1001" orderTypeId="PURCHASE_ORDER" >>>>>> orderName="Demo Purchase Order " salesChannelEnumId="UNKNWN_SAL >>>>>> ES_CHANNEL" >>>>>> orderDate="2009-08-13 17:45:50.419" priority="2" >> entryDate="2009-08-13 >>>>>> 17:45:50.419" statusId="ORDER_COMPLETED" currencyUom="USD" >>>>>> remainingSubTotal="48.00" grandTotal="48.00"/> >>>>>> <OrderItem orderId="Demo1001" orderItemSeqId="00001" >>>>>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>>>>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" >>>>>> selectedAmount="0.000000" unitPrice="24.00" unitListPrice="0.00" >>>>>> isModifiedPrice="N" itemDescription="GZ-2644-0 Round Gizmo" >>>>>> statusId="ITEM_COMPLETED" estimatedDeliveryDate="2009-08-13 >>>>>> 17:43:53.0"/> >>>>>> <OrderItemPriceInfo orderItemPriceInfoId="9001" >>> orderId="Demo1001" >>>>>> orderItemSeqId="00001" description="SupplierProduct >>>>>> [minimumOrderQuantity:0.000000, >>>>>> lastPrice: 24.000]"/> >>>>>> <OrderRole orderId="Demo1001" partyId="Company" >>>>>> roleTypeId="BILL_TO_CUSTOMER" /> >>>>>> @@ -126,7 +126,7 @@ under the License. >>>>>> <AcctgTransEntry acctgTransId="9001" >> acctgTransEntrySeqId="00002" >>>>>> acctgTransEntryTypeId="_NA_" partyId="DemoSupplier" >>>>>> roleTypeId="BILL_FROM_VENDOR" glAccountTypeId="ACCOUNTS_PAYABLE" >>>>>> glAccountId="210000" organizationPartyId="Company" amount="48.00" >>>>>> currencyUomId="USD" origAmount="48.00" origCurrencyUomId="USD" >>>>>> debitCreditFlag="C" reconcileStatusId="AES_NOT_RECONCILED"/> >>>>>> >>>>>> <!--Demo Sales Order for Accounting--> >>>>>> - <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" >>>>>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" >>>>>> orderDate="2009-08-17 14:23:49.475" priority="2" >> entryDate="2009-08-17 >>>>>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" >>>>>> createdBy="admin" >>>>>> currencyUom="USD" webSiteId="OrderEntry" productStoreId="9000" >>>>>> remainingSubTotal="107.98" grandTotal="127.09"/> >>>>>> + <OrderHeader orderId="Demo1002" orderTypeId="SALES_ORDER" >>>>>> orderName="Demo Sales Order" salesChannelEnumId="WEB_SALES_CHANNEL" >>>>>> orderDate="2009-08-17 14:23:49.475" priority="2" >> entryDate="2009-08-17 >>>>>> 14:23:49.475" visitId="10000" statusId="ORDER_COMPLETED" >>>>>> createdBy="admin" >>>>>> currencyUom="USD" productStoreId="9000" remainingSubTotal="107.98" >>>>>> grandTotal="127.09"/> >>>>>> <OrderItem orderId="Demo1002" orderItemSeqId="00001" >>>>>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" >>>>>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.000000" >>>>>> selectedAmount="0.000000" unitPrice="59.99" unitListPrice="60.00" >>>>>> isModifiedPrice="N" itemDescription="Micro Chrome Widget" >>>>>> correspondingPoId="" statusId="ITEM_COMPLETED"/> >>>>>> <OrderItem orderId="Demo1002" orderItemSeqId="00004" >>>>>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="WG-1111" isPromo="Y" >>>>>> quantity="1.000000" selectedAmount="0.000000" unitPrice="59.99" >>>>>> unitListPrice="60.00" isModifiedPrice="N" itemDescription="Micro >> Chrome >>>>>> Widget" correspondingPoId="" statusId="ITEM_COMPLETED"/> >>>>>> <PartyRole partyId="DemoCustomer" >> roleTypeId="END_USER_CUSTOMER" >>> /> >>>>>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ >>>>>> secas.xml >>>>>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>>>>> applications/order/servicedef/secas.xml?rev=1809749&r1= >>>>>> 1809748&r2=1809749&view=diff >>>>>> ============================================================ >>>>>> ================== >>>>>> --- ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ >>> secas.xml >>>>>> (original) >>>>>> +++ ofbiz/ofbiz-framework/trunk/applications/order/servicedef/ >>> secas.xml >>>>>> Tue Sep 26 14:33:05 2017 >>>>>> @@ -401,7 +401,6 @@ under the License. >>>>>> <condition field-name="oldStatusId" operator="not-equals" >>>>>> value="CRQ_ACCEPTED"/> >>>>>> <condition field-name="oldStatusId" operator="not-equals" >>>>>> value="CRQ_PENDING"/> >>>>>> <condition field-name="statusId" operator="equals" >>>>>> value="CRQ_ACCEPTED"/> >>>>>> - <condition field-name="webSiteId" operator="equals" >>>>>> value="OrderEntry"/> >>>>>> <set field-name="bodyParameters.custRequestId" >>>>>> env-name="custRequestId"/> >>>>>> <set field-name="bodyParameters.custRequestName" >>>>>> env-name="custRequestName"/> >>>>>> <set field-name="partyIdTo" env-name="fromPartyId"/> >>>>>> @@ -412,7 +411,6 @@ under the License. >>>>>> <eca service="setCustRequestStatus" event="commit"> >>>>>> <condition field-name="oldStatusId" operator="not-equals" >>>>>> value="CRQ_COMPLETED"/> >>>>>> <condition field-name="statusId" operator="equals" >>>>>> value="CRQ_COMPLETED"/> >>>>>> - <condition field-name="webSiteId" operator="equals" >>>>>> value="OrderEntry"/> >>>>>> <set field-name="bodyParameters.custRequestId" >>>>>> env-name="custRequestId"/> >>>>>> <set field-name="partyIdTo" env-name="fromPartyId"/> >>>>>> <set field-name="emailTemplateSettingId" >>>>>> value="CUST_REQ_COMPLETED"/> >>>>>> >>>>>> Modified: ofbiz/ofbiz-framework/trunk/applications/order/testdef/ >>>>>> data/OrderTestData.xml >>>>>> URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/ >>>>>> applications/order/testdef/data/OrderTestData.xml?rev= >>>>>> 1809749&r1=1809748&r2=1809749&view=diff >>>>>> ============================================================ >>>>>> ================== >>>>>> --- ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ >>>>>> OrderTestData.xml >>>>>> (original) >>>>>> +++ ofbiz/ofbiz-framework/trunk/applications/order/testdef/data/ >>>>>> OrderTestData.xml >>>>>> Tue Sep 26 14:33:05 2017 >>>>>> @@ -30,7 +30,7 @@ under the License. >>>>>> <ProductStoreEmailSetting productStoreId="9000" >>>>>> emailType="PRDS_ODR_CONFIRM" bodyScreenLocation="component: >>>>>> //ecommerce/widget/EmailOrderScreens.xml#OrderConfirmNotice" >>>>>> xslfoAttachScreenLocation="component://ecommerce/widget/ >>>>>> EmailOrderScreens.xml#OrderConfirmNoticePdf" subject="OFBiz Demo - >>> Order >>>>>> Confirmation #${orderId}" bccAddress="[hidden email]" >>>>>> fromAddress=" >>>>>> [hidden email]"/> >>>>>> >>>>>> <!--Demo data for a sales order --> >>>>>> - <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" >>>>>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>>>>> orderDate="2008-04-23 >>>>>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>>>>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" >>>>>> webSiteId="OrderEntry" productStoreId="9000" >> remainingSubTotal="38.40" >>>>>> grandTotal="50.85" invoicePerShipment="Y"/> >>>>>> + <OrderHeader orderId="TEST_DEMO10090" orderTypeId="SALES_ORDER" >>>>>> orderName="" salesChannelEnumId="WEB_SALES_CHANNEL" >>>>>> orderDate="2008-04-23 >>>>>> 16:49:27.392" entryDate="2008-04-23 16:49:27.392" priority="2" >>>>>> visitId="10002" statusId="ORDER_APPROVED" currencyUom="USD" >>>>>> productStoreId="9000" remainingSubTotal="38.40" grandTotal="50.85" >>>>>> invoicePerShipment="Y"/> >>>>>> <OrderItem orderId="TEST_DEMO10090" orderItemSeqId="00001" >>>>>> orderItemTypeId="PRODUCT_ORDER_ITEM" productId="GZ-2644" >>>>>> prodCatalogId="DemoCatalog" isPromo="N" quantity="2.0" >>>>>> selectedAmount="0.0" >>>>>> unitPrice="38.4" unitListPrice="48.0" isModifiedPrice="N" >>>>>> itemDescription="Round Gizmo" correspondingPoId="" >>>>>> statusId="ITEM_APPROVED"/> >>>>>> >>>>>> <Party partyId="TestDemoCustomer" partyTypeId="PERSON" >>>>>> statusId="PARTY_ENABLED"/> >>>>>> >>>>>> >>>>>> >>>>>> |
Free forum by Nabble | Edit this page |