I have a model that have fields binary
file_pdf = fields.Binary(string="File PDF")
I can upload my PDF. But I cannot download back the file. I'm planning to process the binary in the backend so the user will be receive the processed PDF.
I tried what you suggest. here is the result
1 is for Milly shajan
2 is for Dương Nguyễn
Sorry I have to reply from the question since I cannot put image in the reply
Hello, i check the source code and see that if you apply my code on transient model (wizard) you can not have option download because transient model data will be deleted automatically. So i think if you need to download this attachment, write a logic to update it into message_attachment_ids of the model that trigger this wizard
The condition at https://github.com/odoo/odoo/blob/07636eae3c36e6b118af3d8386672278be52cf46/addons/web/static/src/views/fields/binary/binary_field.xml#L13-L18 failed and therefor no download button is display
that make sense. Please update your answer or make new answer. I will mark it as the best answer
Wow, thanks, i have updated the answers cheer sir