【发布时间】:2018-11-11 12:31:25
【问题描述】:
我有 2 个图标需要显示在单元格属性标题中,如下图所示, 点击图标需要执行一些操作。
设计:enter image description here
我试过了:
colModel: [
//{name: 'id', index: 'id', width: 65, align: 'center', sorttype: 'int'},
{name: 'invdate', index: 'invdate', width: 80, align: 'center', sorttype: 'date',
formatter: 'date', formatoptions: {newformat: 'd-M-Y', reformatAfterEdit: true}, datefmt: 'd-M-Y'},
{name: 'name', index: 'name', width: 70,
cellattr: function (rowId, val, rawObject, cm, rdata) {
return 'title="<i class = fa fa-edit></i>"';
}}
]
在单元格悬停时没有获得字体真棒图标,而不是获得<i class = fa fa-edit></i>
虚拟显影屏幕: enter image description here
使用 bootstrap 3.3.7 和 font awesome 4.7 和 Jquery UI css
如何添加图标..?
【问题讨论】:
-
你是否已经包含了所有需要的 css 和 js 文件,这些文件负责使字体真棒运行?
-
是的。 cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/…" />
标签: javascript html jqgrid javascript-objects jqgrid-formatter