Restrcit editing the record when try to edit by passing edit varable in url

  if (status === ‘Billed’ && scriptContext.type === scriptContext.UserEventType.EDIT) {

                    log.debug(‘error’, ‘You cannot edit a Sales Order with status “Billed”.’);

                    throw (‘You cannot edit a Sales Order with status “Billed”.’);

                }

Leave a comment

Your email address will not be published. Required fields are marked *