refactor: 根据最新脚本设置IsResource显示名称

This commit is contained in:
Argo Zhang 2019-07-18 14:33:57 +08:00
parent 7388a54f20
commit 0ba1bcd726
No known key found for this signature in database
GPG Key ID: 152E398953DDF19F
1 changed files with 2 additions and 4 deletions

View File

@ -22,6 +22,7 @@ $(function () {
};
var state = [];
var menuResource = ['菜单', '资源', '按钮'];
var $table = $('table');
$table.lgbTable({
url: Menu.url,
@ -127,10 +128,7 @@ $(function () {
},
{
title: "菜单类型", field: "IsResource", sortable: true, formatter: function (value, row, index) {
var ret = "菜单";
if (value === "1") ret = "资源";
else if (value === "2") ret = "按钮";
return ret;
return menuResource[value];
}
},
{