isDirty

checks whether changes were made within the form

boolean isDirty();
booleanreturns true if the data was changed

Example

if(form.isDirty()){
    if(!form.validate())
        return false;
    form.save();
};

Related samples

Details

With form, the method is used before data validation and saving it to the component and server.

See also
Back to top