how to add an image to a many2one field other than EHCS Many2one Dropdown Image
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- 会計
- 在庫
- PoS
- プロジェクト
- MRP
この質問にフラグが付けられました
1
返信
1021
ビュー
Assuming you have a model named YourModel with a Many2one field named related_field and you want to display an image associated with each record selected in the related_field
in py:
image_field = fields.Binary(string="Image", attachment=True)
in xml:
div>
field name="image_field" widget="image" options='{"preview_image": "image_field"}'/>
/div>
/group>
/sheet>
/form>