User Story
Flow Name: EduStandBy | School Code Generation
As a System Administrator,
I want the School Code to be automatically generated when a school record is created and left empty,
So that each school has a unique identifier without manual entry errors.
Acceptance Criteria:
- When a new School record is created:
- If the School Code field is empty, the system should automatically generate a unique code.
- If a user manually enters a School Code:
- The system must check if the code is already assigned to another school.
- If the code already exists, an error message should be displayed:
- Error: "School Code '{School_Code__c}' is already assigned to another school. Please use a different code."
- The system should not allow saving the record unless the School Code is unique.