|
@@ -23,7 +23,16 @@
|
|
|
</el-col>
|
|
|
<el-col :span="24" v-else-if="activeName != '2'">
|
|
|
<el-col :span="24" class="one">
|
|
|
- <search-1 :form="searchForm" @onSubmit="search" @querySearch="querySearch" @toReset="toClose" :shopList="shopList"> </search-1>
|
|
|
+ <search-1
|
|
|
+ :form="searchForm"
|
|
|
+ :shopList="shopList"
|
|
|
+ :goodsList="goodsList"
|
|
|
+ @onSubmit="search"
|
|
|
+ @querySearch="querySearch"
|
|
|
+ @toReset="toClose"
|
|
|
+ @goodsSearch="goodsSearch"
|
|
|
+ >
|
|
|
+ </search-1>
|
|
|
</el-col>
|
|
|
<data-table :fields="fields" :opera="opera" @query="search" :data="list" :total="total" @detail="toDetails" @sales="toSaless">
|
|
|
<template #is_afterSale="{ row }">
|
|
@@ -48,6 +57,7 @@ const _ = require('lodash');
|
|
|
import { mapState, mapGetters, createNamespacedHelpers } from 'vuex';
|
|
|
const { mapActions: dictData } = createNamespacedHelpers('dictData');
|
|
|
const { mapActions: shop } = createNamespacedHelpers('shop');
|
|
|
+const { mapActions: goods } = createNamespacedHelpers('goods');
|
|
|
const { mapActions } = createNamespacedHelpers('groupOrder');
|
|
|
export default {
|
|
|
name: 'index',
|
|
@@ -56,7 +66,7 @@ export default {
|
|
|
card2: () => import('@/components/orderParts/card-4.vue'),
|
|
|
group_order: () => import('@/components/orderParts/detail/group_order.vue'),
|
|
|
group_sales: () => import('@/components/orderParts/detail/group_sales.vue'),
|
|
|
- search1: () => import('@/components/orderParts/search-2.vue'),
|
|
|
+ search1: () => import('@/components/orderParts/search-3.vue'),
|
|
|
},
|
|
|
data: function () {
|
|
|
return {
|
|
@@ -67,6 +77,10 @@ export default {
|
|
|
statusList: [],
|
|
|
// 店铺列表
|
|
|
shopList: [],
|
|
|
+ // 商品列表
|
|
|
+ goodsList: [],
|
|
|
+ // 规格列表
|
|
|
+ // specList: [],
|
|
|
order_id: '',
|
|
|
sales_id: '',
|
|
|
status: '',
|
|
@@ -97,6 +111,7 @@ export default {
|
|
|
methods: {
|
|
|
...dictData({ dictQuery: 'query' }),
|
|
|
...shop({ shopQuery: 'query' }),
|
|
|
+ ...goods({ goodsQuery: 'query' }),
|
|
|
...mapActions(['query', 'fetch', 'create', 'update', 'delete']),
|
|
|
// 查询
|
|
|
async search({ skip = 0, limit = this.$limit, ...info } = {}) {
|
|
@@ -107,6 +122,7 @@ export default {
|
|
|
delete condition.buy_time;
|
|
|
}
|
|
|
if (this.activeName == '1') info.status = '0';
|
|
|
+ else if (this.activeName == '2') info.status = '1';
|
|
|
else if (this.activeName == '3') info.status = '2';
|
|
|
else if (this.activeName == '4') info.status = '3';
|
|
|
else if (this.activeName == '5') info.status = '-1';
|
|
@@ -163,15 +179,17 @@ export default {
|
|
|
let res = await this.shopQuery({ name: value });
|
|
|
if (this.$checkRes(res)) this.$set(this, 'shopList', res.data);
|
|
|
},
|
|
|
+ //商品名称远程查询
|
|
|
+ async goodsSearch(value) {
|
|
|
+ let res = await this.goodsQuery({ name: value });
|
|
|
+ if (this.$checkRes(res)) this.$set(this, 'goodsList', res.data);
|
|
|
+ },
|
|
|
// 查询其他信息
|
|
|
async searchOther() {
|
|
|
let res;
|
|
|
// 类型
|
|
|
res = await this.dictQuery({ code: 'order_process' });
|
|
|
if (this.$checkRes(res)) this.$set(this, `statusList`, res.data);
|
|
|
- // 店铺
|
|
|
- res = await this.shopQuery();
|
|
|
- if (this.$checkRes(res)) this.$set(this, `shopList`, res.data);
|
|
|
},
|
|
|
},
|
|
|
computed: {
|