Commit 3fe04d55 authored by lshan's avatar lshan

密码设置

parent ca006bb0
......@@ -127,14 +127,14 @@ const routes: Array<RouteRecordRaw> = [
/* webpackChunkName: "UserAgreement" */ '@/views/Auth/UserAgreement/index.vue'
),
},
// {
// path: '/auth/PwdSetting',
// name: 'PwdSetting',
// component: () =>
// import(
// /* webpackChunkName: "PwdSetting" */ '@/views/Auth/PwdSetting/index.vue'
// ),
// },
{
path: '/auth/PwdSetting',
name: 'PwdSetting',
component: () =>
import(
/* webpackChunkName: "PwdSetting" */ '@/views/Auth/PwdSetting/index.vue'
),
},
{
path: '/auth/PwdFind',
name: 'PwdFind',
......
......@@ -12,15 +12,15 @@
<span class=" text-sm">{{getPhone}}</span>
</div>
<!-- 登陆密码 -->
<div class="px-5 py-2 items-center border-b border-gray-200">
<div class="flex justify-between items-center">
<div class="px-5 py-2 items-center border-b border-gray-200">
<div class="flex justify-between items-center">
<div>
<div class=" text-sm font-semibold">登陆密码</div>
<div class=" text-xs text-gray-400 pt-1">保障账户登录安全</div>
</div>
<div class="flex items-center text-xs h-1 text-right">
<span v-if="hasPassword == 3">设置</span>
<span v-else-if="hasPassword == 2">修改</span>
<span v-if="hasPassword == 3" @click="pushRouter">设置</span>
<span v-else-if="hasPassword == 2" @click="pushRouter">修改</span>
<icon
name="icon-gengduo"
color="#8E92A3"
......@@ -28,7 +28,7 @@
class=" inline-block align-text-bottom"
/>
</div>
</div>
</div>
</div>
</div>
<div @click="clickLogout" class="logout-btn flex items-center justify-center fixed">退出登录</div>
......@@ -43,16 +43,18 @@ import { deleteUserMsg, getUserMsg } from '@/utils/userMsg'
import filter from "@/filter"
import router from '@/router'
import { userLogout } from '@/service/UserManagementService'
import { userChangePwd,userLogin} from '@/service/UserManagementService'
import { eSmsType, sendVerifyCode } from '@/service/VerificationService'
import set from '@/views/Auth/PwdSetting/index.vue'
export default defineComponent({
components: { NavBar, Icon },
components: { NavBar, Icon ,set},
computed: {
hasPassword(): eAccountType {
return eAccountType.REG_PDSET
},
getPhone(){
const phone =getUserMsg()?.userInfo.phone+''
var newphone= phone.replace(phone.substr(3, 4),"****")
var newphone= phone.replace(phone.substr(3,5),"*****")
return newphone
}
},
......@@ -69,6 +71,20 @@ export default defineComponent({
filter,
clickLogout
}
},
methods:{
pushRouter(){
console.log('123');
if(this.hasPassword == 3){
this.$router.push({
name: 'PwdSetting'
})
}else if(this.hasPassword == 2){
this.$router.push({
name: 'PwdModify'
})
}
},
}
})
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment