Odoo Help

0

How to change existing model record by use of xml data?

By
Antanas
on 7/26/13, 2:03 PM 5,418 views

Hello,

Is it possible to change existing model records by use of xml data file? Let's say there is a record in 'auditrail.rule' where it's field 'log_deletes' is True. Is it possible to change value of this field with xml data file (I mean .xml which is declared in __openerp__.py 'data' key)?

3

Ray Carnes

--Ray Carnes--
17185
| 9 7 9
Atlanta, United States
--Ray Carnes--

Senior Odoo Analyst

OpenERP 6.1, 7.0; Odoo 8.0, 9.0, 10.0.

Completed Odoo Functional and Technical Training.

Major Skills:

  • User Needs and GAP Analysis;

  • Functional and Technical Design;

  • Prototyping and Proof of Concepts;

  • Requirements Specifications;

  • Agile Implementation;

  • Data Migration;

  • Configuration & Customization (UI and code);

  • Integration - Odoo and non Odoo Applications and Services;

  • Training and Knowledge Transfer;

  • Go Live Support;

  • Helpdesk;

  • Version Upgrades and Migration.

  • Accounting Expert.

I have over 20 years of experience empowering and enabling users with enterprise information systems that make a real and measurable difference in their ability to proactively manage their businesses and organizations. 

I am a skilled Communicator and I only take the serious things seriously!

Ray Carnes
On 7/27/13, 6:17 PM
<record id="THE XML ID OF THE RECORD YOU WANT TO CHANGE" >
    <model="THE MODEL THAT HOLDS THE RECORD">
    <field name="THE NAME OF THE FIELD TO CHANGE">THE NEW VALUE</field>
</record>

So something like:

<record id="XML ID OF YOUR RECORD - EXPORT THE RECORD TO GET ONE IF IT IS FALSE" 
    <model="audittrail.rule">
    <field name="log_deletes">False</field>
</record>

The record ID of the demo record is audittrail.demo_audittrail_rule

Thank you!

Antanas
on 7/28/13, 4:00 AM

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

Register

Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

0 follower(s)

Stats

Asked: 7/26/13, 2:03 PM
Seen: 5418 times
Last updated: 3/16/15, 8:10 AM