import { Route } from '@angular/router';

import { ListComponent } from './components/list.component';

import {
  PartnerListForBranchResolver,
  PartnerListForDivisionResolver,
  PartnerListForMainOfficeResolver,
  PartnerListForOfficeResolver,
  PartnerListForStoreResolver,
  PartnerListResolver,
  PartnersResolver,
} from './resolvers/partner.resolver';

export const partnerRoutes: Route[] = [
  // {
  //   path: '',
  //   pathMatch: 'full',
  //   redirectTo: 'all',
  // },
  {
    path: 'all',
    component: ListComponent,
    resolve: {
      listPartner: PartnerListResolver,
    },
  },
  {
    path: 'main-office',
    component: ListComponent,
    resolve: {
      listPartner: PartnerListForMainOfficeResolver,
    },
  },
  {
    path: 'branch',
    component: ListComponent,
    resolve: {
      listPartner: PartnerListForBranchResolver,
    },
  },
  {
    path: 'division',
    component: ListComponent,
    resolve: {
      listPartner: PartnerListForDivisionResolver,
    },
  },
  {
    path: 'office',
    component: ListComponent,
    resolve: {
      listPartner: PartnerListForOfficeResolver,
    },
  },
  {
    path: 'store',
    component: ListComponent,
    resolve: {
      listPartner: PartnerListForStoreResolver,
    },
  },
];
