İçereği Atla
Menü
Bu soru işaretlendi
1 Cevapla
5662 Görünümler

Hi, I am creating attachment file(upload documents) in my module. I have created successfully created "upload features" using binary field in following way.

xml:

<field name="file_upload">

Python:

'file_upload':fields.binary('Documents')

Here When I click select button My directory will be opened, then i need choose file. But i want these process is doing automatically. That means When I click save button to save a record, documents should be attached automatically.

I tried many way but still I can not get. pls anyone answer this question,.

Avatar
Vazgeç

Anything on this ?

En İyi Yanıt

Python:


binary_field = fields.Binary(string = 'File')

file_name = fields.Char(string = 'Filename')

And in the form view in your XML:

filename="file_name"/>


Avatar
Vazgeç
İlgili Gönderiler Cevaplar Görünümler Aktivite
3
Mar 24
17309
2
Ara 23
25397
1
Mar 15
3441
1
Mar 15
4161
0
Mar 15
3958