Hello
I am trying to make a single If statement that is rather complex with many layers, any help would be appreciated.
I have a singular form that is a 3 step process with each step having its own access level (variable is formUser).
Step1: creation/created = CB
Step2: management = LM
Step3: actioning = AO
There is also New and View Only (VO) access levels.
If(!IsBlank(selectedticket.ID), //No ID means this is not a pre-existing ticket so set formUser to "New"
If(User().FullName = selectedticket.'Actioning Officer'.DisplayName, //is this user the actioning officer?
If(User().FullName = selectedticket.'Line Manager'.DisplayName, //is this user the line manager?
If(User().FullName = selectedticket.'Created By'.DisplayName, //is this user the creator?
If(
User().FullName <> selectedticket.'Created By'.DisplayName
&& User().FullName <> selectedticket.'Line Manager'.DisplayName
&& User().FullName <> selectedticket.'Actioning Officer'.DisplayName
,
Set(formUser, "VO")), //set to view only (VO) if this user is not actioning officer, line manager or creator
Set(formUser, "CB")), //set to creation/created (CB) if you are the creator
Set(formUser, "LM")), //set to management (LM) if you are the line manager
Set(formUser, "AO")), //set to actioning (AO) if you are the actioning officer
Set(formUser, "New")); //if the ticket ID is blank this not a pre-existing ticket so set the ticket to "New"
Thanks in advanced