diff options
| author | Maxime Chambreuil <maxime.chambreuil@savoirfairelinux.com> | 2015-08-17 16:40:49 +0200 |
|---|---|---|
| committer | Denis Ledoux <dle@odoo.com> | 2015-08-17 16:44:09 +0200 |
| commit | b541187345cfd6888a416cad795b9c0f0b65b26c (patch) | |
| tree | b5a5ccdf9525f27d16132db91ede7e3f885cdf7e /addons | |
| parent | 11cd8ba06c27014d2d73279601f4ca9be9dba7a0 (diff) | |
[FIX] l10n_ca: no attempt to re-create input/output accounts properties
Deleting the properties for the default accounts
in the root product category and then
updating the l10n_ca module leaded to a crash
due to the fact the module tried to re-create
the properties as they were no longer there.
Fixes #3130
Closes #3131
Diffstat (limited to 'addons')
| -rw-r--r-- | addons/l10n_ca/account_chart_template_en.xml | 22 | ||||
| -rw-r--r-- | addons/l10n_ca/account_chart_template_fr.xml | 22 |
2 files changed, 24 insertions, 20 deletions
diff --git a/addons/l10n_ca/account_chart_template_en.xml b/addons/l10n_ca/account_chart_template_en.xml index c0deebfce6b..ed28df2fb53 100644 --- a/addons/l10n_ca/account_chart_template_en.xml +++ b/addons/l10n_ca/account_chart_template_en.xml @@ -1,5 +1,17 @@ <?xml version="1.0" encoding="utf-8"?> <openerp> + <data noupdate="1"> + <!-- Those properties are in a noupdate section in the stock module --> + <!-- No need to create them if they have been deleted --> + <record id="stock.property_stock_account_input_categ" model="ir.property" forcecreate="False"> + <field eval="'account.account,'+str(ref('chart2141_en'))" model="account.account" name="value"/> + <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> + </record> + <record id="stock.property_stock_account_output_categ" model="ir.property" forcecreate="False"> + <field eval="'account.account,'+str(ref('chart1145_en'))" model="account.account" name="value"/> + <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> + </record> + </data> <data> <!-- Chart template --> @@ -22,16 +34,6 @@ <field name="value" ref="base.CAD"/> </record> - <record id="stock.property_stock_account_input_categ" model="ir.property"> - <field eval="'account.account,'+str(ref('chart2141_en'))" model="account.account" name="value"/> - <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> - </record> - - <record id="stock.property_stock_account_output_categ" model="ir.property"> - <field eval="'account.account,'+str(ref('chart1145_en'))" model="account.account" name="value"/> - <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> - </record> - <record id="property_stock_valuation_account_id_en" model="ir.property"> <field name="name">property_stock_valuation_account_id</field> <field name="fields_id" search="[('model','=','product.category'),('name','=','property_stock_valuation_account_id')]"/> diff --git a/addons/l10n_ca/account_chart_template_fr.xml b/addons/l10n_ca/account_chart_template_fr.xml index 71b1eb8ba32..d9d24a06d69 100644 --- a/addons/l10n_ca/account_chart_template_fr.xml +++ b/addons/l10n_ca/account_chart_template_fr.xml @@ -1,5 +1,17 @@ <?xml version="1.0" encoding="utf-8"?> <openerp> + <data noupdate="1"> + <!-- Those properties are in a noupdate section in the stock module --> + <!-- No need to create them if they have been deleted --> + <record id="stock.property_stock_account_input_categ" model="ir.property" forcecreate="False"> + <field eval="'account.account,'+str(ref('chart2171_fr'))" model="account.account" name="value"/> + <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> + </record> + <record id="stock.property_stock_account_output_categ" model="ir.property" forcecreate="False"> + <field eval="'account.account,'+str(ref('chart1145_fr'))" model="account.account" name="value"/> + <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> + </record> + </data> <data> <!-- Chart template --> @@ -22,16 +34,6 @@ <field name="value" ref="base.CAD"/> </record> - <record id="stock.property_stock_account_input_categ" model="ir.property"> - <field eval="'account.account,'+str(ref('chart2171_fr'))" model="account.account" name="value"/> - <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> - </record> - - <record id="stock.property_stock_account_output_categ" model="ir.property"> - <field eval="'account.account,'+str(ref('chart1145_fr'))" model="account.account" name="value"/> - <field eval="'product.category,'+str(ref('product.product_category_all'))" model="product.category" name="res_id"/> - </record> - <record id="property_stock_valuation_account_id" model="ir.property"> <field name="name">property_stock_valuation_account_id</field> <field name="fields_id" search="[('model','=','product.category'),('name','=','property_stock_valuation_account_id')]"/> |
