I have a question regarding addresses within ucommerce.
At present, our project allows the customer to create, update and delete multiple addresses in the database. I believe addresses are stored in the ucommerce_address table against the customer.
When an order is processed, the customer will select a shipping address and billing address and records are copied into the order_address table. This is perfect for us because if the user decides to amend an address from the ucommerce_address table, we still have a reference to the previous address in the order_address table.
However, in the purchase_order table there is a reference to billingaddress which is keyed off to the ucommerce_address table. What happens if the customer amends this address after an order has been placed? It could mean that the address is different to the actual address when the order was placed, or even worse, the address could have been deleted.
Am I correct in assuming this? If so, is there a suggested approach where the billingaddress stored against a purchase order will never change?
Ucommerce and multiple addresses
Hi all,
I have a question regarding addresses within ucommerce.
At present, our project allows the customer to create, update and delete multiple addresses in the database. I believe addresses are stored in the ucommerce_address table against the customer.
When an order is processed, the customer will select a shipping address and billing address and records are copied into the order_address table. This is perfect for us because if the user decides to amend an address from the ucommerce_address table, we still have a reference to the previous address in the order_address table.
However, in the purchase_order table there is a reference to billingaddress which is keyed off to the ucommerce_address table. What happens if the customer amends this address after an order has been placed? It could mean that the address is different to the actual address when the order was placed, or even worse, the address could have been deleted.
Am I correct in assuming this? If so, is there a suggested approach where the billingaddress stored against a purchase order will never change?
I hope this makes sense!
Thanks in advance,
Adam
Hello,
The BillingAddress is also an OrderAddress, same as the shipping addresses. So they are "local" copies to the PurchaseOrder.
BillingAddress is key'ed to the OrderAddress table, not the Address Table.
So you should be safe! :-)
Kind regards,
Jesper
is working on a reply...