Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
4155 Переглядів

Hello. I have an action.server defined as follows:

<odoo>
  <data>
    <record model="ir.actions.server" id="my_custom_action">
      <field name="name">action 1</field>
      <field name="model_id" ref="account.model_account_invoice"/>
      <field name="sequence">1</field>
      <field name="type">ir.actions.server</field>
      <field name="state">code</field>
      <field name="code">
                if records: 
                   action = records.my_method_1()
      </field>
    </record>
  </data>
</odoo>

What i would like to do is to call multiple methods from this action server. Lets say I have my_method_1(), my_method_2() and my_method_3(). How can I call them from my action server in order for them to be executed one after another?  If you could provide me an example for this and for "n methods" it would be excellent :D

PD: I assume I would have to do the same if it where functions (giving its required parameters) instead of methods, right?


Thanks in advance!
Jean.


Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
0
бер. 25
654
2
вер. 19
4971
2
квіт. 18
3123
1
бер. 15
7770
2
лют. 24
3015