afterSaveToRepository

Arguments

eobject

An object with the following properties:

hasErrorsboolean

A true or false value. If true, the component data was saved successfully without issue. If false, the component data could not be saved.

Description

Fires after the data in the component has been saved to the Repository

Discussion

The afterSaveToRepository event is triggered when the component data has been saved to the application repository using the {dialog.object}.saveDataInRepository() method. This event can be used to check if the data was successfully saved as well as execute other logic to perform additional tasks after the component data has been saved to the repository.

var btn = {dialog.object}.getPointer("SAVE_BTN");

if (e.hasErrors) {
    // Notify user their settings could not be saved
    {dialog.object}.runAction("SettingsNotSavedNotice",btn);
} else {
    // Notify user their settings were saved
    {dialog.object}.runAction("SettingsSavedNotice",btn);
}

See Also