Commit 4d078883 by wangzhihui

一轮bug修复

1 parent edbefe64
......@@ -66,4 +66,5 @@
</view>
</Dialog>
<!-- <dialog show="{{showModal}}" confirmText="{{success?'去兑换':'我知道了'}}" cancelText="我知道了" showCancelButton success="{{success}}" bindconfirm="dialogConfirm" bindcancel="dialogClose" text="{{dialogText}}"> -->
<!-- </dialog> -->
\ No newline at end of file
<!-- </dialog> -->
<glsx-privacy appletName="积分商城"></glsx-privacy>
\ No newline at end of file
......@@ -168,6 +168,7 @@
font-weight: 600;
font-size: 40rpx;
color: #333333;
text-align: center;
}
.text {
......@@ -175,6 +176,7 @@
color: #888888;
line-height: 36rpx;
white-space: nowrap;
text-align: center;
}
}
......
......@@ -134,12 +134,14 @@
color: #333333;
font-size: 34rpx;
font-weight: 600;
text-align: center;
}
.text{
font-weight: 400;
font-size: 24rpx;
color: #888888;
margin-top:6rpx;
text-align: center;
}
}
}
......
......@@ -90,4 +90,12 @@
width: 0;
height: 0;
color: transparent;
}
.list_data_widget {
// 隐藏滚动条但保持滚动功能
&::-webkit-scrollbar {
display: none; // Webkit浏览器
}
scrollbar-width: none; // Firefox
-ms-overflow-style: none; // IE/Edge
}
\ No newline at end of file
......@@ -4,7 +4,7 @@
收益明细
</view>
<block wx:if="{{list.length}}">
<scroll-view class="list_data_widget" scroll-y="{{true}}" bindrefresherrefresh="bindrefresherrefresh" bindscrolltolower="scrollonReachBottom" refresher-threshold="104" refresher-triggered="{{triggered}}">
<scroll-view class="list_data_widget" scroll-y="{{true}}"enhanced="{{true}}" show-scrollbar="{{false}}" bindrefresherrefresh="bindrefresherrefresh" bindscrolltolower="scrollonReachBottom" refresher-threshold="104" refresher-triggered="{{triggered}}">
<block wx:for="{{list}}" wx:key="index">
<view class="element" bind:tap="handleDetail" data-id="{{item.id}}" data-infoName="{{item.infoName}}" data-channelSource="{{item.channelSource}}">
<view class="title">{{item.infoName}}
......
......@@ -8,6 +8,7 @@ Page({
navStyle: "background-color: transparent;",
showBank: false,
agree: false,
btnDisabled: true,
isConfig: true,
showAuthDialog: false,
showConfirmDialog: false,
......@@ -200,6 +201,8 @@ Page({
} = this.data;
this.setData({
sumbitScore: score
},()=>{
this.checkBtn(score)
})
},
handleInput(e) {
......@@ -213,6 +216,13 @@ Page({
sumbitScore = this.priceVerify(value, score)
this.setData({
sumbitScore: sumbitScore || ''
}, () => {
this.checkBtn(sumbitScore)
})
},
checkBtn(score) {
this.setData({
btnDisabled: Number(score) ? false : true
})
},
// 价格输入校验规则(提现积分值:最小值需大于0)
......@@ -314,14 +324,16 @@ Page({
* 生命周期函数--监听页面显示
*/
onShow() {
if (this.refresh) {
this.getBankList()
}
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
this.refresh = true;
},
/**
......
......@@ -150,7 +150,7 @@
}
.submit {
.button {
font-weight: 500;
font-size: 32rpx;
color: #FFFFFF;
......@@ -163,7 +163,19 @@
position: fixed;
bottom: 266rpx;
left:48rpx;
&[disabled]:not([type]) {
background: #CCCED1 !important;
border-color: #CCCED1 !important;
color: #fff !important;
box-shadow: none;
&::after {
border-color: #CCCED1 !important;
}
}
}
}
}
......@@ -187,4 +199,5 @@
.suggest-box {
font-size: 28rpx;
color: #1B233D;
}
\ No newline at end of file
}
......@@ -40,7 +40,8 @@
<!-- 协议 -->
<auth-setting bind:choose="authChoose" agree="{{ agree }}" url="{{disclaimerAgreementUrl}}" />
</view>
<view class="submit" bind:tap="toSumbitData">提交</view>
<!-- <view class="submit" bind:tap="toSumbitData">提交</view> -->
<button class="button text-center" disabled="{{btnDisabled}}" hover-class="btn-hover" loading="{{submitLoading}}" bind:tap="toSumbitData">提交</button>
</view>
</view>
......
......@@ -12,7 +12,6 @@ Page({
const {
reason
} = e.currentTarget.dataset
// wx.$api.showToast(reason);
wx.showModal({
title: '',
content: String(reason),
......
......@@ -151,4 +151,9 @@ page {
color: #7A8299;
text-align: center;
}
}
.error-icon{
width: 24rpx;
height: 56rpx;
margin-left:4rpx;
}
\ No newline at end of file
......@@ -18,15 +18,15 @@
</block>
<view class="countText flex">
-{{i.withdrawalScore}}
<!-- <block wx:if="{{item.status == 4&&item.failReason}}">
<block wx:if="{{i.status == 4&&i.failReason}}">
<view class="type flex">
<view class="failReason">{{item.failReason}} </view>
<glsx-image mode="widthFix" class="error-icon" bind:tap="toastError" data-reason="{{item.failReason}}" src="store-assistant/error-icon.png" />
<view class="failReason">{{i.failReason}} </view>
<glsx-image mode="widthFix" class="error-icon" bind:tap="toastError" data-reason="{{i.failReason}}" src="/bankAccount/error-icon.png" />
</view>
</block> -->
<block>
</block>
<block wx:else>
<view class="type">
银行卡兑换
银行卡提现积分
</view>
</block>
......
......@@ -30,6 +30,27 @@ Page({
this.getGoodsList()
})
},
simpleWanConvert(num) {
if (num === null || num === undefined || isNaN(num)) {
return '';
}
// 处理大于等于10000的数字
if (Math.abs(num) >= 10000) {
const wan = (num / 10000).toFixed(1);
// 去掉末尾的.0
return parseFloat(wan) == parseInt(wan) ? parseInt(wan) + '万' : wan + '万';
}
// 处理小于10000但大于等于1000的数字
else if (Math.abs(num) >= 1000) {
const qian = (num / 10000).toFixed(1);
return qian + '万';
}
// 小于1000的数字直接返回
else {
return num.toString();
}
},
// 获取商品数据
getGoodsList() {
......@@ -110,7 +131,10 @@ Page({
}).then(res => {
if (res.code == 0) {
this.setData({
taxRateObj: res.data
taxRateObj:{
...res.data,
baseIncome:this.simpleWanConvert(res.data.baseIncome)
}
})
}
}).catch(err => {
......
......@@ -99,7 +99,7 @@
background-size: 100%;
background-repeat: no-repeat;
background-image: url('https://img02.glsx.com.cn/weapp/resource/miniprogram/points-mall/integral/rule-bg.png');
position:relative;
.salary {
padding: 114rpx 32rpx 144rpx;
......@@ -112,8 +112,17 @@
.income {
color: #FFFFFF;
}
}
}
.hypothesis {
font-weight: 400;
font-size: 24rpx;
color: #F55800;
position:absolute;
right:32rpx;
top:2rpx;
}
.accumulative {
margin-bottom: 48rpx;
......@@ -204,9 +213,10 @@
font-size: 32rpx;
color: #FB8A32;
text-align: center;
line-height:80rpx;
line-height: 80rpx;
}
.withdraw{
.withdraw {
background: #FB8A32;
color: #FFFFFF;
}
......
......@@ -19,7 +19,9 @@
<view class="salary flex_scb">
<view class="proportion">{{taxRateObj.taxRateWithoutSalary}}%</view>
<view class="proportion income">{{taxRateObj.taxRateWithSalary}}%</view>
</view>
<view class="hypothesis">假设月工资{{taxRateObj.baseIncome}}</view>
<view class="accumulative flex_sc">
<view class="earning have-no">
<view class="money">{{taxRateObj.totalIncomeWithoutSalary}}元</view>
......@@ -27,7 +29,7 @@
</view>
<view class=" earning have">
<view class="money">{{taxRateObj.totalIncomeWithSalary}}元</view>
<view class="text">{{taxRateObj.withdrawalScore}}*{{taxRateObj.month}}个月+累计提现+本次提现</view>
<view class="text">{{taxRateObj.baseIncome}}*{{taxRateObj.month}}个月+累计提现+本次提现</view>
</view>
</view>
<view class="tips">以上仅为本平台评估展示,本次提现金额不会扣除,您的真实税务建议您去<text>个人所得税APP</text>查询</view>
......
......@@ -25,15 +25,19 @@ Page({
this.login();
},
loginOut() {
console.log(1111)
wx.p.storage.rm('sessionId')
wx.p.isLogin = false
wx.p.storage.rm('userInfo')
wx.p.router.reLaunch('/pages/Login/Login')
},
async login(options = {}) {
console.log(777)
if (!wx.p.storage.get('sessionId')) return this.loginOut()
try {
console.log('try')
const { code, data, message } = await commonApi.getLoginInfo();
console.log(code,'code')
if (code == 0) {
let userInfo = wx.p.storage.get('userInfo')
if (userInfo && Object.keys(userInfo)?.length) {
......@@ -51,6 +55,7 @@ Page({
return this.jumpPage(options.url);
}
} catch (error) {
console.log(90900)
wx.p.isLogin = false; //请求失败默认未登录
console.log(error);
wx.p.wxApi.showToast(String(error));
......
......@@ -7,8 +7,8 @@
export const authPages = [
'/packageMine/',
'/pages/mine/',
'/packageIndex/'
// '/packageIndex/pages/integral/index/index' //积分
'/packageIndex/',
'/packageIndex/pages/integral/index/index' //积分
];
// 不需要拦截的页面路径配置
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!