On 09/06/2010 11:20 PM, "Cédric Krier" <[email protected]>" wrote:
> On 06/09/10 21:45 +0200, Paul J Stevens wrote:
>>
>> Hi all,
>>
>> I'm building a customization module to prime the database with parties,
>> addresses, chart-of-accounts, etc.
>>
>> Since my module relies on account I need to resolve the account_payable
>> and account_receivable requirements. But where can I find documentation
>> about setting up the many2one references in xml to do this? Some basic
>> examples would be great - or do I need to look at openerp demo content
>> for hints?
> 
> I'm not sure to understand. But I think you are looking for the ref
> attribute.
> http://doc.tryton.org/1.6/trytond/doc/topics/modules/index.html#xml-files
> 

Ok, let me rephrase then: I'm aware of the ref attribute, but how does
it work? What if I don't know the xml id of the references item?

For instance reference by name doesn't work:

<record model="party.party" id="party_0">
  <field name="name">NFG Net Facilities Group BV</field>
  <field name="code">NFG</field>
  <field name="vat_number">811863761B01</field>
  <field name="vat_country">NL</field>
  <field name="active" eval="True"/>
  <field name="account_payable" ref="Crediteuren"/>
  <field name="account_receivable" ref="Debiteuren"/>
</record>

So my basic question is/was: where if anywhere is this documented, or
should I 'use the source'?





-- 
  ________________________________________________________________
  Paul Stevens                                      paul at nfg.nl
  NET FACILITIES GROUP                     GPG/PGP: 1024D/11F8CD31
  The Netherlands________________________________http://www.nfg.nl

-- 
[email protected] mailing list

Reply via email to