Skip to Content
Menu
This question has been flagged
2 Replies
153 Views

Hello,

I am selling a personal course product via Odoo’s eCommerce platform. Typically, a product is sold to a single contact using the standard online shop flow. My requirement is to allow a family (parent account) to purchase the same product for multiple children (contacts) in one transaction, specifying which child each product line applies to.

For example:

  • A family account has three child contacts.
  • The parent wants to buy three course products (one per child) in the same cart/checkout.
  • Each cart line should indicate (or be tagged to) the relevant child contact.

Is there a way to natively assign a specific contact/child to each product line during checkout? Or, are there module recommendations or customization tips to add a field/tag in the cart or sales order to specify which contact receives each product?

Thanks in advance!

Przemek

Avatar
Discard
Best Answer

Hi,


Odoo’s standard eCommerce does not allow assigning multiple child contacts to individual cart lines in a single checkout. By default, all products in the cart are linked to the main partner account, so a parent cannot specify which child each purchased course is for.


To achieve this functionality, a small customization is needed. You can add a child_contact_id field to the sales order line that links to one of the parent’s child contacts. This field can then be exposed on the website cart and checkout pages, allowing the parent to select the relevant child for each product line. The selection will be stored in the sales order and can be used for invoicing, enrollment, or reporting purposes.


Hope it helps

Avatar
Discard
Best Answer

No, there is no default way of linking a Contact to a Sale Order Line.

What you can do by default is to create a Product Attribute with one Value - and this Value having the Free Text checkbox set:

Product Attribute:


Product:


eCommerce page:


I'm not aware about a ready-made addon for this, but you can certainly try your luck at https://apps.odoo.com/apps or https://odoo-community.org/shop. In any case, this can not be done out-of-the-box, thus requires a 3rd party or custom module.

Avatar
Discard
Author

Thank you Christophe for help. Indeed, it is not the ideal solution , but it can solve the problem in some limited way .