跳至內容
選單
此問題已被標幟
2 回覆
26257 瀏覽次數

Hi All,

I have a binary field in a wizard, and I am trying to get the name of file attached in button action of that wizard.

I know it is possible in website.

Any Hints.?

頭像
捨棄
最佳答案

Try this,

In Model,

file = fields.Binary("Attachment")

file_name = fields.Char("File Name")

In View,

<field name="file" filename="file_name"/>

<field name="file_name" invisible="1"/>

If you try this, binary field will show the file name.

頭像
捨棄
作者

Perfect, Accepting as answer.

Could you please tell me any way to get the path of the attached file.?

作者

Yes, Got it

相關帖文 回覆 瀏覽次數 活動
0
10月 23
1617
4
10月 18
8401
3
6月 18
6958
1
12月 19
3555
0
10月 19
2863