Matrix of data places in a Script include
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-20-2024 08:24 AM
Not sure if this a good place to post this , but just looking for a design standpoint, I have a script include that is going to accept three values of data , the user type , created date, and department, each function will get the each piece of data
user type | data created | department |
Platinum | 2001 | help desk |
Platinum | 2012 | help desk |
Platinum | 2012 | help desk |
Platinum | 2012 | help desk |
Gold | 2001 | hr |
Gold | 2001 | hr |
Gold | 2000 | hr |
one scenarios could be if the user type is gold, and date is before 2012 and dept is hr then output a value, there are about 20 permatations depending on these scenarios, from a design is there a better way of doing this without a bunch of if loops?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-20-2024 08:36 AM
Hi @ServNowDev ,
You need to pass data like array in the script includes by passing as json object.
Please refer to below thread:
If I could help you with your Query then, please hit the Thumb Icon and mark it as Correct !!
Thanks & Regards,
Sumanth Meda