summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
Diffstat (limited to 'addons')
-rw-r--r--addons/sale/views/report_invoice_layouted.xml18
-rw-r--r--addons/stock/report/report_stockpicking_operations.xml4
-rw-r--r--addons/website/views/website_backend_navbar.xml8
-rw-r--r--addons/website_blog/views/website_blog_templates.xml4
-rw-r--r--addons/website_event/views/website_event_templates.xml4
-rw-r--r--addons/website_forum/views/website_forum.xml4
-rw-r--r--addons/website_hr_recruitment/views/templates.xml4
-rw-r--r--addons/website_sale/views/templates.xml4
-rw-r--r--addons/website_sale_stock/views/templates.xml5
9 files changed, 29 insertions, 26 deletions
diff --git a/addons/sale/views/report_invoice_layouted.xml b/addons/sale/views/report_invoice_layouted.xml
index 19801d28492..037298e3aad 100644
--- a/addons/sale/views/report_invoice_layouted.xml
+++ b/addons/sale/views/report_invoice_layouted.xml
@@ -1,9 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
-<template id="report_invoice_layouted" inherit_id="account.report_invoice_document" groups="sale.group_sale_layout">
- <xpath expr="//table" position="replace">
- <t t-foreach="o.order_lines_layouted()" t-as="page">
+<template id="report_invoice_layouted" inherit_id="account.report_invoice_document">
+ <xpath expr="//table" position="attributes">
+ <attribute name="groups">!sale.group_sale_layout</attribute>
+ </xpath>
+ <xpath expr="//table" position="after">
+ <t groups="sale.group_sale_layout" t-foreach="o.order_lines_layouted()" t-as="page">
<table class="table table-condensed">
<thead>
<tr>
@@ -70,9 +73,12 @@
</xpath>
</template>
- <template id="report_invoice_document_inherit_sale" inherit_id="account.report_invoice_document" groups="sale.group_delivery_invoice_address">
- <xpath expr="//div[@name='invoice_address']" position="replace">
- <div class="col-xs-5 col-xs-offset-7">
+ <template id="report_invoice_document_inherit_sale" inherit_id="account.report_invoice_document">
+ <xpath expr="//div[@name='invoice_address']" position="attributes">
+ <attribute name="groups">!sale.group_delivery_invoice_address</attribute>
+ </xpath>
+ <xpath expr="//div[@name='invoice_address']" position="before">
+ <div class="col-xs-5 col-xs-offset-7" groups="sale.group_delivery_invoice_address">
<strong t-if="o.partner_shipping_id == o.partner_id">Invoicing and shipping address:</strong>
<strong t-if="o.partner_shipping_id != o.partner_id">Invoicing address:</strong>
<div t-field="o.partner_id"
diff --git a/addons/stock/report/report_stockpicking_operations.xml b/addons/stock/report/report_stockpicking_operations.xml
index 57720aea989..a340d227dd7 100644
--- a/addons/stock/report/report_stockpicking_operations.xml
+++ b/addons/stock/report/report_stockpicking_operations.xml
@@ -96,7 +96,9 @@
</tr>
</thead>
<tbody>
- <tr t-foreach="o.pack_operation_ids" t-as="pack_operation">
+ <t t-set="pack_operation_ids" t-value="o.pack_operation_ids"/>
+ <t groups="base.group_portal" t-set="pack_operation_ids" t-value="o.pack_operation_ids.sudo()"/>
+ <tr t-foreach="pack_operation_ids" t-as="pack_operation">
<td><span t-field="pack_operation.product_id"/><br/>
<span t-field="pack_operation.product_id.description_picking"/>
<t t-if="not pack_operation.product_id and pack_operation.package_id"><span t-field="pack_operation.package_id"/></t></td>
diff --git a/addons/website/views/website_backend_navbar.xml b/addons/website/views/website_backend_navbar.xml
index f6483fc8e65..44583e81b61 100644
--- a/addons/website/views/website_backend_navbar.xml
+++ b/addons/website/views/website_backend_navbar.xml
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!-- Front-end/Back-end integration -->
- <template groups="base.group_user" id="user_navbar" inherit_id="website.layout">
+ <template id="user_navbar" inherit_id="website.layout">
<xpath expr="//body" position="attributes">
- <attribute name="class">o_connected_user</attribute>
+ <attribute name="t-att-class">'o_connected_user' if env['ir.ui.view'].user_has_groups('base.group_user') else ''</attribute>
</xpath>
<xpath expr="//body/div['id=wrawrap']" position="before">
- <nav t-if="website and menu_data" id="oe_main_menu_navbar" class="o_main_navbar">
+ <nav groups="base.group_user" t-if="website and menu_data" id="oe_main_menu_navbar" class="o_main_navbar">
<ul id="oe_applications">
<li class="dropdown active">
<a class="dropdown full" data-toggle="dropdown" href="#">
@@ -92,7 +92,7 @@
<!-- Add new page/content modal -->
<xpath expr="//body/div['id=wrawrap']" position="after">
- <div class="modal" id="o_website_add_page_modal">
+ <div groups="base.group_user" class="modal" id="o_website_add_page_modal">
<div class="modal-dialog modal-lg">
<ul>
<li groups="base.group_website_designer"><a href="#" data-action="new_page"><i class="fa fa-file-o"/><p>New Page</p></a></li>
diff --git a/addons/website_blog/views/website_blog_templates.xml b/addons/website_blog/views/website_blog_templates.xml
index 63315d39fc9..f74ecd39a17 100644
--- a/addons/website_blog/views/website_blog_templates.xml
+++ b/addons/website_blog/views/website_blog_templates.xml
@@ -480,9 +480,9 @@
</template>
<!-- User Navbar -->
-<template id="content_new_blogpost" inherit_id="website.user_navbar" groups="base.group_website_designer">
+<template id="content_new_blogpost" inherit_id="website.user_navbar">
<xpath expr="//div[@id='o_website_add_page_modal']//ul" position="inside">
- <li><a href="#" data-action="new_blog_post"><i class="fa fa-rss"/><p>New Blog Post</p></a></li>
+ <li groups="base.group_website_designer"><a href="#" data-action="new_blog_post"><i class="fa fa-rss"/><p>New Blog Post</p></a></li>
</xpath>
</template>
diff --git a/addons/website_event/views/website_event_templates.xml b/addons/website_event/views/website_event_templates.xml
index 3663d00f5f8..fe1f57783c0 100644
--- a/addons/website_event/views/website_event_templates.xml
+++ b/addons/website_event/views/website_event_templates.xml
@@ -629,9 +629,9 @@
<!-- User Navbar -->
-<template id="content_new_event" inherit_id="website.user_navbar" groups="event.group_event_manager">
+<template id="content_new_event" inherit_id="website.user_navbar">
<xpath expr="//div[@id='o_website_add_page_modal']//ul" position="inside">
- <li><a href="#" data-action="new_event"><i class="fa fa-glass"/><p>New Event</p></a></li>
+ <li groups="event.group_event_manager"><a href="#" data-action="new_event"><i class="fa fa-glass"/><p>New Event</p></a></li>
</xpath>
</template>
</odoo>
diff --git a/addons/website_forum/views/website_forum.xml b/addons/website_forum/views/website_forum.xml
index ea749169678..8669261b1a3 100644
--- a/addons/website_forum/views/website_forum.xml
+++ b/addons/website_forum/views/website_forum.xml
@@ -1505,9 +1505,9 @@
</template>
<!-- User Navbar -->
-<template id="content_new_forum" inherit_id="website.user_navbar" groups="base.group_user">
+<template id="content_new_forum" inherit_id="website.user_navbar">
<xpath expr="//div[@id='o_website_add_page_modal']//ul" position="inside">
- <li><a href="#" data-action="new_forum"><i class="fa fa-comment"/><p>New Forum</p></a></li>
+ <li groups="base.group_user"><a href="#" data-action="new_forum"><i class="fa fa-comment"/><p>New Forum</p></a></li>
</xpath>
</template>
diff --git a/addons/website_hr_recruitment/views/templates.xml b/addons/website_hr_recruitment/views/templates.xml
index 3892b8092df..20fa16d6634 100644
--- a/addons/website_hr_recruitment/views/templates.xml
+++ b/addons/website_hr_recruitment/views/templates.xml
@@ -293,9 +293,9 @@
</template>
<!-- User Navbar -->
-<template id="content_new_job_offer" inherit_id="website.user_navbar" groups="base.group_hr_manager">
+<template id="content_new_job_offer" inherit_id="website.user_navbar">
<xpath expr="//div[@id='o_website_add_page_modal']//ul" position="inside">
- <li><a href="/jobs/add" class="js_link2post"><i class="fa fa-briefcase"/><p>New Job Offer</p></a></li>
+ <li groups="base.group_hr_manager"><a href="/jobs/add" class="js_link2post"><i class="fa fa-briefcase"/><p>New Job Offer</p></a></li>
</xpath>
</template>
diff --git a/addons/website_sale/views/templates.xml b/addons/website_sale/views/templates.xml
index 829f2caef4a..a4e52cce2ff 100644
--- a/addons/website_sale/views/templates.xml
+++ b/addons/website_sale/views/templates.xml
@@ -1488,9 +1488,9 @@
<!-- User Navbar -->
-<template id="content_new_product" inherit_id="website.user_navbar" groups="sales_team.group_sale_manager">
+<template id="content_new_product" inherit_id="website.user_navbar">
<xpath expr="//div[@id='o_website_add_page_modal']//ul" position="inside">
- <li><a id="create-new-product" href="#" data-action="new_product"><i class="fa fa-shopping-cart"/><p>New Product</p></a></li>
+ <li groups="sales_team.group_sale_manager"><a id="create-new-product" href="#" data-action="new_product"><i class="fa fa-shopping-cart"/><p>New Product</p></a></li>
</xpath>
</template>
diff --git a/addons/website_sale_stock/views/templates.xml b/addons/website_sale_stock/views/templates.xml
index e78c981166e..fb8965e9c32 100644
--- a/addons/website_sale_stock/views/templates.xml
+++ b/addons/website_sale_stock/views/templates.xml
@@ -31,9 +31,4 @@
</t>
</xpath>
</template>
- <template id="report_picking_portal" inherit_id="stock.report_picking" groups="base.group_portal">
- <xpath expr="//tr[@t-foreach='o.pack_operation_ids']" position="attributes">
- <attribute name="t-foreach">o.pack_operation_ids.sudo()</attribute>
- </xpath>
- </template>
</odoo> \ No newline at end of file