mutations.js 837 Bytes
import * as Types from './types';

export default {
  [Types.FETCH_ORDER_PRODUCT_REQUEST](state) {
    state.orderInfo = {};
    state.fetchingPro = true;
  },
  [Types.FETCH_ORDER_PRODUCT_FAILD](state) {
    state.fetchingPro = false;
  },
  [Types.FETCH_ORDER_PRODUCT_SUCCESS](state, {order}) {
    state.fetchingPro = false;
    state.orderInfo = order;
  },
  [Types.POST_NOSALE_REQUEST](state) {
    state.fetchingNoSale = true;
  },
  [Types.POST_NOSALE_FAILD](state) {
    state.fetchingNoSale = false;
  },
  [Types.POST_NOSALE_SUCCESS](state) {
    state.fetchingNoSale = false;
  },
  [Types.POST_CHANGEPRICE_REQUEST](state) {
    state.fetchingNoSale = true;
  },
  [Types.POST_CHANGEPRICE_FAILD](state) {
    state.fetchingNoSale = false;
  },
  [Types.POST_NOSALE_SUCCESS](state) {
    state.fetchingNoSale = false;
  },
};