Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
2734 มุมมอง

How I can hide or show Export ALL button and action export depend on group user?

I tried this but not work:

base code:

<t t-name="ListView.buttons">
<div class="o_list_buttons d-flex" role="toolbar" aria-label="Main actions">
<button type="button" class="btn btn-primary o_list_button_save" title="Save record" accesskey="s">
Save
button>
<button type="button" class="btn btn-secondary o_list_button_discard" title="Discard record" accesskey="j">
Discard
button>
<t t-if="widget.is_action_enabled('create')">
<button type="button" class="btn btn-primary o_list_button_add" title="Create record" accesskey="c">
Create
button>
t>
<t t-if="widget.is_action_enabled('export_xlsx') and widget.isExportEnable">
<button type="button" class="btn btn-secondary fa fa-download o_list_export_xlsx" title="Export All" aria-label="Export All"/>
t>
div>
t>

my inherit code:

xml version="1.0" encoding="utf-8"?>

<templatesxml:space="preserve">

<tt-inherit="web.ListView.buttons"t-inherit-mode="extension"owl="1">

<xpathexpr="//div//t[2]//button[@title='Export All']"position="attributes">
<attributename="groups">crm_sales_tso.crm_saleAdminattribute>
xpath>
t>

templates>


อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi,

it depends on "Access to Export Feature" group under user form--> technical



อวตาร
ละทิ้ง
ผู้เขียน

have any way I can uncheck "Access to Export Feature" if I'm in an other group?

Related Posts ตอบกลับ มุมมอง กิจกรรม
2
มิ.ย. 22
5024
Export/Import product images แก้ไขแล้ว
2
ก.พ. 25
11232
1
ก.ค. 22
2988
1
ก.ค. 25
1607
1
มิ.ย. 25
1707