콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
3 답글
4943 화면

I want to write a module in which you can upload a file (an excel file in my case) and after uploading, I want to do some processing using the file's data. I couldn't find any tutorials for uploading a file in odoo in a custom modules. anyone can help?

아바타
취소

to upload file you can use binary field, than on button click read that file and process further

작성자

@Sehrish can you be more specific? or send me a link so I can check it out.

베스트 답변

You can use Binary Field to feed uploads.

logo = fields.Binary('Website Logo', default=_default_logo, help="Display this logo on the website.")

above field defined to upload logos. Same can be used to feed any files.

아바타
취소
작성자

How can I process the file that I uploaded? in my case its an excel file

Whenever you upload a file, it will automatically processed by odoo in default and save in ir_attachment field. If you need to do more operations then you can access the file from current object or from ir_attachment table

관련 게시물 답글 화면 활동
3
11월 23
7430
2
6월 24
4652
2
8월 22
6425
1
7월 24
1624
4
5월 24
2894