How to lock closed opportunities/transactions?
How to lock closed opportunities/transactions?
You need to create a custom view record on Opportunities (custom/modules/Opportunities/clients/base/views/record/record.js)
extendsFrom: 'OpportunitiesRecordView',
initialize: function (options) {
this._super('initialize', [options]);
this.model.on("sync",function() {
if(_.contains(['Closed Won', 'Closed Lost'], this.model.get('editable_c'))) {
this.disableButton('edit_button');
this.disableButton('cancel_button');
this.disableButton('save_button');
this.disableButton('delete_button');
}
}, this);this.context.on('button:aldar:click', this.executeMethod, this);
},handleEdit: function(e, cell) {
if(_.contains(['Closed Won', 'Closed Lost'], this.model.get('editable_c'))) this._super('handleEdit', [e, cell]);
},
Remember to run Quick Repair and Rebuild / Rebuild JS Grouping Files
Regards
Hi André,
Thank you for your response and help. I will check if our IT people can do
it.
Best,
Emily
On Wed, Oct 9, 2019 at 10:42 AM André Lopes <sugarcrm-public@jiveon.com>
Hi André,
Thank you for your response and help. I will check if our IT people can do
it.
Best,
Emily
On Wed, Oct 9, 2019 at 10:42 AM André Lopes <sugarcrm-public@jiveon.com>