Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
2 Trả lời
7531 Lượt xem

Hi , i have created a xlsx file and need to open as downloadable when i click on button in python how to achieve this ?

Ảnh đại diện
Huỷ bỏ

Do you have a solution for your problem ?

Câu trả lời hay nhất

In python there is a package called cStringIO, which is used for buffering.write the xlsx file data to the buffer(encode using base64) variable and then write this value in the buffer variable to a binary field in openerp.

Ảnh đại diện
Huỷ bỏ
Tác giả

Thanks for your reply, but my requirement is to display the file and not to store in database how can i achieve this

from where you are creating the xls file?can you give some more details? is it related to openerp?

Tác giả

i am fetching the information from view class and creating the xlsx file

Câu trả lời hay nhất

Take a look at the module that exports the current view to XLS:

https://code.launchpad.net/~domsense/web-addons/7.0-web_export_view

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 2 23
1938
1
thg 3 15
5253
0
thg 5 23
66
2
thg 9 24
3526
1
thg 1 23
16974