diff options
| author | stephanchrst <stephanchrst@gmail.com> | 2022-05-10 21:51:50 +0700 |
|---|---|---|
| committer | stephanchrst <stephanchrst@gmail.com> | 2022-05-10 21:51:50 +0700 |
| commit | 3751379f1e9a4c215fb6eb898b4ccc67659b9ace (patch) | |
| tree | a44932296ef4a9b71d5f010906253d8c53727726 /addons/website_event_sale/views/website_event_templates.xml | |
| parent | 0a15094050bfde69a06d6eff798e9a8ddf2b8c21 (diff) | |
initial commit 2
Diffstat (limited to 'addons/website_event_sale/views/website_event_templates.xml')
| -rw-r--r-- | addons/website_event_sale/views/website_event_templates.xml | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/addons/website_event_sale/views/website_event_templates.xml b/addons/website_event_sale/views/website_event_templates.xml new file mode 100644 index 00000000..ebe72043 --- /dev/null +++ b/addons/website_event_sale/views/website_event_templates.xml @@ -0,0 +1,43 @@ +<?xml version="1.0" encoding="utf-8"?> +<odoo> + +<template id="registration_template" inherit_id="website_event.registration_template"> + <!-- Add price information on tickets (multi tickets, aka in collapse) --> + <xpath expr="//div[hasclass('o_wevent_registration_multi_select')]" position="inside"> + <t t-if="ticket.price"> + <t t-if="(ticket.price-website.get_current_pricelist().currency_id._convert(ticket.price_reduce, event.company_id.sudo().currency_id, event.company_id, datetime.date.today())) > 1 and website.get_current_pricelist().discount_policy == 'without_discount'"> + <del class="text-danger mr-1" t-field="ticket.price" t-options="{'widget': 'monetary', 'from_currency': event.company_id.sudo().currency_id, 'display_currency': website.get_current_pricelist().currency_id}"/> + </t> + <span t-field="ticket.price_reduce" t-options="{'widget': 'monetary', 'display_currency': website.pricelist_id.currency_id}" groups="account.group_show_line_subtotals_tax_excluded"/> + <span t-field="ticket.price_reduce_taxinc" t-options="{'widget': 'monetary', 'display_currency': website.pricelist_id.currency_id}" groups="account.group_show_line_subtotals_tax_included"/> + <span itemprop="price" class="d-none" t-esc="ticket.price"/> + <span itemprop="priceCurrency" class="d-none" t-esc="website.pricelist_id.currency_id.name"/> + </t> + <span t-else="" class="font-weight-bold text-uppercase">Free</span> + </xpath> + <xpath expr="//div[@id='price-range']" position="inside"> + <span class="text-dark"> + From + <span t-esc="event.event_ticket_ids[0].price_reduce" t-options="{'widget': 'monetary', 'display_currency': website.pricelist_id.currency_id}"/> + to + <span t-esc="event.event_ticket_ids[-1].price_reduce" t-options="{'widget': 'monetary', 'display_currency': website.pricelist_id.currency_id}"/> + </span> + </xpath> + <!-- Add price information on tickets (mono ticket, aka not in collapse) --> + <xpath expr="//div[hasclass('o_wevent_registration_single')]//h6" position="after"> + <div class="px-2 text-dark mr-2 border-right d-flex align-items-center align-self-stretch"> + <t t-if="tickets.price"> + <t t-if="(tickets.price-website.get_current_pricelist().currency_id._convert(tickets.price_reduce, event.company_id.sudo().currency_id, event.company_id, datetime.date.today())) > 1 and website.get_current_pricelist().discount_policy == 'without_discount'"> + <del class="text-danger mr-1" t-field="tickets.price" t-options="{'widget': 'monetary', 'from_currency': event.company_id.sudo().currency_id, 'display_currency': website.get_current_pricelist().currency_id}"/> + </t> + <span t-field="tickets.price_reduce" t-options="{'widget': 'monetary', 'display_currency': website.pricelist_id.currency_id}" groups="account.group_show_line_subtotals_tax_excluded"/> + <span t-field="tickets.price_reduce_taxinc" t-options="{'widget': 'monetary', 'display_currency': website.pricelist_id.currency_id}" groups="account.group_show_line_subtotals_tax_included"/> + <span itemprop="price" class="d-none" t-esc="tickets.price"/> + <span itemprop="priceCurrency" class="d-none" t-esc="website.pricelist_id.currency_id.name"/> + </t> + <span t-else="" class="font-weight-bold text-uppercase">Free</span> + </div> + </xpath> +</template> + +</odoo> |
