@Eslam_Mohamed
I’m afraid I’m not quite following what you are looking to achieve but if you are wanting to duplicate the Approve rest-erp call then you could have a look at the ColumnChanging_Approve event:
@Eslam_Mohamed
OK, I understand now the reason you are getting POHeader not found is because the POHeader will not be dirty on an onClick event, as nothing has changed.
However, I think there might be an issue within Application studio as it should be showing “dirtyRows”: POHeader within the properties (it was blank).
Could you try adding POHeader to this property see whether it makes a difference?
@Eslam_Mohamed Ok, I think that property is non functional I have raised an issue with the team to review as it should be an array object supporting multiple views / conditions.
However, what you might have to do for your scenario is perform another event before the rest-erp event which performs a row-update on POHeader.RowMod and set the column to ‘U’, so that the POHeader row becomes dirty.