I’ve almost finished making an App from of a Google spreadsheet to ‘track’ materials over time (location, amount, ‘owner’ etc).
The main Sheet contains unique rows of each material, with many characteristics, one of which is the ‘amount (X)’. It is simple to do things like ‘move material to new location’ (from dependent dropdown) or ‘duplicate the material’ (row) and assign it a new unique ID via Actions and save it in the Sheet.
What is not so easy for me to grasp is making a new action to separate the material into a ‘parent row’ (i.e. the one copied from), and a ‘new copied row’ where the amount of material in the ‘parent row’ is less the amount in the ‘new copied row’ on saving (or some other event)
The amount in the ‘new copied row’ should be validated to be less than the ‘parent row’, or perhaps from another view/workflow? I would also contemplate using a sheet formula to do the math if there was a way to track which rows were affected and pass that to the event structure (e) in google sheets (though probably not possible in the current API).
Any advice/pointers are appreciate!