Files
odoo_source/addons/website_event_sale
Abdelouahab (abla) c2896d3b18 [FIX] website_event_sale: mandatory company
To reproduce
============
- create event with ticket that can be sold on website
- make company field empty in event form
- buy ticket from website and go back to the event form > Error raised

Problem
========
- the method `_compute_sale_price_subtotal` is using `company_id`, but as
it's not required in Form View we give it a null value

Solution
========
- make `company_id` required from view
- if `company_id` is not set, use the current company from `env`
- Define constraint on `website_id` as the user should choose website from
same company of the event

opw-3395108

closes odoo/odoo#132173

X-original-commit: 0d70e38ab4bab850ee4bddc7b21b4c6c10809294
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Abdelouahab Laaroussi (abla) <abla@odoo.com>
2023-08-17 13:03:18 +02:00
..
…
…