EasuUI-js(EasyUI formatter格式化教程) 判断常用:
2024-08-24 17:25:00
EasuUI-js(EasyUI formatter格式化教程) 判断常用:
1.YN标记:
formatter : function(c1, row,index) {
var a = "";
if(c1 == "Y"){
a = a + "<div style = \"background-color:00FF\"> 正确</div>";
}else if(c2 == "N"){
a = a + "<div style = \"background-color:FF0000\"> 错误</div>";
}else{
a;
}
return a;
}
2.NULL和非NULL判断 并且悬浮显示单元格内容:
//判断是否为空,若不为空显示答案并且鼠标悬浮显示
formatter : function(value, row, index) {
var a = "";
if(value == null){
}else{
return "" + value + "";
}
}
}
3.通过与不通过判断
formatter : function(value, row, index) {
var a = "";
if(value == "A"){
a = a + "<div style="background-color:#ff0" >申请中
最新文章
- 第三天--html表格
- 《Ext JS模板与组件基本知识框架图----模板》
- MYSQL临时表创建索引
- SQL 查询总结
- Just a Hook(HDU1698 线段树的简单应用)
- [ActionScript 3.0] NetConnection建立客户端与服务器的双向连接
- Visual Studio 继续并运行上次的成功生成,未提示直接运行上一个版本解决方案!
- Linux编译多个不同目录下的文件以及静态库、动态库的使用
- express框架+jade+bootstrap+mysql开发用户注册登录项目
- ssh: Could not resolve hostname git.*****-inc.com : Temporary failure in name resolution fatal: The remote end hung up unexpectedly
- BZOJ3687: 简单题(dp+bitset)
- DES算法,JAVA,遇到的问题
- Aladdin and the Flying Carpet
- postman环境变量的设置
- Objective C, erum 枚举类型
- 二叉堆的实现(数组)——c++
- SpringMVC札集(04)——SpringMVC传递参数
- SAP CRM One Order跟踪和日志工具CRMD_TRACE_SET
- Java 匿名内部类 只能访问final变量的原因
- Django实现微信公众号简单自动回复
热门文章
- Frameset框架集的应用
- 用户代理字符串(navigator.userAgent)检测方法
- jsp注册页面的省份联动(网上copy别人的,然后自己弄了一下才知道怎么用)
- python中函数的定义,调用,全局变量,局部变量,函数的嵌套使用-初级篇
- JavaScript中判断鼠标按键(event.button)
- async 函数
- Java8学习(3)- Lambda 表达式
- GitHub转华为软件开发云详细教程
- 【javascript】变量作用范围
- 31. leetcode 122. Best Time to Buy and Sell Stock II