new (basic.gbapp): ALLOW ROLE keyword.

This commit is contained in:
Rodrigo Rodriguez 2023-08-25 18:13:10 -03:00
parent a2689c7ce2
commit e8d057cb39

View file

@ -532,10 +532,14 @@ export class DialogKeywords {
* @example ALLOW ROLE "DevOps"
*
*/
public async allowRole({ pid, value: role }) {
public async allowRole({ pid, role }) {
const { min, user, proc } = await DialogKeywords.getProcessInfo(pid);
const sys = new SystemKeywords();
if (!role){
throw new Error(`Invalid access. NULL role specified.`);
}
// Updates current roles allowed from now on this dialog/process.
proc.roles = role;