dt积分冻结模块处理重置签到处理等接口
This commit is contained in:
12
pages.json
12
pages.json
@@ -367,7 +367,17 @@
|
|||||||
"path": "pages/life/capacity",
|
"path": "pages/life/capacity",
|
||||||
"name": "Capacity",
|
"name": "Capacity",
|
||||||
"style": {
|
"style": {
|
||||||
"navigationBarTitleText": "-"
|
"navigationBarTitleText": "-",
|
||||||
|
"app-plus": {
|
||||||
|
"titleNView": {
|
||||||
|
"buttons": [{
|
||||||
|
"text": "重置签到",
|
||||||
|
"fontSize": "14",
|
||||||
|
"width": "80px",
|
||||||
|
"color": "#34CE98"
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"path": "pages/feedback/feedback",
|
"path": "pages/feedback/feedback",
|
||||||
|
|||||||
@@ -5,15 +5,31 @@
|
|||||||
<view class="title">DT积分余额</view>
|
<view class="title">DT积分余额</view>
|
||||||
<view class="num">{{score}}</view>
|
<view class="num">{{score}}</view>
|
||||||
</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('AccountRecharge')">充值</button>
|
||||||
<button class="transfer" size="mini" @click="onTransfer('AccountTransfer')">转账</button>
|
<button class="transfer" size="mini" @click="onTransfer('AccountTransfer')">转账</button>
|
||||||
</view>
|
</view>
|
||||||
<block v-if="logs.length > 0">
|
<block v-if="logs.length > 0">
|
||||||
<view class="logs-title">账户记录</view>
|
<view class="logs-title">账户记录</view>
|
||||||
<view class="logs-item" v-for="(item,index) in logs" :key="index">
|
<view class="logs-item" v-for="(item,index) in logs" :key="index" @click="frozenInfo(item.description)">
|
||||||
<view class="logs-item-title">{{item.remark}}</view>
|
<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-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>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
<block v-else>
|
<block v-else>
|
||||||
@@ -33,9 +49,11 @@
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
score: '0.00',
|
score: '0.00',
|
||||||
|
frozenScore: '0.00',
|
||||||
logs: [],
|
logs: [],
|
||||||
page: 1,
|
page: 1,
|
||||||
has_more: true,
|
has_more: true,
|
||||||
|
description:'',
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
@@ -60,8 +78,10 @@
|
|||||||
this.logs = [];
|
this.logs = [];
|
||||||
}
|
}
|
||||||
this.score = res.score;
|
this.score = res.score;
|
||||||
this.logs = this.logs.concat(res.lists.data);
|
this.frozenScore = res.frozenScore;
|
||||||
this.has_more = res.lists.page.has_more;
|
this.logs = this.logs.concat(res.lists.data);
|
||||||
|
this.description = res.description;
|
||||||
|
this.has_more = res.lists.page.has_more;
|
||||||
uni.stopPullDownRefresh();
|
uni.stopPullDownRefresh();
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -75,7 +95,19 @@
|
|||||||
this.$Router.push({
|
this.$Router.push({
|
||||||
name
|
name
|
||||||
})
|
})
|
||||||
}
|
},
|
||||||
|
frozenInfo(description){
|
||||||
|
if(description!== ''){
|
||||||
|
uni.showModal({
|
||||||
|
title:'温馨提示',
|
||||||
|
content:description,
|
||||||
|
showCancel:false,
|
||||||
|
confirmColor:"#34ce98",
|
||||||
|
confirmText:' 知道了'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
},
|
},
|
||||||
onNavigationBarButtonTap() {
|
onNavigationBarButtonTap() {
|
||||||
this.$Router.push({
|
this.$Router.push({
|
||||||
@@ -99,7 +131,7 @@
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
background: $main-color;
|
background: $main-color;
|
||||||
padding: $padding*3 $padding $padding*2;
|
padding: $padding*2 $padding 0;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
.dt-header-number {
|
.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 {
|
.logs-title {
|
||||||
padding: 0 $padding;
|
padding: 0 $padding;
|
||||||
@@ -158,11 +240,20 @@
|
|||||||
.logs-item-title {
|
.logs-item-title {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: 30rpx;
|
font-size: 30rpx;
|
||||||
line-height: 50rpx;
|
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 {
|
.logs-item-time {
|
||||||
font-size: 28rpx;
|
font-size: 26rpx;
|
||||||
line-height: 40rpx;
|
line-height: 40rpx;
|
||||||
color: gray;
|
color: gray;
|
||||||
}
|
}
|
||||||
@@ -175,6 +266,7 @@
|
|||||||
width: 180rpx;
|
width: 180rpx;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
|
font-size: 30rpx;
|
||||||
@extend .nowrap;
|
@extend .nowrap;
|
||||||
|
|
||||||
&.add {
|
&.add {
|
||||||
@@ -184,6 +276,15 @@
|
|||||||
&.remove {
|
&.remove {
|
||||||
color: $text-price;
|
color: $text-price;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
view {
|
||||||
|
position: absolute;
|
||||||
|
top: $padding+4;
|
||||||
|
right: 0;
|
||||||
|
color: #999;
|
||||||
|
font-size: 22rpx;
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -126,10 +126,82 @@
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
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: {
|
methods: {
|
||||||
onInvitation(){
|
onInvitation(){
|
||||||
this.$Router.push({name: 'Invitation'})
|
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('非安卓设备');
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
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