dt积分冻结模块处理重置签到处理等接口
This commit is contained in:
12
pages.json
12
pages.json
@@ -367,7 +367,17 @@
|
||||
"path": "pages/life/capacity",
|
||||
"name": "Capacity",
|
||||
"style": {
|
||||
"navigationBarTitleText": "-"
|
||||
"navigationBarTitleText": "-",
|
||||
"app-plus": {
|
||||
"titleNView": {
|
||||
"buttons": [{
|
||||
"text": "重置签到",
|
||||
"fontSize": "14",
|
||||
"width": "80px",
|
||||
"color": "#34CE98"
|
||||
}]
|
||||
}
|
||||
}
|
||||
}
|
||||
}, {
|
||||
"path": "pages/feedback/feedback",
|
||||
|
||||
@@ -5,15 +5,31 @@
|
||||
<view class="title">DT积分余额</view>
|
||||
<view class="num">{{score}}</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="dt-header1">
|
||||
<view class="dt-header-number">
|
||||
<view class="title" @click="frozenInfo(description)">
|
||||
DT积分冻结
|
||||
<image src="/static/rank/help.png" style="width: 30rpx;" mode="widthFix" />
|
||||
</view>
|
||||
<view class="num">{{frozenScore}}</view>
|
||||
</view>
|
||||
<button class="transfer" size="mini" @click="onTransfer('AccountRecharge')">充值</button>
|
||||
<button class="transfer" size="mini" @click="onTransfer('AccountTransfer')">转账</button>
|
||||
</view>
|
||||
<block v-if="logs.length > 0">
|
||||
<view class="logs-title">账户记录</view>
|
||||
<view class="logs-item" v-for="(item,index) in logs" :key="index">
|
||||
<view class="logs-item-title">{{item.remark}}</view>
|
||||
<view class="logs-item" v-for="(item,index) in logs" :key="index" @click="frozenInfo(item.description)">
|
||||
<view class="logs-item-title">
|
||||
{{item.remark}}
|
||||
<image v-if ="item.description!== ''" src="/static/rank/help3.png" mode="widthFix" />
|
||||
</view>
|
||||
<view class="logs-item-time">{{item.created_at}}</view>
|
||||
<view class="logs-item-price" :class="item.amount > 0 ? 'add': 'remove'">{{item.amount}}</view>
|
||||
<view class="logs-item-price" :class="item.amount > 0 ? 'add': 'remove'">
|
||||
{{item.amount}}
|
||||
<view v-if="item.frozen.value === 1"> {{item.frozen.value === 1?'冻结中':item.frozen.text}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<block v-else>
|
||||
@@ -33,9 +49,11 @@
|
||||
data() {
|
||||
return {
|
||||
score: '0.00',
|
||||
frozenScore: '0.00',
|
||||
logs: [],
|
||||
page: 1,
|
||||
has_more: true,
|
||||
description:'',
|
||||
};
|
||||
},
|
||||
onShow() {
|
||||
@@ -60,7 +78,9 @@
|
||||
this.logs = [];
|
||||
}
|
||||
this.score = res.score;
|
||||
this.frozenScore = res.frozenScore;
|
||||
this.logs = this.logs.concat(res.lists.data);
|
||||
this.description = res.description;
|
||||
this.has_more = res.lists.page.has_more;
|
||||
uni.stopPullDownRefresh();
|
||||
}).catch(err => {
|
||||
@@ -75,8 +95,20 @@
|
||||
this.$Router.push({
|
||||
name
|
||||
})
|
||||
},
|
||||
frozenInfo(description){
|
||||
if(description!== ''){
|
||||
uni.showModal({
|
||||
title:'温馨提示',
|
||||
content:description,
|
||||
showCancel:false,
|
||||
confirmColor:"#34ce98",
|
||||
confirmText:' 知道了'
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
},
|
||||
onNavigationBarButtonTap() {
|
||||
this.$Router.push({
|
||||
name: 'AccountCode'
|
||||
@@ -99,7 +131,7 @@
|
||||
justify-content: space-between;
|
||||
flex-direction: row;
|
||||
background: $main-color;
|
||||
padding: $padding*3 $padding $padding*2;
|
||||
padding: $padding*2 $padding 0;
|
||||
align-items: center;
|
||||
|
||||
.dt-header-number {
|
||||
@@ -137,6 +169,56 @@
|
||||
}
|
||||
}
|
||||
|
||||
.dt-header1 {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
flex-direction: row;
|
||||
background: $main-color;
|
||||
padding: $padding $padding $padding*2;
|
||||
align-items: center;
|
||||
|
||||
.dt-header-number {
|
||||
width: calc(100% - 330rpx);
|
||||
|
||||
.title {
|
||||
color: rgba(255, 255, 255, .9);
|
||||
font-size: 28rpx;
|
||||
@extend .nowrap;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
box-sizing: border-box;
|
||||
image{
|
||||
padding-left: 4rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.num {
|
||||
font-weight: bold;
|
||||
font-size: 40rpx;
|
||||
color: white;
|
||||
@extend .nowrap;
|
||||
}
|
||||
}
|
||||
|
||||
.transfer[size="mini"] {
|
||||
width: 160rpx;
|
||||
height: 70rpx;
|
||||
border-radius: 40rpx;
|
||||
line-height: 70rpx;
|
||||
background: white;
|
||||
font-size: 30rpx;
|
||||
color: $main-color;
|
||||
margin: 0;
|
||||
font-weight: bold;
|
||||
|
||||
&::after {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 账户记录
|
||||
.logs-title {
|
||||
padding: 0 $padding;
|
||||
@@ -159,10 +241,19 @@
|
||||
font-weight: bold;
|
||||
font-size: 30rpx;
|
||||
line-height: 50rpx;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
box-sizing: border-box;
|
||||
image{
|
||||
width: 30rpx;
|
||||
padding-left: 4rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.logs-item-time {
|
||||
font-size: 28rpx;
|
||||
font-size: 26rpx;
|
||||
line-height: 40rpx;
|
||||
color: gray;
|
||||
}
|
||||
@@ -175,6 +266,7 @@
|
||||
width: 180rpx;
|
||||
text-align: right;
|
||||
font-weight: bold;
|
||||
font-size: 30rpx;
|
||||
@extend .nowrap;
|
||||
|
||||
&.add {
|
||||
@@ -184,6 +276,15 @@
|
||||
&.remove {
|
||||
color: $text-price;
|
||||
}
|
||||
|
||||
view {
|
||||
position: absolute;
|
||||
top: $padding+4;
|
||||
right: 0;
|
||||
color: #999;
|
||||
font-size: 22rpx;
|
||||
font-weight: normal;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -126,9 +126,81 @@
|
||||
})
|
||||
})
|
||||
},
|
||||
onNavigationBarButtonTap() {
|
||||
uni.showModal({
|
||||
title:'温馨提示',
|
||||
content:'重置签到只重新计算24小时时间,所迭代加成的比例不变',
|
||||
confirmColor:'#34CE98',
|
||||
confirmText:'立即重置',
|
||||
cancelColor:'#999',
|
||||
cancelText:'再想想',
|
||||
success: (res) => {
|
||||
if(res.confirm){
|
||||
console.log('再次签到。。。')
|
||||
this.checkIMEI().then(res => {
|
||||
switch (res) {
|
||||
case 'Permanent':
|
||||
uni.showModal({
|
||||
title: '提示',
|
||||
content: '签到功能需使用您的电话状态和网络信息,请在手机设置中权限开启您的权限',
|
||||
showCancel: false,
|
||||
})
|
||||
break;
|
||||
case 'Temporary':
|
||||
uni.showModal({
|
||||
title: '提示',
|
||||
content: '签到功能需使用您的电话状态和网络信息,请点击设置开启应用权限',
|
||||
cancelText: '获取权限',
|
||||
confirmText: '稍后再说',
|
||||
success: e => {
|
||||
if (e.cancel) {
|
||||
this.checkIMEI().then(IMEI => {
|
||||
if (IMEI === 'Success') {
|
||||
this.showAd()
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
break;
|
||||
case 'Success':
|
||||
this.showAd()
|
||||
break;
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
onInvitation(){
|
||||
this.$Router.push({name: 'Invitation'})
|
||||
},
|
||||
// imei权限
|
||||
checkIMEI() {
|
||||
// 检查imei权限
|
||||
return new Promise((resolve, reject) => {
|
||||
if (plus.os.name == "Android") {
|
||||
plus.android.requestPermissions(['android.permission.READ_PHONE_STATE'], (e) => {
|
||||
if (e.deniedAlways.length > 0) {
|
||||
resolve('Permanent');
|
||||
}
|
||||
if (e.deniedPresent.length > 0) {
|
||||
resolve('Temporary');
|
||||
}
|
||||
if (e.granted.length > 0) {
|
||||
resolve('Success');
|
||||
}
|
||||
}, (e) => {
|
||||
uni.showToast({
|
||||
title: JSON.stringify(e),
|
||||
icon: 'none'
|
||||
})
|
||||
})
|
||||
return
|
||||
}
|
||||
reject('非安卓设备');
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
BIN
static/rank/help2.png
Normal file
BIN
static/rank/help2.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.5 KiB |
BIN
static/rank/help3.png
Normal file
BIN
static/rank/help3.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.5 KiB |
File diff suppressed because one or more lines are too long
114
unpackage/dist/dev/app-plus/app-service.js
vendored
114
unpackage/dist/dev/app-plus/app-service.js
vendored
File diff suppressed because one or more lines are too long
112
unpackage/dist/dev/app-plus/app-view.js
vendored
112
unpackage/dist/dev/app-plus/app-view.js
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user