Waiting urgently for you quick reply.
How to stop validation on click on Grid Cancel button
<div class="securityAccessGrid" ma-security-grid-sorting ma-grid-button-disable>
<div ng-init="getListofAccessGroup()" id="securityGrid" e-scrollsettings-width="null"
ej-grid e-datasource="data"
e-columns="columns" class="gridStyle"
e-allowresizing="true" e-allowkeyboardnavigation="true" e-allowscrolling="true" e-allowsorting="true" e-toolbarsettings-showtoolbar="true" e-toolbarsettings-toolbaritems="tools" e-editsettings-allowediting="true" e-editsettings-allowadding="true" e-editsettings-allowdeleting="true" e-minwidth="550" e-isresponsive="true" e-scrollsettings-height="{{maximumGridHeight}}" e-actioncomplete="actioncomplete" e-rowselected="rowselected"
e-actionbegin="deleteConfirmation" e-beginedit="beginEdit"></div>
</div>
$scope.columns = [
{ field: "markingId", isPrimaryKey: true, visible: false },
{ field: "markingString", headerText: administrationSecurityResources.securityGroupName, validationRules: { securityMarking: [], required: true } }
];
$.validator.addMethod("securityMarking", function (value, element, params) {
securityAccessGroup = value;
var errrorMessage;
if (value.charAt(0) === whiteSpace || value.charAt(0) == "-" || value.charAt(0) == "_" || value.charAt(0) == "," || value.charAt(0) == ";" || value.charAt(0)==":") {
setFocus(element);
errrorMessage = administrationSecurityResources.whiteSpaceError;
setErrorForSecurity(errrorMessage);
$rootScope.$broadcast("setSaveDisable", "securityGrid");
return false;
}
if (element.value.trim().length > maxAcceGroupCharacter) {
setFocus(element);
errrorMessage = administrationSecurityResources.accessGroupMaxLength;
setErrorForSecurity(errrorMessage);
$rootScope.$broadcast("setSaveDisable", "securityGrid");
return false;
}
if (!checkUniqness()) {
setFocus(element);
$rootScope.$broadcast("setSaveDisable", "securityGrid");
return false;
}
$rootScope.$broadcast("setSaveEnable", "securityGrid");
return true;
}, errorMessage);
When I click on cancel button validation Fires
How to stop validation on click on cancel button