Via my API connection I receive the status of an order:
But those numbers need to be shown in text, in the bootstrap table. Like this:
10 - New
20 - Scheduled
30 - In progress
35 - Paused
40 - Done
50 - Shipped
60 - Closed
70 - Cancelled
I have tried this:
status.contains(20).then("Scheduled", "")
But I seem to only be able to do that for 1 status (in this case ‘scheduled’) and not for the other statuses. Maybe I’m doing something wrong, anyone an idea?
I don’t know if will work in this case, but you can use nested ternary operators, eg: status == 20 ? "Scheduled" : (status == 35 ? "nextStatus" : "nextTest")
Probably easier to type than enter via the UI, but there may be a better solution (if it is a solution).