Browse Source

[WHAT] 重啟帳號API串接 [WHY] 開發 ShowEasy 前台

登入、忘記密碼:註銷帳號API串接
Dev
Janie 2 years ago
parent
commit
a4b81cce4f
  1. 25
      FrontEnd/pages/user/forgot.vue
  2. 21
      FrontEnd/pages/user/index.vue

25
FrontEnd/pages/user/forgot.vue

@ -163,7 +163,7 @@
{{ $t("Would you like to reactivate this account?")}}
</div>
</v-spacer>
<button class="tw-bg-primary-1 tw-text-white hover:tw-bg-primary-light tw-text-[18px] tw-rounded-[16px] tw-px-[86px] tw-py-[13px]">
<button @click="ReactivateAccount()" class="tw-bg-primary-1 tw-text-white hover:tw-bg-primary-light tw-text-[18px] tw-rounded-[16px] tw-px-[86px] tw-py-[13px]">
{{ $t("Reactivate my account") }}
</button>
<!-- <v-btn class="primary tw-w-auto" rounded
@ -317,6 +317,8 @@ export default {
//console.log(JSON.stringify(response))
if(response && response.data){
this.dialog = false;
clearInterval(this.timer);
this.timer = setInterval(() => {
if (this.countdown > 0) {
@ -331,8 +333,27 @@ export default {
.catch((error) => {
console.log(error);
});
},
ReactivateAccount(){
this.$axios
.post(
`/trending/api/Members/ReactivateAccount?Email=${this.Email}`
)
.then((response) => {
//console.log(JSON.stringify(response))
if(response && response.data && response.data.DATA && response.data.DATA.rel){
let data = response.data.DATA.rel
if(data){
this.deleteDialog = false;
}
}
})
.catch((error) => {
console.log(error);
});
}
},
beforeUnmount() {
clearInterval(this.timeout);

21
FrontEnd/pages/user/index.vue

@ -115,7 +115,7 @@
{{ $t("Would you like to reactivate this account?")}}
</div>
</v-spacer>
<button class="tw-bg-primary-1 tw-text-white hover:tw-bg-primary-light tw-text-[18px] tw-rounded-[16px] tw-px-[86px] tw-py-[13px]">
<button @click="ReactivateAccount()" class="tw-bg-primary-1 tw-text-white hover:tw-bg-primary-light tw-text-[18px] tw-rounded-[16px] tw-px-[86px] tw-py-[13px]">
{{ $t("Reactivate my account") }}
</button>
<!-- <v-btn class="primary tw-w-auto" rounded
@ -251,6 +251,25 @@
});
},
ReactivateAccount(){
this.$axios
.post(
`/trending/api/Members/ReactivateAccountByAcc?Account=${this.userData.Account}`
)
.then((response) => {
console.log(JSON.stringify(response))
if(response && response.data && response.data.DATA && response.data.DATA.rel){
let data = response.data.DATA.rel
if(data){
this.deleteDialog = false;
}
}
})
.catch((error) => {
console.log(error);
});
},
updateValid(){
if(this.userData.Account !=='' && this.userData.Password !==''){
this.valid = true;

Loading…
Cancel
Save