mirror of https://gitee.com/y_project/RuoYi.git
新增表格参数(通过自定义函数设置页脚样式footerStyle)
parent
ae7c436730
commit
947120d136
|
@ -130,6 +130,7 @@ var table = {
|
|||
onReorderRow: options.onReorderRow, // 当拖拽结束后处理函数
|
||||
queryParams: options.queryParams, // 传递参数(*)
|
||||
rowStyle: options.rowStyle, // 通过自定义函数设置行样式
|
||||
footerStyle: options.footerStyle, // 通过自定义函数设置页脚样式
|
||||
columns: options.columns, // 显示列信息(*)
|
||||
data: options.data, // 被加载的数据
|
||||
responseHandler: $.table.responseHandler, // 在加载服务器发送来的数据之前处理函数
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
showRefresh: false,
|
||||
showToggle: false,
|
||||
showColumns: false,
|
||||
footerStyle: footerStyle,
|
||||
columns: [{
|
||||
checkbox: true
|
||||
},
|
||||
|
@ -78,6 +79,17 @@
|
|||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
|
||||
function footerStyle(column) {
|
||||
return {
|
||||
// userBalance: {
|
||||
// classes: 'class'
|
||||
// },
|
||||
userBalance: {
|
||||
css: { color: 'red', 'font-weight': 'normal' }
|
||||
}
|
||||
}[column.field]
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in New Issue