Browse Source

feature:注销方法修正

feature-1.0
Penny 3 years ago
parent
commit
f323a1f0a6
  1. 71
      pages/userInfo/setting/setting.vue

71
pages/userInfo/setting/setting.vue

@ -10,9 +10,9 @@
</template> </template>
<script> <script>
// import { import {
// logout logout
// } from '@/api/auth.js' } from '@/api/auth.js'
export default { export default {
data() { data() {
return { return {
@ -67,40 +67,37 @@
// }, // },
methods: { methods: {
// //
// logoutUser(){ logoutUser(){
// let that = this; let that = this;
// uni.showModal({ uni.showModal({
// title: "", title: "提示",
// content: "", content: "确定注销吗!",
// showCancel: true, showCancel: true,
// success: function(ress){ success: function(ress){
// if(ress.confirm){ if(ress.confirm){
// const param = { logout().then(res => {
// phone: that.userInfo.phone if (res.data.code === 200) {
// } uni.reLaunch({
// logout(param).then(res => { url: '/pages/index/index',
// if (res.data.data === true) { success() {
// uni.reLaunch({ uni.clearStorage();
// url: '/pages/login/login', uni.showToast({
// success() { title: '注销成功!',
// uni.clearStorage(); duration: 2000
// uni.showToast({ });
// title: '!', }
// duration: 2000 });
// }); } else {
// } uni.showModal({
// }); content: "注销失败,请联系管理员!",
// } else { showCancel: false,
// uni.showModal({ });
// content: "!", }
// showCancel: false, });
// }); }
// } }
// }); });
// } }
// }
// });
// }
} }
} }
</script> </script>

Loading…
Cancel
Save