Skip to Content
Menu
This question has been flagged
4 Replies
2142 Views

Hello,

I would like to know if it's possible to add class when we use Odoo Studio.

I can add an automatic action but this is not what I need exactly.

Thanks for your help.

Avatar
Discard
Author Best Answer

Thank you Paresh.

But the fields I need to link are already One2Many with an other model. So I can link them together.

I've find my solution with a For Loop and a link with the main model.


Avatar
Discard
Best Answer

Hi Eric:

You can add a model using the UI. Activate Developer mode and go to Settings > Technical > Database Structure > Models and create the custom model that you need.

Avatar
Discard
Author

Thanks for your help Paresh.

But I want to create a new class to add a new function in Python. Like a link between to model. I can use one2many or many2many because the fields I need to link together are used as many2one with an other model.

See my last new post to understand what I need to do.

Hi Eric: You can define One2many and Many2one relationships in models.

In your post, you have mentioned that an automated action will not meet your need. A little clarification on the requirement would be useful.