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)?
<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
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
|Asked: 7/26/13, 2:03 PM|
|Seen: 4434 times|
|Last updated: 3/16/15, 8:10 AM|