修复了开发环境下的URL配置,并添加了支付状态查询API,商品规格显示,以及预约取货功能。

This commit is contained in:
mkm 2024-07-31 12:07:16 +08:00
parent 0cd6ce7a25
commit f260d52b73
4 changed files with 44 additions and 18 deletions

View File

@ -1,8 +1,8 @@
VITE_NOW_TYPE = 'dist'
# VITE_PUSH_URL = 'ws://192.168.1.201:8787'
# VITE_BASE_URL = 'http://192.168.1.201:8545'
#VITE_PUSH_URL = 'wss://ceshi-multi-store.lihaink.cn/pull'
#VITE_BASE_URL = 'https://ceshi-multi-store.lihaink.cn'
# VITE_PUSH_URL = 'ws://192.168.1.22:8787'
# VITE_BASE_URL = 'http://192.168.1.22:8545'

View File

@ -219,3 +219,10 @@ export function userProductStorageApi(data) {
export function userProductStorageSupplyApi(data) {
return request.post(`/user_product_storage/UserProductStorage/supply`, data)
}
/**
* @description 支付状态查询
*/
export function storeOrderQueryApi(data) {
return request.get(`/store_order/StoreOrder/wechatQuery`, { params: data })
}

View File

@ -234,6 +234,7 @@ onUnmounted(() => {
</div>
</template>
</el-table-column>
<el-table-column prop="cart_info.store_info" label="商品规格" width="150" />
<el-table-column prop="cart_info.price" label="单价" width="150" />
<el-table-column prop="cart_info.cart_num" label="数量" width="150" />
<el-table-column prop="cart_info.pay_price" label="总价" width="150">

View File

@ -6,7 +6,8 @@ import {
orderLadingApi,
cartListApi,
cashierinfoListApi,
cashierinfoDetailsApi
cashierinfoDetailsApi,
storeOrderQueryApi
} from "@/api/store.js";
import { useUserStore } from "@/store/user.js";
import { ElMessage } from "element-plus";
@ -59,6 +60,19 @@ const rePay = () => {
});
payRef.value.drawer = true;
};
const query = () => {
if (formData.value.order_id) {
storeOrderQueryApi({ 'order_no': formData.value.order_id }).then(res => {
console.log(res)
})
}else{
ElMessage({
message: '订单号不能为空',
type: "error",
});
}
};
const getOrderStatus = (id) => {
orderStatusApi({
@ -224,11 +238,13 @@ onUnmounted(() => {
<el-table-column label="商品信息">
<template #default="{ row }">
<div style="display: flex; align-items: center">
<el-image style="height: 3rem; width: 3rem;flex-shrink: 0;" :src="row.cart_info?.image"></el-image>
<el-image style="height: 3rem; width: 3rem;flex-shrink: 0;"
:src="row.cart_info?.image"></el-image>
<span style="margin-left: 0.5rem">{{ row.cart_info?.name }}</span>
</div>
</template>
</el-table-column>
<el-table-column prop="cart_info.store_info" label="商品规格" width="150" />
<el-table-column prop="cart_info.price" label="单价" width="150" />
<el-table-column prop="cart_info.cart_num" label="数量" width="150" />
<el-table-column prop="cart_info.pay_price" label="总价" width="150">
@ -238,6 +254,7 @@ onUnmounted(() => {
</div>
<div class="footer" v-if="!formData.paid">
<el-button type="primary" size="large" @click="rePay">重新支付</el-button>
<el-button type="primary" size="large" @click="query" v-if="formData.pay_type == 9">查询支付</el-button>
</div>
</div>
<div v-else>
@ -295,6 +312,7 @@ onUnmounted(() => {
}
}
}
.footer {
position: absolute;
bottom: 0;