This commit is contained in:
ylj20011123 2025-06-26 11:38:20 +08:00
parent 4199dd82ec
commit c0b8102e2d
85 changed files with 1867 additions and 1124 deletions

View File

@ -1034,24 +1034,26 @@ export default {
let storgeList = uni.getStorageSync("allServiceList"); let storgeList = uni.getStorageSync("allServiceList");
if (storgeList) { // if (storgeList) {
serviceList = storgeList; // serviceList = storgeList;
} else { // } else {
let req = { console.log('this.startObjthis.startObjthis.startObj', this.startObj);
Province_Code: "340000",
longitude: this.seatInfo.longitude || "",
latitude: this.seatInfo.latitude || "",
ShowService: true,
};
// let serviceArea = await this.$api.$get(
// "/CommercialApi/BaseInfo/GetServerpartList",
// req
// );
let serviceArea = await this.$api.$javaGet2('/third-party/getServerPartList', req) let req = {
serviceList = serviceArea.Result_Data.List; Province_Code: "340000",
uni.setStorageSync("serviceList", JSON.stringify(serviceList)); longitude: this.startObj.longitude || this.seatInfo.longitude || "",
} latitude: this.startObj.latitude || this.seatInfo.latitude || "",
ShowService: true,
};
// let serviceArea = await this.$api.$get(
// "/CommercialApi/BaseInfo/GetServerpartList",
// req
// );
let serviceArea = await this.$api.$javaGet2('/third-party/getServerPartList', req)
serviceList = serviceArea.Result_Data.List;
// uni.setStorageSync("serviceList", JSON.stringify(serviceList));
// }

View File

@ -35,10 +35,12 @@
<image class="searchIcon" src="https://eshangtech.com/wanmeiyizhanImg/home/searchIcon.png" /> <image class="searchIcon" src="https://eshangtech.com/wanmeiyizhanImg/home/searchIcon.png" />
<input class="inputBox" placeholder="请输入物品信息" style="font-size: 28rpx" v-model="searchText" confirm-type="send" <input class="inputBox" placeholder="请输入物品信息" style="font-size: 28rpx" v-model="searchText" confirm-type="send"
@focus="clickSearch" @blur="noClickSearch" @confirm="handleEntrySearch" /> @focus="clickSearch" @blur="noClickSearch" @confirm="handleEntrySearch" />
<image class="closeIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/close.svg"
@click="handleClearSearch" />
<!-- <image class="searchIcon" src="https://eshangtech.com/wanmeiyizhanImg/home/searchIcon.png" /> <!-- <image class="searchIcon" src="https://eshangtech.com/wanmeiyizhanImg/home/searchIcon.png" />
<span class="searchText">请输入服务区</span> --> <span class="searchText">请输入服务区</span> -->
</div> </div>
<div class="searchBtn" v-if="showSearchBtn" @click="handleGetListData"> <div class="searchBtn" v-if="showSearchBtn" @click="handleClickSearch">
搜索 搜索
</div> </div>
<!-- <div class="filterBox" @click="showFilter" style="margin-left: 8px"> <!-- <div class="filterBox" @click="showFilter" style="margin-left: 8px">
@ -334,6 +336,17 @@ export default {
} }
}, },
methods: { methods: {
//
handleClearSearch() {
this.searchText = ""
this.dataList = [];
this.pageObj = {
pageIndex: 1,
pageSize: 10,
isOver: false,
};
this.handleGetListData();
},
// //
handlePriviewImgList(url, list) { handlePriviewImgList(url, list) {
let urlList = [] let urlList = []
@ -471,6 +484,15 @@ export default {
this.handleClosePopup(); this.handleClosePopup();
this.handleGetListData(); this.handleGetListData();
}, },
handleClickSearch() {
this.dataList = [];
this.pageObj = {
pageIndex: 1,
pageSize: 10,
isOver: false,
};
this.handleGetListData()
},
// //
async handleGetListData() { async handleGetListData() {
this.isLoading = true; this.isLoading = true;
@ -508,6 +530,9 @@ export default {
oldList = JSON.parse(JSON.stringify(this.dataList)); oldList = JSON.parse(JSON.stringify(this.dataList));
} }
console.log('oldListoldListoldListoldList', JSON.parse(JSON.stringify(oldList)));
let list = data.Result_Data.List; let list = data.Result_Data.List;
if (list && list.length > 0) { if (list && list.length > 0) {
if (list.length < this.pageObj.pageSize) { if (list.length < this.pageObj.pageSize) {
@ -527,6 +552,7 @@ export default {
} else { } else {
this.pageObj.isOver = true; this.pageObj.isOver = true;
} }
console.log('listlistlistlistlistlistlistlist', JSON.parse(JSON.stringify(list)));
this.dataList = oldList.concat(list); this.dataList = oldList.concat(list);
this.isLoading = false; this.isLoading = false;
}, },
@ -554,7 +580,7 @@ export default {
// //
noClickSearch() { noClickSearch() {
this.showSearchBtn = false; this.showSearchBtn = false;
this.handleGetListData() // this.handleGetListData()
}, },
// //
handleCallPhone(obj) { handleCallPhone(obj) {
@ -727,6 +753,12 @@ export default {
// width: calc(100% - 160rpx); // width: calc(100% - 160rpx);
} }
.closeIcon {
width: 36rpx;
height: 36rpx;
margin-left: 10rpx;
}
.searchText { .searchText {
font-family: PingFangSC, PingFang SC; font-family: PingFangSC, PingFang SC;
font-weight: 400; font-weight: 400;

View File

@ -273,28 +273,32 @@ export default {
// _this.$utils.qrc('qrcode2', code, _this.qrcodeHeight2, _this.qrcodeHeight2, null, '../../..https://eshangtech.com/wanmeiyizhanImg/gsuyiw.png') // _this.$utils.qrc('qrcode2', code, _this.qrcodeHeight2, _this.qrcodeHeight2, null, '../../..https://eshangtech.com/wanmeiyizhanImg/gsuyiw.png')
_this.showCode = code.substring(0, 4) + " " + "*".repeat("6"); _this.showCode = code.substring(0, 4) + " " + "*".repeat("6");
wx.canvasToTempFilePath({ setTimeout(() => {
canvasId: "barcode", wx.canvasToTempFilePath({
success: (res) => { canvasId: "barcode",
console.log("barcode", res); success: (res) => {
// this.setData({ console.log("barcode", res);
// qrCodeImage: res.tempFilePath, // // this.setData({
// }); // qrCodeImage: res.tempFilePath, //
_this.barcodeImg = res.tempFilePath; // });
_this.$forceUpdate(); _this.barcodeImg = res.tempFilePath;
}, _this.$forceUpdate();
}); },
wx.canvasToTempFilePath({ });
canvasId: "qrcode", wx.canvasToTempFilePath({
success: (res) => { canvasId: "qrcode",
console.log("barcode", res); success: (res) => {
// this.setData({ console.log("barcode", res);
// qrCodeImage: res.tempFilePath, // // this.setData({
// }); // qrCodeImage: res.tempFilePath, //
_this.qrcodeImg = res.tempFilePath; // });
_this.$forceUpdate(); _this.qrcodeImg = res.tempFilePath;
}, _this.$forceUpdate();
}); },
});
}, 300)
_this.$forceUpdate(); _this.$forceUpdate();
_this.timer = setInterval(function () { _this.timer = setInterval(function () {

View File

@ -3,13 +3,8 @@
<div class="content"> <div class="content">
<div class="contentTop"> <div class="contentTop">
<span class="title">您对商家/菜品满意吗</span> <span class="title">您对商家/菜品满意吗</span>
<radio <radio class="anonymous" color="#CAA97F" @click="isAnonymous($event, saveMsg)" :checked="saveMsg.isAnonymous">
class="anonymous" 匿名评价</radio>
color="#CAA97F"
@click="isAnonymous($event, saveMsg)"
:checked="saveMsg.isAnonymous"
>匿名评价</radio
>
<!-- <checkbox <!-- <checkbox
class="anonymous" class="anonymous"
:checked="saveMsg.isAnonymous" :checked="saveMsg.isAnonymous"
@ -20,46 +15,29 @@
</checkbox> --> </checkbox> -->
</div> </div>
<div class="starRate"> <div class="starRate">
<image <image class="shopImg" mode="aspectFit" lazy-load="true" :src="saveMsg.merchantsId
class="shopImg" ? storeMsg.MERCHANTS_LOGO ||
mode="aspectFit" 'https://eshangtech.com/ShopICO/no-picture.png'
lazy-load="true" : storeMsg.MERCHANTS_LOGO ||
:src=" 'https://eshangtech.com/ShopICO/no-picture.png'
saveMsg.merchantsId " />
? storeMsg.MERCHANTS_LOGO ||
'https://eshangtech.com/ShopICO/no-picture.png'
: storeMsg.MERCHANTS_LOGO ||
'https://eshangtech.com/ShopICO/no-picture.png'
"
/>
<div class="rateBox"> <div class="rateBox">
<div class="shopName"> <div class="shopName">
{{ {{
saveMsg.merchantsId saveMsg.merchantsId
? storeMsg.MERCHANTS_EN || "-" ? storeMsg.MERCHANTS_NAME || storeMsg.MERCHANTS_EN || "-"
: proMsg.COMMODITY_NAME || "-" : proMsg.COMMODITY_NAME || "-"
}} }}
</div> </div>
<uni-rate <uni-rate :size="24" allowHalf v-model="saveMsg.commentScore" @change="changeRate($event, saveMsg)" />
:size="24"
allowHalf
v-model="saveMsg.commentScore"
@change="changeRate($event, saveMsg)"
/>
</div> </div>
</div> </div>
<div class="textBox"> <div class="textBox">
<textarea <textarea cols="30" rows="5" :placeholder="saveMsg.merchantsId
cols="30" ? '说说这家店的口味、环境、服务'
rows="5" : '商品满足你的期待吗?说说你的使用心得,分享给想买的他们吧'
:placeholder=" " v-model="saveMsg.commentContent"></textarea>
saveMsg.merchantsId
? '说说这家店的口味、环境、服务'
: '商品满足你的期待吗?说说你的使用心得,分享给想买的他们吧'
"
v-model="saveMsg.commentContent"
></textarea>
<view class="tip-text"> 评价文字不可少于3字 </view> <view class="tip-text"> 评价文字不可少于3字 </view>
<view class="photo-box"> <view class="photo-box">
@ -76,16 +54,9 @@
</div> </div>
<!-- 提交按钮 --> <!-- 提交按钮 -->
<div <div class="submitBox" :class="{ active: saveMsg.commentContent.length > 2 && noPost }">
class="submitBox" <div :class="saveMsg.commentContent.length > 2 && noPost ? 'submit' : 'post-btn'
:class="{ active: saveMsg.commentContent.length > 2 && noPost }" " @click="postRate">
>
<div
:class="
saveMsg.commentContent.length > 2 && noPost ? 'submit' : 'post-btn'
"
@click="postRate"
>
提交 提交
</div> </div>
</div> </div>
@ -93,46 +64,27 @@
<view class="card" v-if="false"> <view class="card" v-if="false">
<view class="store-title"> <view class="store-title">
<view v-if="saveMsg.merchantsId"> <view v-if="saveMsg.merchantsId">
<image <image mode="aspectFit" lazy-load="true" :src="storeMsg.MERCHANTS_LOGO ||
mode="aspectFit" 'https://eshangtech.com/ShopICO/no-picture.png'
lazy-load="true" "></image>
:src="
storeMsg.MERCHANTS_LOGO ||
'https://eshangtech.com/ShopICO/no-picture.png'
"
></image>
<text class="name">{{ storeMsg.MERCHANTS_EN }}</text> <text class="name">{{ storeMsg.MERCHANTS_EN }}</text>
</view> </view>
<view v-else> <view v-else>
<image <image mode="aspectFit" lazy-load="true" :src="proMsg.IMAGE_PATH ||
mode="aspectFit" 'https://eshangtech.com/ShopICO/no-picture.png'
lazy-load="true" "></image>
:src="
proMsg.IMAGE_PATH ||
'https://eshangtech.com/ShopICO/no-picture.png'
"
></image>
<text class="name-commodity">{{ proMsg.COMMODITY_NAME }}</text> <text class="name-commodity">{{ proMsg.COMMODITY_NAME }}</text>
</view> </view>
<!-- uni-app 不自带 Vant 组件可以用替代方案 --> <!-- uni-app 不自带 Vant 组件可以用替代方案 -->
<checkbox <checkbox :checked="saveMsg.isAnonymous" color="#CAA97F" @change="isAnonymous($event, saveMsg)">
:checked="saveMsg.isAnonymous"
color="#CAA97F"
@change="isAnonymous($event, saveMsg)"
>
<text style="font-size: 26rpx">匿名评价</text> <text style="font-size: 26rpx">匿名评价</text>
</checkbox> </checkbox>
</view> </view>
<view class="star-box"> <view class="star-box">
<!-- 替换 van-rate 可以使用自定义评分组件 --> <!-- 替换 van-rate 可以使用自定义评分组件 -->
<uni-rate <uni-rate :size="32" allowHalf v-model="saveMsg.commentScore" @change="changeRate($event, saveMsg)" />
:size="32"
allowHalf
v-model="saveMsg.commentScore"
@change="changeRate($event, saveMsg)"
/>
<!-- <uni-rate <!-- <uni-rate
:value="saveMsg.commentScore" :value="saveMsg.commentScore"
size="32" size="32"
@ -146,16 +98,10 @@
</view> </view>
<view class="evaluate-box"> <view class="evaluate-box">
<textarea <textarea cols="30" rows="5" :placeholder="saveMsg.merchantsId
cols="30" ? '说说这家店的口味、环境、服务'
rows="5" : '商品满足你的期待吗?说说你的使用心得,分享给想买的他们吧'
:placeholder=" " v-model="saveMsg.commentContent"></textarea>
saveMsg.merchantsId
? '说说这家店的口味、环境、服务'
: '商品满足你的期待吗?说说你的使用心得,分享给想买的他们吧'
"
v-model="saveMsg.commentContent"
></textarea>
<view class="photo-box"> <view class="photo-box">
<view class="images" v-for="(item, i) in imgsList" :key="i"> <view class="images" v-for="(item, i) in imgsList" :key="i">
@ -172,12 +118,8 @@
</view> </view>
</view> </view>
<view <view v-if="false" class="post-btn" :class="{ active: saveMsg.commentContent.length > 2 && noPost }"
v-if="false" @click="postRate">
class="post-btn"
:class="{ active: saveMsg.commentContent.length > 2 && noPost }"
@click="postRate"
>
提交 提交
</view> </view>
</view> </view>
@ -317,24 +259,26 @@ export default {
}); });
}, },
deleteImg(index) { deleteImg(index) {
let _this = this; this.imgsList.splice(index, 1);
_this.$api this.saveMsg.imageArr.splice(index, 1);
.postCoop({ // let _this = this;
action_type: "DelFile", // _this.$api
filePath: _this.saveMsg.imageArr[index], // .postCoop({
}) // action_type: "DelFile",
.then((res) => { // filePath: _this.saveMsg.imageArr[index],
// eslint-disable-next-line eqeqeq // })
if (res.ResultCode == "100") { // .then((res) => {
_this.imgsList.splice(index, 1); // // eslint-disable-next-line eqeqeq
_this.saveMsg.imageArr.splice(index, 1); // if (res.ResultCode == "100") {
} else { // _this.imgsList.splice(index, 1);
uni.showToast({ // _this.saveMsg.imageArr.splice(index, 1);
title: "删除失败请稍后重试。错误:" + res.ResultDesc, // } else {
icon: "none", // uni.showToast({
}); // title: "" + res.ResultDesc,
} // icon: "none",
}); // });
// }
// });
}, },
postRate() { postRate() {
let _this = this; let _this = this;
@ -460,17 +404,20 @@ export default {
background: #f5f6f7; background: #f5f6f7;
box-sizing: border-box; box-sizing: border-box;
padding: 16rpx 32rpx; padding: 16rpx 32rpx;
.content { .content {
background: #ffffff; background: #ffffff;
border-radius: 6rpx; border-radius: 6rpx;
width: 100%; width: 100%;
box-sizing: border-box; box-sizing: border-box;
padding: 32rpx; padding: 32rpx;
.contentTop { .contentTop {
width: 100%; width: 100%;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
.title { .title {
font-family: PingFangSC, PingFang SC; font-family: PingFangSC, PingFang SC;
font-weight: 400; font-weight: 400;
@ -480,6 +427,7 @@ export default {
text-align: left; text-align: left;
font-style: normal; font-style: normal;
} }
.anonymous { .anonymous {
font-family: PingFangSC, PingFang SC; font-family: PingFangSC, PingFang SC;
font-weight: 400; font-weight: 400;
@ -498,6 +446,7 @@ export default {
padding-bottom: 32rpx; padding-bottom: 32rpx;
border-bottom: 2rpx solid #f0f0f0; border-bottom: 2rpx solid #f0f0f0;
margin-top: 40rpx; margin-top: 40rpx;
.shopImg { .shopImg {
width: 104rpx; width: 104rpx;
height: 104rpx; height: 104rpx;
@ -505,6 +454,7 @@ export default {
overflow: hidden; overflow: hidden;
margin-right: 24rpx; margin-right: 24rpx;
} }
.rateBox { .rateBox {
.shopName { .shopName {
font-family: PingFangSC, PingFang SC; font-family: PingFangSC, PingFang SC;
@ -521,6 +471,7 @@ export default {
.textBox { .textBox {
margin-top: 32px; margin-top: 32px;
.photo-box { .photo-box {
display: flex; display: flex;
align-items: center; align-items: center;
@ -613,6 +564,7 @@ export default {
box-sizing: border-box; box-sizing: border-box;
bottom: 0; bottom: 0;
left: 0; left: 0;
.submit { .submit {
width: 100%; width: 100%;
font-family: PingFangSC, PingFang SC; font-family: PingFangSC, PingFang SC;

View File

@ -323,7 +323,7 @@ export default {
_this.minutes = ""; _this.minutes = "";
_this.isMinute = false; _this.isMinute = false;
clearInterval(_this.timer); clearInterval(_this.timer);
_this.getOrderType(); // _this.getOrderType();
// console.log(1) // console.log(1)
} }
}, 1000); }, 1000);
@ -371,7 +371,8 @@ export default {
notify_url: notify_url:
"https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx", // "https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx", //
amount: { amount: {
total: Number(_this.tatalMoney) * 100 || 1, // total: Number(_this.tatalMoney) * 100 || 1,
total: Math.round(parseFloat(_this.tatalMoney) * 100) || 1,
currency: "CNY", currency: "CNY",
}, // }, //
payer: { payer: {
@ -442,7 +443,8 @@ export default {
package: `prepay_id=${res.data.prepay_id}`, package: `prepay_id=${res.data.prepay_id}`,
signType: "RSA", signType: "RSA",
paySign: paySign, paySign: paySign,
total_fee: Number(_this.tatalMoney) * 100 || 1, // total_fee: Number(_this.tatalMoney) * 100 || 1,
total_fee: Math.round(parseFloat(_this.tatalMoney) * 100) || 1,
success(res) { success(res) {
console.log("res", res); console.log("res", res);
}, },
@ -487,9 +489,7 @@ export default {
// if (_this.status === 1005) { // if (_this.status === 1005) {
if (_this.status < 3000) { if (_this.status < 3000) {
// //
// _this.showTime(); _this.showTime();
} }
} }
}); });
@ -708,6 +708,8 @@ export default {
let _this = this; let _this = this;
let total = 0; let total = 0;
_this.shopOrder = data; _this.shopOrder = data;
console.log('_this.shopOrder_this.shopOrder_this.shopOrder', _this.shopOrder);
data.map((v) => { data.map((v) => {
total += v.ORDER_AMOUNT; total += v.ORDER_AMOUNT;
}); });

View File

@ -1594,6 +1594,7 @@ export default {
list = await this.handleGetOilData(list, idList) list = await this.handleGetOilData(list, idList)
this.isLoading = false this.isLoading = false
this.chargeData = list[0]
if (this.showListPage) { if (this.showListPage) {
this.allDataList = list this.allDataList = list
} else { } else {

View File

@ -1215,8 +1215,10 @@ export default {
} else { } else {
let req = { let req = {
Province_Code: "340000", Province_Code: "340000",
longitude: this.seatInfo.longitude || "", // longitude: this.seatInfo.longitude || "",
latitude: this.seatInfo.latitude || "", // latitude: this.seatInfo.latitude || "",
longitude: this.startObj.longitude || "",
latitude: this.startObj.latitude || "",
ShowService: true, ShowService: true,
}; };
// let serviceArea = await this.$api.$get( // let serviceArea = await this.$api.$get(
@ -1224,7 +1226,7 @@ export default {
// req // req
// ); // );
let serviceArea = await this.$api.$javaGet2('/third-party/getServerPartList', req) let serviceArea = await this.$api.$javaGet2('/third-party/getServerPartList', req)
let serviceList = serviceArea.Result_Data.List; serviceList = serviceArea.Result_Data.List;
uni.setStorageSync("serviceList", JSON.stringify(serviceList)); uni.setStorageSync("serviceList", JSON.stringify(serviceList));
} }
// //

View File

@ -105,12 +105,12 @@
<span class="price">{{ <span class="price">{{
oliData && oliData["92"] oliData && oliData["92"]
? `${oliData["92"].toString().split('.')[0]}` ? `${oliData["92"].toString().split('.')[0]}`
: detailInfo.sumDetail.REFUELINGGUN92 || "-" : detailInfo.sumDetail.REFUELINGGUN92 || "00"
}}</span> }}</span>
<span class="smallPrice">{{ <span class="smallPrice">{{
oliData && oliData["92"] oliData && oliData["92"]
? `.${oliData["92"].toString().split('.')[1]}` ? `.${oliData["92"].toString().split('.')[1]}`
: detailInfo.sumDetail.REFUELINGGUN92 || "-" : ".00"
}}</span> }}</span>
</view> </view>
@ -137,12 +137,12 @@
<span class="price">{{ <span class="price">{{
oliData && oliData["95"] oliData && oliData["95"]
? `${oliData["95"].toString().split('.')[0]}` ? `${oliData["95"].toString().split('.')[0]}`
: detailInfo.sumDetail.REFUELINGGUN92 || "-" : detailInfo.sumDetail.REFUELINGGUN95 || "00"
}}</span> }}</span>
<span class="smallPrice">{{ <span class="smallPrice">{{
oliData && oliData["95"] oliData && oliData["95"]
? `.${oliData["95"].toString().split('.')[1]}` ? `.${oliData["95"].toString().split('.')[1]}`
: detailInfo.sumDetail.REFUELINGGUN92 || "-" : ".00"
}}</span> }}</span>
</view> </view>
@ -169,12 +169,12 @@
<span class="price">{{ <span class="price">{{
oliData && oliData["0"] oliData && oliData["0"]
? `${oliData["0"].toString().split('.')[0]}` ? `${oliData["0"].toString().split('.')[0]}`
: detailInfo.sumDetail.REFUELINGGUN92 || "-" : detailInfo.sumDetail.REFUELINGGUN0 || "00"
}}</span> }}</span>
<span class="smallPrice">{{ <span class="smallPrice">{{
oliData && oliData["0"] oliData && oliData["0"]
? `.${oliData["0"].toString().split('.')[1]}` ? `.${oliData["0"].toString().split('.')[1]}`
: detailInfo.sumDetail.REFUELINGGUN92 || "-" : ".00"
}}</span> }}</span>
</view> </view>
@ -1314,9 +1314,9 @@ export default {
sumObj.LIAUTOCHARGE += item.LIAUTOCHARGE; sumObj.LIAUTOCHARGE += item.LIAUTOCHARGE;
sumObj.GACENERGYCHARGE += item.GACENERGYCHARGE; sumObj.GACENERGYCHARGE += item.GACENERGYCHARGE;
sumObj.OTHERCHARGE += item.OTHERCHARGE; sumObj.OTHERCHARGE += item.OTHERCHARGE;
sumObj.REFUELINGGUN92 += item.REFUELINGGUN92; sumObj.REFUELINGGUN92 = item.REFUELINGGUN92;
sumObj.REFUELINGGUN95 += item.REFUELINGGUN95; sumObj.REFUELINGGUN95 = item.REFUELINGGUN95;
sumObj.REFUELINGGUN0 += item.REFUELINGGUN0; sumObj.REFUELINGGUN0 = item.REFUELINGGUN0;
sumObj.HASPANTRY += item.HASPANTRY; sumObj.HASPANTRY += item.HASPANTRY;
sumObj.HASWIFI += item.HASWIFI; sumObj.HASWIFI += item.HASWIFI;
sumObj.TOILETCOUNT += item.TOILETCOUNT; sumObj.TOILETCOUNT += item.TOILETCOUNT;
@ -1418,6 +1418,7 @@ export default {
serverpartId: this.detailInfo.SERVERPART_ID, serverpartId: this.detailInfo.SERVERPART_ID,
}); });
let oliData = data.Result_Data.List; let oliData = data.Result_Data.List;
// 92 95 0 // 92 95 0
let oliObj = {}; let oliObj = {};
if (oliData && oliData.length > 0) { if (oliData && oliData.length > 0) {

View File

@ -882,8 +882,10 @@ export default {
_this.currentOrderDetail = res.Data; _this.currentOrderDetail = res.Data;
// //
// APP // APP
uni.setStorageSync('noShopCar', null);
if (_this.loginType === "min") { if (_this.loginType === "min") {
_this.handleWxPay(res.Data); _this.handleWxPay(res.Data);
} else { } else {
// ; // ;
// _this.$refs.payPopup.open("bottom"); // _this.$refs.payPopup.open("bottom");
@ -921,6 +923,8 @@ export default {
let serial_no = "5904E3BF9EDC8B2AA3F99E51440B34FB7FFA6EDA"; // let serial_no = "5904E3BF9EDC8B2AA3F99E51440B34FB7FFA6EDA"; //
let out_trade_no = obj.SALEBILL_CODE; // let out_trade_no = obj.SALEBILL_CODE; //
console.log('_this.orderAmount_this.orderAmount', Number(_this.orderAmount) * 100 || 1);
let req = { let req = {
appid: "wx4c497eddcec4a0e7", // id appid: "wx4c497eddcec4a0e7", // id
mchid: mchid, // mchid: mchid, //
@ -929,7 +933,8 @@ export default {
notify_url: notify_url:
"https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx", // "https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx", //
amount: { amount: {
total: Number(_this.orderAmount) * 100 || 1, // 100 // total: Number(_this.orderAmount) * 100 || 1, // 100
total: Math.round(parseFloat(_this.orderAmount) * 100) || 1, // 100
currency: "CNY", // currency: "CNY", //
}, // }, //
payer: { payer: {
@ -994,7 +999,8 @@ export default {
package: `prepay_id=${res.data.prepay_id}`, package: `prepay_id=${res.data.prepay_id}`,
signType: "RSA", signType: "RSA",
paySign: paySign, paySign: paySign,
total_fee: Number(_this.orderAmount) * 100 || 1, // total_fee: Number(_this.orderAmount) * 100 || 1,
total_fee: Math.round(parseFloat(_this.orderAmount) * 100) || 1,
success(res) { success(res) {
console.log("res", res); console.log("res", res);
}, },

View File

@ -26,7 +26,7 @@
<span style="margin: 0 8rpx; color: #fff; font-size: 22rpx">|</span> <span style="margin: 0 8rpx; color: #fff; font-size: 22rpx">|</span>
<span class="month">人均<span class="value">{{ <span class="month">人均<span class="value">{{
listDetail.PERCAPITA || merchatsMsg.PERCAPITA || "-" listDetail.PERCAPITA || merchatsMsg.PERCAPITA || "-"
}}</span></span> }}</span></span>
</div> </div>
<scroll-view :scroll-x="true" class="newCoupop"> <scroll-view :scroll-x="true" class="newCoupop">
@ -556,7 +556,8 @@ export default {
isLoading: false, isLoading: false,
listDetail: {}, // listDetail: {}, //
onLoadMid: "", onLoadMid: "",
onLoadType: "" onLoadType: "",
isFirst: true
}; };
}, },
computed: { computed: {
@ -983,6 +984,8 @@ export default {
console.log("tableNum", this.tableNum); console.log("tableNum", this.tableNum);
console.log("o", o); console.log("o", o);
// eslint-disable-next-line eqeqeq // eslint-disable-next-line eqeqeq
uni.setStorageSync('noShopCar', null);
if (this.tableNum !== 0) { if (this.tableNum !== 0) {
uni.navigateTo({ uni.navigateTo({
url: `/pages/shopPages/settlement/index?tableNum=${this.tableNum}&id=${id}&sid=${this.stroreId}&province=${this.merchatsMsg.PROVINCE_CODE}&SERVERPART_ID=${this.merchatsMsg.SERVERPART_ID}`, url: `/pages/shopPages/settlement/index?tableNum=${this.tableNum}&id=${id}&sid=${this.stroreId}&province=${this.merchatsMsg.PROVINCE_CODE}&SERVERPART_ID=${this.merchatsMsg.SERVERPART_ID}`,
@ -1077,7 +1080,9 @@ export default {
console.log('sellerIdsellerIdsellerIdsellerIdsellerId', { sellerId: id }); console.log('sellerIdsellerIdsellerIdsellerIdsellerId', { sellerId: id });
console.log('_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList', _this.couponList); console.log('_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList', _this.couponList);
if (!_this.isFirst) {
return
}
let tabList = []; let tabList = [];
let isFood = false; let isFood = false;
if (_this.couponList && _this.couponList.length > 0) { if (_this.couponList && _this.couponList.length > 0) {
@ -1102,6 +1107,7 @@ export default {
_this.activeTabs = isFood ? 1 : tabList[0].value; _this.activeTabs = isFood ? 1 : tabList[0].value;
console.log('_this.activeTabs_this.activeTabs', _this.activeTabs); console.log('_this.activeTabs_this.activeTabs', _this.activeTabs);
_this.isFirst = false
_this.$forceUpdate() _this.$forceUpdate()
}); });
}, },
@ -1127,8 +1133,6 @@ export default {
}, },
onReady() { }, onReady() { },
async onLoad(options) { async onLoad(options) {
console.log("options", options);
let type = uni.getStorageSync("loginType"); let type = uni.getStorageSync("loginType");
this.loginType = type; this.loginType = type;
if (options.buyType) { if (options.buyType) {
@ -1156,9 +1160,24 @@ export default {
this.goodsH = goodsHeight; this.goodsH = goodsHeight;
} }
let noShopCar = uni.getStorageSync('noShopCar');
if (noShopCar) {
this.shopCart = JSON.parse(noShopCar)
console.log('this.shopCartthis.shopCart', this.shopCart);
this._resetTotalNum();
}
this.$utils.addUserBehaviorNew(); this.$utils.addUserBehaviorNew();
}, },
onUnload() { onUnload() {
//
uni.setStorageSync('noShopCar', this.shopCart && this.shopCart.length > 0 ? JSON.stringify(this.shopCart) : null);
this.$store.commit("couponPrice", ""); this.$store.commit("couponPrice", "");
this.$store.commit("orderRemark", ""); this.$store.commit("orderRemark", "");
this.totalNum = 0; this.totalNum = 0;

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -315,6 +315,17 @@ var _default = {
} }
}, },
methods: { methods: {
// 清除输入框中的内容
handleClearSearch: function handleClearSearch() {
this.searchText = "";
this.dataList = [];
this.pageObj = {
pageIndex: 1,
pageSize: 10,
isOver: false
};
this.handleGetListData();
},
// 查看预览图片 // 查看预览图片
handlePriviewImgList: function handlePriviewImgList(url, list) { handlePriviewImgList: function handlePriviewImgList(url, list) {
var urlList = []; var urlList = [];
@ -488,6 +499,15 @@ var _default = {
this.handleClosePopup(); this.handleClosePopup();
this.handleGetListData(); this.handleGetListData();
}, },
handleClickSearch: function handleClickSearch() {
this.dataList = [];
this.pageObj = {
pageIndex: 1,
pageSize: 10,
isOver: false
};
this.handleGetListData();
},
// 拿到失物招领的数据 只要最近三个月的数据 // 拿到失物招领的数据 只要最近三个月的数据
handleGetListData: function handleGetListData() { handleGetListData: function handleGetListData() {
var _this3 = this; var _this3 = this;
@ -526,6 +546,7 @@ var _default = {
if (_this3.dataList && _this3.dataList.length > 0) { if (_this3.dataList && _this3.dataList.length > 0) {
oldList = JSON.parse(JSON.stringify(_this3.dataList)); oldList = JSON.parse(JSON.stringify(_this3.dataList));
} }
console.log('oldListoldListoldListoldList', JSON.parse(JSON.stringify(oldList)));
list = data.Result_Data.List; list = data.Result_Data.List;
if (list && list.length > 0) { if (list && list.length > 0) {
if (list.length < _this3.pageObj.pageSize) { if (list.length < _this3.pageObj.pageSize) {
@ -544,9 +565,10 @@ var _default = {
} else { } else {
_this3.pageObj.isOver = true; _this3.pageObj.isOver = true;
} }
console.log('listlistlistlistlistlistlistlist', JSON.parse(JSON.stringify(list)));
_this3.dataList = oldList.concat(list); _this3.dataList = oldList.concat(list);
_this3.isLoading = false; _this3.isLoading = false;
case 11: case 13:
case "end": case "end":
return _context3.stop(); return _context3.stop();
} }
@ -578,7 +600,7 @@ var _default = {
// 关闭搜索按钮 // 关闭搜索按钮
noClickSearch: function noClickSearch() { noClickSearch: function noClickSearch() {
this.showSearchBtn = false; this.showSearchBtn = false;
this.handleGetListData(); // this.handleGetListData()
}, },
// 调起打电话 // 调起打电话
handleCallPhone: function handleCallPhone(obj) { handleCallPhone: function handleCallPhone(obj) {

File diff suppressed because one or more lines are too long

View File

@ -143,6 +143,11 @@
.main .headerBox .searchBox .inputBox.data-v-57bb4cfa { .main .headerBox .searchBox .inputBox.data-v-57bb4cfa {
width: 100%; width: 100%;
} }
.main .headerBox .searchBox .closeIcon.data-v-57bb4cfa {
width: 36rpx;
height: 36rpx;
margin-left: 10rpx;
}
.main .headerBox .searchBox .searchText.data-v-57bb4cfa { .main .headerBox .searchBox .searchText.data-v-57bb4cfa {
font-family: PingFangSC, PingFang SC; font-family: PingFangSC, PingFang SC;
font-weight: 400; font-weight: 400;

View File

@ -272,28 +272,30 @@ var _default = {
_this.$utils.qrc("qrcode", code, _this.qrcodeHeight, _this.qrcodeHeight, null, "https://eshangtech.com/wanmeiyizhanImg/home/YDIconWhiteBg.png"); _this.$utils.qrc("qrcode", code, _this.qrcodeHeight, _this.qrcodeHeight, null, "https://eshangtech.com/wanmeiyizhanImg/home/YDIconWhiteBg.png");
// _this.$utils.qrc('qrcode2', code, _this.qrcodeHeight2, _this.qrcodeHeight2, null, '../../..https://eshangtech.com/wanmeiyizhanImg/gsuyiw.png') // _this.$utils.qrc('qrcode2', code, _this.qrcodeHeight2, _this.qrcodeHeight2, null, '../../..https://eshangtech.com/wanmeiyizhanImg/gsuyiw.png')
_this.showCode = code.substring(0, 4) + " " + "*".repeat("6"); _this.showCode = code.substring(0, 4) + " " + "*".repeat("6");
wx.canvasToTempFilePath({ setTimeout(function () {
canvasId: "barcode", wx.canvasToTempFilePath({
success: function success(res) { canvasId: "barcode",
console.log("barcode", res); success: function success(res) {
// this.setData({ console.log("barcode", res);
// qrCodeImage: res.tempFilePath, // 保存图片路径 // this.setData({
// }); // qrCodeImage: res.tempFilePath, // 保存图片路径
_this.barcodeImg = res.tempFilePath; // });
_this.$forceUpdate(); _this.barcodeImg = res.tempFilePath;
} _this.$forceUpdate();
}); }
wx.canvasToTempFilePath({ });
canvasId: "qrcode", wx.canvasToTempFilePath({
success: function success(res) { canvasId: "qrcode",
console.log("barcode", res); success: function success(res) {
// this.setData({ console.log("barcode", res);
// qrCodeImage: res.tempFilePath, // 保存图片路径 // this.setData({
// }); // qrCodeImage: res.tempFilePath, // 保存图片路径
_this.qrcodeImg = res.tempFilePath; // });
_this.$forceUpdate(); _this.qrcodeImg = res.tempFilePath;
} _this.$forceUpdate();
}); }
});
}, 300);
_this.$forceUpdate(); _this.$forceUpdate();
_this.timer = setInterval(function () { _this.timer = setInterval(function () {
_this.getCode(); _this.getCode();

View File

@ -325,22 +325,26 @@ var _default = {
}); });
}, },
deleteImg: function deleteImg(index) { deleteImg: function deleteImg(index) {
var _this = this; this.imgsList.splice(index, 1);
_this.$api.postCoop({ this.saveMsg.imageArr.splice(index, 1);
action_type: "DelFile", // let _this = this;
filePath: _this.saveMsg.imageArr[index] // _this.$api
}).then(function (res) { // .postCoop({
// eslint-disable-next-line eqeqeq // action_type: "DelFile",
if (res.ResultCode == "100") { // filePath: _this.saveMsg.imageArr[index],
_this.imgsList.splice(index, 1); // })
_this.saveMsg.imageArr.splice(index, 1); // .then((res) => {
} else { // // eslint-disable-next-line eqeqeq
uni.showToast({ // if (res.ResultCode == "100") {
title: "删除失败请稍后重试。错误:" + res.ResultDesc, // _this.imgsList.splice(index, 1);
icon: "none" // _this.saveMsg.imageArr.splice(index, 1);
}); // } else {
} // uni.showToast({
}); // title: "删除失败请稍后重试。错误:" + res.ResultDesc,
// icon: "none",
// });
// }
// });
}, },
postRate: function postRate() { postRate: function postRate() {
var _this = this; var _this = this;

File diff suppressed because one or more lines are too long

View File

@ -319,7 +319,7 @@ var _default = {
_this.minutes = ""; _this.minutes = "";
_this.isMinute = false; _this.isMinute = false;
clearInterval(_this.timer); clearInterval(_this.timer);
_this.getOrderType(); // _this.getOrderType();
// console.log(1) // console.log(1)
} }
}, 1000); }, 1000);
@ -375,7 +375,8 @@ var _default = {
notify_url: "https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx", notify_url: "https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx",
// 商户回调地址 // 商户回调地址
amount: { amount: {
total: Number(_this.tatalMoney) * 100 || 1, // total: Number(_this.tatalMoney) * 100 || 1,
total: Math.round(parseFloat(_this.tatalMoney) * 100) || 1,
currency: "CNY" currency: "CNY"
}, },
// 订单金额 // 订单金额
@ -435,7 +436,8 @@ var _default = {
package: "prepay_id=".concat(res.data.prepay_id), package: "prepay_id=".concat(res.data.prepay_id),
signType: "RSA", signType: "RSA",
paySign: paySign, paySign: paySign,
total_fee: Number(_this.tatalMoney) * 100 || 1, // total_fee: Number(_this.tatalMoney) * 100 || 1,
total_fee: Math.round(parseFloat(_this.tatalMoney) * 100) || 1,
success: function success(res) { success: function success(res) {
console.log("res", res); console.log("res", res);
}, },
@ -496,7 +498,7 @@ var _default = {
// if (_this.status === 1005) { // if (_this.status === 1005) {
if (_this.status < 3000) { if (_this.status < 3000) {
// 待付款时添加倒计时 // 待付款时添加倒计时
// _this.showTime(); _this.showTime();
} }
} }
}); });
@ -727,6 +729,7 @@ var _default = {
var _this = this; var _this = this;
var total = 0; var total = 0;
_this.shopOrder = data; _this.shopOrder = data;
console.log('_this.shopOrder_this.shopOrder_this.shopOrder', _this.shopOrder);
data.map(function (v) { data.map(function (v) {
total += v.ORDER_AMOUNT; total += v.ORDER_AMOUNT;
}); });

View File

@ -627,9 +627,9 @@ var _default = {
sumObj.LIAUTOCHARGE += item.LIAUTOCHARGE; sumObj.LIAUTOCHARGE += item.LIAUTOCHARGE;
sumObj.GACENERGYCHARGE += item.GACENERGYCHARGE; sumObj.GACENERGYCHARGE += item.GACENERGYCHARGE;
sumObj.OTHERCHARGE += item.OTHERCHARGE; sumObj.OTHERCHARGE += item.OTHERCHARGE;
sumObj.REFUELINGGUN92 += item.REFUELINGGUN92; sumObj.REFUELINGGUN92 = item.REFUELINGGUN92;
sumObj.REFUELINGGUN95 += item.REFUELINGGUN95; sumObj.REFUELINGGUN95 = item.REFUELINGGUN95;
sumObj.REFUELINGGUN0 += item.REFUELINGGUN0; sumObj.REFUELINGGUN0 = item.REFUELINGGUN0;
sumObj.HASPANTRY += item.HASPANTRY; sumObj.HASPANTRY += item.HASPANTRY;
sumObj.HASWIFI += item.HASWIFI; sumObj.HASWIFI += item.HASWIFI;
sumObj.TOILETCOUNT += item.TOILETCOUNT; sumObj.TOILETCOUNT += item.TOILETCOUNT;

File diff suppressed because one or more lines are too long

View File

@ -897,6 +897,7 @@ var _default = {
_this.currentOrderDetail = res.Data; _this.currentOrderDetail = res.Data;
// 如果是微信小程序的话 直接调用支付 // 如果是微信小程序的话 直接调用支付
// APP端的话 弹出支付宝和微信支付的选择 并调用对应的方法 // APP端的话 弹出支付宝和微信支付的选择 并调用对应的方法
uni.setStorageSync('noShopCar', null);
if (_this.loginType === "min") { if (_this.loginType === "min") {
_this.handleWxPay(res.Data); _this.handleWxPay(res.Data);
} else { } else {
@ -941,6 +942,7 @@ var _default = {
nonceStr = Math.random().toString(36).substring(2, 8); // 随机字符串 nonceStr = Math.random().toString(36).substring(2, 8); // 随机字符串
serial_no = "5904E3BF9EDC8B2AA3F99E51440B34FB7FFA6EDA"; // 证书序列号 serial_no = "5904E3BF9EDC8B2AA3F99E51440B34FB7FFA6EDA"; // 证书序列号
out_trade_no = obj.SALEBILL_CODE; // 本地生成的订单编码 out_trade_no = obj.SALEBILL_CODE; // 本地生成的订单编码
console.log('_this.orderAmount_this.orderAmount', Number(_this.orderAmount) * 100 || 1);
req = { req = {
appid: "wx4c497eddcec4a0e7", appid: "wx4c497eddcec4a0e7",
// 小程序的id // 小程序的id
@ -953,7 +955,8 @@ var _default = {
notify_url: "https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx", notify_url: "https://mp.eshangtech.com/Coop.Merchant/Handler/Handler_Trade.ashx",
// 商户回调地址 // 商户回调地址
amount: { amount: {
total: Number(_this.orderAmount) * 100 || 1, // total: Number(_this.orderAmount) * 100 || 1, // 多少钱 分为单位所以乘了100
total: Math.round(parseFloat(_this.orderAmount) * 100) || 1,
// 多少钱 分为单位所以乘了100 // 多少钱 分为单位所以乘了100
currency: "CNY" // 人民币的标识 currency: "CNY" // 人民币的标识
}, },
@ -973,9 +976,9 @@ var _default = {
console.log("timeStamp", timeStamp); console.log("timeStamp", timeStamp);
console.log("serial_no", serial_no); console.log("serial_no", serial_no);
// 生成签名的接口 // 生成签名的接口
_context9.next = 15; _context9.next = 16;
return _this6.$api.$get("/WeChat/GenerateSign", reqSign); return _this6.$api.$get("/WeChat/GenerateSign", reqSign);
case 15: case 16:
data = _context9.sent; data = _context9.sent;
console.log("data.Result_Data", data.Result_Data); console.log("data.Result_Data", data.Result_Data);
Authorization = "mchid=\"".concat(mchid, "\",nonce_str=\"").concat(nonceStr, "\",signature=\"").concat(data.Result_Data, "\",timestamp=\"").concat(timeStamp, "\",serial_no=\"").concat(serial_no, "\""); Authorization = "mchid=\"".concat(mchid, "\",nonce_str=\"").concat(nonceStr, "\",signature=\"").concat(data.Result_Data, "\",timestamp=\"").concat(timeStamp, "\",serial_no=\"").concat(serial_no, "\"");
@ -1015,7 +1018,8 @@ var _default = {
package: "prepay_id=".concat(res.data.prepay_id), package: "prepay_id=".concat(res.data.prepay_id),
signType: "RSA", signType: "RSA",
paySign: paySign, paySign: paySign,
total_fee: Number(_this.orderAmount) * 100 || 1, // total_fee: Number(_this.orderAmount) * 100 || 1,
total_fee: Math.round(parseFloat(_this.orderAmount) * 100) || 1,
success: function success(res) { success: function success(res) {
console.log("res", res); console.log("res", res);
}, },
@ -1048,7 +1052,7 @@ var _default = {
return success; return success;
}() }()
}); });
case 20: case 21:
case "end": case "end":
return _context9.stop(); return _context9.stop();
} }

View File

@ -316,7 +316,8 @@ var _default = {
listDetail: {}, listDetail: {},
// 列表带进来的数据 月售和人均 // 列表带进来的数据 月售和人均
onLoadMid: "", onLoadMid: "",
onLoadType: "" onLoadType: "",
isFirst: true
}; };
}, },
computed: _objectSpread({}, (0, _vuex.mapGetters)({ computed: _objectSpread({}, (0, _vuex.mapGetters)({
@ -718,6 +719,7 @@ var _default = {
console.log("tableNum", this.tableNum); console.log("tableNum", this.tableNum);
console.log("o", o); console.log("o", o);
// eslint-disable-next-line eqeqeq // eslint-disable-next-line eqeqeq
uni.setStorageSync('noShopCar', null);
if (this.tableNum !== 0) { if (this.tableNum !== 0) {
uni.navigateTo({ uni.navigateTo({
url: "/pages/shopPages/settlement/index?tableNum=".concat(this.tableNum, "&id=").concat(id, "&sid=").concat(this.stroreId, "&province=").concat(this.merchatsMsg.PROVINCE_CODE, "&SERVERPART_ID=").concat(this.merchatsMsg.SERVERPART_ID) url: "/pages/shopPages/settlement/index?tableNum=".concat(this.tableNum, "&id=").concat(id, "&sid=").concat(this.stroreId, "&province=").concat(this.merchatsMsg.PROVINCE_CODE, "&SERVERPART_ID=").concat(this.merchatsMsg.SERVERPART_ID)
@ -825,6 +827,9 @@ var _default = {
sellerId: id sellerId: id
}); });
console.log('_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList', _this.couponList); console.log('_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList_this.couponList', _this.couponList);
if (!_this.isFirst) {
return;
}
var tabList = []; var tabList = [];
var isFood = false; var isFood = false;
if (_this.couponList && _this.couponList.length > 0) { if (_this.couponList && _this.couponList.length > 0) {
@ -851,6 +856,7 @@ var _default = {
_this.tabList = tabList; _this.tabList = tabList;
_this.activeTabs = isFood ? 1 : tabList[0].value; _this.activeTabs = isFood ? 1 : tabList[0].value;
console.log('_this.activeTabs_this.activeTabs', _this.activeTabs); console.log('_this.activeTabs_this.activeTabs', _this.activeTabs);
_this.isFirst = false;
_this.$forceUpdate(); _this.$forceUpdate();
}); });
}, },
@ -874,12 +880,11 @@ var _default = {
onLoad: function onLoad(options) { onLoad: function onLoad(options) {
var _this5 = this; var _this5 = this;
return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() { return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
var type, systemInfo, goodsHeight; var type, systemInfo, goodsHeight, noShopCar;
return _regenerator.default.wrap(function _callee3$(_context3) { return _regenerator.default.wrap(function _callee3$(_context3) {
while (1) { while (1) {
switch (_context3.prev = _context3.next) { switch (_context3.prev = _context3.next) {
case 0: case 0:
console.log("options", options);
type = uni.getStorageSync("loginType"); type = uni.getStorageSync("loginType");
_this5.loginType = type; _this5.loginType = type;
if (options.buyType) { if (options.buyType) {
@ -889,15 +894,15 @@ var _default = {
_this5.listDetail = JSON.parse(options.stroreDetail); _this5.listDetail = JSON.parse(options.stroreDetail);
} }
_this5.stroreId = options.id; _this5.stroreId = options.id;
_context3.next = 8; _context3.next = 7;
return _this5.getNewGood(options.id, options.province); return _this5.getNewGood(options.id, options.province);
case 8: case 7:
// this.merchatsMsg.MERCHANTS_ID = options.mid // this.merchatsMsg.MERCHANTS_ID = options.mid
_this5.onLoadMid = options.mid; _this5.onLoadMid = options.mid;
_this5.onLoadType = options.type; _this5.onLoadType = options.type;
_context3.next = 12; _context3.next = 11;
return _this5.getShop(options.mid, options.type || 0); return _this5.getShop(options.mid, options.type || 0);
case 12: case 11:
// 获取商户信息 // 获取商户信息
_this5.tableNum = options.tableNum || 0; // tableNum 桌号 不等于0说明是门店扫码进入 则当确认订单时 不要选择相关的方向 _this5.tableNum = options.tableNum || 0; // tableNum 桌号 不等于0说明是门店扫码进入 则当确认订单时 不要选择相关的方向
_this5.$store.commit("orderTable", options.tableNum || 0); _this5.$store.commit("orderTable", options.tableNum || 0);
@ -908,8 +913,14 @@ var _default = {
} else { } else {
_this5.goodsH = goodsHeight; _this5.goodsH = goodsHeight;
} }
noShopCar = uni.getStorageSync('noShopCar');
if (noShopCar) {
_this5.shopCart = JSON.parse(noShopCar);
console.log('this.shopCartthis.shopCart', _this5.shopCart);
_this5._resetTotalNum();
}
_this5.$utils.addUserBehaviorNew(); _this5.$utils.addUserBehaviorNew();
case 18: case 19:
case "end": case "end":
return _context3.stop(); return _context3.stop();
} }
@ -918,6 +929,8 @@ var _default = {
}))(); }))();
}, },
onUnload: function onUnload() { onUnload: function onUnload() {
// 没有下单的购物车数据
uni.setStorageSync('noShopCar', this.shopCart && this.shopCart.length > 0 ? JSON.stringify(this.shopCart) : null);
this.$store.commit("couponPrice", ""); this.$store.commit("couponPrice", "");
this.$store.commit("orderRemark", ""); this.$store.commit("orderRemark", "");
this.totalNum = 0; this.totalNum = 0;