No one should be able to edit the form once the process is completed.
لقد تم الإبلاغ عن هذا السؤال
1
الرد
5003
أدوات العرض
Hi,
Try the below Javascript code
odoo.define('module.extension_name', function (require) {
var FormView = require('web.FormView');
FormView.include({
load_record: function() {
this._super.apply(this, arguments);
if (this.model === 'your.model') {
if (this.datarecord && (this.datarecord.state === 'state')) {
this.$buttons.find('.o_form_button_edit').css({'display':'none'});
}
else {
this.$buttons.find('.o_form_button_edit').css({'display':''});
}
}
});
});And include the file in assets:
Regards
هل أعجبك النقاش؟ لا تكن مستمعاً فقط. شاركنا!
أنشئ حساباً اليوم لتستمتع بالخصائص الحصرية، وتفاعل مع مجتمعنا الرائع!
تسجيل| المنشورات ذات الصلة | الردود | أدوات العرض | النشاط | |
|---|---|---|---|---|
|
|
1
يونيو 24
|
4742 | ||
|
|
1
أبريل 24
|
11377 | ||
|
|
1
مايو 22
|
6008 | ||
|
|
2
يونيو 21
|
5310 | ||
|
|
1
سبتمبر 20
|
5317 |