Auto filed update for enum field type

Hi

I am working on an app which is for order delivery. I have a field called as order status Type Enum. The drop down options that I have in ENum are new ,approved ,WIP ,rejected ect. My question is on once an order is placed the order status should automatically be new and once the order is approved by Manager the order status should change to a approved, And once the order is accepted by the factory the order status should change to WIP. We tried with auto compute option however it is not getting updated due to the field type is ENum can somebody help on this. Once the order is been dispatched the dispatch section would manually select the order status as closed as this process has both automated and Manjal selection of feels is there a way that we can have Both auto selection and manual selection for a seat

0 2 110
2 REPLIES 2

Hello @bysani_madhukar, i believe the best way to implement that kind of approval process is by placing action buttons in your app for each step, that once pressed should change the value of the “order status” for the row.

Then you can hide it on your form using CONTEXT() and set its initial value as “new”

These are very straightforward data change actions, you can read more of that here:

Given the variety of users of your app, you MUST have a current user system !

Hey @bysani_madhukar

A very common element that I’ll include in my apps, is an [Order_Auto_Status] column.

  • It’s function is nearly the same as that of the [Order_Manual_Status], except that it’s value is derived from a formula

With this sort of setup, it’s all about creating layered IF() formulas - each with their own criteria for when that specific status should be shown.

For Example; let’s say we have the following tables:

Table Name Description
Orders The “root” of the hierarchy, holds basic info about the order (number, date, customer, etc.)
Order_Items Contains a list of all the items ordered in the order
Order_Picked_Items When an employee physically picks the item from it’s storage location and puts it inside a box for this order; that’s what these records represent
Order_Packed_Items When each of the picked items have been individually wrapped and packed in the box

Instead of relying on users to physically change the status by pushing a button, you can “figure out” the status by looking at the states of the various [Related Whatever] columns.

Let’s say I have the following statuses:

  • Open (when NO items have been picked)
  • Pick in progress (when at least 1 item has been picked)
  • Picked (when all items have been picked, but nothing packed
  • Packed (when all items picked have been packed)

The idea is to create a layered set of IF statements, each on for one of your statuses

IF(IsBlank([Picked_Items]), "Open", 
IF(IsNotBlank([Remaining_Items_to_Pick]), "Pick in Progress", 
IF(IsNotBlank([Remaining_Items_to_Pack]), "Picked ", 
"Packed"
)))

Notes

  • Since this [Order_Auto_Status] is a Virtual Column, it’s value won’t be written to the table - where it can be physically stored.

    • To get around this, you could create an Automation that executes the manual status changes based on submittals of child-related data
  • I find it helpful to implement both functionalities: an [Auto_Status] column, but also a [Manual_Status] as well

    • It can be helpful to include an manual override, that way people can conform things when they get off.
    • To do this, include a branch at the start of your formula, that checks to see if the manual status column has a value - if it does, use that; otherwise use the original formula.
IF(IsNotBlank([Order_Manual_Status], [Order_Manual_Status], 
IF(IsBlank([Picked_Items]), "Open", 
IF(IsNotBlank([Remaining_Items_to_Pick]), "Pick in Progress", 
IF(IsNotBlank([Remaining_Items_to_Pack]), "Picked ", 
"Packed"
))))
Top Labels in this Space