From 05d2d518867feb240e9ed3f9b2f1e68cc7be070b Mon Sep 17 00:00:00 2001
From: yujialong <479214531@qq.com>
Date: Fri, 29 Oct 2021 11:08:45 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dbug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/index.js | 1 +
src/main.js | 2 +-
src/pages/account/login/index.vue | 5 ++++-
src/pages/evaluation/list/index.vue | 28 +++++++++++-----------------
src/router/index.js | 2 +-
5 files changed, 18 insertions(+), 20 deletions(-)
diff --git a/src/api/index.js b/src/api/index.js
index b7ff9f3..e42abeb 100644
--- a/src/api/index.js
+++ b/src/api/index.js
@@ -8,6 +8,7 @@ export default {
logins: `${host}users/users/user/login`, //登录
verification: `${host}users/users/user/captcha`,// 验证码图片
+ isClient: `${host}users/users/user/isClient`,// 验证码图片
// 权限管理
getUserRolesPermissionMenu: `${host}users/user-role/getUserRolesPermissionMenu`,
diff --git a/src/main.js b/src/main.js
index 719d2d7..4d783c7 100644
--- a/src/main.js
+++ b/src/main.js
@@ -39,7 +39,7 @@ Vue.prototype.auth = function(values){
// 直接拿值进行匹配,取得当前router的mate信息,传入,返回一个boolean,以此进行vif判断
// router.meta 信息匹配传进来的value,用vif去进行按钮级权限配置即可。
// $router.currentRoute.meta
- // console.log(router.currentRoute.meta,'当前路由的按钮权限数组')
+ console.log(router.currentRoute.meta,'当前路由的按钮权限数组')
return router.currentRoute.meta.btn.some(e=>e===values)
}
new Vue({
diff --git a/src/pages/account/login/index.vue b/src/pages/account/login/index.vue
index 3aa750e..0625407 100644
--- a/src/pages/account/login/index.vue
+++ b/src/pages/account/login/index.vue
@@ -140,7 +140,10 @@ export default {
});
},
queryCustomer() { // 查询是否是客户
-
+ this.$get(this.api.isClient).then(res => {
+ this.setCustomer(res.customer);
+ this.setCustomerName(res.customerName);
+ }).catch(res => {});
},
phoneCountdown() {
let count = 60;
diff --git a/src/pages/evaluation/list/index.vue b/src/pages/evaluation/list/index.vue
index 82a56e3..d38f21d 100644
--- a/src/pages/evaluation/list/index.vue
+++ b/src/pages/evaluation/list/index.vue
@@ -44,19 +44,15 @@
-
- 查看
-
-
- 修改
-
+ 查看
+ 编辑
删除
@@ -395,15 +391,10 @@ export default {
this.resetForm();
},
switchQues(val, row, index) {
- this.$post(`${this.api.questionsIsDisable}?id=${row.id}`)
- .then(res => {
- if (res.status == 400) {
- util.errorMsg(res.message);
- row.isEnable = row.isEnable == 1 ? 0 : 1;
- }
- })
- .catch(err => {
- });
+ this.$post(`${this.api.questionsIsDisable}?id=${row.id}`).then(res => {
+ util.successMsg("更新状态成功");
+ this.getData();
+ }).catch(err => {});
},
delData(row) {
this.$confirm("确定要删除吗?", "提示", {
@@ -664,5 +655,8 @@ export default {
.check-wrap.checked {
color: #9076FF;
}
+/deep/ .el-switch__label *{
+ font-size: 12px;
+}
diff --git a/src/router/index.js b/src/router/index.js
index eccc09f..9f78cfe 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -267,7 +267,7 @@ router.beforeEach(function(to, from, next) {
}
}
// 根据路由元信息设置文档标题
- window.document.title = to.meta.title;
+ window.document.title = to.meta.title ? to.meta.title : "";
next();
});
\ No newline at end of file