Skip to Content
Menu
This question has been flagged
2 Replies
4677 Views

 Can anyone please explain ORM methods and their purpose in Odoo?

Avatar
Discard
Best Answer

Hi William son,

Here are some common ORM methods.

1. create/update : Create() method is used to create new records in a model.vals_list is the dictionary used to initialize new records.
2. Search/Read : Search () method is used to fetch or search the records from any specific model. You can fetch the values by passing the domain also in the search method.
3. Unlink : The unlink method is used to remove the recordset from the model. The unlink method does not take any argument, it removes the current active record of the mode.
4. copy : The copy() method is used to duplicate a recordset in the current model. This method accepts only the default argument.
5. write : The write() method is used to update the records inside the model with the provided values. This method accepts a set of dictionary values and the record is updated with these values.
6. browse : The browse() method is used to return a set of records for the IDs passed as the parameter in the current working model. This method accepts a set of IDs and returns the record sets corresponding to that IDs.

If you need any assistance or support, please don't hesitate to reach out. Our team is always here to help!"

Regards,

Team Ksolves!


Avatar
Discard
Related Posts Replies Views Activity
0
Aug 24
158
1
Jul 24
734
1
Mar 22
3350
1
Jun 21
2154
0
Mar 21
1137