Forums
S3 Security
Lawson Security Version 10
Author
Messages
Stacie
New Member
Posts: 2
8/6/2013 5:51 PM
Within LSA - Rules for an Online Securable Type - Has anyone utilized the Expression Builder to create an If statement with the Global Function Utils of "getDBField"?
Trying to write this against the PURCHORDER table for PO20.1 form so that once the vendor number has been added the vendor number can not be changed with the Action Function Code of "change" for a certain role of users. Any examples would be helpful.
Greg Moeller
Veteran Member
Posts: 1498
8/6/2013 6:46 PM
I don't have a PURCHORDER example for you, but how about an EMPLOYEE table example?
trim(getDBField('EMPLOYEE','PROCESS-LEVEL',form.EMP_COMPANY,form.EMP_EMPLOYEE))=='900'||trim(getDBField('EMPLOYEE','PROCESS-LEVEL',form.EMP_COMPANY,form.EMP_EMPLOYEE))=='950')
'NO_ACCESS,'
else
'ALL_ACCESS,'
This compares the PROCESS-LEVEL field from the EMPLOYEE table to the EMPLOYEE trying to be displayed on the form (form.EMP_EMPLOYEE) and if they are process level 900 or 950 (our executives) it doesn't allow it.
Stacie
New Member
Posts: 2
8/6/2013 7:16 PM
Greg,
Thank you.
We do not have HR but wanted to ask that the EMPLOYEE Table has only 2 primary keys:
Company
Employee
Stacie
Greg Moeller
Veteran Member
Posts: 1498
8/6/2013 7:30 PM
The index EMPSET1 only has those 2 fields as keys. There are other keys associated with the other indexes.