AnsweredAssumed Answered

Need to authorise creation of new record

Question asked by richard@itech on Sep 21, 2015
Latest reply on Sep 22, 2015 by richard@itech



I am working on a solution which has users privilege sets to determine access levels. A transaction table is used to store records, and if a low level user is logged in, I need to have this record creation authorised by a higher level user.


What I have come up with so far is this:-

     Store current users name in variable


     Custom dialog box comes up asking for authorisers Username and password, the values are saved in global fields.

     I then use the re-login script to try and login using these credentials

     When this succeeds an Exit Loop If Get (CurrentPrivilegeSetName) is not equal to "Low-level" is used to check the account can authorise the transaction

End Loop


I then fill in the relevant fields in the transaction record with the user who is now logged in (Authoriser), before I run a second loop which prompts for the original users password so I can switch back to them using another Re-login.


Whilst this works, it feels clumsy, especially having to ask for the password to re-login the second time.


Am I missing an easier way to do this?