ParamQuery grid support forum
General Category => Help for ParamQuery Pro => Topic started by: noctrona on April 25, 2014, 01:21:00 pm
-
Hi,
I have a column use "type: 'select'" to generate a picklist. But as I used, if I choose a value in this picklist and save this value on cell, then I open picklist again, the value which I save didn't be choose, the first value in the picklist will be choose.
I check some demo which used picklist have this problem too.
This is my column:
{ title: "Product", dataIndx: "product",width: 130,
editor: {
type: "select", options: productArray,style: 'width:230px;'
},
render: function (ui) {
return (ui.cellData.split(':')[0])
}
}
And this is my pick list source:
var productArray = [];
for(var i = 0; i < productList.length; i++ ){
var idVals = productList[i].Name+'-'+ productList[i].Description + ':' + productList[i].Id;
var nameVal = productList[i].Name+'-'+productList[i].Description;
var obj = {}; //create an empty object
obj[idVals] = nameVal; //create a new property with a dynamic key and assign to value.
productArray.push(obj); //push onto the productArray
}
So do we have solution to handle this problem? When open the picklist the current value will be choose as highlight not the first picklist value.
Thank you!
-
The selected value is highlighted in the select list, but not the first one.
Please refer to this demo:
http://paramquery.com/pro/demos/editing_custom
-
The selected value is highlighted in the select list, but not the first one.
Please refer to this demo:
http://paramquery.com/pro/demos/editing_custom
Hi,
I post a reply but looks like didn't pass approved.
I check the pick list function in this demo. I choose a book from book pick list and save this cell. Then when I double click this cell the book name which I selected will display on the pick list but only this value, other parts in the pick list didn't display.
Do we have solution can show the whole pick list and highlight the selected value too?
Thank you!
-
Noctrona
Book column which you referred to in your new post is not a select list but it is jQueryUI autocomplete. It is answered here http://paramquery.com/forum/index.php?topic=626.0