Skip to Content
Menu
This question has been flagged
746 Rodiniai

Environment:
Working in Odoo.sh 18.0 on a shared hosting.


Question:
How can I modify default settings through my module?
In example the setting "Sales>Product Catalog>Variant Grid Entry" has a field "module_sale_product_matrix" (as seen through the computed Arch)
This field can be activated by loading in the module "sale_product_matrix" in the manifest 
(easy to figure out as to just remove "module_" from the naming)

But how to load the setting "Sales>Product Catalog>Units of Measure" which has field "group_uom"?


Reasoning:

In my Development branch I want the same settings as in Productrion and Staging.
Because now I need to set them at each commit which causes a build and thus wipes the settings.

Tried:

​1. models.TransientModel

Creating a class with the field to overwrite the "group_uom" value​

​2. JupyterLab

​config_settings = env['ir.config_parameter'].sudo() #'res.config.settings' didn't work either.

​config_settings.set_param('group_uom', '1')


Any feedback would be helpfull, thanks in advance!

Portretas
Atmesti
Related Posts Replies Rodiniai Veikla
1
birž. 24
1993
2
birž. 24
3052
1
gruod. 24
4369
1
gruod. 24
3873
2
saus. 23
5631