hi
I
have a js function that allows me to format a column grid after a
select from another column in the same grid (column type
dojox.grix.cells.select ") :
function formatterColonne()
{
grid.getCell(4).formatEditing = function(inDatum, inRowIndex)
{
if (widget == "select") {
codeHTML = "<select class=\"dojoxGridSelect\">";
for (var i = 0; i < tab.length; i++) {
codeHTML += "<option value=\""+tab[i]["id"]+"\">"
+tab[i]["valeur"]+"</option>";
}
codeHTML += "</select>";
return codeHTML;
}
}
}
This
function works very well: they change the type of the second column
grid based on the value selected in the first column grid.
eg if I select 'select' the 1st column, the type of the column grid becomes second drop-down list.
but I have a small problem:
I want to display in the grid the values and stored in the database idOption.
thank you in advance
Gratuit : Hotmail plus rapide avec Internet Explorer 8 !
Cliquez ici !