2013/9/9 Kaushik S <[email protected]>
> Hi,
> I need to add some entries to the party.party table right at the
> beginning of the installation of GNU Health. We have a list persons with
> their details. We want them to be added right at the start. How should we
> do this?
>
> I need to do something like this -
> def initialiseParties(partyList):
> partyTable= Pool.get('party.party')
> for i in partyList:
> partyTable.create(i)
>
>
> We have out own module. Is there a startup event where we can call this
> code. Perhaps there is some place where such initialising database is
> done.
>
>
Maybe you could develop a wizard and launch it at installation time. And
then, add a record to this table:
<record model="ir.module.module.config_wizard.item"
id="config_wizard_translate_chart_account_es_ca">
<field name="action" ref="translate_accounts_action_wizard"/>
<field name="sequence" eval="5"/>
</record>
> Thanks
>
>
--
Jesús Martín
Zikzakmedia SL
Dr. Fleming, 28, baixos
08720 Vilafranca del Penedès
☏ 93 890 21 08