i want to loop through all these checkboxes and generate them dynamically according to their roles and to concatenate role id dynamically with their friendly names instead of writing them manually , is there any way to do this ?
function leave_module_config()
{
return [
'fields' => [
'Checkbox Field Name' => [
'FriendlyName' => 'role1',
'Type' => 'yesno',
'Description' => 'Tick to enable',
Question
talhaarif
i want to loop through all these checkboxes and generate them dynamically according to their roles and to concatenate role id dynamically with their friendly names instead of writing them manually , is there any way to do this ?
function leave_module_config()
{
return [
'fields' => [
'Checkbox Field Name' => [
'FriendlyName' => 'role1',
'Type' => 'yesno',
'Description' => 'Tick to enable',
'FriendlyName' => 'role2',
'Type' => 'yesno',
'Description' => 'Tick to enable',
'FriendlyName' => 'role3',
'Type' => 'yesno',
'Description' => 'Tick to enable',
'FriendlyName' => 'role4',
'Type' => 'yesno',
'Description' => 'Tick to enable',
],
]
];
}
Link to comment
Share on other sites
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.