Add requiredAttrs array to the webservice informations
Hello @tdockx
The modification helps to know for each section which attrs are mandatory, for example
$ C /types/USER/user
{
"sections": {
"perso": {
"name": "Personal information",
"icon": "geticon.php?context=types&icon=user&size=16",
"attrs": [
"cn",
"sn",
"givenName",
"initials",
"description",
"jpegPhoto"
],
"requiredAttrs": [
"sn",
"givenName"
]
},
"contact": {
"name": "Organizational contact information",
"icon": "geticon.php?context=types&icon=contact&size=16",
"attrs": [
"l",
"st",
"postalAddress",
"roomNumber",
"telephoneNumber",
"mobile",
"pager",
"facsimileTelephoneNumber",
"labeledURI"
],
"requiredAttrs": []
},
"account": {
"name": "Account information",
"icon": "geticon.php?context=applications&icon=ldap&size=16",
"attrs": [
"base",
"uid",
"preferredLanguage",
"userPassword"
],
"requiredAttrs": [
"uid"
]
},
"homecontact": {
"name": "Personal contact information",
"icon": "geticon.php?context=types&icon=contact&size=16",
"attrs": [
"displayName",
"homePostalAddress",
"homePhone"
],
"requiredAttrs": []
},
"organization": {
"name": "Organizational information",
"icon": "geticon.php?context=places&icon=folder&size=16",
"attrs": [
"title",
"o",
"ou",
"departmentNumber",
"employeeNumber",
"employeeType",
"manager"
],
"requiredAttrs": []
}
},
"sections_order": [
"perso",
"contact",
"account",
"homecontact",
"organization"
]
}
There will be cases like userPassword that will see as not mandatory because the attribute is not set as required.