For uCommerce 2.5 Security Foundation makes this pretty easy to accomplish with these three steps:
Step 1: Set up the stores
What I'd do is create a shared store to handle the actual sale and then two or more stores, which handle order processing. With that done you'll have three stores (ProductCatalogGroups in uCommerce parlance) in the backend as the topmost nodes under "Product Catalog":
Store A for sales
Store B for order processing
Store C for order processing
Step 2: Set up users for order processing
For each order processing store create a user in Umbraco. Each user is to be allowed only to one store or the other, but not both. With the two new users in place navigate back to the uCommerce app and set up permissions for those users under Settings / Security. User 1 should have checked the permissions "Purchase Orders" and "Change Order Status" for the order processing store B, and user 2 the same for order processing store C.
Step 3: Override the default store assignment for new orders
Now the way uCommerce assigns orders to stores by default is assign them to the store the order is created in, e.g. customer navigates to store A and starts adding items to the basket. That basket will be tied to store A.
You'll want to override this default behavior and channel orders to the relevant order processing store based on whatever business rules are in place. Sometimes the order processing centers are regional so you might use the post code as the key for channelling orders.
The simplest way to override where the order is channelled is to write a new pipeline task and add that to the checkout pipeline as the last step. The task will do the following:
Take a look at the post code entered by the customer on the billing- or shipping address (whatever fits best with your scenario)
Find the relevant order processing store based on the post codes assigned to the store
Update the PurchaseOrder.ProductCatalogGroup property accordingly
New order only get shown to 1 User
I have this problem
i am making a webshop which have 2 storage locations and they both share same webshop.
Something like:
if customer lives in area Central europe
User1 should handle the order and user2 shouldnt even be able to see it.
if customer lives in southern europe
User2 should handle the order and user1 shouldnt even be able to see it.
How should i handle this?
Are we talking about order processing in the backend?
Yes the backend.
For uCommerce 2.5 Security Foundation makes this pretty easy to accomplish with these three steps:
Step 1: Set up the stores
What I'd do is create a shared store to handle the actual sale and then two or more stores, which handle order processing. With that done you'll have three stores (ProductCatalogGroups in uCommerce parlance) in the backend as the topmost nodes under "Product Catalog":
Step 2: Set up users for order processing
For each order processing store create a user in Umbraco. Each user is to be allowed only to one store or the other, but not both. With the two new users in place navigate back to the uCommerce app and set up permissions for those users under Settings / Security. User 1 should have checked the permissions "Purchase Orders" and "Change Order Status" for the order processing store B, and user 2 the same for order processing store C.
Step 3: Override the default store assignment for new orders
Now the way uCommerce assigns orders to stores by default is assign them to the store the order is created in, e.g. customer navigates to store A and starts adding items to the basket. That basket will be tied to store A.
You'll want to override this default behavior and channel orders to the relevant order processing store based on whatever business rules are in place. Sometimes the order processing centers are regional so you might use the post code as the key for channelling orders.
The simplest way to override where the order is channelled is to write a new pipeline task and add that to the checkout pipeline as the last step. The task will do the following:
Writing a new pipeline is documneted in the article uCommerce Pipelines Explained.
Hope this helps.
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.