import Vue from 'vue'
import Router from 'vue-router'
import {
  UserQuestion,
  ByhService,
  ByhServiceDetail,
  Test,
  Login,
  Index,
  // Default,
  LoanRecordList,
  LoanRecordHandlerList,
  LoanRecordDetail,
  LoanRecordHandlerDetail,
  ClientDataUpload,
  BankCardMaintenance,
  DutyManagement,
  UserManagement,
  DownloadExecl,
  LendBankCardList,
  DutyBizGroupsListDialog,
  CustomerDistribution,
  DistributionBatchDialog,
  ByhPlanRemindDetails,
  ByhPlanRemindDetailNew,
  ByhLoanBackedDetails,
  ByhLoanCollectList,
  ByhLoanCollectDetails,
  ByhLoanLinkerList,
  ByhMarket,
  ByhSaleCustomer,
  SaleCustomerDetail,
  ByhTestCall,
  SeatManage,
  ByhCallPhonelog,
  RemindMondayData,
  RemindDayData,
  SettingSystem,
  ByhPagePlanList,
  ByhLoanSnapList,
  GxdloanList,
  CardBankList,
  ServiceProblem
} from './routes'

Vue.use(Router)
export default new Router({
  mode: 'hash',
  // mode: 'history',
  routes: [
    {path: '/', redirect: '/login'},
    {path: '/login', name: 'Login', meta: {title: '登录', filter: false}, component: Login},
    {
      path: '/index',
      name: 'Index',
      component: Index,
      meta: {title: '首页'},
      children: [
        // {
        //   path: '',
        //   name: 'Default',
        //   component: Default,
        //   meta: {title: '首页', filter: true}
        // },
        {
          path: '/test',
          name: 'Test',
          component: Test,
          meta: {
            title: '测试',
            filter: false
          }
        },
        {
          path: '/loan/LoanRecordHandlerList',
          name: 'LoanRecordHandlerList',
          component: LoanRecordHandlerList,
          meta: {title: '处理人借款列表', filter: true}
        },
        {
          path: '/loan/loanRecordList',
          name: 'LoanRecordList',
          component: LoanRecordList,
          meta: {title: '业务组借款列表', filter: true}
        },
        {
          path: '/loan/loanRecordDetail',
          name: 'LoanRecordDetail',
          component: LoanRecordDetail,
          meta: {title: '借条详情', filter: true}
        },
        {
          path: '/loan/LoanRecordHandlerDetail',
          name: 'LoanRecordHandlerDetail',
          component: LoanRecordHandlerDetail,
          meta: {title: '处理人借条详情', filter: true}
        },
        {
          path: '/system/clientDataUpload',
          name: 'ClientDataUpload',
          component: ClientDataUpload,
          meta: {title: '客户资料上传', filter: true}
        },
        {
          path: '/system/bankCardMaintenance',
          name: 'BankCardMaintenance',
          component: BankCardMaintenance,
          meta: {title: '银行卡维护', filter: true}
        },
        {
          path: '/system/dutyManagement',
          name: 'DutyManagement',
          component: DutyManagement,
          meta: {title: '值班管理', filter: true}
        },
        {
          path: '/system/UserManagement',
          name: 'UserManagement',
          component: UserManagement,
          meta: {title: '用户管理', filter: true}
        },
        {
          path: '/system/UserQuestion',
          name: 'UserQuestion',
          component: UserQuestion,
          meta: {title: '用户管理', filter: true}
        },
        {
          path: '/system/DownloadExecl',
          name: 'DownloadExecl',
          component: DownloadExecl,
          meta: {title: '下载管理', filter: true}
        },
        {
          path: '/system/CustomerDistribution',
          name: 'CustomerDistribution',
          component: CustomerDistribution,
          meta: {title: '批次分配', filter: true}
        },
        {
          path: '/system/DistributionBatchDialog',
          name: 'DistributionBatchDialog',
          component: DistributionBatchDialog,
          meta: {title: '分配批次', filter: true}
        },
        {
          path: '/system/LendBankCardList',
          name: 'LendBankCardList',
          component: LendBankCardList,
          meta: {title: '出借人管理', filter: true}
        },
        {
          path: '/system/DutyBizGroupsListDialog',
          name: 'DutyBizGroupsListDialog',
          component: DutyBizGroupsListDialog,
          meta: {title: '业务组列表', filter: true}
        },
        {
          path: '/byh/collect/ByhLoanCollectList',
          name: 'ByhLoanCollectList',
          component: ByhLoanCollectList,
          meta: {title: '逾期列表', filter: true}
        },
        {
          path: '/byh/collect/ByhLoanLinkerList',
          name: 'ByhLoanLinkerList',
          component: ByhLoanLinkerList,
          meta: {title: '通讯录列表', filter: true}
        },
        {
          path: '/byh/collect/ByhLoanCollectDetails',
          name: 'ByhLoanCollectDetails',
          component: ByhLoanCollectDetails,
          meta: {title: '逾期详情', filter: true}
        },
        {
          path: '/byh/ByhPlanRemindDetails',
          name: 'ByhPlanRemindDetails',
          component: ByhPlanRemindDetails,
          meta: {title: '还款计划详情', filter: true}
        },
        {
          path: '/byh/ByhPlanRemindDetailNew',
          name: 'ByhPlanRemindDetailNew',
          component: ByhPlanRemindDetailNew,
          meta: {title: '还款详情', filter: true}
        },
        {
          path: '/byh/ByhLoanBackedDetails',
          name: 'ByhLoanBackedDetails',
          component: ByhLoanBackedDetails,
          meta: {title: '还款详情', filter: true}
        },
        {
          path: '/byh/ByhService',
          name: 'ByhService',
          component: ByhService,
          meta: {title: '客服管理', filter: true}
        },
        {
          path: '/byh/ByhServiceDetail',
          name: 'ByhServiceDetail',
          component: ByhServiceDetail,
          meta: {title: '客服详情', filter: true}
        },
        {
          path: '/byh/ServiceProblem',
          name: 'ServiceProblem',
          component: ServiceProblem,
          meta: {title: '意见反馈', filter: true}
        },
        {
          path: '/byh/ByhSaleCustomer',
          name: 'ByhSaleCustomer',
          component: ByhSaleCustomer,
          meta: {title: '我的销售客户', filter: true}
        },
        {
          path: '/byh/ByhMarket',
          name: 'ByhMarket',
          component: ByhMarket,
          meta: {title: '销售批次管理', filter: true}
        },
        {
          path: '/byh/SaleCustomerDetail',
          name: 'SaleCustomerDetail',
          component: SaleCustomerDetail,
          meta: {title: '销售客户详情', filter: true}
        },
        {
          path: '/byh/collect/ByhTestCall',
          name: 'ByhTestCall',
          component: ByhTestCall,
          meta: {
            title: '测试通话',
            filter: true
          }
        },
        {
          path: '/user/SeatManage',
          name: 'SeatManage',
          component: SeatManage,
          meta: {
            title: '坐席管理',
            filter: true
          }
        },
        {
          path: '/byh/ByhCallPhonelog',
          name: 'ByhCallPhonelog',
          component: ByhCallPhonelog,
          meta: {
            title: '通话记录查询',
            filter: true
          }
        },
        {
          path: '/byh/analytics/RemindMondayData',
          name: 'RemindMondayData',
          component: RemindMondayData,
          meta: {
            title: '提醒数据月报',
            filter: true
          }
        },
        {
          path: '/byh/analytics/RemindDayData',
          name: 'RemindDayData',
          component: RemindDayData,
          meta: {
            title: '提醒数据日报',
            filter: true
          }
        },
        {
          path: '/byh/setting/SettingSystem',
          name: 'SettingSystem',
          component: SettingSystem,
          meta: {
            title: '修改当前系统配置',
            filter: true
          }
        },
        {
          path: '/byh/ByhPagePlanList',
          name: 'ByhPagePlanList',
          component: ByhPagePlanList,
          meta: {
            title: '还款列表',
            filter: true
          }
        },
        {
          path: '/byh/ByhLoanSnapList',
          name: 'ByhLoanSnapList',
          component: ByhLoanSnapList,
          meta: {
            title: '临时放款列表',
            filter: true
          }
        },
        {
          path: '/byh/GxdloanList',
          name: 'GxdloanList',
          component: GxdloanList,
          meta: {
            title: '借款列表',
            filter: true
          }
        },
        {
          path: '/byh/finance/CardBankList',
          name: 'CardBankList',
          component: CardBankList,
          meta: {
            title: '支付渠道',
            filter: true
          }
        },

      ]
    }
  ]
})
