提交 40b623e9 编写于 作者: DCloud_JSON's avatar DCloud_JSON

- 新增注销用户账号的功能 - 修复在某些情况下,签到不连续7天,也获得60积分的问题

上级 3460a423
## 1.1.24(2021-11-29)
- 新增注销用户账号的功能
- 修复在某些情况下,签到不连续7天,也获得60积分的问题
## 1.1.23(2021-11-20) ## 1.1.23(2021-11-20)
- 使用`uni.getUniverifyManager`优化一键登陆中,点击第三方登陆的逻辑:未勾选隐私政策时,toast提醒并阻止了一键登陆界面的close - 使用`uni.getUniverifyManager`优化一键登陆中,点击第三方登陆的逻辑:未勾选隐私政策时,toast提醒并阻止了一键登陆界面的close
- 新增支持看激励视频广告签到 - 新增支持看激励视频广告签到
......
{ {
"id": "uni-starter", "id": "uni-starter",
"displayName": "uni-starter", "displayName": "uni-starter",
"version": "1.1.23", "version": "1.1.24",
"description": "云端一体应用快速开发基本项目模版", "description": "云端一体应用快速开发基本项目模版",
"keywords": [ "keywords": [
"login", "login",
......
...@@ -22,6 +22,9 @@ ...@@ -22,6 +22,9 @@
</template> </template>
<script> <script>
import {
mapMutations
} from 'vuex';
export default { export default {
data() { data() {
return { return {
...@@ -32,12 +35,11 @@ ...@@ -32,12 +35,11 @@
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: this.$t('deactivate.navigationBarTitle') title: this.$t('deactivate.navigationBarTitle')
}) })
uni.showModal({
content: '该功能暂未完全开发完成,敬请期待!',
showCancel: false
});
}, },
methods: { methods: {
...mapMutations({
logout: 'user/logout'
}),
cancel(){ cancel(){
uni.navigateBack() uni.navigateBack()
}, },
...@@ -46,10 +48,29 @@ ...@@ -46,10 +48,29 @@
content: '已经仔细阅读注销提示,知晓可能带来的后果,并确认要注销', content: '已经仔细阅读注销提示,知晓可能带来的后果,并确认要注销',
complete: (e) => { complete: (e) => {
if(e.confirm){ if(e.confirm){
uni.showToast({ uniCloud.callFunction({
title: '该功能暂未开发完成', name:'uni-id-cf',
icon: 'none' data:{
}); "action":"closeAccount"
},
complete: (e) => {
console.log(e);
if(e.result.code === 0){
uni.showToast({
title: '注销成功'
});
this.logout();
uni.navigateTo({
url:"/pages/ucenter/login-page/index/index"
})
}else{
uni.showToast({
icon:'error',
title: e.result.errMsg
});
}
}
})
}else{ }else{
uni.navigateBack() uni.navigateBack()
} }
......
## 1.0.8(2021-11-29)
新增 `closeAccount`注销账号
## 1.0.7(2021-10-20) ## 1.0.7(2021-10-20)
新增bindMobileByMpWeixin,一键获取微信绑定的手机号 新增bindMobileByMpWeixin,一键获取微信绑定的手机号
## 1.0.6(2021-09-23) ## 1.0.6(2021-09-23)
......
{ {
"id": "uni-id-cf", "id": "uni-id-cf",
"displayName": "uni-id-cf", "displayName": "uni-id-cf",
"version": "1.0.7", "version": "1.0.8",
"description": "uni-id-cf", "description": "uni-id-cf",
"keywords": [ "keywords": [
"uni-id-cf", "uni-id-cf",
......
...@@ -443,6 +443,10 @@ exports.main = async (event, context) => { ...@@ -443,6 +443,10 @@ exports.main = async (event, context) => {
uid: params.uid uid: params.uid
}) })
} }
break;
case 'closeAccount':
console.log(params.uid,'-----------------------');
res = await uniID.closeAccount({uid:params.uid});
break; break;
// =========================== admin api start ========================= // =========================== admin api start =========================
......
## 1.0.4(2021-11-29)
修复在某些情况下,签到不连续7天,也获得60积分的问题
## 1.0.3(2021-11-20) ## 1.0.3(2021-11-20)
新增支持看激励视频广告签到 新增支持看激励视频广告签到
## 1.0.2(2021-08-25) ## 1.0.2(2021-08-25)
......
{ {
"id": "uni-sign-in", "id": "uni-sign-in",
"displayName": "签到插件 - 提升用户粘性,流量变现", "displayName": "签到插件 - 提升用户粘性,流量变现",
"version": "1.0.3", "version": "1.0.4",
"description": "培养用户习惯,提升用户粘性,支持广告流量变现的签到得积分功能", "description": "培养用户习惯,提升用户粘性,支持广告流量变现的签到得积分功能",
"keywords": [ "keywords": [
"uni-sign-in", "uni-sign-in",
......
...@@ -74,7 +74,7 @@ module.exports = async function({user_id,ip}) { ...@@ -74,7 +74,7 @@ module.exports = async function({user_id,ip}) {
}); });
} }
//给加积分 //给加积分
let score = n == 7 ? 60 : 10 //如果是第七天就多加50分,也就是60分 let score = n+days.length==14?60:10 //如果连续签到7天就多加50分,也就是60分
balance += score balance += score
let addScores = await scoresTable.add({ let addScores = await scoresTable.add({
user_id, user_id,
......
...@@ -62,7 +62,7 @@ module.exports = { ...@@ -62,7 +62,7 @@ module.exports = {
console.log({setIsDeleteRes}); console.log({setIsDeleteRes});
} }
//给加积分 //给加积分
let score = n==7?60:10 //如果是第七天就多加50分,也就是60分 let score = n+days.length==14?60:10 //如果连续签到7天就多加50分,也就是60分
balance += score balance += score
let addScores = await scoresTable.add({ let addScores = await scoresTable.add({
user_id:state.auth.uid, user_id:state.auth.uid,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册