Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
1911 Näkymät

Hi,


If I use Settings -> Attachments I don't see all my attachments.

Eg. I have a field image = fields.Binary(... attachment=True). If I add images to a model I can't see them in the Frontend
The interesting thing is i see the Attachment in the database table.

And even if I create another field with a relation to ir.attachment I can chose this attachment in the frontend. 
How can I access this images in the backend? This query returns []

eg.
attachment_ids = ( env["ir.attachment"] .sudo() .search([("res_model", "=", "forum.post"), ("res_id", "=", 1834)]))

Avatar
Hylkää
Aiheeseen liittyviä artikkeleita Vastaukset Näkymät Toimenpide
1
maalisk. 23
7204
2
huhtik. 22
4693
0
lokak. 21
2998
2
toukok. 20
12638
2
jouluk. 17
4709