TNT blog |
|
|||
日歷
統(tǒng)計(jì)
導(dǎo)航常用鏈接留言簿(2)隨筆分類隨筆檔案文章分類
文章檔案
收藏夾home搜索最新隨筆最新評(píng)論
閱讀排行榜 |
DWRUtil.addOptions('coRegulateurList_tbody', TermList, {
creatorFunction: function(oneTerm) { var oneOption = new Option(oneTerm.terminalId+(oneTerm.terminalActive?" Active": ""), oneTerm.terminalId); oneOption.id='term_'+oneTerm.terminalId; oneOption.selected=oneTerm.terminalSelected; } }); But why the hell use DWRUtil, I'm doing all the work :op Some maybe like this it would be smarter : DWRUtil.addOptions( 'coRegulateurList_tbody', TermList, { idFunction: function(oneTerm) { return 'term_' +oneTerm.terminalId; }, selectedFunction:function(oneTerm) { return oneTerm.terminalSelected; }, textFunction:function(oneTerm) { return oneTerm.terminalId+(oneTerm.terminalActive?" Active" :""); } });
|
![]() |
|
Copyright © TNT | Powered by: 博客園 模板提供:滬江博客 |