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

want to change before template email, to format for thousand separator 

(but this also not working) 

after changing email template, now showing error Failed to render template : 'goal' is undefined

already revert html code and also the translation, but it none helps


https://drive.google.com/file/d/1Rm1pzWIMkD4_1dPbkllpEu2tbkC06Dzw/view?usp=sharing 

https://drive.google.com/file/d/1RjqzvmRLFlfmtPHvdvE0zobRWL1gC2_p/view?usp=sharing 


file templates: 

https://drive.google.com/file/d/1RmRAkbQX2ivmNx_Pp-a3n5YBJwm8vLUl/view?usp=sharing


it works a day before, don't know what happened, as this should change email template only, 

creating new email template, dont help either, how to check for the problem cause?


in the log showing this error:

odoo journal[45279]: Odoo Server 14.0+e-20210930:Final6:INFO:odoo.addons.mail.models.mail_render_mixin:Failed to render template : 'goal' is undefined#012Traceback (most recent call last):#012 File "/opt/odoo/odoo14/odoo/addons/mail/models/mail_render_mixin.py", line 352, in _render_template_jinja#012 render_result = template.render(variables)#012 File "/opt/odoo/odoo14-venv-python3.8.6/lib64/python3.8/site-packages/jinja2/environment.py", line 1090, in render#012 self.environment.handle_exception()#012 File "/opt/odoo/odoo14-venv-python3.8.6/lib64/python3.8/site-packages/jinja2/environment.py", line 832, in handle_exception#012 reraise(*rewrite_traceback_stack(source=source))#012 File "/opt/odoo/odoo14-venv-python3.8.6/lib64/python3.8/site-packages/jinja2/_compat.py", line 28, in reraise#012 raise value.with_traceback(tb)#012 File "", line 173, in top-level template code#012 File "/opt/odoo/odoo14-venv-python3.8.6/lib64/python3.8/site-packages/jinja2/sandbox.py", line 384, in getitem#012 return obj[argument]#012jinja2.exceptions.UndefinedError: 'goal' is undefined

아바타
취소
작성자 베스트 답변

odoo seems reformat for the html that put loop for in the wrong line:

% for goal in line[''goals'']:
% set tdBgColor = ''#fff''
% set tdColor = ''gray''
% set mutedColor = ''#AAAAAA''
% set tdPercentageColor = ''#9A6C8E''
table html div and stuff
% endfor


it should format like this in the sql, manually update in database:

https://drive.google.com/file/d/1Rvj73Tk6IPb_RN_3FxZC1NOFWzUywQQ2/view?usp=sharing 


아바타
취소
관련 게시물 답글 화면 활동
3
5월 22
5664
0
1월 25
1046
1
11월 23
2128
0
9월 21
1994
1
3월 15
4515