二维码修改 售后修改

This commit is contained in:
1154079537 2024-06-12 17:54:00 +08:00
parent 173e7051f1
commit a9071886cc
6 changed files with 114 additions and 119 deletions

View File

@ -4,7 +4,8 @@
<view v-if="nav" style="width: 100%;background-color: #fff;" :style="{height: height + 'px'}"></view> <view v-if="nav" style="width: 100%;background-color: #fff;" :style="{height: height + 'px'}"></view>
<!-- #endif --> <!-- #endif -->
<!-- #ifndef MP-WEIXIN --> <!-- #ifndef MP-WEIXIN -->
<view v-if="nav" style="width: 100%;height: calc( var(--status-bar-height) + 44px );background-color: #fff;"></view> <view v-if="nav" style="width: 100%;height: calc( var(--status-bar-height) + 44px );background-color: #fff;">
</view>
<!-- #endif --> <!-- #endif -->
<view class="center"> <view class="center">
<slot></slot> <slot></slot>
@ -17,7 +18,9 @@
</template> </template>
<script setup> <script setup>
import { ref } from "vue" import {
ref
} from "vue"
const props = defineProps({ const props = defineProps({
nav: { nav: {
@ -68,7 +71,7 @@
position: absolute; position: absolute;
top: 0; top: 0;
left: 0; left: 0;
z-index: 10; z-index: 11;
.center { .center {
animation: slideDown 0.3s forwards; animation: slideDown 0.3s forwards;

View File

@ -27,7 +27,7 @@
<text class="goods_name">{{item.store_name}}</text> <text class="goods_name">{{item.store_name}}</text>
</view> </view>
<view class="afterSales-goods-right-info"> <view class="afterSales-goods-right-info">
<text class="goods_desc">牛腩块</text> <text class="goods_desc">{{item.unit || ''}}</text>
</view> </view>
</view> </view>
</view> </view>
@ -83,7 +83,7 @@
onLoad(() => { onLoad(() => {
const eventChannel = instance.getOpenerEventChannel(); const eventChannel = instance.getOpenerEventChannel();
eventChannel.on('afterSalesOrderDetail', function(data) { eventChannel.on('afterSalesDetail', function(data) {
shopInfo.value = data; shopInfo.value = data;
console.log(shopInfo.value); console.log(shopInfo.value);
}) })

View File

@ -274,6 +274,7 @@
const searchKeyword = () => { const searchKeyword = () => {
where.value.name = keyword.value; where.value.name = keyword.value;
where.value.store_name = keyword.value;
getGoodList(); getGoodList();
} }
@ -287,6 +288,7 @@
page_size: 25, page_size: 25,
name: '', name: '',
order: '', order: '',
store_name: '',
store_id: STORE_INFO.id || '' store_id: STORE_INFO.id || ''
}) })
@ -307,7 +309,8 @@
goodListApi({ goodListApi({
...where.value, ...where.value,
class_all: class_all, class_all: class_all,
class: class_id class: class_id,
cate_id: class_id,
}).then(res => { }).then(res => {
if (loadmore) goodList.value.push(...res.data.lists); if (loadmore) goodList.value.push(...res.data.lists);
else goodList.value = res.data.lists; else goodList.value = res.data.lists;
@ -427,8 +430,6 @@
}) })
} }
// uni.setStorageSync()
// //
const showGoodPopup = ref(false); const showGoodPopup = ref(false);
const goodRef = ref(null); const goodRef = ref(null);
@ -517,16 +518,14 @@
const instance = getCurrentInstance(); // const instance = getCurrentInstance(); //
const getWXDom = () => { const getWXDom = () => {
let query = uni.createSelectorQuery().in(instance).select("#drag_area"); let query = uni.createSelectorQuery().in(instance).select("#drag_area");
query query.fields({
.fields({
size: true, size: true,
scrollOffset: true, scrollOffset: true,
}, },
(data) => { (data) => {
targetHeight.value = data.scrollHeight - data.height targetHeight.value = data.scrollHeight - data.height
} }
) ).exec();
.exec();
} }
setTimeout(() => { setTimeout(() => {
getWXDom() getWXDom()

View File

@ -82,9 +82,8 @@
</view> </view>
<view class="qr_code" v-if="datas.paid == 1 && datas.status == 1"> <view class="qr_code" v-if="datas.paid == 1 && datas.status == 1">
<w-barcode :options="options"></w-barcode> <up-image :src="datas.verify_img" width="404rpx" height="60rpx"></up-image>
<!-- <QRCode :val="datas.verify_code" :size="150"></QRCode> --> <view style="font-weight: bold;color: #333;font-size: 26;margin-top: 20rpx;">
<view style="font-weight: bold;color: #333;font-size: 26;">
核销码 {{datas.verify_code}} 核销码 {{datas.verify_code}}
</view> </view>
</view> </view>
@ -196,7 +195,6 @@
import orderCanclePopup from "@/components/orderCanclePopup.vue"; import orderCanclePopup from "@/components/orderCanclePopup.vue";
import shopListPopupVue from "@/components/shopListPopup.vue"; import shopListPopupVue from "@/components/shopListPopup.vue";
import modal from "@/components/modal.vue"; import modal from "@/components/modal.vue";
// import QRCode from "@/uni_modules/uview-plus/components/u-qrcode/u-qrcode.vue";
import { import {
orderDetailApi, orderDetailApi,
cancelOrderApi, cancelOrderApi,
@ -242,9 +240,7 @@
order_id: datas.value.id order_id: datas.value.id
}).then(res => { }).then(res => {
datas.value = res.data; datas.value = res.data;
options.code = datas.value.verify_code; // options.code = datas.value.verify_code; //
shopInfo.value = res.data.store_info; shopInfo.value = res.data.store_info;
if (addressList.value.length > 0 && res.data.paid) { if (addressList.value.length > 0 && res.data.paid) {
addressInfo.value = addressList.value.find(item => item.address_id == res.data.address_id); addressInfo.value = addressList.value.find(item => item.address_id == res.data.address_id);
@ -504,13 +500,9 @@
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
height: 500rpx; height: 300rpx;
background: #fff; background: #fff;
border-radius: 5px; border-radius: 5px;
view {
margin-top: 44rpx;
}
} }
.m-address { .m-address {
@ -557,7 +549,6 @@
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
color: #989898; color: #989898;
// background-color: red;
.title { .title {
display: flex; display: flex;

View File

@ -53,8 +53,9 @@
@click="rePay">立即支付</up-button></view> @click="rePay">立即支付</up-button></view>
</view> </view>
<view v-else class="item-btn"> <view v-else class="item-btn">
<view @click="showVerifyPop=true,options.code=datas.verify_code" v-if="datas.status==1" <view @click="showVerifyPop=true,options.code=datas.verify_img" v-if="datas.status==1" style="width: 80px;">
style="width: 80px;"><up-button size="small" plain color="#20B128" shape="circle">核销码</up-button></view> <up-button size="small" plain color="#20B128" shape="circle">核销码</up-button>
</view>
<view @click="purchaseAgain" v-if="datas.status==2||datas.status==3" style="width: 80px;"><up-button <view @click="purchaseAgain" v-if="datas.status==2||datas.status==3" style="width: 80px;"><up-button
size="small" plain color="#20B128" shape="circle">再次购买</up-button></view> size="small" plain color="#20B128" shape="circle">再次购买</up-button></view>
<view @click="navTo" style="width: 80px;"><up-button size="small" plain color="#20B128" <view @click="navTo" style="width: 80px;"><up-button size="small" plain color="#20B128"
@ -68,16 +69,14 @@
<up-popup :show="showVerifyPop" @close="showVerifyPop=false" @open="showVerifyPop=true" mode="center"> <up-popup :show="showVerifyPop" @close="showVerifyPop=false" @open="showVerifyPop=true" mode="center">
<view style="width: 80vw;height: 20vh;position: relative;"> <view style="width: 80vw;height: 20vh;position: relative;">
<view style="position: absolute;top: 50%;left: 50%;transform: translate(-50%,-50%);"> <view style="position: absolute;top: 50%;left: 50%;transform: translate(-50%,-50%);">
<w-barcode v-if='options.code' :options="options"></w-barcode> <up-image :src="datas.verify_img" width="404rpx" height="60rpx"></up-image>
<view style="font-weight: bold;color: #333;font-size: 26;text-align: center;"> <view style="font-weight: bold;color: #333;font-size: 26;text-align: center;margin-top: 20rpx;">
核销码 {{datas.verify_code}} 核销码 {{datas.verify_code}}
</view> </view>
</view> </view>
</view> </view>
</up-popup> </up-popup>
</view> </view>
</template> </template>
<script setup> <script setup>
@ -107,9 +106,12 @@
}) })
const navTo = () => { const navTo = () => {
if (props.status == 4) { if (props.datas.status == -1) {
uni.navigateTo({ uni.navigateTo({
url: "/pages/afterSales/afterSalesOrderDetail?id=" + props.datas.id url: "/pages/afterSales/afterSalesOrderDetail",
success(res) {
res.eventChannel.emit('afterSalesDetail', props.datas)
}
}) })
} else { } else {
uni.navigateTo({ uni.navigateTo({

View File

@ -21,7 +21,7 @@
refresher-background="#F6F6F6"> refresher-background="#F6F6F6">
<view class="page-box"> <view class="page-box">
<view v-if="list.length>0" class="list"> <view v-if="list.length>0" class="list">
<good v-for="(item, index) in list" :datas="item" :key="index" :type="k" <good v-for="(item, index) in list" :datas="item" :key="index" :type="k" :status="status"
:order_id='item.order_id' @cancleOrder="cancleOrder" @takeOrder="takeOrder" :order_id='item.order_id' @cancleOrder="cancleOrder" @takeOrder="takeOrder"
@rePay="rePay" @purchaseAgain="purchaseAgain" @applyAfterSales="applyAfterSales"></good> @rePay="rePay" @purchaseAgain="purchaseAgain" @applyAfterSales="applyAfterSales"></good>
</view> </view>