1、效果图
2、核心js代码
{field: 'new_name', title:'资质名称|证书号|发证日期|有效期', operate: 'LIKE',
formatter : function(value, row, index, field){
if(row.new_name){
return row.new_name.replace(/,/g,'<br>')
}else{
return '-';
}
},
cellStyle : function(value, row, index, field){
return {
css: {
"white-space": "nowrap",//单行省略必备
"text-overflow": "ellipsis",//单行省略必备
"overflow": "hidden",//单行省略必备
"text-align": "left",
"color": "#7536d0",
"display":"block",
}
};
}
},
3、数据库
数据库表字段为英文字符“,”隔开的字符串, operate: 'LIKE',则支持模糊搜索