I have a one2many field to ir.attachment,
i want to get file from my computer and upload it to the filed thank you
attachment = fields.One2many('ir.attachment', 'res_partner_id', string='Attachment', compute='_get_file')
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
I have a one2many field to ir.attachment,
i want to get file from my computer and upload it to the filed thank you
attachment = fields.One2many('ir.attachment', 'res_partner_id', string='Attachment', compute='_get_file')
Just Add
Field: attachment_ids
Type: many2many
Widget: many2many_binary
Widget logic: odoo-13.0\addons\web\static\src\js\widgets\attach_document.js
Example:
model.py
attachment_ids = fields.Many2many("Add Attachments")view.xml
<field name="attachment_ids" widget="many2many_binary"/>
i want a computed one2many attachment field and that attachments will upload them automatically, if you have any ideas. Thanks
Создайте аккаунт сегодня, чтобы получить доступ к эксклюзивным функциям и стать частью нашего замечательного сообщества!
Регистрация| Похожие посты | Ответы | Просмотры | Активность | |
|---|---|---|---|---|
|
2
янв. 22
|
14652 | |||
|
0
нояб. 25
|
3 | |||
|
2
июл. 25
|
6563 | |||
|
2
окт. 25
|
8852 | |||
|
How to ORDER BY? [Odoo 10]
Решено
|
2
нояб. 24
|
29789 |
1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.