import { resultSuccess } from '../_util';

const info = {
  userId: 10026,
  username: 'bj',
  realName: 'bj',
  avatar: '',
  desc: '',
  password: '',
  token: '2d255659-ff5d-4d66-b856-385702672c21',
  roleType: '10',
  permissions: [
    {
      label: '系统管理',
      value: 'system',
      url: null,
      menuType: 0,
      routeUrl: '/system',
      routeName: 'system',
    },
    {
      label: '用户管理',
      value: 'system_user',
      url: 'user',
      menuType: 1,
      routeUrl: 'user',
      routeName: 'system_user',
    },
    {
      label: '菜单管理',
      value: 'system_menu',
      url: 'menu',
      menuType: 1,
      routeUrl: 'menu',
      routeName: 'system_menu',
    },
    {
      label: '角色管理',
      value: 'role:list',
      url: 'role',
      menuType: 1,
      routeUrl: 'role',
      routeName: 'system_role',
    },
    {
      label: '字典管理',
      value: 'dict',
      url: 'dictionary',
      menuType: 1,
      routeUrl: 'dictionary',
      routeName: 'system_dictionary',
    },
    {
      label: '文章管理',
      value: 'article',
      url: '/api/article/list',
      menuType: 0,
      routeUrl: '/article',
      routeName: 'System_Article',
    },
    {
      label: '日志管理',
      value: 'system_logs',
      url: 'logs',
      menuType: 0,
      routeUrl: 'logs',
      routeName: 'system_logs',
    },
    {
      label: '区域管理',
      value: 'region:list',
      url: '/api/region/list',
      menuType: 0,
      routeUrl: 'region',
      routeName: 'system_region',
    },
    {
      label: '配置管理',
      value: 'sysconfig:list',
      url: '/api/sysconfig/list',
      menuType: 0,
      routeUrl: 'config',
      routeName: 'system_config',
    },
    {
      label: '组织管理',
      value: 'sysdept:list',
      url: '/api/dept/list',
      menuType: 1,
      routeUrl: 'dept',
      routeName: 'dept',
    },
    {
      label: '站内通知',
      value: 'sysnotice',
      url: '/api/notice/list',
      menuType: 0,
      routeUrl: '/instation',
      routeName: 'instation',
    },
    {
      label: '添加文章',
      value: 'article:add',
      url: '/api/article/add',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '编辑文章',
      value: 'article:update',
      url: '/api/article/update',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '删除文章',
      value: 'article:delete',
      url: '/api/article/delete',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '查看文章',
      value: 'article:view',
      url: '/api/article/info',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '添加菜单',
      value: 'menu:add',
      url: '/api/menu/add',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '编辑菜单',
      value: 'menu:update',
      url: '/api/menu/update',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '删除菜单',
      value: 'menu:delete',
      url: '/api/menu/delete',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '查看菜单',
      value: 'menu:view',
      url: '/api/menu/info',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '日志列表',
      value: 'log:list',
      url: '/api/log/list',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '字典列表',
      value: 'dict:list',
      url: '/api/dict/listDictType',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '添加字典',
      value: 'dict:add',
      url: '/api/dict/addDictType',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '编辑字典',
      value: 'dict:update',
      url: '/api/dict/updateDictType',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '删除字典',
      value: 'dict:delete',
      url: '/api/dict',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '查看字典',
      value: 'dict:view',
      url: '/api/dict/dictTypeInfo',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '用户列表',
      value: 'user:list',
      url: '/api/user/list',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '添加用户',
      value: 'user:add',
      url: '/api/user/add',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '编辑用户',
      value: 'user:update',
      url: '/api/user/update',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '删除用户',
      value: 'user:del',
      url: '/api/user/delete',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '查看用户',
      value: 'user:view',
      url: '/api/user/info',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '角色列表',
      value: 'role:list',
      url: '/api/role/list',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '添加角色',
      value: 'role:add',
      url: '/api/role/add',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '编辑角色',
      value: 'role:update',
      url: '/api/role/update',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '删除角色',
      value: 'role:delete',
      url: '/api/role/delete',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: '查看角色',
      value: 'role:view',
      url: '/api/role/info',
      menuType: 2,
      routeUrl: '',
      routeName: null,
    },
    {
      label: 'Dashboard',
      value: '',
      url: '',
      menuType: 0,
      routeUrl: '/dashboard',
      routeName: 'dashboard',
    },
    {
      label: '主控台',
      value: 'dashboard_console',
      url: 'console',
      menuType: 1,
      routeUrl: 'console',
      routeName: 'dashboard_console',
    },
    {
      label: '区域新增',
      value: 'region:add',
      url: '/api/region/add',
      menuType: 2,
      routeUrl: null,
      routeName: null,
    },
    {
      label: '区域修改',
      value: 'region:update',
      url: '/api/region/update',
      menuType: 2,
      routeUrl: null,
      routeName: null,
    },
    {
      label: '区域删除',
      value: 'region:delete',
      url: '/api/region/delete',
      menuType: 2,
      routeUrl: null,
      routeName: null,
    },
    {
      label: '区域查看',
      value: 'region:view',
      url: '/api/region/view',
      menuType: 2,
      routeUrl: null,
      routeName: null,
    },
    {
      label: '添加配置',
      value: 'sysconfig:add',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '编辑配置',
      value: 'sysconfig:update',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '删除配置',
      value: 'sysconfig:delete',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '配置查看',
      value: 'sysconfig:view',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '公共权限',
      value: '',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '上传图片',
      value: 'common:upload',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '添加部门',
      value: 'sysdept:add',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '编辑部门',
      value: 'sysdept:update',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '删除部门',
      value: 'sysdept:delete',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '部门查看',
      value: 'sysdept:view',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '添加通知',
      value: 'sysnotice:add',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '编辑通知',
      value: 'sysnotice:update',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '删除通知',
      value: 'sysnotice:delete',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '查看通知（按钮）',
      value: 'sysnotice:view',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '权限管理',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: '/auth',
      routeName: 'auth',
    },
    {
      label: '通知管理',
      value: 'sysnotice:list',
      url: null,
      menuType: 1,
      routeUrl: 'notice',
      routeName: 'instation_notice',
    },
    {
      label: '租户管理',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'tenant',
      routeName: 'system_tenant',
    },
    {
      label: '租户列表',
      value: 'systenant:list',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '添加租户',
      value: 'systenant:add',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '编辑租户',
      value: 'systenant:update',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '删除租户',
      value: 'systenant:delete',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '查看租户',
      value: 'systenant:view',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '强退用户',
      value: 'user:logout',
      url: null,
      menuType: 2,
      routeUrl: '',
      routeName: '',
    },
    {
      label: '相机管理',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: '/cameras',
      routeName: 'cameras',
    },
    {
      label: '相机配置',
      value: 'camera_overview',
      url: null,
      menuType: 1,
      routeUrl: 'overview',
      routeName: 'camera_overview',
    },
    {
      label: '系统设置',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: 'system-config',
      routeName: 'system-config',
    },
    {
      label: '场景布局',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'scene-layout',
      routeName: 'scene-layout',
    },
    {
      label: '模板管理',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'template',
      routeName: 'system-config/template',
    },
    {
      label: '算法管理',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'algo-manager',
      routeName: 'algo-manager',
    },
    {
      label: '相机预览',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: 'preview',
      routeName: 'cameras/preview',
    },
    {
      label: '场景管理',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: 'scene-manage',
      routeName: 'scene-manage',
    },
    {
      label: '主页配置',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: '/page-config',
      routeName: 'page-config',
    },
    {
      label: '主页布局',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'layout',
      routeName: 'page-layout',
    },
    {
      label: '地图布局',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'layout',
      routeName: 'map-layout',
    },
    {
      label: '地图配置',
      value: '',
      url: null,
      menuType: 0,
      routeUrl: '/map-config',
      routeName: 'map-config',
    },
    {
      label: '主页配置',
      value: '',
      url: null,
      menuType: 1,
      routeUrl: 'config',
      routeName: 'layout-config',
    },
  ],
  nickname: 'bj',
  sex: '',
  mobile: '',
  email: '',
  remark: '',
  tenantName: '北京租户',
};

export default [
  {
    url: '/safety_api/api/login/info',
    timeout: 1000,
    method: 'post',
    response: () => {
      return resultSuccess(info);
    },
  },

  {
    url: '/api/common/queryTentantList',
    timeout: 1000,
    method: 'get',
    response: () => {
      return resultSuccess([
        {
          tenantId: 1,
          tenantCode: 'comac',
          tenantName: '上飞公司',
        },
      ]);
    },
  },
  {
    url: '/api/common/initData',
    timeout: 1000,
    method: 'get',
    response: () => {
      return resultSuccess({
        isEnableCode: false,
      });
    },
  },
  {
    url: '/api/login/auth',
    timeout: 1000,
    method: 'post',
    response: () => {
      return resultSuccess({
        satoken: 'ddb094c3-731e-4d11-8ca9-a4b0ba751a8d',
        tenantId: '4510784fbc3c4ca59238666e5c75c2f8498702880',
      });
    },
  },
];
