2024年6月15日发(作者:)
jQuery jqGrid中 ColModel 的参数大全(详解带实例 (2012-03-28 10:53:46转载▼
标签: jquery jqgrid colmodel的参数 大全 详解 demo 实例 杂谈 分类: WEB技术
ColModel 是 jqGrid 里最重要的一个属性,设置表格列的属性。
用法:
Java 代码
jQuery("#gridid".jqGrid({
...
colModel: [ {name:'name1', index:'index1'...}, {...}, ... ],
...
};
属性 数据类型 备注 默认值
align string 定义单元格对齐方式;可选值:left, center, right. left
classes string 设置列的 css 。 多个 class 之间用空格分隔, 如:'class1 class2' 。 表
格默认的 css 属性是 ui-ellipsis empty string
datefmt string 对日期列进行格式化。 ” /” , ” -” , and ” . ” 都是有效的日期
分隔符。 y,Y,yyyy 年 YY, yy 月 m,mm for monthsd,dd 日 . ISO Date (Y-m-d
defval string 查询字段的默认值 空
editable boolean 单元格是否可编辑 false
editoptions array 对列进行编辑时设置的一些属性 empty array
editrules array 对于可编辑单元格的一些额外属性设置 empty array
edittype string 可以编辑的类型。 可选值:text, textarea, select,
password, button, image and file. text
fixed boolean 列宽度是否要固定不可变 false
formoptions array 对于 form 进行编辑时的属性设置 empty
formatoptions array 对某些列进行格式化的设置 none
formatter mixed 对列进行格式化时设置的函数名或者类型 none
checkbox,
发布者:admin,转转请注明出处:http://www.yc00.com/web/1718418793a2749548.html
评论列表(0条)