Function: hasPendingChanges()
hasPendingChanges(
page,options?):Promise<boolean>
Defined in: src/modules/odata.ts:500
Ai
Checks whether the UI5 OData model has unsaved (pending) changes.
Parameters
page
ODataPage
Playwright Page (or compatible subset).
options?
OData options (modelName).
Returns
Promise<boolean>
true if the model has pending changes, false otherwise.
Intent
Check if the OData model has unsaved changes (dirty state).
Ai Context
Calls model.hasPendingChanges(). Useful to verify before navigating away or to assert that edits have been properly saved.
Sap Module
sap.ui.model.odata.v2.ODataModel, sap.ui.model.odata.v4.ODataModel
Business Context
Detect unsaved changes before navigation to prevent data loss warnings.
Example
const dirty = await hasPendingChanges(page);
if (dirty) {
logger.warn('Model has unsaved changes');
}