summaryrefslogtreecommitdiff
path: root/addons/website_slides_survey/static/src/xml
diff options
context:
space:
mode:
authorqmo-odoo <qmo@odoo.com>2019-03-13 13:35:05 +0000
committerjem-odoo <jem@openerp.com>2019-03-15 20:38:58 +0000
commite8e8d7a956a9cc858c06673db62cb2eb9784c9df (patch)
tree9b174a445196d85abc8fb63eaafe33207292ce5f /addons/website_slides_survey/static/src/xml
parent44ae98d3ddbc4cf436e20539d7274e6bcba12e29 (diff)
[FIX] website_slides_survey: certification slide url
Before this commit, in fullscreen mode, clicking on the "pass certification" button would redirect the user to the "non-fullscreen" view. After this commit, the button directly redirects the user to the survey page. To avoid generating user_input of survey (test entry or not) for certification slides in fullscreen mode (table of content), we decided to create those user_input lazily: we redirect the user to a route that create (or reuse) the correct user_input. Task-1946511
Diffstat (limited to 'addons/website_slides_survey/static/src/xml')
-rw-r--r--addons/website_slides_survey/static/src/xml/website_slides_fullscreen.xml11
1 files changed, 6 insertions, 5 deletions
diff --git a/addons/website_slides_survey/static/src/xml/website_slides_fullscreen.xml b/addons/website_slides_survey/static/src/xml/website_slides_fullscreen.xml
index e76839db82a..dab906f24eb 100644
--- a/addons/website_slides_survey/static/src/xml/website_slides_fullscreen.xml
+++ b/addons/website_slides_survey/static/src/xml/website_slides_fullscreen.xml
@@ -1,16 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<templates>
- <t t-extend="website.slides.fullscreen">
- <t t-jquery="t:last" t-operation="after">
- <div t-if="widget.get('slide').type === 'certification' &amp;&amp; !widget.get('slide').certificationDone" class="o_wslides_fs_certification">
+
+ <t t-name="website.slides.fullscreen.certification">
+ <div class="justify-content-center align-self-center">
+ <div t-if="widget.get('slide').type === 'certification' &amp;&amp; !widget.get('slide').completed" class="">
<a class="btn btn-primary" t-att-href="'/slides/slide/' + widget.get('slide').id" target="new"><i class="fa fa-trophy"/> Pass Certification</a>
</div>
- <div class="o_wslides_fs_certification" t-if="widget.get('slide').type == 'certification' &amp;&amp; widget.get('slide').completed">
+ <div class="" t-if="widget.get('slide').type === 'certification' &amp;&amp; widget.get('slide').completed">
<a role="button" class="btn btn-primary" t-att-href="'/survey/' + widget.get('slide').certificationId + '/get_certification'">
<i class="fa fa-fw fa-trophy" role="img" aria-label="Download certification" title="Download certification"/> Download certification
</a>
</div>
- </t>
+ </div>
</t>
<t t-extend="website.slides.fullscreen.title">