Skip to content

Commit bd0c1b6

Browse files
committed
[IMP] survey_sign_oca: add end heading
1 parent b3670c7 commit bd0c1b6

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

survey_sign_oca/models/survey_survey.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ class Survey(models.Model):
77
_inherit = "survey.survey"
88

99
start_button_name = fields.Char("Survey Start Button Name", default="Start")
10+
end_heading_name = fields.Char("Survey End Heading Name", default="Thank you!")

survey_sign_oca/views/survey_survey_views.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
<field name="arch" type="xml">
88
<field name="users_can_go_back" position="after">
99
<field name="start_button_name" />
10+
<field name="end_heading_name" />
1011
</field>
1112
</field>
1213
</record>

survey_sign_oca/views/survey_templates.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,12 @@
1313
</t>
1414
</xpath>
1515
</template>
16+
<template id="survey_fill_form_done" inherit_id="survey.survey_fill_form_done">
17+
<xpath expr="//div[hasclass('o_survey_finished')]/h1" position="attributes">
18+
<attribute name="t-if">not survey.end_heading_name</attribute>
19+
</xpath>
20+
<xpath expr="//div[hasclass('o_survey_finished')]/h1" position="after">
21+
<h1 t-if="survey.end_heading_name" t-out="survey.end_heading_name" />
22+
</xpath>
23+
</template>
1624
</odoo>

0 commit comments

Comments
 (0)