Magento – How to different users log in with the same customer(same email id) and place multiple orders simultaneously

b2bcartcheckoutquote

We want to implement a functionality in which multiple executives logged in from a dealer account can place orders simultaneously.

As per Magento default functionality with users logged in using the same account, Magento merges the carts of all users. Can any one suggest a way to implement it or have an idea if already implement the same function previously.

Best Answer

Let's think about this:

There is only one active quote per customer.

If you log in, this quote get attached to your session. If you have already a filled quote, these quotes get merged.

So I think this can be done. I would start to remove the merging process, so you get one quote per session. The problem is, if you don't check out, your cart is lost ,because there is no way to determine, which session owns which quote.

Maybe you can have very long sessions and add the session id to the quote, so you can find it again.


Maybe it is a better idea to implement a layer between this, so you have a login (which is not the customer login) and after this, you can choose a customer (somehow? however this is called for the user) and then the customer is logged in. After the order is made, the customer_id is changed, so all the orders are in one customer account.

But then you have the problem that the other accounts can't access the order after the customer id is changed...