|
@@ -7,7 +7,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
|
|
|
extend: {
|
|
|
index_url: 'appcomment/index' + location.search,
|
|
|
add_url: 'appcomment/add',
|
|
|
- edit_url: 'appcomment/edit',
|
|
|
+// edit_url: 'appcomment/edit',
|
|
|
del_url: 'appcomment/del',
|
|
|
multi_url: 'appcomment/multi',
|
|
|
import_url: 'appcomment/import',
|
|
@@ -36,7 +36,22 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
|
|
|
{field: 'auditremark', title: __('Auditremark'), operate: 'LIKE'},
|
|
|
{field: 'user.username', title: __('User.username'), operate: 'LIKE'},
|
|
|
{field: 'user.nickname', title: __('User.nickname'), operate: 'LIKE'},
|
|
|
- {field: 'operate', title: __('Operate'), table: table, events: Table.api.events.operate, formatter: Table.api.formatter.operate}
|
|
|
+ {field: 'operate', title: __('Operate'), table: table,
|
|
|
+ buttons:[
|
|
|
+ {
|
|
|
+ name:'audit',
|
|
|
+ text:'审核',
|
|
|
+ title:'审核',
|
|
|
+ icon:'fa fa-exclamation-circle',
|
|
|
+ classname:'btn btn-xs btn-info btn-dialog',
|
|
|
+ url:'appcomment/audit/id/{ids}?dialog=1',
|
|
|
+ target:'_self',
|
|
|
+ hidden:function($row){
|
|
|
+ return $row.status == 0 ? false : true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ],
|
|
|
+ events: Table.api.events.operate, formatter: Table.api.formatter.operate}
|
|
|
]
|
|
|
]
|
|
|
});
|
|
@@ -44,6 +59,9 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
|
|
|
// 为表格绑定事件
|
|
|
Table.api.bindevent(table);
|
|
|
},
|
|
|
+ audit: function () {
|
|
|
+ Controller.api.bindevent();
|
|
|
+ },
|
|
|
add: function () {
|
|
|
Controller.api.bindevent();
|
|
|
},
|