function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Rashmi Sahu 9Rashmi Sahu 9 

Once Opportunity is in Contract Signed stage should be locked for manual edition

GIVEN: as a Sales rep
WHEN: I am log in Salesforce
THEN my opportunity is in Contract Signed stage
THEN my opportunity cannot be manually edited anymore
PS - will be locked for manual edition but system integration will continues updating opportunity.

How we can acheive this requirement?
Harpreet On CloudHarpreet On Cloud

1. Create a new Record Type "ReadOnly" on Opportunity. Define a Page Layout for that Record Type and keep all fields as read-only on that Record Type's page layout. Keep the layout of fields on this new Page Layout same as the actual Page Layout with only difference that the fields are read-only.
2. As soon as the Opp Stage is "Contract Signed", change the record type of Opp to "ReadOnly" record type.

Hence users will not be able to make any change from UI but Integration User will still be able to make changes using code.

If this answers your question, please mark it accordingly.