|
@@ -2,8 +2,8 @@
|
|
|
* @Description: 个人中心
|
|
|
* @Author: 空白格
|
|
|
* @Date: 2022-08-15 10:09:03
|
|
|
- * @LastEditors: gcz
|
|
|
- * @LastEditTime: 2022-08-25 14:31:55
|
|
|
+ * @LastEditors: 空白格
|
|
|
+ * @LastEditTime: 2022-08-25 15:19:05
|
|
|
* @FilePath: \veterans_client_web\src\views\PersonalCenter\PersonalCenterIndex.vue
|
|
|
* @Copyright: Copyright (c) 2016~2022 by 空白格, All Rights Reserved.
|
|
|
-->
|
|
@@ -29,7 +29,10 @@
|
|
|
<div class="pchb-left-user">
|
|
|
<div class="pchb-left-user-item">
|
|
|
<div class="plui-username">{{ userInfo.name || "-" }}</div>
|
|
|
- <div class="plui-integral" @click="jumpPage('/personalcenter/progresspoints')">
|
|
|
+ <div
|
|
|
+ class="plui-integral"
|
|
|
+ @click="jumpPage('/personalcenter/progresspoints')"
|
|
|
+ >
|
|
|
<div class="plui-integral-item">进步<br />积分</div>
|
|
|
<div class="plui-integral-item">
|
|
|
{{ integralTotal || 0 }}
|
|
@@ -50,13 +53,18 @@
|
|
|
>已认证</template
|
|
|
>
|
|
|
<template v-else>
|
|
|
- <router-link to="/applyeducationauth">未认证</router-link>
|
|
|
+ <router-link to="/applyeducationauth"
|
|
|
+ >未认证</router-link
|
|
|
+ >
|
|
|
</template>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="plui-train">
|
|
|
<div class="plui-train-item">适应性培训</div>
|
|
|
- <div class="plui-train-item link" @click="jumpPage('/adaptivetraining')">
|
|
|
+ <div
|
|
|
+ class="plui-train-item link"
|
|
|
+ @click="jumpPage('/adaptivetraining')"
|
|
|
+ >
|
|
|
<template v-if="userInfo.adaptTrainIsPass === 1"
|
|
|
>已通过</template
|
|
|
>
|
|
@@ -75,7 +83,10 @@
|
|
|
:key="index"
|
|
|
>
|
|
|
<p>{{ item.label }}</p>
|
|
|
- <p><span>{{ learnObj[item.key] || 0 }}</span>{{ item.unit }}</p>
|
|
|
+ <p>
|
|
|
+ <span>{{ learnObj[item.key] || 0 }}</span
|
|
|
+ >{{ item.unit }}
|
|
|
+ </p>
|
|
|
</div>
|
|
|
</div>
|
|
|
</el-col>
|
|
@@ -288,11 +299,40 @@ export default {
|
|
|
this.$router.push(path, query);
|
|
|
}
|
|
|
},
|
|
|
- logout(){
|
|
|
- this.$store.dispatch("Logout", {}).then(res=>{
|
|
|
- console.log('logout',res);
|
|
|
+ /**
|
|
|
+ * 退出登录
|
|
|
+ * @date 2022-08-25
|
|
|
+ * @returns {any}
|
|
|
+ */
|
|
|
+ logout() {
|
|
|
+ this.$confirm("您确认要退出登录吗?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning",
|
|
|
})
|
|
|
- }
|
|
|
+ .then(() => {
|
|
|
+ this.$store.dispatch("Logout", {}).then((res) => {
|
|
|
+ if (res.code === 200) {
|
|
|
+ this.$message({
|
|
|
+ type: "success",
|
|
|
+ message: "退出登录成功!",
|
|
|
+ });
|
|
|
+ this.$router.push("/login");
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ type: "error",
|
|
|
+ message: res.msg || "退出登录失败!",
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ this.$message({
|
|
|
+ type: "info",
|
|
|
+ message: "已取消退出登录!",
|
|
|
+ });
|
|
|
+ });
|
|
|
+ },
|
|
|
},
|
|
|
};
|
|
|
</script>
|
|
@@ -401,7 +441,7 @@ export default {
|
|
|
p {
|
|
|
font-family: PingFangSC-Regular;
|
|
|
span {
|
|
|
- color: #FE7B02;
|
|
|
+ color: #fe7b02;
|
|
|
font-size: 36px;
|
|
|
}
|
|
|
}
|
|
@@ -441,13 +481,13 @@ export default {
|
|
|
color: #333333;
|
|
|
}
|
|
|
}
|
|
|
- .logout-btn{
|
|
|
+ .logout-btn {
|
|
|
margin: 54px auto 24px;
|
|
|
width: 240px;
|
|
|
height: 38px;
|
|
|
line-height: 38px;
|
|
|
text-align: center;
|
|
|
- border: 1px solid #FF0000;
|
|
|
+ border: 1px solid #ff0000;
|
|
|
color: #f00;
|
|
|
border-radius: 7px;
|
|
|
cursor: pointer;
|