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

As you may know, invisible elements are still available in the DOM so can the can easily be restored.

https://www.odoo.com/nl_NL/forum/help-1/odoo-security-issue-for-invisible-fields-86106

What about removing:
this.$("button.o_invisible_modifier").remove();

Still not perfect but better?
What do you think?

Thanks,


Alexander

Odoo13 (all versions)

อวตาร
ละทิ้ง
Graag contact opnemen via pieter@briqwise.com Vriendelijke groet, Alexander
คำตอบที่ดีที่สุด

Hi,

We can try this method like,

odoo.define('module_name.invisible', function (require) {
    "use strict";
    var FormRenderer = require('web.FormRenderer');
    FormRenderer.include({
        start: function () {
            return this._super.apply(this, arguments).then(() =>{
                this.$el.find('.o_invisible_modifier').remove()
            })
    },
    })
    })


Hope it helps

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
0
มี.ค. 15
2503
2
เม.ย. 24
7250
6
ต.ค. 15
5421
3
มี.ค. 15
6388
How to override JS code in Odoo? แก้ไขแล้ว
2
มี.ค. 15
20820