jQuery UI Widgets › Forums › Grid › Validation issue in Grid
This topic contains 2 replies, has 1 voice, and was last updated by Keshavan 12 years, 1 month ago.
-
AuthorValidation issue in Grid Posts
-
Hi,
I have a Grid with Popup edit, i have issue while clicking ‘Save’ (in my popup edit) when calling ‘validationSuccess’ method,
in ‘Save’ , even when the validation passes test, there is ‘no action ‘ when save is clicked, the popup remains as is.If i comment the line – $(‘#jqxValidator’).on(‘validationSuccess’, function (event)
inside ‘Save’, the code works when save is clicked.
i have pasted relevant code below,
$('#testForm').jqxValidator({ hintType: 'label', animationDuration: 0, rules: [ { input: '#companyName', message: 'CompanyName is required!', action: 'keyup, blur', rule: 'required' }, { input: '#companyName', message: 'Company Name must be between 20 and 50 characters!', action: 'keyup, blur', rule: 'length=20,50'} ] }); $("#Save").click(function () { $('#testForm').jqxValidator('validate'); $('#jqxValidator').on('validationSuccess', function (event) { if (editrow >= 0) { row = { CompId: $("#compId").val(), CompanyName: $("#companyName").val(), AddressLine1: $("#addressLine1").val(), AddressLine2: $("#addressLine2").val(), City: $("#city").val(), ZipCode: $("#zipCode").val(), CompanyEmail: $("companyEmail").val(), AuthorizedSignatory: $("#authorizedSignatory").val(), AdminPhone: $("#adminPhone").val(), AdminMobile: $("#adminMobile").val(), AdminEmail: $("#adminEmail").val(), Lattitude: $("#lattitude").val(), Longitude: $("#longitude").val() }; var rowID = $('#jqxgrid').jqxGrid('getrowid', editrow); $('#jqxgrid').jqxGrid('updaterow', rowID, row); $("#popupWindow").jqxWindow('hide'); } }); });
Hi,
The version is – jQWidgets v2.7.0 Release, Feb-08-2013.
Thanks,
Keshavan
Hi,
Don’t bother , i solved the issue, issue closed.
Thanks,
Keshavan
-
AuthorPosts
You must be logged in to reply to this topic.