xiuli.gao 2 years ago
parent
commit
0ed6c07939

+ 1 - 0
project/src/assets/config/interface_api.js

@@ -30,6 +30,7 @@ var api = {
30 30
   moveCustomerToBlackList: "/api/customer/moveCustomerToBlackList",
31 31
   blackList: "/api/customer/blackList",
32 32
   removeCustomerFromBlackList: "/api/customer/removeCustomerFromBlackList",
33
+  welcomeMsg_lists: "/api/welcomeMsg/lists",
33 34
 };
34 35
 
35 36
 export { api };

+ 7 - 8
project/src/components/Home.vue

@@ -1,8 +1,8 @@
1 1
 <template>
2
-  <div style="min-height:calc(100vh - 70px);margin-top:10px">
2
+  <div style="min-height:calc(100vh - 70px);margin-top:10px" class="bg-ffffff">
3 3
     <div class="topCon">
4 4
       <span>WELCOME!</span>
5
-      <p>欢迎访问酷炫直播运营系统</p>
5
+      <p>欢迎访问企微助手</p>
6 6
     </div>
7 7
     <img src="@/assets/img/homeBigImg.png" class="homeBigImg" alt="">
8 8
   </div>
@@ -13,17 +13,16 @@
13 13
   padding-top: 50px;
14 14
   position: relative;
15 15
   span {
16
-    font-size: 80px;
16
+    font-size: 100px;
17 17
     line-height: 124px;
18
-    color: rgba(255, 255, 255, 0.11);
18
+    color: rgba(0, 179, 138, 0.08);
19 19
     font-weight: bold;
20 20
     letter-spacing: 0.1em;
21 21
   }
22 22
   p {
23
-    color: #ffffff;
24
-    font-size: 50px;
23
+    color: #313333;
24
+    font-size: 70px;
25 25
     line-height: 69px;
26
-    font-weight: bold;
27 26
     position: absolute;
28 27
     bottom: -10px;
29 28
     left: 0;
@@ -36,6 +35,6 @@
36 35
   width: 600px;
37 36
   margin: auto;
38 37
   margin-top: 40px;
39
-  opacity: 0.74;
38
+  opacity: 0.9;
40 39
 }
41 40
 </style>

+ 6 - 3
project/src/components/assembly/screen/customerService.vue

@@ -1,8 +1,8 @@
1 1
 <template>
2 2
   <div class="common-screen-item">
3
-    <label class="common-screen-label">{{title}}</label>
3
+    <label class="common-screen-label" v-if="title&&title!=''">{{title}}</label>
4 4
     <el-popover placement="bottom" trigger="click" v-model="visible" @show="visibleShow">
5
-      <div :class="['common-screen-self-box','common-input-select',final_result&&final_result.length!=0&&clearable?'common-input-select-hover':'']" slot="reference">
5
+      <div :style="width?'width:'+width:''" :class="['common-screen-self-box','common-input-select',final_result&&final_result.length!=0&&clearable?'common-input-select-hover':'']" slot="reference">
6 6
         <div :class="['common-screen-self-con',!final_result||final_result.length==0?'common-screen-self-placeholder':'']">
7 7
           <span v-if="!final_result||final_result.length==0">请选择</span>
8 8
           <template v-else>
@@ -89,7 +89,10 @@ export default {
89 89
     reset: {
90 90
       type: Boolean,
91 91
       default: false
92
-    }
92
+    },
93
+    width: {
94
+      type: String
95
+    },
93 96
   },
94 97
   watch: {
95 98
     reset () {

+ 76 - 0
project/src/components/customOperate/create.scss

@@ -0,0 +1,76 @@
1
+.backBox {
2
+  background: #ffffff;
3
+  padding: 15px;
4
+  margin-bottom: 10px;
5
+  .back {
6
+    font-size: 16px;
7
+    font-weight: bold;
8
+    color: #333333;
9
+    cursor: pointer;
10
+    display: inline-block;
11
+  }
12
+}
13
+.createMassMsg{
14
+  width: 100%;
15
+  min-height: 400px;
16
+  .bigTitle {
17
+    color: #333333;
18
+    font-size: 16px;
19
+    line-height: 22px;
20
+    font-weight: bold;
21
+  }
22
+  .line {
23
+    width: 730px;
24
+    height: 1px;
25
+    background: #e9e9e9;
26
+    margin: 40px 0 20px;
27
+  }
28
+  .regulations {
29
+    display: flex;
30
+    align-items: flex-start;
31
+    margin-top: 28px;
32
+    label {
33
+      width: 100px;
34
+      color: #333333;
35
+      font-size: 14px;
36
+      line-height: 28px;
37
+      em {
38
+        color: #ff0000;
39
+      }
40
+    }
41
+  }
42
+}
43
+
44
+// .switch_self{
45
+//   display: flex;
46
+//   align-items: center;
47
+//   height: 30px;
48
+//   font-size: 13px;
49
+//   .switch_self_button{
50
+//     color: #333333;
51
+//     padding: 0 8px;
52
+//     border: 1px solid #e9e9e9;
53
+//     height: 100%;
54
+//     line-height: 28px;
55
+//     border-right: none;
56
+//     cursor: pointer;
57
+//     &:last-of-type{
58
+//       border-top-right-radius: 4px;
59
+//       border-bottom-right-radius: 4px;
60
+//       border-right: 1px solid #e9e9e9;
61
+//     }
62
+//     &:first-of-type{
63
+//       border-top-left-radius: 4px;
64
+//       border-bottom-left-radius: 4px;
65
+//     }
66
+//     &.switch_self_button_active{
67
+//       background: #43B083;
68
+//       border-color: #43B083;
69
+//       color: #ffffff;
70
+//     }
71
+//   }
72
+// }
73
+// <div class="switch_self">
74
+// <div class="switch_self_button switch_self_button_active">全部员工</div>
75
+// <div class="switch_self_button">部分员工</div>
76
+// </div>

+ 1 - 38
project/src/components/customOperate/createMassMsg.vue

@@ -314,37 +314,12 @@ export default {
314 314
 }
315 315
 </script>
316 316
 <style lang="scss" scoped>
317
+@import "./create.scss";
317 318
 .reversalAnimation {
318 319
   transform: rotate(180deg);
319 320
 }
320 321
 .createMassMsg {
321
-  width: 100%;
322
-  min-height: 400px;
323
-  .bigTitle {
324
-    color: #333333;
325
-    font-size: 16px;
326
-    line-height: 22px;
327
-    font-weight: bold;
328
-  }
329
-  .line {
330
-    width: 730px;
331
-    height: 1px;
332
-    background: #e9e9e9;
333
-    margin: 40px 0 20px;
334
-  }
335 322
   .regulations {
336
-    display: flex;
337
-    align-items: flex-start;
338
-    margin-top: 28px;
339
-    label {
340
-      width: 100px;
341
-      color: #333333;
342
-      font-size: 14px;
343
-      line-height: 20px;
344
-      em {
345
-        color: #ff0000;
346
-      }
347
-    }
348 323
     .regulations-account {
349 324
       width: 365px;
350 325
       height: 40px;
@@ -455,16 +430,4 @@ export default {
455 430
   border: none;
456 431
   margin: 40px 70px;
457 432
 }
458
-.backBox {
459
-  background: #ffffff;
460
-  padding: 15px;
461
-  margin-bottom: 10px;
462
-  .back {
463
-    font-size: 16px;
464
-    font-weight: bold;
465
-    color: #333333;
466
-    cursor: pointer;
467
-    display: inline-block;
468
-  }
469
-}
470 433
 </style>

+ 48 - 0
project/src/components/customOperate/welcom_message.vue

@@ -0,0 +1,48 @@
1
+<template>
2
+  <div class="createMassMsg" v-loading="loading">
3
+    <div class="backBox" @click="$router.go(-1)">
4
+      <div class="back">
5
+        <i class="el-icon-back"></i>
6
+        <span>返回</span>
7
+      </div>
8
+    </div>
9
+    <div v-if="!loading" class="bg-ffffff" style="padding: 15px;">
10
+      <h3 class="bigTitle">基础信息</h3>
11
+      <div class="self-hint" style="margin-top:10px;width:730px">
12
+        <i class="el-icon-message-solid"></i>
13
+        <div>
14
+          <p>1、在渠道码处设置的欢迎语会被优先推送,如果成员在渠道码处设置了欢迎语,在此设置的欢迎语不会生效</p>
15
+          <p>2、一个成员如果被设置了多个欢迎语,将会使用最新设置或修改的欢迎语。</p>
16
+        </div>
17
+      </div>
18
+      <div class="regulations">
19
+        <label><em>*</em>使用成员:</label>
20
+        <div>
21
+          <div style="display:flex">
22
+            <el-radio v-model="is_for_all" :disabled="!editFlag" :label="0">全部员工</el-radio>
23
+            <el-radio v-model="is_for_all" :disabled="!editFlag" :label="1">部分员工</el-radio>
24
+          </div>
25
+          <self-customerservice title='' width="300px" @customerDefine="(val)=>{user_id_list=val;}"></self-customerservice>
26
+        </div>
27
+      </div>
28
+      <div class="line" style="margin-top:20px"></div>
29
+    </div>
30
+  </div>
31
+</template>
32
+<script>
33
+import selfCustomerservice from '@/components/assembly/screen/customerService.vue'
34
+export default {
35
+  components: { selfCustomerservice },
36
+  data () {
37
+    return {
38
+      loading: false,
39
+      user_id_list: [],
40
+      is_for_all: 1,
41
+      editFlag: true
42
+    }
43
+  }
44
+}
45
+</script>
46
+<style lang="scss" scoped>
47
+@import "./create.scss";
48
+</style>

+ 109 - 0
project/src/components/customOperate/welcomeMsg.vue

@@ -0,0 +1,109 @@
1
+<template>
2
+  <div>
3
+    <div class="tableInfo">
4
+      <div>
5
+        <div class="flex">
6
+          <div class="totalCustom">共有<span>{{total}}</span>条欢迎语</div>
7
+        </div>
8
+      </div>
9
+      <div class="flex">
10
+        <el-button type="primary" size="small" @click="createWelcom">新建欢迎语</el-button>
11
+      </div>
12
+    </div>
13
+    <el-table ref="multipleTable" :data="tableData" tooltip-effect="dark" style="width: 100%">
14
+      <el-table-column prop="name" label="欢迎语标题" show-overflow-tooltip align="center"></el-table-column>
15
+      <el-table-column label="创建人" align="center">
16
+        <template slot-scope="scope">
17
+          <div class="customerServiceTagBox">
18
+            <div class="customerServiceTag"><i class="el-icon-user-solid"></i> {{ scope.row.creator }}</div>
19
+          </div>
20
+        </template>
21
+      </el-table-column>
22
+      <el-table-column label="使用成员" align="center">
23
+        <template slot-scope="scope">
24
+          <div v-if="scope.row.is_for_all==1">全部员工</div>
25
+          <template v-else>
26
+            <div class="customerServiceTagBox biaoqian">
27
+              <div class="customerServiceTag" v-for="(item) in scope.row.user_list" :key="item">
28
+                <i class="el-icon-s-custom"></i>
29
+                {{item}}
30
+              </div>
31
+            </div>
32
+          </template>
33
+        </template>
34
+      </el-table-column>
35
+      <el-table-column prop="updated_at" label="更新时间" show-overflow-tooltip align="center"></el-table-column>
36
+      <el-table-column prop="created_at" label="创建时间" show-overflow-tooltip align="center"></el-table-column>
37
+      <el-table-column label="是否可用" show-overflow-tooltip align="center">
38
+        <template slot-scope="scope">
39
+          <div>{{scope.row.enable==0?'否':'是'}}</div>
40
+        </template>
41
+      </el-table-column>
42
+      <el-table-column label="操作" align="center">
43
+        <template slot-scope="scope">
44
+          <div class="flex" style="justify-content:center">
45
+            <div class="c-00B38A pointer" style="margin:0 6px" @click="goDetail(scope.row.rule_id)">删除</div>
46
+            <div class="c-00B38A pointer" style="margin:0 6px" @click="removeCustomer(scope.row)">编辑</div>
47
+          </div>
48
+        </template>
49
+      </el-table-column>
50
+    </el-table>
51
+    <div class="pagination" v-show="total>0">
52
+      <el-pagination background :current-page="page" @current-change="handleCurrentChange" layout="prev, pager, next" :page-count='Number(pages)'>
53
+      </el-pagination>
54
+    </div>
55
+  </div>
56
+</template>
57
+<script>
58
+export default {
59
+  data () {
60
+    return {
61
+      loading: false,
62
+      page: 1,
63
+      pages: 0,
64
+      total: 0,
65
+      page_size: 20,
66
+      tableData: []
67
+    }
68
+  },
69
+  created () {
70
+    this.init(1)
71
+  },
72
+  methods: {
73
+    createWelcom () {
74
+      this.$router.push({ path: '/welcom_message_create' })
75
+    },
76
+    init (page) {
77
+      this.page = page ? page : this.page;
78
+      this.loading = true
79
+      this.$axios.get(this.URL.BASEURL + this.URL.welcomeMsg_lists, {
80
+        params: {
81
+          page: this.page,
82
+          page_size: this.page_size
83
+        }
84
+      }).then((res) => {
85
+        var res = res.data
86
+        this.loading = false
87
+        if (res && res.errno == 0) {
88
+          this.tableData = res.rst.data;
89
+          this.total = res.rst.pageInfo.total;
90
+          this.pages = res.rst.pageInfo.pages;
91
+        } else if (res.errno != 4002) {
92
+          this.$message({
93
+            message: res.err,
94
+            type: "warning"
95
+          })
96
+        }
97
+      }).catch((err) => {
98
+        this.loading = false
99
+      });
100
+    },
101
+  }
102
+}
103
+</script>
104
+<style lang="scss" scoped>
105
+@import "@/style/list.scss";
106
+.tableInfo {
107
+  height: 50px;
108
+}
109
+</style>

+ 22 - 0
project/src/router/allRouter.js

@@ -5,6 +5,8 @@ const customManage = () => import(/* webpackChunkName: 'customManage' */ '@/comp
5 5
 const employee_bulk_messaging_log = () => import(/* webpackChunkName: 'employee_bulk_messaging_log' */ '@/components/customOperate/employee_bulk_messaging_log.vue')
6 6
 const createMassMsg = () => import(/* webpackChunkName: 'createMassMsg' */ '@/components/customOperate/createMassMsg.vue')
7 7
 const blackList = () => import(/* webpackChunkName: 'blackList' */ '@/components/customManage/blackList.vue')
8
+const welcomeMsg = () => import(/* webpackChunkName: 'welcomeMsg' */ '@/components/customOperate/welcomeMsg.vue')
9
+const welcom_message = () => import(/* webpackChunkName: 'welcom_message' */ '@/components/customOperate/welcom_message.vue')
8 10
 
9 11
 
10 12
 export var allRouter = [
@@ -54,6 +56,26 @@ export var allRouter = [
54 56
         }
55 57
       },
56 58
       {
59
+        path: 'welcomeMsg',
60
+        name: 'welcomeMsg',
61
+        component: welcomeMsg,
62
+        meta: {
63
+          keepAlive: false,
64
+          isLogin: true,
65
+          title: '客户欢迎语'
66
+        }
67
+      },
68
+      {
69
+        path: 'welcom_message_create',
70
+        name: 'welcom_message',
71
+        component: welcom_message,
72
+        meta: {
73
+          keepAlive: false,
74
+          isLogin: true,
75
+          title: '创建欢迎语'
76
+        }
77
+      },
78
+      {
57 79
         path: 'createMassMsg',
58 80
         name: 'createMassMsg',
59 81
         component: createMassMsg,

+ 1 - 1
project/src/router/navList.js

@@ -44,7 +44,7 @@ var navList = [
44 44
     small_menu: [
45 45
       {
46 46
         viewName: '客户欢迎语',
47
-        path: 'liveNotice',
47
+        path: 'welcomeMsg',
48 48
       },
49 49
       {
50 50
         viewName: '客户群发',