Hi
It seems to be a jQuery problem
If you set
xmlReader : {
root:”m\:return”,
row: “m:\Incident”,
repeatitems: false,
id: “Reference”
}
This will work in IE6, but not in FF.
Do not known what to do for now. I posted the problem to the jQuery group, but not sure if there will be solution. Anyway I will search for solution.
Thank you
Regards
Tony
Sorry
the expression should be:
var rowdata = (“#mygrid”).getDataIDs(rowid);
Hi,
This is just idea.
Add a hidden field in the grid, which holds the number of subgrid rows.
Let’s assume that this is row_cnt_field, then:
subGridRowExpanded : function (div_id,rowid) {
var rowdata = getDataIDs(rowid);
if(rowdata.row_cnt == 0) {
$(“#”+div_id).html(“No records”)
} else {
// construct grid as subgrid here
}
}
Regards
Tony
Andrei,
This is a good idea I will add it to the wish list.
Thank you
Tony
Ashish,
If you use the grid as subgrid this can be easy. The idea is to perform some checking in subGridRowExpanded event – in case of zero records you can add custom display message and do not perform ajax call.
If you use the other way I will think about this. We can use params array to do that.
Regards
Tony
Hi,
Currently jqGrid does not support form checking. You can use one of the available plugins to do that. One direction of this is to add the neccessary class to that field with editoptions and then use onInitializeForm event to add the checking. For more information refer to documentation
Regards
Tony
Will check it and replay to you as soon as possible
Thank you
Tony
Ah,
There is another problem.
Please find a addXmlData function and replace the line:
$(ts.p.xmlReader.root+”>”+ts.p.xmlReader.row,xml).each( function( j ) {
with
$(ts.p.xmlReader.root+” “+ts.p.xmlReader.row,xml).each( function( j ) {
I will correct this in next release
Tony
ЗдраÑтвуй,
Short – In xmlReader you have booth row and cell with the same name – i.e.
Incident.
To work this remove the cell definition – i.e
xmlReader : {
root: “return”,
row: “Incident”,
repeatitems: false,
id: “Reference”
}
This should work
Regards
Tony
See attribute media here:
link rel=”stylesheet” type=”text/css” media=”screen” title=”basic” href=”themes/basic/grid.css”
If you remove this attribute all should work
regards
Tony
Use code tags – See Some XHTML is allowed:
at bottom when you post
Hi the working code should be:
$(“#list2”).setGridParam({
page:1,
search:true,
searchdata : {
searchString:obj.options[obj.selectedIndex].value,
searchOper:”cn”,
searchField:”NO_SAL_ATB”
}
}).trigger(“reloadGrid”);
Regards
Tony
1. Error handling on request will be added in next release.
2. Toolbar is implemented in ver 3.1. See examples
3. Loading animation – there will be option in next release to disable this
4. UI Calender is just example. The animation in Calendar can be disabled – for more information see documentation for the UI Calendar.
5. You can add what you want after every editable field – button, image and etc. – just see the examples in detail
Kind Regards
Tony
Hi Patrick,
IMHO You have two possible solutions.
You have a special case here. What is happen?
You have xml string that is loaded into the grid. After that the datatype is set to clientSide automatically from the grid. Between the interval the user click to sort some column. The data is sorted in appropriate way (do not forget to set sorttype in colModel when the data is clientSide). The new sort parameters are saved in the options. There is another request (after some time) that is not sended from the grid. The expected data should be sorted in the new way, but this is not true since this is a request from other place.
So the solutions.
1. You should become the xml string already sorted – you can pass two parameters to the “external” request sortname and sortorder. These can be obtained with getGridParam method. If this is not possible
2. You should make second reloading of the grid to sort the data in appropriate way. This can be easy done with the flowing trick.
Use loadComplete event. In case of xmlstring or jsonstring this callback is executed after the data is loaded. The code should be something like:
$("#mygrid").jqGrid( {
...
loadComplete: function () {
if ( the sort order or name is changed ) {
$("#mygrid").trigger("reloadGrid");
}
},
...
});
Regards
Tony
Something like Excel 🙂 . Will think about this instead.
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top