add
This commit is contained in:
parent
801d2cb413
commit
55e5572005
|
@ -75,3 +75,7 @@ export const refundReasonListApi = (data) => {
|
|||
export const applyRefundApi = (data) => {
|
||||
return request.post('/order/order/apply_refund', data);
|
||||
}
|
||||
|
||||
export const UserProductStorageLogApi = (data) => {
|
||||
return request.get('/user_product_storage_log/UserProductStorageLog/lists', data);
|
||||
}
|
|
@ -63,14 +63,7 @@
|
|||
computed,
|
||||
nextTick,
|
||||
ref,
|
||||
|
||||
} from "vue"
|
||||
import {
|
||||
toast
|
||||
} from "../uni_modules/uview-plus";
|
||||
import {
|
||||
onShow
|
||||
} from '@dcloudio/uni-app';
|
||||
|
||||
const foucs1 = ref(null)
|
||||
const props = defineProps({
|
||||
|
@ -78,20 +71,17 @@
|
|||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
priceKey: {
|
||||
type: Object,
|
||||
default: () => ({})
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
const valChange = () => {
|
||||
uni.vibrateShort();
|
||||
}
|
||||
|
||||
let priceKey = ref({})
|
||||
if (uni.getStorageSync('PRICE_KEY')) {
|
||||
priceKey.value = JSON.parse(uni.getStorageSync('PRICE_KEY'));
|
||||
} else {
|
||||
priceKey.value = {};
|
||||
}
|
||||
|
||||
|
||||
const datas = ref({
|
||||
cart_num: ''
|
||||
});
|
||||
|
@ -121,7 +111,9 @@
|
|||
|
||||
const subtotal = computed(() => {
|
||||
let num = +datas.value.cart_num || 1;
|
||||
let sell = +datas.value[priceKey.value.off_activity == 1 ? priceKey.value.price : priceKey.value.op_price];
|
||||
let sell = +datas.value[props.priceKey.off_activity == 1 ? props.priceKey.price : props
|
||||
.priceKey
|
||||
.op_price];
|
||||
return Number(num * sell * 100 / 100).toFixed(2)
|
||||
})
|
||||
|
||||
|
|
|
@ -0,0 +1,137 @@
|
|||
<template>
|
||||
<up-sticky bgColor="#fff" style="padding: 20rpx;">
|
||||
<up-tabs :list="tabsLst" :itemStyle="{ width: '50vw', paddingBottom: '20rpx' }" lineColor='#50C758'
|
||||
:current='currentTab' @change="tabsChange"></up-tabs>
|
||||
</up-sticky>
|
||||
<view class="content" v-if="lists.length">
|
||||
<view class="card" v-for="(item,index) in lists" :key="item.id">
|
||||
<view class="head">
|
||||
<view class="">
|
||||
{{item.system_store_name}}
|
||||
</view>
|
||||
<view v-if="currentTab==0" style="text-decoration: underline;text-underline-offset: 5rpx;"
|
||||
@click="hdClick(item)">
|
||||
提货码
|
||||
</view>
|
||||
</view>
|
||||
<view class="card-li" v-if="currentTab==0">
|
||||
<text class="lab">预约时间:</text>{{item.times}}
|
||||
</view>
|
||||
<view class="card-li" v-if="currentTab==1">
|
||||
<text class="lab">提货时间:</text>{{item.update_time}}
|
||||
</view>
|
||||
<view class="card-li" style="display: flex;justify-content: space-between;">
|
||||
<view class="">
|
||||
<text class="lab">商品信息:</text>{{item.store_name}}
|
||||
</view>
|
||||
<view class="">
|
||||
x{{item.nums}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<up-empty v-else mode="history" style="margin-top: 20vh;" text='没有更多内容了'>
|
||||
</up-empty>
|
||||
|
||||
<view class="mask" v-if='showVerifyPop' @click="showVerifyPop=false">
|
||||
<view
|
||||
style="position: absolute;top: 50%;left: 50%;transform: translate(-50%,-50%);background-color: white;padding: 20rpx;">
|
||||
<up-image :src="orderData.verify_img" width="710rpx" height="105rpx"></up-image>
|
||||
<view style="font-weight: bold;color: #333;font-size: 26;text-align: center;margin-top: 20rpx;">
|
||||
提货码 {{orderData.verify_code}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
ref,
|
||||
reactive
|
||||
} from "vue"
|
||||
import {
|
||||
UserProductStorageLogApi
|
||||
} from "@/api/order.js"
|
||||
import useUserStore from "@/store/user";
|
||||
|
||||
const userStore = useUserStore().userInfo;
|
||||
const currentTab = ref(0)
|
||||
const showVerifyPop = ref(false)
|
||||
const orderData = reactive({})
|
||||
const tabsLst = reactive([{
|
||||
name: '已预约'
|
||||
},
|
||||
{
|
||||
name: '已提货'
|
||||
},
|
||||
|
||||
]);
|
||||
|
||||
const tabsChange = (e) => {
|
||||
currentTab.value = e.index
|
||||
getLists()
|
||||
}
|
||||
|
||||
|
||||
const lists = ref([{}])
|
||||
const getLists = async () => {
|
||||
let res = await UserProductStorageLogApi({
|
||||
uid: userStore.id,
|
||||
status: currentTab.value
|
||||
})
|
||||
lists.value = res.data.lists
|
||||
}
|
||||
|
||||
const hdClick = (item) => {
|
||||
orderData.verify_code = item.verify_code
|
||||
orderData.verify_img = item.verify_img
|
||||
showVerifyPop.value = true
|
||||
}
|
||||
|
||||
getLists()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
}
|
||||
|
||||
|
||||
.card {
|
||||
background-color: white;
|
||||
border-radius: 20rpx;
|
||||
// padding: 20rpx;
|
||||
margin-bottom: 20rpx;
|
||||
padding-bottom: 20rpx;
|
||||
|
||||
.head {
|
||||
background-color: #50C758;
|
||||
border-radius: 20rpx 20rpx 0 0;
|
||||
color: white;
|
||||
padding: 20rpx;
|
||||
font-size: 30rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.card-li {
|
||||
padding: 0 20rpx;
|
||||
margin-top: 10rpx;
|
||||
|
||||
.lab {
|
||||
color: #989898;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.mask {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
background-color: rgba(0, 0, 0, .5);
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 99999 !important;
|
||||
}
|
||||
</style>
|
File diff suppressed because it is too large
Load Diff
|
@ -245,10 +245,17 @@
|
|||
{
|
||||
"path": "asset/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "会员资产",
|
||||
"navigationBarTitleText": "用户资产",
|
||||
"enablePullDownRefresh": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "asset/lists",
|
||||
"style": {
|
||||
"navigationBarTitleText": "预约记录",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "Gifts/index",
|
||||
"style": {
|
||||
|
|
|
@ -168,15 +168,15 @@
|
|||
<view class="shop-content-li-r" style="color:#FC452F ;">¥<text
|
||||
style="font-size: 30rpx;">{{item[priceKey.price]}}</text>/{{ item.unit_name }}
|
||||
</view>
|
||||
<view class="tag">
|
||||
<view class="tag" v-if="item.tag">
|
||||
<view class="icon" />
|
||||
赠10%品牌礼品券
|
||||
{{item.tag}}
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view class="shop-content-li" style="color: #999999;" v-if="priceKey.off_activity==1">
|
||||
<view class="shop-content-li" style="color: #999999;" v-if="priceKey.off_activity==1">
|
||||
<view class="shop-content-li-l">原价</view>
|
||||
<view class="shop-content-li-r line-through">¥{{item[priceKey.op_price]}}</view>
|
||||
</view> -->
|
||||
</view>
|
||||
|
||||
<view class="shop-content-li" v-else>
|
||||
<view class="shop-content-li-l">售价</view>
|
||||
|
@ -231,7 +231,8 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<goodPopup ref="goodRef" :show="showGoodPopup" @close="showGoodPopup = false" @change="changeGood" />
|
||||
<goodPopup ref="goodRef" :priceKey='priceKey' :show="showGoodPopup" @close="showGoodPopup = false"
|
||||
@change="changeGood" />
|
||||
|
||||
<u-overlay :show="showOverlay" @click="showOverlay = false">
|
||||
<view class="warp">
|
||||
|
|
|
@ -118,6 +118,7 @@
|
|||
<up-cell-group>
|
||||
<!-- <up-cell v-if="userInfo.user_ship==1" title="赠品区" :isLink="true" url="/pageQuota/Gifts/index"></up-cell> -->
|
||||
<up-cell title="我的资产" :isLink="true" url="/pageQuota/asset/index"></up-cell>
|
||||
<up-cell title="预约记录" :isLink="true" url="/pageQuota/asset/lists"></up-cell>
|
||||
<up-cell title="我的地址" :isLink="true" url="/pagesOrder/addressList/addressList"></up-cell>
|
||||
<up-cell title="支付密码" :isLink="true" url="/pagesOrder/setPayPassword/index"></up-cell>
|
||||
</up-cell-group>
|
||||
|
|
Loading…
Reference in New Issue