一、案例效果
针对一个功能做数据已读未读的标识二、实现思路
1.勾选功能配置中“启用修改标记”配置项
2.注册需标记字段的列内容格式化事件(renderer),编写代码,例如用案例编号作为标记字段
三、操作步骤 1. 勾选功能配置中“启用修改标记”配置项 2.注册需标记字段的列内容格式化事件(renderer),编写代码,例如用案例编号作为标记字段 四、相关代码- function(value,metaData,record,rowIndex,colIndex,store,view){
- var grid = this,
- column = grid.columnManager.getHeaderAtIndex(colIndex);//当前列
- //找到编辑列
- var funcedit = record.get("SY_FUNCEDIT");
- //如果编辑列状态为0,则是未读否则是已读
- if(funcedit=='0'){
- return '<div style="width: 10px;height: 10px;background: #b0adad;border-radius: 100%;display:inline-block;margin-right:5px;"></div>'+value;
- }else{
- return '<div style="width: 10px;height: 10px;background: red;border-radius: 100%;display:inline-block;margin-right:5px;"></div>'+value;
- }
- }
复制代码
五、关键字,相关问题
已读未读
列表数据
|