Commit c5d47917 by zhangzhen

功能优化

parent c353695d
...@@ -49,7 +49,7 @@ http.interceptor.request = (config => { ...@@ -49,7 +49,7 @@ http.interceptor.request = (config => {
return config; return config;
}) })
http.interceptor.response = (config) => { http.interceptor.response = (config) => {
uni.hideLoading(); // uni.hideLoading();
// console.log(config.data, "请求结果") // console.log(config.data, "请求结果")
if (config.header && config.header["Access-Control-Expose-Headers"]) { if (config.header && config.header["Access-Control-Expose-Headers"]) {
......
...@@ -131,7 +131,7 @@ ...@@ -131,7 +131,7 @@
box-shadow: 0 4upx 8upx rgba(0, 0, 0, 0.1); box-shadow: 0 4upx 8upx rgba(0, 0, 0, 0.1);
border-radius: 12upx; border-radius: 12upx;
overflow: hidden; overflow: hidden;
margin-top: 24upx; // margin-top: 24upx;
padding: 20upx 0; padding: 20upx 0;
.room-img-box { .room-img-box {
......
...@@ -177,7 +177,7 @@ ...@@ -177,7 +177,7 @@
justify-content: center; justify-content: center;
align-items: center; align-items: center;
width: 60px; width: 60px;
height: 54px; height: 60px;
border-radius: 12px 0 0 12px; border-radius: 12px 0 0 12px;
// background: rgba(255, 255, 255, 0.72); // background: rgba(255, 255, 255, 0.72);
// border-top: 1px solid #E40583; // border-top: 1px solid #E40583;
......
...@@ -2,8 +2,8 @@ const CONFIG = { ...@@ -2,8 +2,8 @@ const CONFIG = {
// 开发环境配置 // 开发环境配置
development: { development: {
// assetsPath: 'https://www.coujio.com/wechat_static', // 静态资源路径 // assetsPath: 'https://www.coujio.com/wechat_static', // 静态资源路径
// assetsPath: 'https://coujiao.pseer.com/wechat_static', // 静态资源路径 assetsPath: 'https://coujiao.pseer.com/wechat_static', // 静态资源路径
assetsPath: 'http://10.24.5.167:8211/static', // 静态资源路径 // assetsPath: 'http://10.24.5.167:8211/static', // 静态资源路径
// baseUrl: 'https://www.coujio.com/front-api', // 后台接口请求地址 // baseUrl: 'https://www.coujio.com/front-api', // 后台接口请求地址
baseUrl: 'https://coujiao.pseer.com/front-api', // 后台接口请求地址 baseUrl: 'https://coujiao.pseer.com/front-api', // 后台接口请求地址
// baseUrl: 'http://10.24.3.185:8883/front-api', // baseUrl: 'http://10.24.3.185:8883/front-api',
......
...@@ -328,10 +328,16 @@ ...@@ -328,10 +328,16 @@
objListDate: [], objListDate: [],
timer2: null, timer2: null,
timerLocation: null, timerLocation: null,
storeNavBg:'rgba(255, 255, 255, 1)' storeNavBg:'rgba(255, 255, 255, 1)',
tempStoreInfo:{},
} }
}, },
onShow() { onShow() {
if(!this.storeInfo.id || this.storeInfo.id != uni.getStorageSync('storeId')){
uni.showLoading({
title:"加载中..."
})
}
this.onGetSysConfig(); this.onGetSysConfig();
this.onGetListStore(); this.onGetListStore();
this.timerLocation = setInterval(() => { this.timerLocation = setInterval(() => {
...@@ -457,7 +463,7 @@ ...@@ -457,7 +463,7 @@
obj = res.data.data[0]; obj = res.data.data[0];
uni.setStorageSync("storeId", obj.id); uni.setStorageSync("storeId", obj.id);
} }
that.storeInfo = { that.tempStoreInfo = {
...obj, ...obj,
distance: obj.distance ? Number(obj.distance.substr(0, 8)).toFixed(2) : 0 distance: obj.distance ? Number(obj.distance.substr(0, 8)).toFixed(2) : 0
} }
...@@ -478,6 +484,7 @@ ...@@ -478,6 +484,7 @@
getRoomList({ getRoomList({
storeId storeId
}).then(res => { }).then(res => {
uni.hideLoading();
if (res.data.code == 200 && res.data.data.length) { if (res.data.code == 200 && res.data.data.length) {
let list = res.data.data.map(item => { let list = res.data.data.map(item => {
let sortNum = 1; let sortNum = 1;
...@@ -520,6 +527,7 @@ ...@@ -520,6 +527,7 @@
}) })
list.sort((a, b) => a.sortNum - b.sortNum); list.sort((a, b) => a.sortNum - b.sortNum);
this.storeInfo = this.tempStoreInfo;
that.roomVoList = list; that.roomVoList = list;
let l = that.roomVoList.filter(item => item.sortNum === 1) let l = that.roomVoList.filter(item => item.sortNum === 1)
...@@ -530,9 +538,9 @@ ...@@ -530,9 +538,9 @@
} }
} else { } else {
this.storeInfo = this.tempStoreInfo;
that.roomVoList = [] that.roomVoList = []
} }
uni.hideLoading()
}) })
}, },
// 检查当前小时段是否被全部占用 true 完全占用 false 部分占用 // 检查当前小时段是否被全部占用 true 完全占用 false 部分占用
......
...@@ -304,14 +304,14 @@ ...@@ -304,14 +304,14 @@
<view class="flex-row time-box"> <view class="flex-row time-box">
<view class="part-1"> <view class="part-1">
<image :src="assetsPath+'/time_bg_icon.png'" mode="widthFix"></image> <!-- <image :src="assetsPath+'/time_bg_icon.png'" mode="widthFix"></image> -->
<view class="absolute"> <view class="absolute">
<text>{{formatAllData.startTime}}</text> <text>{{formatAllData.startTime}}</text>
</view> </view>
</view> </view>
<text></text> <text></text>
<view class="part-1"> <view class="part-1">
<image :src="assetsPath+'/time_bg_icon.png'" mode="widthFix"></image> <!-- <image :src="assetsPath+'/time_bg_icon.png'" mode="widthFix"></image> -->
<view class="absolute"> <view class="absolute">
<text>{{formatAllData.endTime}}</text> <text>{{formatAllData.endTime}}</text>
</view> </view>
...@@ -320,13 +320,13 @@ ...@@ -320,13 +320,13 @@
<view class="info flex-row-center"> <view class="info flex-row-center">
<text class="text-black text-bold text-lg">房间:</text> <text class="text-black text-bold text-lg">房间:</text>
<text class="text-pink margin-left text-lg ">{{roomInfo.name}}{{roomTypeEnum[roomInfo.roomType]}}</text> <text class=" margin-left text-lg ">{{roomInfo.name}}{{roomTypeEnum[roomInfo.roomType]}}</text>
</view> </view>
<view class="info flex-row-center"> <view class="info flex-row-center">
<text class="text-black text-bold text-lg">金额:</text> <text class="text-black text-bold text-lg">金额:</text>
<text class="margin-left text-pink text-lg"></text> <text class="margin-left text-lg"></text>
<text class="text-pink text-xl ">{{Number(computePriceInfo.payFee).toFixed(2)}}</text> <text class=" text-xl ">{{Number(computePriceInfo.payFee).toFixed(2)}}</text>
</view> </view>
</view> </view>
...@@ -2353,7 +2353,8 @@ ...@@ -2353,7 +2353,8 @@
.text-title{ .text-title{
font-weight: 600; font-weight: 600;
font-size: 36rpx; font-size: 36rpx;
color: #E03997; // color: #E03997;
color: #333333;
} }
} }
.time-box{ .time-box{
...@@ -2362,15 +2363,16 @@ ...@@ -2362,15 +2363,16 @@
justify-content: center; justify-content: center;
width: 100%; width: 100%;
align-items: center; align-items: center;
margin: 20upx 0; margin: 30upx 0;
.part-1{ .part-1{
position: relative; position: relative;
display: flex; display: flex;
flex: 1; flex: 1;
margin: 0 20upx; margin: 0 24upx;
height: 90upx;
image{ image{
width: 100%; width: 100%;
height: 104upx; height: 100%;
} }
.absolute{ .absolute{
position: absolute; position: absolute;
...@@ -2381,10 +2383,13 @@ ...@@ -2381,10 +2383,13 @@
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
border: 6upx solid #E03997;
border-radius: 47upx;
text{ text{
font-weight: 600; font-weight: 600;
font-size: 60upx; font-size: 60upx;
color: #333333; // color: #333333;
color: #E03997;
} }
} }
} }
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
</view> </view>
<view class="VerticalBox" :style="{paddingTop:CustomBar+50+'px'}"> <view class="VerticalBox" :style="{paddingTop:CustomBar+50+'px'}">
<view class="banner2"> <view class="banner2">
<image :src="assetsPath+'/banner2.png'" mode="widthFix"></image> <image :src="assetsPath+'/banner3.png'" mode="widthFix"></image>
</view> </view>
<view class="room-content-box"> <view class="room-content-box">
<!-- 展示所有房间列表 --> <!-- 展示所有房间列表 -->
...@@ -196,7 +196,7 @@ ...@@ -196,7 +196,7 @@
} }
.banner2 { .banner2 {
width: 674upx; width: 674upx;
margin: -12upx auto 0; margin: 12px auto 0;
image { image {
display: block; display: block;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment