The auto refresh is handled based on refresh schemes.
Example of a Refresh Scheme
{ "Tables": "", // table name or comma separated list of multiple tables names "AddRepositionTo": '#NewRecord', // default reposition to newly created record (other options: #KeepSelection, #NextRow) "UpdateRepositionTo":'#KeepSelection', // default keeps selection of the selected record (other options: #NextRow) "RemoveRepositionTo": '#NextRow' // default reposition to next available record using #NextRow }
Above is the default Scheme, the refresh will add the BEs own entityTable by default and you can add multiple Tables in the refreshScheme.Tables.
The reposition options are default values (you are not required to define them if you need to add more tables to the refresh).
You can also change the handling on Add event, for eg. to reposition to the currently selected record, by changing the AddRepositionTo: '#KeepSelection'.
For a delete refresh you can call the RefreshEmitter as follows:
akioma.RefreshEmitter.refreshData('eTerm*', { lastRowState: 'delete' }) // This will select the next available record
For an update refresh you can call the RefreshEmitter as follows:
akioma.RefreshEmitter.refreshData('eTerm*', { lastRowState: 'update' })
For an add refresh developer can call the RefreshEmitter
akioma.RefreshEmitter.refreshData('eTerm*', { lastRowState: 'add', lastUpdatedRecord: { selfhdl: 'A69:111:000008101398'} })