MVC5+Easyui1.3.6+EF6 开发部分备忘笔记

一点一点增加,后面继续。

1、Row Editing in DataGrid 编辑,总是绑定不了checkbox的问题

Status第一次的状态,如果是true, 无论如果都绑定不了checkbox,意思是checkbox的勾一直没有打上,手点之后,下一次编辑,就可以打上了。通过firebug,查看到原因:

如果返回的Json是{"productid":"FI-SW-01","productname":"Koi","unitcost":10.00,"status":true,"listprice":36.50,"attr1":"Large","itemid":"EST-1"},这种格式,就是"status":true,则不会自动打上勾。要改为:"status":"true" 这种格式,字符串的格式。

或者,将改editor:{type:'checkbox',options:{on: 1,off: 0}}为0,1表示。

原文地址:https://www.cnblogs.com/jys509/p/3808777.html