콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
2 답글
6243 화면
odoo 13 change date format overridden controllers below class and init method,
Changes not reflected.


from odoo.addons.web.controllers.main import ExportXlsxWriter


class ExportXlsxWriter(ExportXlsxWriter):

def __init__(self, fields, row_count=0):
super(ExportXlsxWriter, self).__init__(fields, row_count=row_count)
self.date_style = self.workbook.add_format({'text_wrap': True, 'num_format': 'mm-dd-yyyy'})

Odoo old to new all versions export date format change or set in user interface feature not available.
Is any custom module available export data date format and float_time widget change from user interface? or any plan to add this feature in the latest odoo 14 version.
아바타
취소

I experience the exact same problem. Why is this format fixed and not aligned with user settings for language in Odoo or Excel ?

베스트 답변
def __myinit__(self, field_names, row_count=0):
self.field_names = field_names
self.output = io.BytesIO()
...

ExportXlsxWriter.__init__ = __myinit__


아바타
취소
베스트 답변
just add format_date(self.env,date),'num_format': 'dd-mm-yyyy'},


아바타
취소
관련 게시물 답글 화면 활동
4
8월 24
75282
2
5월 25
1155
0
10월 23
2284
2
10월 23
2069
0
9월 23
1022