#5878 - FiscalData validations #1851

Merged
carlossa merged 58 commits from 5858-fiscalData-validations into dev 2024-02-28 13:53:34 +00:00
1 changed files with 6 additions and 10 deletions
Showing only changes of commit f09e249348 - Show all commits

View File

@ -17,17 +17,13 @@ module.exports = Self => {
message: 'The social name cannot be empty' message: 'The social name cannot be empty'
}); });
if (this.city) { Self.validatesPresenceOf('city', {
Self.validatesPresenceOf('city', { message: 'City cannot be empty'
message: 'City cannot be empty' });
});
}
if (this.nif) { Self.validatesPresenceOf('nif', {
Self.validatesPresenceOf('nif', { message: 'The nif cannot be empty'
message: 'The nif cannot be empty' });
});
}
Self.validatesUniquenessOf('nif', { Self.validatesUniquenessOf('nif', {
message: 'TIN must be unique' message: 'TIN must be unique'