Hi, I’ve got a feature that I want to add to my client’s app and I’m wondering if there’s a smart way to do it.
The app is part of a factory workflow, and every time a factory worker starts or ends a new batch, they need to fill out a number of maintenance fields. Sounds straightforward enough - however, my client would like to be able to edit the fields in the app itself - so they need to be dynamic.
I have another part of the app like this for leftover materials, but that’s more straightforward because the fields for the material entries are always the same - text name of material, decimal amount of material.
I handle it by having the materials table “belong” to the batch table, and just generating x rows in leftovers (based on another table called Material Types) related to the batch which can be edited in the batch.
However, the maintenance part is more complicated because the questions could be text, number or yes/no (maybe more things). What I want this to be is a simple table with “Maintenance Item” and “Value”, and the user fills in Value, but the Value is not necessarily always the same type.
One idea I had to get around this was to have three different columns for potential values in the maintenance table and only showing one of them depending on the type, but A) this is going to be an inline table so it will not display properly if I do that, and B) it will probably make something else break later.
Alternatively - is there a way to add/remove/edit COLUMNS themselves from an app? That would be even better, as I wouldn’t have to break up the form with inline tables.