2023-09-19 02:50:09 +00:00
|
|
|
|
|
|
|
|
|
|
|
<template>
|
2023-09-20 11:59:14 +00:00
|
|
|
<view :style="{background:'url('+'../../static/bbj1@3x.png'+')'}" class="main">
|
2023-09-22 07:39:58 +00:00
|
|
|
<title-block style="flex-shrink: 0;width: 100%" title="寄存"></title-block>
|
2023-09-22 06:35:58 +00:00
|
|
|
<view class="order" @click="goConsignmen">
|
2023-09-20 11:59:14 +00:00
|
|
|
<view class="order-item">
|
|
|
|
<image src="@/static/image/write.png" mode="scaleToFill" style="width: 63rpx;height: 62rpx" />
|
|
|
|
<view style="color: #fff;margin-top:10rpx">填写下单</view>
|
|
|
|
</view>
|
2023-09-23 07:01:34 +00:00
|
|
|
<view class="order-item" style="background:#76C458;" @click.stop="scanOrder">
|
2023-09-20 11:59:14 +00:00
|
|
|
<image src="@/static/image/scan.png" mode="scaleToFill" style="width: 57rpx;height: 57rpx" />
|
2023-09-23 07:01:34 +00:00
|
|
|
<view style="color: #fff;margin-top:10rpx">扫码下单</view>
|
2023-09-20 11:59:14 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="list">
|
|
|
|
<view style="color: #76C458">目前可用寄存仓库地址</view>
|
|
|
|
<u-divider :dashed="true" lineColor="#4E964D"></u-divider>
|
2023-09-22 06:35:58 +00:00
|
|
|
<view v-for="(item,index) in addressList" :key="item.ID">
|
|
|
|
<view class="list-item">
|
|
|
|
<view>{{item.address}}</view>
|
|
|
|
<view>剩余{{item.deletedAt}}位置</view>
|
|
|
|
</view>
|
|
|
|
<u-divider :dashed="true" lineColor="#4E964D" v-if="index !== addressList.length-1"></u-divider>
|
2023-09-20 11:59:14 +00:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<tabbar :current="0"></tabbar>
|
|
|
|
</view>
|
2023-09-19 02:50:09 +00:00
|
|
|
</template>
|
|
|
|
<script>
|
2023-09-20 11:59:14 +00:00
|
|
|
import tabbar from "../../components/uiq-tabbar/uiq-tabbar.vue";
|
2023-09-19 02:50:09 +00:00
|
|
|
|
|
|
|
export default {
|
|
|
|
name: "index",
|
|
|
|
onLoad() {
|
2023-09-20 11:59:14 +00:00
|
|
|
uni.hideTabBar();
|
2023-09-19 02:50:09 +00:00
|
|
|
},
|
2023-09-22 06:35:58 +00:00
|
|
|
onShow() {
|
|
|
|
this.getAddress();
|
|
|
|
},
|
2023-09-20 11:59:14 +00:00
|
|
|
components: {
|
2023-09-19 02:50:09 +00:00
|
|
|
tabbar
|
2023-09-20 11:59:14 +00:00
|
|
|
},
|
2023-09-22 06:35:58 +00:00
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
addressList: []
|
|
|
|
};
|
|
|
|
},
|
2023-09-20 11:59:14 +00:00
|
|
|
methods: {
|
|
|
|
scanOrder() {
|
|
|
|
uni.scanCode({
|
|
|
|
onlyFromCamera: false,
|
|
|
|
success: res => {
|
|
|
|
console.log("条码类型:" + res.scanType);
|
|
|
|
console.log("条码内容:" + res.result);
|
2023-09-22 06:35:58 +00:00
|
|
|
uni.navigateTo({
|
|
|
|
url: "/pages/consignment-painting/index?url=" + res.result
|
|
|
|
});
|
2023-09-20 11:59:14 +00:00
|
|
|
}
|
|
|
|
});
|
2023-09-22 06:35:58 +00:00
|
|
|
},
|
|
|
|
async getAddress() {
|
|
|
|
const res = await this.$api.deposit.address();
|
|
|
|
console.log(res);
|
|
|
|
if (res.status === 0) {
|
|
|
|
this.addressList = res.data.data;
|
|
|
|
} else {
|
|
|
|
this.$common.msgToast(res.msg);
|
|
|
|
}
|
|
|
|
},
|
|
|
|
goConsignmen() {
|
|
|
|
uni.navigateTo({
|
|
|
|
url: "/pages/consignment-painting/index"
|
|
|
|
});
|
2023-09-20 11:59:14 +00:00
|
|
|
}
|
2023-09-19 02:50:09 +00:00
|
|
|
}
|
2023-09-20 11:59:14 +00:00
|
|
|
};
|
2023-09-19 02:50:09 +00:00
|
|
|
</script>
|
|
|
|
<style scoped lang="scss">
|
2023-09-20 11:59:14 +00:00
|
|
|
.main {
|
|
|
|
box-sizing: border-box;
|
|
|
|
height: 100vh;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
align-items: center;
|
2023-09-23 06:59:54 +00:00
|
|
|
padding: 0 30rpx;
|
2023-09-22 07:00:26 +00:00
|
|
|
|
2023-09-20 11:59:14 +00:00
|
|
|
.order {
|
|
|
|
width: 100%;
|
|
|
|
margin-top: 40rpx;
|
|
|
|
display: flex;
|
|
|
|
justify-content: space-between;
|
|
|
|
.order-item {
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
justify-content: center;
|
|
|
|
align-items: center;
|
|
|
|
width: 330rpx;
|
|
|
|
height: 208rpx;
|
|
|
|
border-radius: 20rpx;
|
|
|
|
background: #4e964d;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
.list {
|
|
|
|
margin-top: 40rpx;
|
|
|
|
width: 100%;
|
|
|
|
border-radius: 20rpx;
|
|
|
|
box-sizing: border-box;
|
|
|
|
padding: 12rpx 20rpx;
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
background: #fff;
|
|
|
|
font-size: 24rpx;
|
|
|
|
.list-item {
|
|
|
|
width: 100%;
|
|
|
|
display: flex;
|
|
|
|
justify-content: space-between;
|
|
|
|
color: #939393;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2023-09-19 02:50:09 +00:00
|
|
|
</style>
|