mirror of
https://github.com/OCA/pms.git
synced 2025-01-29 00:17:45 +02:00
[ADD] pms: Added init_hook.py to activate advanced pricelist when pms is installed
This commit is contained in:
10
pms/init_hook.py
Normal file
10
pms/init_hook.py
Normal file
@@ -0,0 +1,10 @@
|
||||
from odoo import SUPERUSER_ID
|
||||
from odoo.api import Environment
|
||||
|
||||
|
||||
def post_init_hook(cr, _):
|
||||
with Environment.manage():
|
||||
env = Environment(cr, SUPERUSER_ID, {})
|
||||
env["ir.config_parameter"].sudo().set_param(
|
||||
"product.product_pricelist_setting", "advanced"
|
||||
)
|
||||
Reference in New Issue
Block a user