import {
  UserLayout,
  BasicLayout,
  BlankLayout,
  BigScreen,
  PageView
} from '@/layouts'
export default {
  path: '/dealerManagement',
  redirect: '/dealerManagement/marketingDivisionSet',
  component: PageView,
  meta: {
    title: '经销商管理',
    icon: 'idcard',
    permission: 'M_dealerManagement'
  },
  children: [
    {
      path: '/dealerManagement/merchantInfoManagement',
      redirect: '/dealerManagement/merchantInfoManagement/list',
      name: 'merchantInfoManagement',
      component: BlankLayout,
      meta: {
        title: '经销商资料管理',
        icon: 'file-text',
        permission: 'M_merchantInfoManagementList'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'merchantInfoManagementList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/list.vue'),
          meta: {
            title: '经销商资料列表',
            icon: 'file-text',
            hidden: true,
            permission: 'M_merchantInfoManagementList'
          }
        },
        {
          path: 'add',
          name: 'merchantInfoManagementAdd',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/edit.vue'),
          meta: {
            title: '新增经销商',
            icon: 'file-text',
            hidden: true
          }
        },
        {
          path: 'edit/:id',
          name: 'merchantInfoManagementEdit',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/edit.vue'),
          meta: {
            title: '编辑经销商',
            icon: 'file-text',
            hidden: true
          }
        },
        {
          path: 'permissionSetting/:sn/:name/:dealerLevel',
          name: 'merchantInfoManagementSet',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/merchantInfoManagement/permissionSettingNew.vue'),
          meta: {
            title: '经销权设置',
            icon: 'file-text',
            replaceTab: true,
            hidden: true
          }
        },
        {
          path: 'rebateBinding/:sn',
          name: 'rebateBinding',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/rebateBinding/list.vue'),
          meta: {
            title: '差价设置',
            icon: 'file-text',
            replaceTab: true,
            hidden: true
          }
        }
      ]
    },
    {
      path: '/dealerManagement/dealerAccountManagement',
      redirect: '/dealerManagement/dealerAccountManagement/list',
      name: 'dealerAccountManagement',
      component: BlankLayout,
      meta: {
        title: '经销商账号管理',
        icon: 'team',
        permission: 'M_dealerAccountManagementList'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'dealerAccountManagementList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccountManagement/list.vue'),
          meta: {
            title: '经销商账号列表',
            icon: 'team',
            hidden: true,
            permission: 'M_dealerAccountManagementList'
          }
        }
      ]
    },
    {
      path: '/dealerManagement/dealerAccount',
      redirect: '/dealerManagement/dealerAccount/list',
      name: 'dealerAccount',
      component: BlankLayout,
      meta: {
        title: '经销商账户',
        icon: 'team',
        permission: 'M_dealerAccountList'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'dealerAccountList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccount/list.vue'),
          meta: {
            title: '经销商账户列表',
            icon: 'team',
            hidden: true,
            permission: 'M_dealerAccountList'
          }
        },
        {
          path: 'detail/:sn/:aSn',
          name: 'dealerAccountDetail',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerAccount/detail.vue'),
          meta: {
            title: '经销商账户明细',
            icon: 'thunderbolt',
            replaceTab: true,
            hidden: true,
            permission: 'M_dealerAccountDetail'
          }
        }
      ]
    },
    {
      path: '/promotionRulesManagement/dealerPromotions',
      redirect: '/promotionRulesManagement/dealerPromotions/list',
      name: 'dealerPromotionManagement',
      component: BlankLayout,
      meta: {
        title: '经销商促销',
        icon: 'setting',
        permission: 'M_dealerPromotionManagementList'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'dealerPromotionManagementList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/list.vue'),
          meta: {
            title: '经销商促销列表',
            icon: 'setting',
            hidden: true,
            permission: 'M_dealerPromotionManagementList'
          }
        },
        {
          path: 'detail',
          name: 'dealerPromotionManagementDetail',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/detail.vue'),
          meta: {
            title: '促销活动详情',
            icon: 'thunderbolt',
            hidden: true
          }
        },
        {
          path: 'ruleSet',
          name: 'dealerPromotionManagementRule',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/promotionRulesManagement/dealerPromotions/ruleSet.vue'),
          meta: {
            title: '促销规则设置',
            icon: 'thunderbolt',
            replaceTab: true,
            hidden: true
          }
        }
      ]
    },
    {
      path: '/dealerManagement/provincialWarehouseManagement',
      redirect: '/dealerManagement/provincialWarehouseManagement/list',
      name: 'provincialWarehouse',
      component: BlankLayout,
      meta: {
        title: '省仓管理',
        icon: 'share-alt',
        permission: 'M_provincialWarehouse'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'provincialWarehouseList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/provincialWarehouseManagement/list.vue'),
          meta: {
            title: '省仓管理列表',
            icon: 'share-alt',
            hidden: true,
            permission: 'M_provincialWarehouseList'
          }
        },
        {
          path: 'relatedDealers/:sn/:name',
          name: 'relatedDealersList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/provincialWarehouseManagement/relatedDealersList.vue'),
          meta: {
            title: '省仓关联经销商',
            icon: 'share-alt',
            hidden: true,
            replaceTab: true,
            permission: 'M_relatedDealersList'
          }
        }
      ]
    },
    {
      path: '/dealerManagement/tireStorageManagement',
      redirect: '/dealerManagement/tireStorageManagement/list',
      name: 'tireSavingWarehouse',
      component: BlankLayout,
      meta: {
        title: '轮胎省仓管理',
        icon: 'share-alt',
        permission: 'M_tireSavingWarehouse'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'tireSavingWarehouseList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/tireStorageManagement/list.vue'),
          meta: {
            title: '轮胎省仓管理列表',
            icon: 'share-alt',
            hidden: true,
            permission: 'M_tireSavingWarehouseList'
          }
        }
      ]
    },
    {
      path: '/dealerManagement/marketingDivisionSetNew',
      redirect: '/dealerManagement/marketingDivisionSetNew/list',
      name: 'marketingDivisionSetNew',
      component: BlankLayout,
      meta: {
        title: '营销分区设置',
        icon: 'setting',
        permission: 'M_marketingDivisionSetList'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'marketingDivisionSetNewList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/marketingDivisionSetNew/list.vue'),
          meta: {
            title: '营销分区列表',
            icon: 'setting',
            hidden: true,
            permission: 'M_marketingDivisionSetList'
          }
        }
      ]
    },
    {
      path: '/dealerManagement/businessOwnerSettings',
      redirect: '/dealerManagement/businessOwnerSettings/list',
      name: 'businessOwnerSettings',
      component: BlankLayout,
      meta: {
        title: '数据权限配置',
        icon: 'stock',
        permission: 'M_businessOwnerSettings'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'businessOwnerSettingsList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/businessOwnerSettings/list.vue'),
          meta: {
            title: '数据权限配置列表',
            icon: 'stock',
            hidden: true,
            permission: 'M_businessOwnerSettingsList'
          }
        },
        {
          path: 'settingsIndex',
          name: 'categorySet',
          component: () => import(/* webpackChunkName: "salesManagement" */ '@/views/dealerManagement/businessOwnerSettings/settingsIndex.vue'),
          meta: {
            title: '管辖品类权限设置',
            icon: 'user',
            hidden: true,
            replaceTab: false,
            permission: 'M_settingsIndex'
          }
        }
      ]
    },
    {
      path: '/dealerManagement/dealerZoneSearch',
      redirect: '/dealerManagement/dealerZoneSearch/list',
      name: 'dealerZoneSearch',
      component: BlankLayout,
      meta: {
        title: '经销商所属分区查询',
        icon: 'setting',
        permission: 'M_dealerZoneSearch'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'dealerZoneSearchList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/dealerZoneSearch/list.vue'),
          meta: {
            title: '经销商所属分区查询',
            icon: 'setting',
            hidden: true,
            permission: 'M_dealerZoneSearchList'
          }
        }
      ]
    },
    {
      path: '/dealerManagement/newCustomSearch',
      redirect: '/dealerManagement/newCustomSearch/list',
      name: 'newCustomSearch',
      component: BlankLayout,
      meta: {
        title: '新客户查询',
        icon: 'setting',
        permission: 'M_newCustomSearchList'
      },
      hideChildrenInMenu: true,
      children: [
        {
          path: 'list',
          name: 'newCustomSearchList',
          component: () => import(/* webpackChunkName: "dealerManagement" */ '@/views/dealerManagement/newCustomSearch/list.vue'),
          meta: {
            title: '新客户查询列表',
            icon: 'setting',
            hidden: true,
            permission: 'M_newCustomSearchList'
          }
        }
      ]
    }
  ]
}
