Closed pmaselkowski closed 7 years ago
This validator should prevent changing property if it's already saved and param to check against (defaults to itself) is trueish. Example: Prevent changing name if set:
@ImmutableValidator $name = ''
Prevent changing name if installed:
@ImmutableValidator(against = 'installed') $name = '' $installed = false
NOTE: This need to check if model is saved, and if saved value to check against of should be taken from db too.
This validator should prevent changing property if it's already saved and param to check against (defaults to itself) is trueish. Example: Prevent changing name if set:
Prevent changing name if installed:
NOTE: This need to check if model is saved, and if saved value to check against of should be taken from db too.