Commit c60a692a authored by 罗超's avatar 罗超

Merge branch 'master' of http://gitlab.oytour.com/zk123/jz_travel

parents 85b82277 38f4ba68
...@@ -4,22 +4,19 @@ ...@@ -4,22 +4,19 @@
<u-col span="6" v-for="(cx, ci) in g" :key="ci"> <u-col span="6" v-for="(cx, ci) in g" :key="ci">
<view class="good" @click="showSkuHandler(cx)"> <view class="good" @click="showSkuHandler(cx)">
<view class="good-img"> <view class="good-img">
<image mode="aspectFill" :src="getImgs(cx.imgCover)" style="width: 100%; height: 100%;"> <image mode="aspectFill" :src="getImgs(cx.imgCover)" style="width: 100%; height: 100%;border-top-left-radius: 10px;
border-top-right-radius: 10px;">
</image> </image>
</view> </view>
<view class="good-name"> <view class="good-name">
{{cx.title}} {{cx.title}}
</view> </view>
<view class="goodsSubName"> <!-- <view class="goodsSubName">
<text v-if="cx.productRecommend">{{cx.productRecommend}}</text> <text v-if="cx.productRecommend">{{cx.productRecommend}}</text>
</view> </view> -->
<view class="good-info"> <view class="good-info">
<view class="price"> <view class="price">
{{$utils.getretailer()==true? cx.b2BPrice:cx.b2CPrice}} {{$utils.getretailer()==true? cx.b2BPrice:cx.b2CPrice}}
<!-- <text class="sell"></text> -->
</view>
<view class="cart">
<u-icon name="cart-o" color="#ff4544" size="40" />
</view> </view>
</view> </view>
</view> </view>
...@@ -171,6 +168,7 @@ ...@@ -171,6 +168,7 @@
font-size: 14px; font-size: 14px;
color: #ff4544; color: #ff4544;
flex: 1; flex: 1;
text-align: right;
} }
.u-good-list .good .good-info .sell { .u-good-list .good .good-info .sell {
......
...@@ -38,12 +38,18 @@ ...@@ -38,12 +38,18 @@
<div class="good-name" v-if="goodsInfo.showGoodsName">{{ item.name }}</div> <div class="good-name" v-if="goodsInfo.showGoodsName">{{ item.name }}</div>
<view class="good-sub-name" v-if="item.subname">{{item.subname}}</view> <view class="good-sub-name" v-if="item.subname">{{item.subname}}</view>
<div class="good-price-info"> <div class="good-price-info">
<span class="price"> <view style="display: flex;justify-content: space-between;width:100%;align-items: center;">
<span style="font-size: 28rpx;font-weight: 500;margin-right: 2rpx;"></span> <view style="font-size:22rpx;color:#999999;">
{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : '' }} {{item.thirdname}}
<!-- <span style='text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> --> </view>
</span> <view>
<span class="buy" v-if="goodsInfo.showBuyBtn"> <span class="price">
<span style="font-size: 28rpx;font-weight: 500;margin-right: 2rpx;"></span>
{{ goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : '' }}
</span>
</view>
</view>
<span class="buy" v-if="goodsInfo.showBuyBtn" style="display:none;">
<u-icon name="cart-o" size="40" style="color:#ff4544" v-if="goodsInfo.buyBtn == 'cart'" /> <u-icon name="cart-o" size="40" style="color:#ff4544" v-if="goodsInfo.buyBtn == 'cart'" />
<u-icon name="add-o" size="40" style="color:#ff4544" v-else-if="goodsInfo.buyBtn == 'add'" /> <u-icon name="add-o" size="40" style="color:#ff4544" v-else-if="goodsInfo.buyBtn == 'add'" />
<u-button <u-button
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
</view> --> </view> -->
<view class="good-price-info"> <view class="good-price-info">
<view class="price"> <view class="price">
{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : '' }} {{ goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : '' }}
<!-- <span style='text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> --> <!-- <span style='text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> -->
</view> </view>
<view class="buy" v-if="goodsInfo.showBuyBtn" @click.stop="showSkuHandler(item)"> <view class="buy" v-if="goodsInfo.showBuyBtn" @click.stop="showSkuHandler(item)">
......
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
<div class="good-price-info"> <div class="good-price-info">
<view class="price" :style="{ color: mainColor }"> <view class="price" :style="{ color: mainColor }">
<span>{{ <span>{{
goodsInfo.showGoodsPrice ? getPrice(item.price) : "" goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ""
}}</span> }}</span>
<span <span
style=" style="
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
}}</view> }}</view>
<view class="good-price-info"> <view class="good-price-info">
<view class="price" :style="{ color: mainColor }">{{ <view class="price" :style="{ color: mainColor }">{{
goodsInfo.showGoodsPrice ? getPrice(item.price) : "" goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ""
}}</view> }}</view>
<view <view
class="buy" class="buy"
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
item.thirdname item.thirdname
}}</view> }}</view>
<span> <span>
{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : "" }} {{ goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : "" }}
</span> </span>
<!-- <span style='text-decoration: line-through;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> --> <!-- <span style='text-decoration: line-through;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> -->
</view> </view>
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
}}</view> }}</view>
<view class="good-price-info"> <view class="good-price-info">
<view class="price" :style="{ color: mainColor }" <view class="price" :style="{ color: mainColor }"
>{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : "" }} >{{ goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : "" }}
<!-- <span style='text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> --> <!-- <span style='text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> -->
</view> </view>
<view <view
......
...@@ -112,7 +112,7 @@ ...@@ -112,7 +112,7 @@
class="price" class="price"
:style="{ color: mainColor }" :style="{ color: mainColor }"
v-if="item.price > 0 && goodsInfo.showGoodsPrice" v-if="item.price > 0 && goodsInfo.showGoodsPrice"
>{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : "" }} >{{ goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : "" }}
<span <span
style=" style="
text-decoration: line-through; text-decoration: line-through;
......
...@@ -6,9 +6,9 @@ ...@@ -6,9 +6,9 @@
:current="current" :current="current"
@change="change" @change="change"
:active-color="mainColor" :active-color="mainColor"
bar-height='4' bar-height="4"
height="100" height="100"
:show-bar="showBar"
></u-tabs> ></u-tabs>
<u-empty v-if="g.length == 0" text="暂无相关卡券" mode="order"></u-empty> <u-empty v-if="g.length == 0" text="暂无相关卡券" mode="order"></u-empty>
<view <view
...@@ -39,38 +39,37 @@ ...@@ -39,38 +39,37 @@
>没有更多卡券了</u-divider >没有更多卡券了</u-divider
> >
</scroll-view> </scroll-view>
</view> </view>
<!-- 加载中 --> <!-- 加载中 -->
<view class="loading" v-if="loading"> <view class="loading" v-if="loading">
<u-loading mode="flower" size="48">></u-loading> <u-loading mode="flower" size="48">></u-loading>
<Text style="color: #fff; margin-top: 10rpx;">加载中...</Text> <Text style="color: #fff; margin-top: 10rpx">加载中...</Text>
</view> </view>
<!-- 取消提示 --> <!-- 取消提示 -->
<u-toast ref="uToast" /> <u-toast ref="uToast" />
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth= 'goback'></auth> <auth
v-if="showAuth"
@changeuserinfo="reloadUserinfo"
@gbAuth="goback"
></auth>
</view> </view>
</template> </template>
<script> <script>
import error from '../../../components/error/error.vue'; import error from "../../../components/error/error.vue";
import auth from "../../../components/auth/index.vue"; import auth from "../../../components/auth/index.vue";
export default { export default {
components: { components: {
error, error,
auth auth,
}, },
data() { data() {
return { return {
pageTitle: "我的卡券", pageTitle: "我的卡券",
current: 0, current: 0,
showAuth: false, showAuth: false,
list: [ list: [{ name: "未使用" }, { name: "已使用" }, { name: "已过期" }],
{ name: "未使用" },
{ name: "已使用" },
{ name: "已过期" },
],
mainColor: "", mainColor: "",
contentHeight: 0, contentHeight: 0,
page: 1, page: 1,
...@@ -81,23 +80,27 @@ export default { ...@@ -81,23 +80,27 @@ export default {
item: "", item: "",
index: 0, index: 0,
isover: false, isover: false,
u:{}, u: {},
showBar: true,
}; };
}, },
created() { created() {
this.contentHeight = this.$utils.calcContentHeight(-40) + "px"; this.contentHeight = this.$utils.calcContentHeight(-40) + "px";
this.mainColor = this.$uiConfig.mainColor; this.mainColor = this.$uiConfig.mainColor;
this.u = uni.getStorageSync("mall_UserInfo"); this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) { if (!this.u) {
this.u = { this.u = {
nickName: "未登录", nickName: "未登录",
avatarUrl: "" avatarUrl: "",
}; };
this.showAuth = true; this.showAuth = true;
} else{ } else {
this.loading = true; this.loading = true;
this.init(); this.init();
} }
// #ifdef MP-ALIPAY
this.showBar = false;
// #endif
}, },
mounted() { mounted() {
let currentPages = getCurrentPages(); let currentPages = getCurrentPages();
...@@ -116,7 +119,6 @@ export default { ...@@ -116,7 +119,6 @@ export default {
}, },
methods: { methods: {
change(index) { change(index) {
this.current = index; this.current = index;
this.page = 1; this.page = 1;
this.g = []; this.g = [];
...@@ -126,7 +128,7 @@ export default { ...@@ -126,7 +128,7 @@ export default {
init() { init() {
this.isover = false; this.isover = false;
let h = this.apiheader(); let h = this.apiheader();
this.loading = false; this.loading = false;
}, },
lower(e) { lower(e) {
if (this.page < this.page_count) { if (this.page < this.page_count) {
...@@ -136,15 +138,15 @@ export default { ...@@ -136,15 +138,15 @@ export default {
this.isover = true; this.isover = true;
} }
}, },
reloadUserinfo() { reloadUserinfo() {
this.u = uni.getStorageSync("mall_UserInfo"); this.u = uni.getStorageSync("mall_UserInfo");
// this.showAuth = false; // this.showAuth = false;
this.loading = true; this.loading = true;
this.init(); this.init();
}, },
goback(){ goback() {
uni.navigateBack() uni.navigateBack();
}, },
}, },
}; };
</script> </script>
...@@ -171,5 +173,4 @@ export default { ...@@ -171,5 +173,4 @@ export default {
margin-left: -100rpx; margin-left: -100rpx;
z-index: 999; z-index: 999;
} }
</style> </style>
This diff is collapsed.
This diff is collapsed.
...@@ -280,6 +280,7 @@ ...@@ -280,6 +280,7 @@
.jz_Content .price .money { .jz_Content .price .money {
font-size: 36rpx; font-size: 36rpx;
color:#FF3166;
} }
</style> </style>
<template> <template>
...@@ -395,8 +396,7 @@ ...@@ -395,8 +396,7 @@
</view> </view>
<view> <view>
<text></text> <text></text>
<text class="money">{{$utils.getretailer()==true? item.b2BPrice:item.b2CPrice}}</text> <text class="money">{{item.b2CPrice}}</text>
<text></text>
</view> </view>
</view> </view>
</view> </view>
......
...@@ -80,11 +80,7 @@ ...@@ -80,11 +80,7 @@
<view class="jz_TopPrice"> <view class="jz_TopPrice">
<view class="jz_LineTitle"> <view class="jz_LineTitle">
<text class="jz_renmin">¥</text <text class="jz_renmin">¥</text
><text class="jz_B2bPrice">{{ ><text class="jz_B2bPrice">{{currentPrice.b2CPrice}}</text>
$utils.getretailer() == true
? currentPrice.b2BPrice
: currentPrice.b2CPrice
}}</text>
<text style="color: #999999; font-size: 24rpx; font-weight: 400"> <text style="color: #999999; font-size: 24rpx; font-weight: 400">
/人起</text /人起</text
> >
...@@ -183,9 +179,7 @@ ...@@ -183,9 +179,7 @@
<view <view
v-if="item.remainNum > 0" v-if="item.remainNum > 0"
style="color: #ff3166; font-size: 26rpx" style="color: #ff3166; font-size: 26rpx"
>{{ >{{item.b2CPrice}}</view
$utils.getretailer() == true ? item.b2BPrice : item.b2CPrice
}}</view
> >
<view v-if="item.remainNum == 0" style="padding: 20rpx 0"> <view v-if="item.remainNum == 0" style="padding: 20rpx 0">
<text style="font-size: 32rpx; font-weight: 600">已售罄</text> <text style="font-size: 32rpx; font-weight: 600">已售罄</text>
...@@ -530,9 +524,9 @@ ...@@ -530,9 +524,9 @@
v-if="subItem.childItem.useDinnerType == '2'" v-if="subItem.childItem.useDinnerType == '2'"
>午餐:{{ subItem.childItem.dinnerName }}</text >午餐:{{ subItem.childItem.dinnerName }}</text
> >
<text v-if="subItem.childItem.useDinnerType == '3'">晚餐:{{ <text v-if="subItem.childItem.useDinnerType == '3'"
subItem.childItem.dinnerName >晚餐:{{ subItem.childItem.dinnerName }}</text
}}</text> >
</template> </template>
</text> </text>
</view> </view>
...@@ -1260,14 +1254,28 @@ export default { ...@@ -1260,14 +1254,28 @@ export default {
}, },
//立即预定 //立即预定
goReserce() { goReserce() {
let myCurrentInfo = this.currentPrice; let myObj={};
myCurrentInfo.startCityName = this.dataList.startCityName; // let myCurrentInfo = this.currentPrice;
// myCurrentInfo.startCityName = this.dataList.startCityName;
myObj.startCityName = this.dataList.startCityName
myObj.startDate = this.currentPrice.startDate;
myObj.dayNum = this.currentPrice.dayNum;
myObj.title = this.currentPrice.title;
myObj.b2BPrice = this.currentPrice.b2BPrice;
myObj.b2CPrice = this.currentPrice.b2CPrice;
myObj.childNeedPrice = this.currentPrice.childNeedPrice;
myObj.childNoNeedPrice = this.currentPrice.childNoNeedPrice;
myObj.babyPrice = this.currentPrice.babyPrice;
myObj.babyChargePrice = this.currentPrice.babyChargePrice;
myObj.b2BMemberPrice = this.currentPrice.b2BMemberPrice;
myObj.tcid = this.currentPrice.tcid;
let imgCover = JSON.parse(this.dataList.imgCover); let imgCover = JSON.parse(this.dataList.imgCover);
if (imgCover.length > 0) { if (imgCover.length > 0) {
myCurrentInfo.CoverImg = imgCover[0].Url; // myCurrentInfo.CoverImg = imgCover[0].Url;
myObj.CoverImg = imgCover[0].Url
} }
let myCurr = JSON.stringify(myCurrentInfo); let myCurr = JSON.stringify(myObj);
console.log(myCurrentInfo, "myCurrentInfo");
let ren = { let ren = {
crCount: this.crCount, crCount: this.crCount,
etCount: this.etCount, etCount: this.etCount,
...@@ -1278,12 +1286,10 @@ export default { ...@@ -1278,12 +1286,10 @@ export default {
url: url:
"/pages/jiuzhai/jz_Reserve?currentPriceInfo=" + "/pages/jiuzhai/jz_Reserve?currentPriceInfo=" +
encodeURIComponent(myCurr) + encodeURIComponent(myCurr) +
"&ln=" +
this.dataList.ltName +
"&seat=" + "&seat=" +
encodeURIComponent(JSON.stringify(ren)) + encodeURIComponent(JSON.stringify(ren)) +
"&tips=" + "&tcid=" +
encodeURIComponent(this.dataList.feature.importantTipText), this.delMsg.tcid,
}); });
}, },
......
This diff is collapsed.
...@@ -341,11 +341,7 @@ ...@@ -341,11 +341,7 @@
<text style="margin-right: 30rpx">成人</text> <text style="margin-right: 30rpx">成人</text>
</view> </view>
<view style="text-align: right" <view style="text-align: right"
>{{ orderMsg.ManNum }}人 × ¥{{ >{{ orderMsg.ManNum }}人 × ¥{{currentPriceInfo.b2CPrice}}</view
$utils.getretailer()
? currentPriceInfo.b2BPrice
: currentPriceInfo.b2CPrice
}}</view
> >
</view> </view>
<view <view
...@@ -501,7 +497,8 @@ export default { ...@@ -501,7 +497,8 @@ export default {
}); });
}, },
onLoad(option) { onLoad(option) {
if (option.currentPriceInfo) { console.log(504, option);
if (option.seat) {
this.currentPriceInfo = JSON.parse( this.currentPriceInfo = JSON.parse(
decodeURIComponent(option.currentPriceInfo) decodeURIComponent(option.currentPriceInfo)
); );
...@@ -510,12 +507,27 @@ export default { ...@@ -510,12 +507,27 @@ export default {
this.orderMsg.ChirdNeedBedNum = t.etCount; this.orderMsg.ChirdNeedBedNum = t.etCount;
this.orderMsg.ChirdNoBedNum = t.etbCount; this.orderMsg.ChirdNoBedNum = t.etbCount;
this.orderMsg.BabyNum = t.yeCount; this.orderMsg.BabyNum = t.yeCount;
this.tips = decodeURIComponent(option.tips);
this.calcMoney(); this.calcMoney();
this.ltName = option.ln; }
if (option.tcid) {
this.getDetails(option.tcid);
} }
}, },
methods: { methods: {
//获取详情
getDetails(id) {
this.apipost(
"b2b_get_GetB2BTravelInfoNoDesV1",
{ tcid: id },
(res) => {
if (res.resultCode == 1) {
this.tips = res.data.feature.importantTipText;
this.ltName = res.data.ltName;
}
},
null
);
},
updateUser() { updateUser() {
uni.navigateBack({ uni.navigateBack({
delta: 1, delta: 1,
...@@ -555,11 +567,13 @@ export default { ...@@ -555,11 +567,13 @@ export default {
//计算价格 //计算价格
calcMoney() { calcMoney() {
var price = 0; var price = 0;
if (this.$utils.getretailer()) { // if (this.$utils.getretailer()) {
price = this.currentPriceInfo.b2BMemberPrice; // price = this.currentPriceInfo.b2BPrice;
} else { // } else {
price = this.currentPriceInfo.b2CMemberPrice; // price = this.currentPriceInfo.b2CPrice;
} // }
price = this.currentPriceInfo.b2CPrice;
this.orderMsg.ChirdNum = this.orderMsg.ChirdNum =
parseInt(this.orderMsg.ChirdNoBedNum) + parseInt(this.orderMsg.ChirdNoBedNum) +
parseInt(this.orderMsg.ChirdNeedBedNum); parseInt(this.orderMsg.ChirdNeedBedNum);
...@@ -607,18 +621,11 @@ export default { ...@@ -607,18 +621,11 @@ export default {
this.submit = true; this.submit = true;
this.userInfo = uni.getStorageSync("mall_UserInfo"); this.userInfo = uni.getStorageSync("mall_UserInfo");
this.basedataObj = uni.getStorageSync("basedata").mall; this.basedataObj = uni.getStorageSync("basedata").mall;
var CustomerId = 0; var CustomerId = this.basedataObj.virtualB2BCustomerId;
var ContactName = this.contactName; var ContactName = this.contactName;
var ContactMobile = this.contactMobile; var ContactMobile = this.contactMobile;
var CustomerType = 3; var CustomerType = 4;
var price = 0; var price = this.currentPriceInfo.b2CPrice;
if (this.$utils.getretailer()) {
CustomerId = this.basedataObj.virtualB2BCustomerId;
CustomerType = 1;
price = this.currentPriceInfo.b2BMemberPrice;
} else {
price = this.currentPriceInfo.b2CMemberPrice;
}
let msg = { let msg = {
OrderId: 0, OrderId: 0,
TCID: this.currentPriceInfo.tcid, TCID: this.currentPriceInfo.tcid,
...@@ -763,18 +770,12 @@ export default { ...@@ -763,18 +770,12 @@ export default {
this.submit = true; this.submit = true;
this.userInfo = uni.getStorageSync("mall_UserInfo"); this.userInfo = uni.getStorageSync("mall_UserInfo");
this.basedataObj = uni.getStorageSync("basedata").mall; this.basedataObj = uni.getStorageSync("basedata").mall;
var CustomerId = 0; var CustomerId = this.basedataObj.virtualB2BCustomerId;
var ContactName = this.contactName; var ContactName = this.contactName;
var ContactMobile = this.contactMobile; var ContactMobile = this.contactMobile;
var CustomerType = 3; var CustomerType = 4;
var price = 0; var price = this.currentPriceInfo.b2CPrice;
if (this.$utils.getretailer()) {
CustomerId = this.basedataObj.virtualB2BCustomerId;
CustomerType = 1;
price = this.currentPriceInfo.b2BMemberPrice;
} else {
price = this.currentPriceInfo.b2CMemberPrice;
}
let msg = { let msg = {
OrderId: 0, OrderId: 0,
TCID: this.currentPriceInfo.tcid, TCID: this.currentPriceInfo.tcid,
...@@ -872,7 +873,6 @@ export default { ...@@ -872,7 +873,6 @@ export default {
duration: 2000, duration: 2000,
}); });
} }
console.log(873, res); console.log(873, res);
} }
); );
......
This diff is collapsed.
<template> <template>
<view class="integralDStyle" :style="{ height: contentHeight }"> <view class="integralDStyle" :style="{ height: contentHeight }">
<u-tabs :list="list" :is-scroll="false" :current="current" @change="change" :active-color="mainColor" height="100"></u-tabs> <u-tabs
<u-empty v-if="g.length == 0" text="暂无积分明细" mode="list"></u-empty> :list="list"
<view v-if="g.length > 0" style="height: calc(100vh - 50px);width: calc(100vw);overflow: hidden; "> :is-scroll="false"
<scroll-view :scroll-y="true" :enable-back-to-top="true" :enable-flex="true" @scrolltolower="lower" :style="{ height: '100%' }"> :current="current"
<view class="interDList" v-for="(x, i) in g" :key="i"> @change="change"
<Text>{{x.Description}}</Text> :active-color="mainColor"
<view style="display: flex;align-items: center;justify-content: space-between;width: 100%;margin-top: 5px;"> height="100"
<Text :style="{color:x.Type==1?mainColor:secondary}">{{x.Type==1?'+':'-'}}{{x.Integral}}积分</Text> :show-bar="showBar"
<Text style='font-size: 12px; color: #B5B5B5;'>时间:{{x.CreateDate}}</Text> ></u-tabs>
</view> <u-empty v-if="g.length == 0" text="暂无积分明细" mode="list"></u-empty>
</view> <view
<u-loadmore :status="status" :load-text="loadText" :font-size="24" :margin-top="20" :margin-bottom="20" bg-color="#f3f4f6" /> v-if="g.length > 0"
</scroll-view> style="height: calc(100vh - 50px); width: calc(100vw); overflow: hidden"
</view> >
<!-- 加载中 --> <scroll-view
<view class="loading" v-if="loading"> :scroll-y="true"
<u-loading mode="flower" size="48">></u-loading> :enable-back-to-top="true"
<Text style="color: #fff; margin-top: 10rpx;">加载中...</Text> :enable-flex="true"
</view> @scrolltolower="lower"
<!-- 取消提示 --> :style="{ height: '100%' }"
<u-toast ref="uToast" /> >
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth='gbAuth'></auth> <view class="interDList" v-for="(x, i) in g" :key="i">
</view> <Text>{{ x.Description }}</Text>
<view
style="
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
margin-top: 5px;
"
>
<Text :style="{ color: x.Type == 1 ? mainColor : secondary }"
>{{ x.Type == 1 ? "+" : "-" }}{{ x.Integral }}积分</Text
>
<Text style="font-size: 12px; color: #b5b5b5"
>时间:{{ x.CreateDate }}</Text
>
</view>
</view>
<u-loadmore
:status="status"
:load-text="loadText"
:font-size="24"
:margin-top="20"
:margin-bottom="20"
bg-color="#f3f4f6"
/>
</scroll-view>
</view>
<!-- 加载中 -->
<view class="loading" v-if="loading">
<u-loading mode="flower" size="48">></u-loading>
<Text style="color: #fff; margin-top: 10rpx">加载中...</Text>
</view>
<!-- 取消提示 -->
<u-toast ref="uToast" />
<auth
v-if="showAuth"
@changeuserinfo="reloadUserinfo"
@gbAuth="gbAuth"
></auth>
</view>
</template> </template>
<script> <script>
import auth from "../../../components/auth/index.vue"; import auth from "../../../components/auth/index.vue";
export default { export default {
components: { components: {
auth auth,
}, },
data() { data() {
return { return {
pageTitle: "积分明细", pageTitle: "积分明细",
current: 0, current: 0,
list: [{ list: [
name: "收入" {
}, name: "收入",
{ },
name: "支出" {
}, name: "支出",
], },
showAuth: false, ],
msg: { showAuth: false,
pageIndex: 1, msg: {
pageSize: 10, pageIndex: 1,
Type: 0 pageSize: 10,
}, Type: 0,
mainColor: "", },
secondary: '', mainColor: "",
contentHeight: 0, secondary: "",
page: 1, contentHeight: 0,
page_count: 1, page: 1,
g: [], page_count: 1,
loading: false, g: [],
isover: false, loading: false,
status: "loadmore", isover: false,
loadText: { status: "loadmore",
loadmore: "轻轻上拉,加载更多", loadText: {
loading: "努力加载中", loadmore: "轻轻上拉,加载更多",
nomore: "没有更多了", loading: "努力加载中",
}, nomore: "没有更多了",
}; },
}, showBar: true,
created() { };
this.contentHeight = this.$utils.calcContentHeight(-40) + "px"; },
this.mainColor = this.$uiConfig.mainColor; created() {
this.secondary = this.$uiConfig.secondary; this.contentHeight = this.$utils.calcContentHeight(-40) + "px";
}, this.mainColor = this.$uiConfig.mainColor;
mounted() { this.secondary = this.$uiConfig.secondary;
let currentPages = getCurrentPages(); // #ifdef MP-ALIPAY
let u = "/" + currentPages[currentPages.length - 1].route; this.showBar = false;
let pages = wx.getStorageSync("basedata") ? // #endif
wx.getStorageSync("basedata").bar_title : },
[]; mounted() {
pages.forEach((x) => { let currentPages = getCurrentPages();
if (x.value == u) { let u = "/" + currentPages[currentPages.length - 1].route;
this.pageTitle = x.new_name ? x.new_name : x.name; let pages = wx.getStorageSync("basedata")
} ? wx.getStorageSync("basedata").bar_title
}); : [];
uni.setNavigationBarTitle({ pages.forEach((x) => {
title: this.pageTitle, if (x.value == u) {
}); this.pageTitle = x.new_name ? x.new_name : x.name;
}, }
onLoad() { });
this.u = uni.getStorageSync("mall_UserInfo"); uni.setNavigationBarTitle({
if (!this.u) { title: this.pageTitle,
this.u = { });
nickName: "未登录", },
avatarUrl: "" onLoad() {
}; this.u = uni.getStorageSync("mall_UserInfo");
this.showAuth = true; if (!this.u) {
} else { this.u = {
this.init(); nickName: "未登录",
} avatarUrl: "",
}, };
methods: { this.showAuth = true;
change(index) { } else {
this.current = index; this.init();
this.msg.pageIndex = 1; }
this.g = []; },
this.loading = true; methods: {
this.init(); change(index) {
}, this.current = index;
init() { this.msg.pageIndex = 1;
this.loading = true; this.g = [];
this.msg.Type = this.current + 1 this.loading = true;
this.request2({ this.init();
url: '/api/AppletUser/GetMemberIntegralPageList', },
data: this.msg init() {
}, this.loading = true;
res => { this.msg.Type = this.current + 1;
if (res.resultCode == 1) { this.request2(
this.loading = false; {
this.g = this.g.concat(res.data.pageData); url: "/api/AppletUser/GetMemberIntegralPageList",
this.page_count = res.data.pageCount; data: this.msg,
if (this.page_count == 1) { },
this.status = "nomore"; (res) => {
} if (res.resultCode == 1) {
} this.loading = false;
} this.g = this.g.concat(res.data.pageData);
); this.page_count = res.data.pageCount;
}, if (this.page_count == 1) {
lower(e) { this.status = "nomore";
if (this.msg.pageIndex < this.page_count) { }
this.msg.pageIndex++; }
this.status = "loading"; }
this.init(); );
} else { },
this.status = "nomore"; lower(e) {
} if (this.msg.pageIndex < this.page_count) {
}, this.msg.pageIndex++;
reloadUserinfo() { this.status = "loading";
this.u = uni.getStorageSync("mall_UserInfo"); this.init();
this.init(); } else {
}, this.status = "nomore";
//关闭登录窗口 }
gbAuth() { },
uni.navigateBack() reloadUserinfo() {
} this.u = uni.getStorageSync("mall_UserInfo");
}, this.init();
}; },
//关闭登录窗口
gbAuth() {
uni.navigateBack();
},
},
};
</script> </script>
<style> <style>
.integralDStyle { .integralDStyle {
width: 100%; width: 100%;
height: 100%; height: 100%;
background: #f3f4f6; background: #f3f4f6;
} }
.integralDStyle .loading { .integralDStyle .loading {
width: 200rpx; width: 200rpx;
height: 200rpx; height: 200rpx;
background: #000000; background: #000000;
opacity: 0.7; opacity: 0.7;
border-radius: 10rpx; border-radius: 10rpx;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
position: fixed; position: fixed;
left: 50%; left: 50%;
top: 30%; top: 30%;
margin-left: -100rpx; margin-left: -100rpx;
z-index: 999; z-index: 999;
} }
.integralDStyle .interDList { .integralDStyle .interDList {
width: 100%; width: 100%;
padding: 20px 15px; padding: 20px 15px;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
background: #fff; background: #fff;
border-top: 1px solid #f5f5f5; border-top: 1px solid #f5f5f5;
} }
</style> </style>
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