This commit is contained in:
parent
1f12492c0c
commit
937359ad4e
|
@ -1,5 +1,5 @@
|
|||
NODE_ENV = 'development'
|
||||
VITE_NOW_TYPE = 'dist'
|
||||
# Base API
|
||||
# VITE_APP_BASE_URL='http://192.168.1.22:8546'
|
||||
VITE_APP_BASE_URL='https://erp.lihaink.cn'
|
||||
VITE_APP_BASE_URL='http://192.168.1.22:8546'
|
||||
# VITE_APP_BASE_URL='https://erp.lihaink.cn'
|
|
@ -21,6 +21,7 @@
|
|||
"mavon-editor": "3.0.1",
|
||||
"nprogress": "^0.2.0",
|
||||
"pinia": "^2.0.14",
|
||||
"print-js": "^1.6.0",
|
||||
"vditor": "^3.9.9",
|
||||
"vue": "^3.2.37",
|
||||
"vue-clipboard3": "^2.0.0",
|
||||
|
@ -6233,6 +6234,11 @@
|
|||
"node": ">=6.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/print-js": {
|
||||
"version": "1.6.0",
|
||||
"resolved": "https://registry.npmjs.org/print-js/-/print-js-1.6.0.tgz",
|
||||
"integrity": "sha512-BfnOIzSKbqGRtO4o0rnj/K3681BSd2QUrsIZy/+WdCIugjIswjmx3lDEZpXB2ruGf9d4b3YNINri81+J0FsBWg=="
|
||||
},
|
||||
"node_modules/prismjs": {
|
||||
"version": "1.29.0",
|
||||
"resolved": "https://registry.npmjs.org/prismjs/-/prismjs-1.29.0.tgz",
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
"mavon-editor": "3.0.1",
|
||||
"nprogress": "^0.2.0",
|
||||
"pinia": "^2.0.14",
|
||||
"print-js": "^1.6.0",
|
||||
"vditor": "^3.9.9",
|
||||
"vue": "^3.2.37",
|
||||
"vue-clipboard3": "^2.0.0",
|
||||
|
|
|
@ -49,3 +49,9 @@ export function apiOpurchaseinfoListList(params: any) {
|
|||
export function apicreateSupplierGoods(params: any) {
|
||||
return request.post({ url: '/operation/opurchaseclass/createSupplierGoods', params })
|
||||
}
|
||||
|
||||
// 平台添加采购订单
|
||||
export function apioperationOpurchaseclassAdd() {
|
||||
return request.post({ url: '/operation/opurchaseclass/add' })
|
||||
}
|
||||
|
||||
|
|
|
@ -83,7 +83,7 @@
|
|||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
<pagination v-if="pager.lists" v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
<el-dialog v-model="dialogVisible" title="入库" width="600">
|
||||
<el-descriptions class="margin-top" :column="1" border>
|
||||
|
@ -131,6 +131,7 @@ const route = useRoute();
|
|||
const queryParams = reactive({
|
||||
id: route.query.id,
|
||||
is_adopt: "",
|
||||
is_mer: 1
|
||||
});
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
<pagination v-if="pager.lists" v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
<detail ref="detailRef" v-if="showDetail" :dictData="dictData"
|
||||
@close="showDetail = false"/>
|
||||
|
@ -41,6 +41,7 @@ const route = useRoute();
|
|||
|
||||
const queryParams = reactive({
|
||||
id: route.query.id,
|
||||
is_mer: 1
|
||||
});
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
|
|
|
@ -36,10 +36,10 @@
|
|||
<el-table-column prop="nums_count" label="已采纳数量" />
|
||||
</el-table>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="子订单" name="order">
|
||||
<el-tab-pane label="摊贩订单" name="order">
|
||||
<subOrder ref="subOrderRef" />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="报价列表" name="offer">
|
||||
<!-- <el-tab-pane label="报价列表" name="offer">
|
||||
<goodsOffer ref="goodsOfferRef" />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="未推送商品" name="notPushedGoods">
|
||||
|
@ -54,7 +54,7 @@
|
|||
<el-table-column prop="total" label="合计(元)" />
|
||||
<el-table-column label="备注" prop="data" show-overflow-tooltip />
|
||||
</el-table>
|
||||
</el-tab-pane>
|
||||
</el-tab-pane> -->
|
||||
</el-tabs>
|
||||
</el-card>
|
||||
</div>
|
||||
|
@ -109,6 +109,7 @@ const { pager, getLists, resetParams, resetPage } = usePaging({
|
|||
params: { is_push: 0, id: route.query.id },
|
||||
});
|
||||
|
||||
// getLists()
|
||||
|
||||
const rePush = async () => {
|
||||
await apicreateSupplierGoods({ id: route.query.id })
|
||||
|
@ -116,7 +117,5 @@ const rePush = async () => {
|
|||
|
||||
}
|
||||
|
||||
// 获取字典数据
|
||||
|
||||
getLists()
|
||||
</script>
|
||||
|
|
|
@ -1,24 +1,29 @@
|
|||
<template>
|
||||
<div>
|
||||
<el-card class="!border-none mb-4" shadow="never">
|
||||
<el-form class="mb-[-16px]" :model="queryParams" inline>
|
||||
<el-form-item label="所属商户" prop="merchant">
|
||||
<el-input class="w-[280px]" v-model="queryParams.merchant" clearable placeholder="请输入所属商户" />
|
||||
</el-form-item>
|
||||
<el-form-item label="零售订单id" prop="order_arr">
|
||||
<div>
|
||||
<el-card class="!border-none mb-4" shadow="never">
|
||||
<el-form class="mb-[-16px]" :model="queryParams" inline>
|
||||
<el-form-item label="所属商户" prop="merchant">
|
||||
<el-input
|
||||
class="w-[280px]"
|
||||
v-model="queryParams.merchant"
|
||||
clearable
|
||||
placeholder="请输入所属商户"
|
||||
/>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="零售订单id" prop="order_arr">
|
||||
<el-input class="w-[280px]" v-model="queryParams.order_arr" clearable placeholder="请输入零售订单id" />
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="单据编号" prop="number">
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item label="单据编号" prop="number">
|
||||
<el-input class="w-[280px]" v-model="queryParams.number" clearable placeholder="请输入单据编号" />
|
||||
</el-form-item> -->
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="resetPage">查询</el-button>
|
||||
<el-button @click="resetParams">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-card>
|
||||
<el-card class="!border-none" v-loading="pager.loading" shadow="never">
|
||||
<!-- <el-button v-perms="['operation.opurchaseclass/add']" type="primary" @click="handleAdd">
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="resetPage">查询</el-button>
|
||||
<el-button @click="resetParams">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-card>
|
||||
<el-card class="!border-none" v-loading="pager.loading" shadow="never">
|
||||
<!-- <el-button v-perms="['operation.opurchaseclass/add']" type="primary" @click="handleAdd">
|
||||
<template #icon>
|
||||
<icon name="el-icon-Plus" />
|
||||
</template>
|
||||
|
@ -31,25 +36,82 @@
|
|||
>
|
||||
删除
|
||||
</el-button> -->
|
||||
<div class="mt-4">
|
||||
<el-table :data="pager.lists" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column label="ID" prop="id" show-overflow-tooltip />
|
||||
<el-table-column label="所属商户" prop="merchant_name" show-overflow-tooltip />
|
||||
<el-table-column label="零售订单id" prop="order_arr" show-overflow-tooltip />
|
||||
<el-table-column label="购物车id" prop="cart_id" show-overflow-tooltip />
|
||||
<el-table-column label="单据编号" prop="number" width="220" show-overflow-tooltip />
|
||||
<el-table-column label="单据金额" prop="total" show-overflow-tooltip />
|
||||
<el-table-column label="抵扣金额" prop="deduction_price" show-overflow-tooltip />
|
||||
<el-table-column label="实际金额" prop="actual" show-overflow-tooltip />
|
||||
<el-table-column label="实收金额" prop="money" show-overflow-tooltip />
|
||||
<el-table-column label="是否支付" prop="paid" show-overflow-tooltip />
|
||||
<el-table-column label="操作" width="120" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button type="primary" link @click="handleDetail(row)">
|
||||
详情
|
||||
</el-button>
|
||||
<!-- <el-button
|
||||
<el-button
|
||||
v-perms="['operation.opurchaseclass/add']"
|
||||
type="primary"
|
||||
@click="submitOrder"
|
||||
>
|
||||
<template #icon>
|
||||
<icon name="el-icon-Plus" />
|
||||
</template>
|
||||
提交今日商户采购订单
|
||||
</el-button>
|
||||
<el-button
|
||||
v-perms="['operation.opurchaseclass/add']"
|
||||
type="success"
|
||||
@click="onPrintOrder"
|
||||
>
|
||||
<template #icon>
|
||||
<icon name="el-icon-Printer" />
|
||||
</template>
|
||||
打印
|
||||
</el-button>
|
||||
<div class="mt-4">
|
||||
<el-table :data="pager.lists" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column label="ID" prop="id" show-overflow-tooltip />
|
||||
<el-table-column
|
||||
label="所属商户"
|
||||
prop="merchant_name"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="零售订单id"
|
||||
prop="order_arr"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="购物车id"
|
||||
prop="cart_id"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="单据编号"
|
||||
prop="number"
|
||||
width="220"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="单据金额"
|
||||
prop="total"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="抵扣金额"
|
||||
prop="deduction_price"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="实际金额"
|
||||
prop="actual"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="实收金额"
|
||||
prop="money"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column label="是否支付" prop="paid" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<span>{{ row.paid ? "是" : "否" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="120" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button type="primary" link @click="handleDetail(row)">
|
||||
详情
|
||||
</el-button>
|
||||
<!-- <el-button
|
||||
v-perms="['operation.opurchaseclass/edit']"
|
||||
type="primary"
|
||||
link
|
||||
|
@ -65,91 +127,141 @@
|
|||
>
|
||||
删除
|
||||
</el-button> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
</el-card>
|
||||
<edit-popup v-if="showEdit" ref="editRef" :dict-data="dictData" @success="getLists" @close="showEdit = false" />
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
</el-card>
|
||||
<edit-popup
|
||||
v-if="showEdit"
|
||||
ref="editRef"
|
||||
:dict-data="dictData"
|
||||
@success="getLists"
|
||||
@close="showEdit = false"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup name="opurchaseclassLists">
|
||||
import { usePaging } from '@/hooks/usePaging'
|
||||
import { useDictData } from '@/hooks/useDictOptions'
|
||||
import { apiOpurchaseclassLists, apiOpurchaseclassDelete } from '@/api/opurchaseclass'
|
||||
import { timeFormat } from '@/utils/util'
|
||||
import feedback from '@/utils/feedback'
|
||||
import EditPopup from './edit.vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { usePaging } from "@/hooks/usePaging";
|
||||
import { useDictData } from "@/hooks/useDictOptions";
|
||||
import {
|
||||
apiOpurchaseclassLists,
|
||||
apiOpurchaseclassDelete,
|
||||
apioperationOpurchaseclassAdd,
|
||||
} from "@/api/opurchaseclass";
|
||||
import { timeFormat } from "@/utils/util";
|
||||
import feedback from "@/utils/feedback";
|
||||
import EditPopup from "./edit.vue";
|
||||
import { useRouter } from "vue-router";
|
||||
import print from "print-js";
|
||||
|
||||
const router = useRouter()
|
||||
const router = useRouter();
|
||||
|
||||
const editRef = shallowRef<InstanceType<typeof EditPopup>>()
|
||||
const editRef = shallowRef<InstanceType<typeof EditPopup>>();
|
||||
// 是否显示编辑框
|
||||
const showEdit = ref(false)
|
||||
|
||||
const showEdit = ref(false);
|
||||
|
||||
// 查询条件
|
||||
const queryParams = reactive({
|
||||
merchant: '',
|
||||
order_arr: '',
|
||||
number: ''
|
||||
})
|
||||
merchant: "",
|
||||
order_arr: "",
|
||||
number: "",
|
||||
is_mer: 1, // 1是商户,2是平台
|
||||
});
|
||||
|
||||
// 选中数据
|
||||
const selectData = ref<any[]>([])
|
||||
const selectData = ref<any[]>([]);
|
||||
|
||||
// 表格选择后回调事件
|
||||
const handleSelectionChange = (val: any[]) => {
|
||||
selectData.value = val.map(({ id }) => id)
|
||||
}
|
||||
selectData.value = val.map(({ id }) => id);
|
||||
};
|
||||
|
||||
// 获取字典数据
|
||||
const { dictData } = useDictData('')
|
||||
const { dictData } = useDictData("");
|
||||
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
fetchFun: apiOpurchaseclassLists,
|
||||
params: queryParams
|
||||
})
|
||||
fetchFun: apiOpurchaseclassLists,
|
||||
params: queryParams,
|
||||
});
|
||||
|
||||
// 添加
|
||||
const handleAdd = async () => {
|
||||
showEdit.value = true
|
||||
await nextTick()
|
||||
editRef.value?.open('add')
|
||||
}
|
||||
showEdit.value = true;
|
||||
await nextTick();
|
||||
editRef.value?.open("add");
|
||||
};
|
||||
|
||||
// 提交订单
|
||||
const submitOrder = async () => {
|
||||
apioperationOpurchaseclassAdd().then((res) => {
|
||||
ElMessage.success("提交成功");
|
||||
});
|
||||
};
|
||||
|
||||
// 打印订单
|
||||
const onPrintOrder = async () => {
|
||||
var someJSONdata = [
|
||||
{
|
||||
name: "John Doe",
|
||||
email: "john@doe.com",
|
||||
phone: "111-111-1111",
|
||||
},
|
||||
{
|
||||
name: "Barry Allen",
|
||||
email: "barry@flash.com",
|
||||
phone: "222-222-2222",
|
||||
},
|
||||
{
|
||||
name: "Cool Dude",
|
||||
email: "cool@dude.com",
|
||||
phone: "333-333-3333",
|
||||
},
|
||||
];
|
||||
print({
|
||||
printable: someJSONdata,
|
||||
type: "json",
|
||||
properties: [
|
||||
{ field: "name", displayName: "自定义表头" },
|
||||
{ field: "email", displayName: "自定义表头" },
|
||||
{ field: "phone", displayName: "自定义表头" },
|
||||
],
|
||||
maxWidth: 58,
|
||||
gridHeaderStyle: "color: red; border: 2px solid #3971A5;",
|
||||
gridStyle: "border: 2px solid #3971A5;",
|
||||
});
|
||||
};
|
||||
|
||||
// 详情
|
||||
const handleDetail = async (data: any) => {
|
||||
console.log(data);
|
||||
router.push({
|
||||
path: 'detail',
|
||||
query: {
|
||||
id: data.id
|
||||
}
|
||||
})
|
||||
}
|
||||
console.log(data);
|
||||
router.push({
|
||||
path: "detail",
|
||||
query: {
|
||||
id: data.id,
|
||||
},
|
||||
});
|
||||
};
|
||||
|
||||
// 编辑
|
||||
const handleEdit = async (data: any) => {
|
||||
showEdit.value = true
|
||||
await nextTick()
|
||||
editRef.value?.open('edit')
|
||||
editRef.value?.setFormData(data)
|
||||
}
|
||||
showEdit.value = true;
|
||||
await nextTick();
|
||||
editRef.value?.open("edit");
|
||||
editRef.value?.setFormData(data);
|
||||
};
|
||||
|
||||
// 删除
|
||||
const handleDelete = async (id: number | any[]) => {
|
||||
await feedback.confirm('确定要删除?')
|
||||
await apiOpurchaseclassDelete({ id })
|
||||
getLists()
|
||||
}
|
||||
await feedback.confirm("确定要删除?");
|
||||
await apiOpurchaseclassDelete({ id });
|
||||
getLists();
|
||||
};
|
||||
|
||||
getLists()
|
||||
getLists();
|
||||
</script>
|
||||
|
||||
|
|
|
@ -83,7 +83,7 @@
|
|||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
<pagination v-if="pager.lists" v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
<el-dialog v-model="dialogVisible" title="入库" width="600">
|
||||
<el-descriptions class="margin-top" :column="1" border>
|
||||
|
@ -131,6 +131,7 @@ const route = useRoute();
|
|||
const queryParams = reactive({
|
||||
id: route.query.id,
|
||||
is_adopt: "",
|
||||
is_mer: 2
|
||||
});
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
|
|
|
@ -0,0 +1,60 @@
|
|||
<template>
|
||||
<div>
|
||||
<el-button type="primary" @click="rePush" style="margin-bottom: 16px;"> 重新推送 </el-button>
|
||||
<el-table :data="pager.lists">
|
||||
<el-table-column
|
||||
label="商品名称"
|
||||
prop="goods_name"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="商品标签"
|
||||
prop="sys_labels_arr"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column label="单位" prop="unit_name" show-overflow-tooltip />
|
||||
<el-table-column label="单价(元)" prop="price" show-overflow-tooltip />
|
||||
<el-table-column prop="nums" label="数量" />
|
||||
<el-table-column prop="total" label="合计(元)" />
|
||||
<el-table-column label="备注" prop="data" show-overflow-tooltip />
|
||||
</el-table>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-if="pager.lists" v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup name="subOrder">
|
||||
import { usePaging } from "@/hooks/usePaging";
|
||||
import { useDictData } from "@/hooks/useDictOptions";
|
||||
import {
|
||||
apiOpurchaseinfoListList,
|
||||
apicreateSupplierGoods,
|
||||
} from "@/api/opurchaseclass";
|
||||
import { useRoute } from "vue-router";
|
||||
|
||||
const route = useRoute();
|
||||
|
||||
const queryParams = reactive({
|
||||
is_push: 0,
|
||||
id: route.query.id,
|
||||
is_mer: 2,
|
||||
sys_labels_arr: "",
|
||||
});
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
fetchFun: apiOpurchaseinfoListList,
|
||||
params: queryParams,
|
||||
});
|
||||
|
||||
defineExpose({
|
||||
getLists,
|
||||
});
|
||||
|
||||
// 获取字典数据
|
||||
const { dictData } = useDictData("pay_type,auditing_type");
|
||||
|
||||
const rePush = async () => {
|
||||
await apicreateSupplierGoods({ id: route.query.id });
|
||||
};
|
||||
</script>
|
|
@ -18,12 +18,14 @@
|
|||
/>
|
||||
<el-table-column label="操作" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button type="primary" @click="openDetail(row)" link>详情</el-button>
|
||||
<router-link :to="`/opurchase/detail?id=${row.id}`">
|
||||
<el-button type="primary" link>详情</el-button>
|
||||
</router-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
<pagination v-if="pager.lists" v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
<detail ref="detailRef" v-if="showDetail" :dictData="dictData"
|
||||
@close="showDetail = false"/>
|
||||
|
@ -41,6 +43,7 @@ const route = useRoute();
|
|||
|
||||
const queryParams = reactive({
|
||||
id: route.query.id,
|
||||
is_mer: 2
|
||||
});
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
|
|
|
@ -23,7 +23,11 @@
|
|||
{{ form.merchant_name }}
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
<el-table :data="form.goods_info" border style="width: 100%; margin-top: 20px">
|
||||
<el-table
|
||||
:data="form.goods_info"
|
||||
border
|
||||
style="width: 100%; margin-top: 20px"
|
||||
>
|
||||
<el-table-column prop="id" label="ID" width="120" />
|
||||
<el-table-column prop="goods_name" label="商品名称" />
|
||||
<el-table-column prop="price" label="单价(元)" />
|
||||
|
@ -33,24 +37,14 @@
|
|||
<el-table-column prop="nums_count" label="已采纳数量" />
|
||||
</el-table>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="子订单" name="order">
|
||||
<el-tab-pane label="商户订单" name="order">
|
||||
<subOrder ref="subOrderRef" />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="报价列表" name="offer">
|
||||
<goodsOffer ref="goodsOfferRef" />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="未推送商品" name="notPushedGoods">
|
||||
<el-button type="primary" @click="rePush">
|
||||
重新推送
|
||||
</el-button>
|
||||
<el-table :data="pager.lists">
|
||||
<el-table-column label="商品名称" prop="goods_name" show-overflow-tooltip />
|
||||
<el-table-column label="单位" prop="unit_name" show-overflow-tooltip />
|
||||
<el-table-column label="单价(元)" prop="price" show-overflow-tooltip />
|
||||
<el-table-column prop="nums" label="数量" />
|
||||
<el-table-column prop="total" label="合计(元)" />
|
||||
<el-table-column label="备注" prop="data" show-overflow-tooltip />
|
||||
</el-table>
|
||||
<noPush ref="noPushRef" />
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</el-card>
|
||||
|
@ -67,7 +61,7 @@ import {
|
|||
import { useRoute } from "vue-router";
|
||||
import subOrder from "./component/subOrder.vue";
|
||||
import goodsOffer from "./component/goodsOffer.vue";
|
||||
import { apiOpurchaseinfoListList, apicreateSupplierGoods } from "@/api/opurchaseclass";
|
||||
import noPush from "./component/noPush.vue";
|
||||
|
||||
const route = useRoute();
|
||||
const form = ref({});
|
||||
|
@ -91,28 +85,13 @@ getDetail();
|
|||
|
||||
const subOrderRef = ref(null);
|
||||
const goodsOfferRef = ref(null);
|
||||
const noPushRef = ref(null);
|
||||
const tabChange = (type: any) => {
|
||||
if (!activeMap.value.get(type)) {
|
||||
activeMap.value.set(type, true);
|
||||
if (type == "order") subOrderRef.value?.getLists();
|
||||
if (type == "offer") goodsOfferRef.value?.getLists();
|
||||
activeMap.value.set(type, true);
|
||||
if (type == "notPushedGoods") noPushRef.value?.getLists();
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
fetchFun: apiOpurchaseinfoListList,
|
||||
params: { is_push: 0, id: route.query.id },
|
||||
});
|
||||
|
||||
|
||||
const rePush = async () => {
|
||||
await apicreateSupplierGoods({ id: route.query.id })
|
||||
getLists()
|
||||
|
||||
}
|
||||
|
||||
// 获取字典数据
|
||||
|
||||
getLists()
|
||||
</script>
|
||||
|
|
|
@ -5,9 +5,9 @@
|
|||
<el-form-item label="所属商户" prop="merchant">
|
||||
<el-input class="w-[280px]" v-model="queryParams.merchant" clearable placeholder="请输入所属商户" />
|
||||
</el-form-item>
|
||||
<el-form-item label="零售订单id" prop="order_arr">
|
||||
<!-- <el-form-item label="零售订单id" prop="order_arr">
|
||||
<el-input class="w-[280px]" v-model="queryParams.order_arr" clearable placeholder="请输入零售订单id" />
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<!-- <el-form-item label="单据编号" prop="number">
|
||||
<el-input class="w-[280px]" v-model="queryParams.number" clearable placeholder="请输入单据编号" />
|
||||
</el-form-item> -->
|
||||
|
@ -35,7 +35,7 @@
|
|||
<el-table :data="pager.lists" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column label="ID" prop="id" show-overflow-tooltip />
|
||||
<!-- <el-table-column label="所属商户" prop="merchant_name" show-overflow-tooltip /> -->
|
||||
<el-table-column label="所属商户" prop="merchant_name" show-overflow-tooltip />
|
||||
<!-- <el-table-column label="零售订单id" prop="order_arr" show-overflow-tooltip /> -->
|
||||
<el-table-column label="购物车id" prop="cart_id" show-overflow-tooltip />
|
||||
<el-table-column label="单据编号" prop="number" width="220" show-overflow-tooltip />
|
||||
|
@ -43,7 +43,11 @@
|
|||
<el-table-column label="抵扣金额" prop="deduction_price" show-overflow-tooltip />
|
||||
<el-table-column label="实际金额" prop="actual" show-overflow-tooltip />
|
||||
<el-table-column label="实收金额" prop="money" show-overflow-tooltip />
|
||||
<el-table-column label="是否支付" prop="paid" show-overflow-tooltip />
|
||||
<el-table-column label="是否支付" prop="paid">
|
||||
<template #default="{ row }">
|
||||
<span>{{ row.paid ? '是' : '否' }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="120" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button type="primary" link @click="handleDetail(row)">
|
||||
|
@ -97,7 +101,8 @@ const showEdit = ref(false)
|
|||
const queryParams = reactive({
|
||||
merchant: '',
|
||||
order_arr: '',
|
||||
number: ''
|
||||
number: '',
|
||||
is_mer: 2 // 1是商户,2是平台
|
||||
})
|
||||
|
||||
// 选中数据
|
||||
|
|
Loading…
Reference in New Issue