1.同时声明多个变量
1 var oType, checkConfig, diffValue; 2 oType = that.uiStore.cmbObjectType.getValue();
2.获取编辑行信息
1.传递Index参数
align: 'center', formatter: function (value, row, index) { return "<a class='link' onclick='modObj.editJudgeConfig("" + index + "");'>编辑</a>" }
2.获取index参数
1 editJudgeConfig: function(index){ 2 var that = modObj; 3 var title = "编辑检查条件"; 4 //设置要传递的数据 5 xUI.dialog.setParam({ 6 nodeID: that.dataStore.nodeID, 7 modelID: that.dataStore.modelID, 8 checkData: that.uiStore.gvList.getData().rows[index] 9 }); 10 //显示编辑窗体 11 xUI.dialog.open('CheckEdit.html', title, 400, 300); 12 },
3.a? b : c使用
1 align: 'center', formatter: function (value, row, index) { 2 return ( value == 'PKG') ? "存储过程" : "表达式"; 3 }