Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1 Відповісти
2012 Переглядів

I want to disable the sort property of a field in a tree view. Can anyone help me the way to do this?

Аватар
Відмінити
Найкраща відповідь

Hi,

To disable sorting in a tree view, you can inherit Web.ListRender template and set null for required attributes.


<?xml version="1.0" encoding="UTF-8" ?>
      <templates xml:space="preserve">
<t t-name="custommodule_name.ListRenderer" t-inherit="web.ListRenderer" t-inherit- mode="extension" owl="1">
<xpath expr="//t[@t-foreach='state.columns']//th" position="attributes">
             <attribute name="t-on-click"/>
              <attribute name="t-on-mouseenter"/>
                <attribute name="t-on-mouseleave"/>
                <attribute name="t-att-class"/>
        </xpath>
</t>
</templates>



Hope it helps

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
0
квіт. 15
2900
1
лип. 24
1067
2
трав. 24
2153
1
лют. 23
2381
4
лист. 23
28395