index.js 2.53 KB
import PriceChange from './price-change';
import OrderList from './order-list';
import OrderDetail from './order-detail';

export default [
  {
    name: 'OrderSellConfirm',
    path: '/xianyu/order/sellconfirm.html',
    component: () => import(/* webpackChunkName: "order" */ './seller-confirm'),
    props: route => ({
      productId: route.query.productId,
      storageId: route.query.storageId,
    }),
  },
  {
    name: 'OrderPay',
    path: '/xianyu/order/pay.html',
    component: () => import(/* webpackChunkName: "order" */ './pay'),
    props: route => ({
      orderCode: route.query.orderCode,
      payParams: route.query.payParams,
      extra: route.query.extra,
      price: route.query.price
    }),
  },
  {
    name: 'OrderBuyConfirm',
    path: '/xianyu/order/buyconfirm.html',
    component: () => import(/* webpackChunkName: "order" */ './buyer-confirm'),
    props: route => ({
      productId: route.query.productId,
      storageId: route.query.storageId,
    }),
  },
  {
    name: 'SellPayOk',
    path: '/xianyu/order/sellpayok.html',
    component: () => import(/* webpackChunkName: "order" */ './sell-pay-ok'),
    props: route => ({
      orderCode: route.query.orderCode,
    }),
  },
  {
    name: 'BuyPayOk',
    path: '/xianyu/order/buypayok.html',
    component: () => import(/* webpackChunkName: "order" */ './buy-pay-ok'),
    props: route => ({
      orderCode: route.query.orderCode,
      productId: route.query.productId,
    }),
  },
  {
    name: 'buyerAskOrder', // 买家求购确认
    path: '/xianyu/order/buyeraskorder.html',
    component: () => import('./buyer-ask-order'),
    props: route => ({
      storageId: route.query.storageId,
    }),
  },

  {
    name: 'sellAskOrder', // 卖家求购确认
    path: '/xianyu/order/selleraskorder.html',
    component: () => import('./seller-ask-order'),
    props: route => ({
      skup: route.query.skup,
      price: route.query.price,
    }),
  },

  // 物流信息
  // code: 订单编码
  {
    name: 'orderLogisticsInfo',
    path: '/xianyu/:owner/order/logistics/:code',
    component: () => import('./order-logistics-info'),
  },
  {
    name: 'order.deliver',
    path: '/xianyu/order/deliver/:skup/:code',
    component: () =>
      import(/* webpackChunkName: "order.deliver" */ './deliver'),
  },
  {
    name: 'deliverBackAddress',
    path: '/xianyu/detail/deliver/back/address/:code',
    component: () =>
      import(
        /* webpackChunkName: "deliverBackAddress" */ './delivery-back-address.vue'
      ),
  },
  ...PriceChange,
  ...OrderList,
  ...OrderDetail,
];