Skip to content
Snippets Groups Projects
Commit 1110ea43 authored by yhu-odoo's avatar yhu-odoo Committed by Aurélien Warnon
Browse files

[FIX] survey: get certification of failure back


PURPOSE

As Certification PDF can be called on failed user input, generate a
certification of failure in that case.

SPECIFICATIONS

In the survey_report_templates.xml, when user_input.quizz_passed is
false, a certification of failure can be generated.

This commit is actually about applying again 57fef7c1 that has been lost
while performing major cleaning in survey templates.

LINKS

PR #42811
Task ID 2148449

closes odoo/odoo#43274

X-original-commit: 6206e0e6213be14a977db028b8f4dc4f755bf11c
Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
parent 7fe7d0ac
No related branches found
No related tags found
No related merge requests found
......@@ -14,12 +14,17 @@
</div>
<div class="certification-bottom">
<h5 class="user-name-label">This Certificate is Presented to</h5>
<div class="user-name" t-esc="user_input.partner_id.name or user_input.email"/>
<div t-if="user_input.scoring_success">
<h5 class="user-name-label">This Certificate is Presented to</h5>
<div class="user-name" t-esc="user_input.partner_id.name or user_input.email"/>
<div class="certification-description">
<span t-field="user_input.survey_id.create_uid.company_id.display_name"/> is proud to award this certificate to
<span t-esc="user_input.partner_id.name or user_input.email"/> for gratuating from <span t-field="user_input.survey_id.display_name"/>.
<div class="certification-description">
<span t-field="user_input.survey_id.create_uid.company_id.display_name"/> is proud to award this certificate to
<span t-esc="user_input.partner_id.name or user_input.email"/> for gratuating from <span t-field="user_input.survey_id.display_name"/>.
</div>
</div>
<div t-else="">
<h5>Certification Failed</h5>
</div>
<div class="certification-bottom-group">
......@@ -46,13 +51,18 @@
<div class="certification-name" t-field="user_input.survey_id.display_name"/>
<hr/>
<h5>This Certificate is Presented to</h5>
<div class="user-name" t-esc="user_input.partner_id.name or user_input.email"/>
<hr class="small"/>
<div t-if="user_input.scoring_success">
<h5>This Certificate is Presented to</h5>
<div class="user-name" t-esc="user_input.partner_id.name or user_input.email"/>
<hr class="small"/>
<div class="certification-description">
<span t-field="user_input.survey_id.create_uid.company_id.display_name"/> is proud to award this certificate to
<span t-esc="user_input.partner_id.name or user_input.email"/> for graduating from <span t-field="user_input.survey_id.display_name"/>.
<div class="certification-description">
<span t-field="user_input.survey_id.create_uid.company_id.display_name"/> is proud to award this certificate to
<span t-esc="user_input.partner_id.name or user_input.email"/> for graduating from <span t-field="user_input.survey_id.display_name"/>.
</div>
</div>
<div t-else="">
<h5>Certification Failed</h5>
</div>
<div class="certification-date" t-field="user_input.create_date" t-options='{"widget": "date"}'/>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment