diff --git a/src/api/model/customer.js b/src/api/model/customer.js
index a0cee05..5b8eb2c 100644
--- a/src/api/model/customer.js
+++ b/src/api/model/customer.js
@@ -51,4 +51,18 @@ export default {
return await http.post(this.url, data);
}
},
+ contactList:{
+ url: `${config.API_URL}/customer.service.message.contact.list`,
+ name: "联系人列表推送",
+ post: async function(data){
+ return await http.post(this.url, data);
+ }
+ },
+ attachmentMessage: {
+ url: `${config.API_URL}/customer.service.message.attachment.push`,
+ name: "附件推送",
+ post: async function(data){
+ return await http.post(this.url, data);
+ }
+ },
}
diff --git a/src/components/scCustomer/index.vue b/src/components/scCustomer/index.vue
index d89bb75..9f7a74a 100644
--- a/src/components/scCustomer/index.vue
+++ b/src/components/scCustomer/index.vue
@@ -66,11 +66,18 @@ export default {
mounted() {
let token = this.$TOOL.cookie.get('TOKEN');
if (token && token != null) {
+ // 登录成功连接ws
+ let global_callback = function () {};
+ this.$socketApi.createWebSocket(global_callback);
+
// 获取新消息
eventBus.$on('sockBack', this.getWsResult);
+
const userInfo = this.$TOOL.data.get("USER_INFO");
- this.user_id = userInfo.id;
+ if(userInfo && userInfo.id){
+ this.user_id = userInfo.id;
+ }
}
},
unmounted() {
diff --git a/src/router/systemRouter.js b/src/router/systemRouter.js
index e92475b..1ef92f7 100644
--- a/src/router/systemRouter.js
+++ b/src/router/systemRouter.js
@@ -64,7 +64,14 @@ const routes = [
meta: {
title: "维保服务"
}
- }
+ },
+ {
+ path: "/personalCenter",
+ component: () => import(/* webpackChunkName: "personalCenter" */ '@/views/personalCenter'),
+ meta: {
+ title: "个人中心"
+ }
+ },
]
export default routes;
diff --git a/src/style/serve.scss b/src/style/serve.scss
new file mode 100644
index 0000000..6d20566
--- /dev/null
+++ b/src/style/serve.scss
@@ -0,0 +1,35 @@
+.serveMain{
+ display: flex;
+ flex-direction: column;
+ .serveTitle{
+ font-size: 14px;
+ position: relative;
+ }
+ .serveTitle:before{
+ content: "";
+ position: absolute;
+ left: 4px;
+ top: calc(50% - 8px);
+ width:3px;
+ height: 16px;
+ border-radius: 4px;
+ background: var(--el-color-primary);
+ }
+ .searchMain{
+ display: flex;
+ align-items: center;
+ margin-bottom: 20px;
+ .searchItem{
+ display: flex;
+ align-items: center;
+ margin: 10px 10px 0 0;
+ .name{
+ width: 70px;
+ }
+ }
+ }
+ .mainTable{
+ flex: 1;
+ overflow: hidden;
+ }
+}
diff --git a/src/style/style.scss b/src/style/style.scss
index 97936bc..6b9b0e3 100644
--- a/src/style/style.scss
+++ b/src/style/style.scss
@@ -8,3 +8,4 @@
@import 'docs.scss';
@import "order.scss";
@import "search.scss";
+@import "serve.scss";
diff --git a/src/views/login/components/passwordForm.vue b/src/views/login/components/passwordForm.vue
index a09388b..ce62739 100644
--- a/src/views/login/components/passwordForm.vue
+++ b/src/views/login/components/passwordForm.vue
@@ -75,9 +75,9 @@
return false
}
if(user.data.user.company_id === 0){
- // 登录成功连接ws
- let global_callback = function () {};
- this.$socketApi.createWebSocket(global_callback);
+ // // 登录成功连接ws
+ // let global_callback = function () {};
+ // this.$socketApi.createWebSocket(global_callback);
this.$router.replace({
path: '/maintenance'
})
diff --git a/src/views/maintenance/index.vue b/src/views/maintenance/index.vue
index 883c270..9365e26 100644
--- a/src/views/maintenance/index.vue
+++ b/src/views/maintenance/index.vue
@@ -145,6 +145,7 @@ export default {
height: 100%;
display: flex;
flex-direction: column;
+ padding: 0 20px;
.rowView{
height: 220px;
padding: 20px 0;
diff --git a/src/views/personalCenter/index.vue b/src/views/personalCenter/index.vue
new file mode 100644
index 0000000..7ac5a59
--- /dev/null
+++ b/src/views/personalCenter/index.vue
@@ -0,0 +1,120 @@
+
+