Ext1 Grid Panel Insert Record Issue
I am using Ext1 controls and visual studio 2015. I had a grid which was working fine before applying grouping. I have an "Add" button to insert a new record in grid. before applying "GroupField" property of store, the insert code was working fine but after applying grouping, it inserts a record but also displays following prompt:
Quote:
You have uncommitted changes. Are you sure you want to reload data?
store code:
Code:
<ext:Store
ID="dsObjectives"
IDMode="Explicit"
AutoLoad="false"
runat="server"
RemoteSort="true"
UseIdConfirmation="true" GroupField="ObjectiveTypeDesc">
script code to insert a record:
Code:
var InsertNewRecord = function(){
var pos;
pos = #{grdObjectives}.insertRecord(0,{});
//pos = #{grdObjectives}.addRecord({});
#{grdObjectives}.getView().focusRow(pos);
#{grdObjectives}.getRowEditor().startEditing(pos);
#{CmbObjectives}.setDisabled(false);
}
i also tried to use "addRecord()" but issue remains same. Further, i also tried
Quote:
WarningOnDirty="false"
it prevents the prompt but gives errory
HTML Code:
The parameters dictionary contains a null entry for parameter 'limit' of non-nullable type 'System.Int32' for method 'Ext.Net.MVC.AjaxStoreResult GetObjectiveAppraisalDet(System.String, Int32, Int32, System.String, System.String)' in 'SmartHCM.Controllers.HrsController'. An optional parameter must be a reference type, a nullable type, or be declared as an optional parameter.
Rest works fine, it also inserts a record and when I give some data in that record it also reflects in database. I guess the grid is reloading the data and submitting null values to function. any idea?
just changed a propert and it is working now
i just removed this property of store and it is working now, need further testing but for the time, it is working: