You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
130 KiB
14 lines
130 KiB
2 years ago
|
using Magic.Core;
|
||
|
using Magic.Core.Entity;
|
||
|
|
||
|
namespace Magic.CodeFirst;
|
||
|
|
||
|
public class SysMenuSeedData : ISeedData , ISqlSugarEntitySeedData<SysMenu>
|
||
|
{ public IEnumerable<SysMenu> HasData()
|
||
|
{ string json = @"[{""Pid"":0,""Pids"":""[0],"",""Name"":""组织架构"",""Code"":""sys_mgr"",""Type"":0,""Icon"":""team"",""Router"":""/sys"",""Component"":""PageView"",""Permission"":null,""Application"":""manage"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""Redirect"":null,""Weight"":1,""Sort"":100,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307000914633},{""Pid"":0,""Pids"":""[0],"",""Name"":""主控面板"",""Code"":""system_index"",""Type"":0,""Icon"":""home"",""Router"":""/"",""Component"":""RouteView"",""Permission"":null,""Application"":""busiapp"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""Redirect"":""/analysis"",""Weight"":1,""Sort"":1,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307070910560},{""Pid"":142307070910560,""Pids"":""[0],[142307070910560],"",""Name"":""分析页"",""Code"":""system_index_dashboard"",""Type"":1,""Icon"":null,""Router"":""analysis"",""Component"":""system/dashboard/Analysis"",""Permission"":null,""Application"":""busiapp"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""Redirect"":null,""Weight"":1,""Sort"":100,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307070910561},{""Pid"":142307070910560,""Pids"":""[0],[142307070910560],"",""Name"":""工作台"",""Code"":""system_index_workplace"",""Type"":1,""Icon"":null,""Router"":""workplace"",""Component"":""system/dashboard/Workplace"",""Permission"":null,""Application"":""busiapp"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""Redirect"":null,""Weight"":1,""Sort"":100,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307070910562},{""Pid"":0,""Pids"":""[0],"",""Name"":""权限管理"",""Code"":""auth_manager"",""Type"":0,""Icon"":""safety-certificate"",""Router"":""/auth"",""Component"":""PageView"",""Permission"":null,""Application"":""manage"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""Redirect"":null,""Weight"":1,""Sort"":100,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307070910563},{""Pid"":142307070910563,""Pids"":""[0],[142307070910563],"",""Name"":""用户管理"",""Code"":""sys_user_mgr"",""Type"":1,""Icon"":null,""Router"":""/mgr_user"",""Component"":""system/user/index"",""Permission"":null,""Application"":""manage"",""OpenType"":1,""Visible"":""Y"",""Link"":null,""Redirect"":null,""Weight"":1,""Sort"":100,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307070910564},{""Pid"":142307070910564,""Pids"":""[0],[142307070910563],[142307070910564],"",""Name"":""用户查询"",""Code"":""sys_user_mgr_page"",""Type"":2,""Icon"":null,""Router"":null,""Component"":null,""Permission"":""sysUser:page"",""Application"":""manage"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""Redirect"":null,""Weight"":1,""Sort"":100,""Remark"":null,""Status"":0,""CreatedTime"":null,""UpdatedTime"":null,""CreatedUserId"":null,""CreatedUserName"":null,""UpdatedUserId"":null,""UpdatedUserName"":null,""IsDeleted"":false,""Id"":142307070910565},{""Pid"":142307070910564,""Pids"":""[0],[142307070910563],[142307070910564],"",""Name"":""用户编辑"",""Code"":""sys_user_mgr_edit"",""Type"":2,""Icon"":null,""Router"":null,""Component"":null,""Permission"":""sysUser:edit"",""Application"":""manage"",""OpenType"":0,""Visible"":""Y"",""Link"":null,""
|
||
|
";
|
||
|
List<SysMenu> list = JsonUtil.ToObject<List<SysMenu>>(json);
|
||
|
|
||
|
return list;
|
||
|
}}
|