seimin 2 years ago
parent
commit
1e3c63b5ec

+ 11 - 0
package-lock.json

@@ -14,6 +14,7 @@
14
         "less": "^3.9.0",
14
         "less": "^3.9.0",
15
         "less-loader": "^4.1.0",
15
         "less-loader": "^4.1.0",
16
         "lib-flexible": "^0.3.2",
16
         "lib-flexible": "^0.3.2",
17
+        "seiminutils": "^1.0.1",
17
         "vconsole": "^3.9.4",
18
         "vconsole": "^3.9.4",
18
         "vue": "^2.5.2",
19
         "vue": "^2.5.2",
19
         "vue-axios": "^2.1.4",
20
         "vue-axios": "^2.1.4",
@@ -12369,6 +12370,11 @@
12369
       "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=",
12370
       "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=",
12370
       "dev": true
12371
       "dev": true
12371
     },
12372
     },
12373
+    "node_modules/seiminutils": {
12374
+      "version": "1.0.1",
12375
+      "resolved": "https://registry.npmmirror.com/seiminutils/-/seiminutils-1.0.1.tgz",
12376
+      "integrity": "sha512-0J/lxdy9sHflsS88k/8Ll9Nq4jwLbxxaobKwS7FH8iJ3wQ+pY7zarsvnFMyJNYE/L13r6aSoWXWR37Lja/f8cQ=="
12377
+    },
12372
     "node_modules/select-hose": {
12378
     "node_modules/select-hose": {
12373
       "version": "2.0.0",
12379
       "version": "2.0.0",
12374
       "resolved": "https://registry.npm.taobao.org/select-hose/download/select-hose-2.0.0.tgz",
12380
       "resolved": "https://registry.npm.taobao.org/select-hose/download/select-hose-2.0.0.tgz",
@@ -25359,6 +25365,11 @@
25359
         }
25365
         }
25360
       }
25366
       }
25361
     },
25367
     },
25368
+    "seiminutils": {
25369
+      "version": "1.0.1",
25370
+      "resolved": "https://registry.npmmirror.com/seiminutils/-/seiminutils-1.0.1.tgz",
25371
+      "integrity": "sha512-0J/lxdy9sHflsS88k/8Ll9Nq4jwLbxxaobKwS7FH8iJ3wQ+pY7zarsvnFMyJNYE/L13r6aSoWXWR37Lja/f8cQ=="
25372
+    },
25362
     "select-hose": {
25373
     "select-hose": {
25363
       "version": "2.0.0",
25374
       "version": "2.0.0",
25364
       "resolved": "https://registry.npm.taobao.org/select-hose/download/select-hose-2.0.0.tgz",
25375
       "resolved": "https://registry.npm.taobao.org/select-hose/download/select-hose-2.0.0.tgz",

+ 1 - 0
package.json

@@ -18,6 +18,7 @@
18
     "less": "^3.9.0",
18
     "less": "^3.9.0",
19
     "less-loader": "^4.1.0",
19
     "less-loader": "^4.1.0",
20
     "lib-flexible": "^0.3.2",
20
     "lib-flexible": "^0.3.2",
21
+    "seiminutils": "^1.0.1",
21
     "vconsole": "^3.9.4",
22
     "vconsole": "^3.9.4",
22
     "vue": "^2.5.2",
23
     "vue": "^2.5.2",
23
     "vue-axios": "^2.1.4",
24
     "vue-axios": "^2.1.4",

BIN
src/assets/HM-search/attention.png


BIN
src/assets/HM-search/attention_forbid.png


BIN
src/assets/HM-search/back.png


BIN
src/assets/HM-search/delete.png


+ 17 - 13
src/custom/seiminSearch.vue

@@ -67,7 +67,7 @@
67
       },
67
       },
68
       //HM修改 触发组件input事件
68
       //HM修改 触发组件input事件
69
       inputChange(event) {
69
       inputChange(event) {
70
-        var keyword = event.detail.value;
70
+        var keyword = event.target.value;
71
         this.$emit('input', keyword);
71
         this.$emit('input', keyword);
72
         if (this.inputVal) {
72
         if (this.inputVal) {
73
           this.isDelShow = true;
73
           this.isDelShow = true;
@@ -146,7 +146,7 @@
146
       display: flex;
146
       display: flex;
147
       align-items: center;
147
       align-items: center;
148
       width: 100%;
148
       width: 100%;
149
-      height: 60upx;
149
+      height: 0.6rem;
150
       background: #fff;
150
       background: #fff;
151
       overflow: hidden;
151
       overflow: hidden;
152
       transition: all 0.2s linear;
152
       transition: all 0.2s linear;
@@ -162,10 +162,10 @@
162
         }
162
         }
163
 
163
 
164
         .icon {
164
         .icon {
165
-          padding: 0 15upx;
165
+          padding: 0 0.15rem;
166
 
166
 
167
           &.icon-del {
167
           &.icon-del {
168
-            font-size: 38upx;
168
+            font-size: 0.38rem;
169
 
169
 
170
             &:before {
170
             &:before {
171
               content: "\e644";
171
               content: "\e644";
@@ -180,12 +180,16 @@
180
         .input {
180
         .input {
181
           width: 100%;
181
           width: 100%;
182
           max-width: 100%;
182
           max-width: 100%;
183
-          line-height: 60upx;
184
-          height: 60upx;
183
+          line-height: 0.6rem;
184
+          height: 0.6rem;
185
           transition: all 0.2s linear;
185
           transition: all 0.2s linear;
186
 
186
 
187
+          &:focus-visible {
188
+            outline: none;
189
+          }
190
+
187
           &.center {
191
           &.center {
188
-            width: 600upx;
192
+            width: 6rem;
189
           }
193
           }
190
 
194
 
191
           &.sub {
195
           &.sub {
@@ -198,9 +202,9 @@
198
       .serachBtn {
202
       .serachBtn {
199
         height: 100%;
203
         height: 100%;
200
         flex-shrink: 0;
204
         flex-shrink: 0;
201
-        padding: 0 30upx;
202
-        background: linear-gradient(to right, #72c172, #3bb197);
203
-        line-height: 60upx;
205
+        padding: 0 0.3rem;
206
+        background: #005395;
207
+        line-height: 0.6rem;
204
         color: #fff;
208
         color: #fff;
205
         transition: all 0.3s;
209
         transition: all 0.3s;
206
       }
210
       }
@@ -218,8 +222,8 @@
218
       overflow: hidden;
222
       overflow: hidden;
219
 
223
 
220
       &.active {
224
       &.active {
221
-        padding-left: 15upx;
222
-        width: 100upx;
225
+        padding-left: 0.15rem;
226
+        width: 1rem;
223
       }
227
       }
224
     }
228
     }
225
   }
229
   }
@@ -233,7 +237,7 @@
233
 
237
 
234
   .icon {
238
   .icon {
235
     font-family: iconfont;
239
     font-family: iconfont;
236
-    font-size: 32upx;
240
+    font-size: 0.32rem;
237
     font-style: normal;
241
     font-style: normal;
238
     color: #999;
242
     color: #999;
239
 
243
 

+ 376 - 210
src/views/newIncident.vue

@@ -27,11 +27,14 @@
27
     >
27
     >
28
       <cube-form-group>
28
       <cube-form-group>
29
         <cube-form-item
29
         <cube-form-item
30
+          :field="fields[24]"
31
+          class="btn_plcaeholde"
32
+        ></cube-form-item>
33
+        <cube-form-item
30
           :field="fields[20]"
34
           :field="fields[20]"
31
           v-if="valConfig == 2"
35
           v-if="valConfig == 2"
32
           class="btn_plcaeholde btn_local"
36
           class="btn_plcaeholde btn_local"
33
         >
37
         >
34
-          <!-- <cube-button @click="showPlacePicker()">{{selectedPlaceTxt?selectedPlaceTxt:'请输入故障地点'}}</cube-button> -->
35
           <input
38
           <input
36
             type="text"
39
             type="text"
37
             class="inp_local"
40
             class="inp_local"
@@ -42,6 +45,20 @@
42
           />
45
           />
43
         </cube-form-item>
46
         </cube-form-item>
44
         <cube-form-item
47
         <cube-form-item
48
+          :field="fields[25]"
49
+          v-if="valConfig == 2"
50
+          class="btn_plcaeholde btn_local"
51
+        >
52
+          <input
53
+            type="text"
54
+            class="inp_local"
55
+            placeholder="请输入报修人"
56
+            v-model="userInpVal"
57
+            @input="changeUserList()"
58
+            @click="showUserPicker()"
59
+          />
60
+        </cube-form-item>
61
+        <cube-form-item
45
           v-if="valConfig == 1"
62
           v-if="valConfig == 1"
46
           :field="fields[0]"
63
           :field="fields[0]"
47
         ></cube-form-item>
64
         ></cube-form-item>
@@ -52,43 +69,20 @@
52
         <cube-form-item :field="fields[1]"></cube-form-item>
69
         <cube-form-item :field="fields[1]"></cube-form-item>
53
         <cube-form-item :field="fields[2]" class="btn_plcaeholde">
70
         <cube-form-item :field="fields[2]" class="btn_plcaeholde">
54
           <cube-button @click="showPlacePicker()">{{
71
           <cube-button @click="showPlacePicker()">{{
55
-            selectedPlaceTxt ? selectedPlaceTxt : "请选择区域地点"
72
+            selectedPlaceTxt ? selectedPlaceTxt : "请选择院区楼栋"
56
           }}</cube-button>
73
           }}</cube-button>
57
         </cube-form-item>
74
         </cube-form-item>
58
         <cube-form-item :field="fields[23]" v-if="ifRoom == 1"></cube-form-item>
75
         <cube-form-item :field="fields[23]" v-if="ifRoom == 1"></cube-form-item>
59
-        <!-- 故障地点: -->
60
-        <!-- <cube-form-item :field="fields[19]" class="btn_plcaeholde btn_local"> -->
61
-        <!-- <cube-button @click="showPlacePicker()">{{selectedPlaceTxt?selectedPlaceTxt:'请输入故障地点'}}</cube-button> -->
62
-        <!-- <input
63
-            type="text"
64
-            class="inp_local"
65
-            placeholder="请输入故障地点"
66
-            v-model="inpLocalVal"
67
-            @input="changeLocalList()"
68
-            @click="showPlacePicker()"
69
-          />
70
-        </cube-form-item> -->
71
         <cube-form-item :field="fields[3]"></cube-form-item>
76
         <cube-form-item :field="fields[3]"></cube-form-item>
72
         <cube-form-item :field="fields[4]" class="btn_plcaeholde">
77
         <cube-form-item :field="fields[4]" class="btn_plcaeholde">
73
           <cube-button @click="showCategoryPicker()">{{
78
           <cube-button @click="showCategoryPicker()">{{
74
-            selectedCategoryTxt ? selectedCategoryTxt : "请选择事件分类"
79
+            selectedCategoryTxt ? selectedCategoryTxt : "请选择故障现象"
75
           }}</cube-button>
80
           }}</cube-button>
76
         </cube-form-item>
81
         </cube-form-item>
77
         <cube-form-item
82
         <cube-form-item
78
           :field="fields[5]"
83
           :field="fields[5]"
79
           class="btn_plcaeholde"
84
           class="btn_plcaeholde"
80
         ></cube-form-item>
85
         ></cube-form-item>
81
-        <!-- <cube-form-item :field="fields[6]" class="btn_plcaeholde incidentTitle">
82
-          <div class="titleRefer">
83
-            <textarea
84
-              class="titleTxtArea fl"
85
-              placeholder="请输入事件主题"
86
-              v-model="incidentTitle"
87
-              @input="inpTitle()"
88
-            ></textarea>
89
-            <span class="abtn fl" @click="referKnowledge()">引入知识库</span>
90
-          </div>
91
-        </cube-form-item>-->
92
         <cube-form-item :field="fields[7]"></cube-form-item>
86
         <cube-form-item :field="fields[7]"></cube-form-item>
93
         <div class="label formLabel">
87
         <div class="label formLabel">
94
           报修图片
88
           报修图片
@@ -96,7 +90,8 @@
96
         </div>
90
         </div>
97
         <div class="uplod">
91
         <div class="uplod">
98
           <cube-upload
92
           <cube-upload
99
-            ref="upload"
93
+            ref="upload" 
94
+            v-model="imgFiles"
100
             :max="3"
95
             :max="3"
101
             :action="action"
96
             :action="action"
102
             :simultaneous-uploads="3"
97
             :simultaneous-uploads="3"
@@ -104,8 +99,6 @@
104
             @file-submitted="fileSubmitted"
99
             @file-submitted="fileSubmitted"
105
           />
100
           />
106
         </div>
101
         </div>
107
-        <!-- <cube-form-item :field="fields[8]" class="btn_plcaeholde"></cube-form-item>
108
-        <cube-form-item :field="fields[9]" class="btn_plcaeholde"></cube-form-item>-->
109
         <cube-form-item
102
         <cube-form-item
110
           :field="fields[10]"
103
           :field="fields[10]"
111
           class="btn_plcaeholde"
104
           class="btn_plcaeholde"
@@ -117,6 +110,11 @@
117
           ></cube-form-item>
110
           ></cube-form-item>
118
           <span class="icon dash dash-saoyisao zc-sao" @click="scan()"></span>
111
           <span class="icon dash dash-saoyisao zc-sao" @click="scan()"></span>
119
         </div>
112
         </div>
113
+        <cube-form-item :field="fields[26]" class="btn_plcaeholde">
114
+          <cube-button @click="showTimePicker()">{{
115
+            selectedYytimeTxt ? selectedYytimeTxt : "请选择预约时间"
116
+          }}</cube-button>
117
+        </cube-form-item>
120
         <div class="label" id="handlerInfo">处理信息</div>
118
         <div class="label" id="handlerInfo">处理信息</div>
121
         <div class="handleRadio">
119
         <div class="handleRadio">
122
           <cube-radio-group
120
           <cube-radio-group
@@ -128,11 +126,11 @@
128
           />
126
           />
129
         </div>
127
         </div>
130
         <!-- 直接处理 begin -->
128
         <!-- 直接处理 begin -->
131
-        <cube-form-item
129
+        <!-- <cube-form-item
132
           v-if="order == 1"
130
           v-if="order == 1"
133
           :field="fields[11]"
131
           :field="fields[11]"
134
           class="btn_plcaeholde"
132
           class="btn_plcaeholde"
135
-        ></cube-form-item>
133
+        ></cube-form-item> -->
136
         <cube-form-item
134
         <cube-form-item
137
           v-if="order == 1"
135
           v-if="order == 1"
138
           :field="fields[12]"
136
           :field="fields[12]"
@@ -143,7 +141,7 @@
143
           :field="fields[13]"
141
           :field="fields[13]"
144
           class="btn_plcaeholde"
142
           class="btn_plcaeholde"
145
         ></cube-form-item>
143
         ></cube-form-item>
146
-        <div v-if="order == 1" class="label formLabel">
144
+        <!-- <div v-if="order == 1" class="label formLabel">
147
           报修图片
145
           报修图片
148
           <span>(最多可上传3张JPG或PNG,每张不能超过10M)</span>
146
           <span>(最多可上传3张JPG或PNG,每张不能超过10M)</span>
149
         </div>
147
         </div>
@@ -156,8 +154,8 @@
156
             @files-added="filesAdded1"
154
             @files-added="filesAdded1"
157
             @file-submitted="fileSubmitted1"
155
             @file-submitted="fileSubmitted1"
158
           />
156
           />
159
-        </div>
160
-        <cube-form-item v-if="order == 1" :field="fields[14]"></cube-form-item>
157
+        </div> -->
158
+        <!-- <cube-form-item v-if="order == 1" :field="fields[14]"></cube-form-item> -->
161
         <cube-form-item
159
         <cube-form-item
162
           v-if="order == 1 && model.knowledge == true"
160
           v-if="order == 1 && model.knowledge == true"
163
           :field="fields[15]"
161
           :field="fields[15]"
@@ -192,6 +190,7 @@
192
   </div>
190
   </div>
193
 </template>
191
 </template>
194
 <script>
192
 <script>
193
+import dateFormat from 'seiminutils/es/dateFormat';
195
 import seiminModel from "./../custom/seiminModel";
194
 import seiminModel from "./../custom/seiminModel";
196
 import CubePage from "./../components/cube-page.vue";
195
 import CubePage from "./../components/cube-page.vue";
197
 import CubeButtonGroup from "./../components/cube-button-group.vue";
196
 import CubeButtonGroup from "./../components/cube-button-group.vue";
@@ -214,7 +213,7 @@ const solution = {
214
     return {
213
     return {
215
       selected: [],
214
       selected: [],
216
       selectData: [],
215
       selectData: [],
217
-      initVal: JSON.parse(localStorage.getItem("solution")) || [0, 0, 0],
216
+      initVal: [0, 0, 0],
218
       allPlace: {}, //存放请求到的所有区域地点
217
       allPlace: {}, //存放请求到的所有区域地点
219
       sleectHouseNumber: {}, //区域地点
218
       sleectHouseNumber: {}, //区域地点
220
       initSjList: [], //原始事件列表
219
       initSjList: [], //原始事件列表
@@ -251,7 +250,6 @@ const solution = {
251
       });
250
       });
252
       this.selected = selected;
251
       this.selected = selected;
253
       this.$emit("input", selectedVal);
252
       this.$emit("input", selectedVal);
254
-      localStorage.setItem("solution", JSON.stringify(selectedIndex));
255
     },
253
     },
256
     // 获取事件分类数据
254
     // 获取事件分类数据
257
     getTree() {
255
     getTree() {
@@ -318,8 +316,11 @@ const solution = {
318
 export default {
316
 export default {
319
   data() {
317
   data() {
320
     return {
318
     return {
319
+      imgFiles: [],
320
+      selectDeptIndex:[0],
321
+      selectUserIndex:[0],
322
+      selectedPlaceIndex:[0, 0],
321
       validity: {},
323
       validity: {},
322
-
323
       valid: undefined,
324
       valid: undefined,
324
       action: {
325
       action: {
325
         target:
326
         target:
@@ -349,22 +350,28 @@ export default {
349
       incidentTitle: "", //事件主题
350
       incidentTitle: "", //事件主题
350
       referenceInfo: {}, //引用信息
351
       referenceInfo: {}, //引用信息
351
       placeSelectData: [], //区域地点下拉框选项
352
       placeSelectData: [], //区域地点下拉框选项
352
-      inpLocalVal: "", //故障地点输入框
353
+      // inpLocalVal: "", //故障地点输入框
353
       faultLocationList: [], //区域地点拼接下拉框选项
354
       faultLocationList: [], //区域地点拼接下拉框选项
354
       deptInpVal: "", //报修科室输入框
355
       deptInpVal: "", //报修科室输入框
355
       deptList: [], //报修科室下拉选项
356
       deptList: [], //报修科室下拉选项
356
       deptRes: "", //下拉框科室信息
357
       deptRes: "", //下拉框科室信息
358
+      userInpVal: "", //报修人输入框
359
+      userList: [], //报修人下拉选项
360
+      userRes: "", //下拉框报修人信息
357
       model: {
361
       model: {
362
+        contacts: "",
358
         contactsInformation: "",
363
         contactsInformation: "",
359
         placeValue: [],
364
         placeValue: [],
360
         address: "", //故障地点
365
         address: "", //故障地点
361
         requester: "", //报修科室
366
         requester: "", //报修科室
367
+        requesterUser: "", //报修人
362
         houseNumber: "", //详细地址
368
         houseNumber: "", //详细地址
363
         description: "", //事件描述
369
         description: "", //事件描述
364
         // bxcode: "",
370
         // bxcode: "",
365
         assetId: "", //资产
371
         assetId: "", //资产
366
         category: [],
372
         category: [],
367
         source: "", //事件来源
373
         source: "", //事件来源
374
+        branch: "", //院区
368
         title: "", //事件主题
375
         title: "", //事件主题
369
         priority: "", //优先级
376
         priority: "", //优先级
370
         emergency: "", //紧急度
377
         emergency: "", //紧急度
@@ -377,14 +384,17 @@ export default {
377
         candidateGroups: "", //处理组
384
         candidateGroups: "", //处理组
378
         solutionType: [], //知识库类型
385
         solutionType: [], //知识库类型
379
         handleUserOrGroup: false, //处理人or处理组
386
         handleUserOrGroup: false, //处理人or处理组
380
-        room: "" //房间号
387
+        room: "", //房间号
381
       },
388
       },
382
       selectedCategoryTxt: "", //事件分类选中展示
389
       selectedCategoryTxt: "", //事件分类选中展示
383
       selectedPlaceTxt: "", //区域地点选中展示
390
       selectedPlaceTxt: "", //区域地点选中展示
391
+      selectedYytimeTxt: dateFormat(Date.now(),'yyyy-MM-dd hh:mm'), //预约时间
392
+      selectedYytimeStamp: 0, //预约时间戳
384
       // showPrompting:false,
393
       // showPrompting:false,
385
       promptingConent: "",
394
       promptingConent: "",
386
       promptingStatus: "",
395
       promptingStatus: "",
387
       order: 1, //处理方式  1:直接处理,2:派单
396
       order: 1, //处理方式  1:直接处理,2:派单
397
+      branchArr: [], //院区数组
388
       sourceArr: [], //事件来源数组
398
       sourceArr: [], //事件来源数组
389
       priorityArr: [], //优先级数组
399
       priorityArr: [], //优先级数组
390
       emergencyArr: [], //紧急度数组
400
       emergencyArr: [], //紧急度数组
@@ -431,12 +441,12 @@ export default {
431
         {
441
         {
432
           component: "button",
442
           component: "button",
433
           modelKey: "placeValue",
443
           modelKey: "placeValue",
434
-          label: "区域地点:",
444
+          label: "院区楼栋:",
435
           rules: {
445
           rules: {
436
             required: false
446
             required: false
437
           },
447
           },
438
           messages: {
448
           messages: {
439
-            required: "请选择区域地点"
449
+            required: "请选择院区楼栋"
440
           }
450
           }
441
         },
451
         },
442
         {
452
         {
@@ -454,7 +464,7 @@ export default {
454
         {
464
         {
455
           component: "button",
465
           component: "button",
456
           modelKey: "category",
466
           modelKey: "category",
457
-          label: "事件分类:",
467
+          label: "故障现象:",
458
           rules: {
468
           rules: {
459
             required: true
469
             required: true
460
           }
470
           }
@@ -472,7 +482,7 @@ export default {
472
             placeholder: "请选择事件来源"
482
             placeholder: "请选择事件来源"
473
           },
483
           },
474
           rules: {
484
           rules: {
475
-            required: true
485
+            required: false
476
           }
486
           }
477
         },
487
         },
478
         {
488
         {
@@ -490,7 +500,7 @@ export default {
490
         {
500
         {
491
           type: "textarea",
501
           type: "textarea",
492
           modelKey: "description",
502
           modelKey: "description",
493
-          label: "事件描述:",
503
+          label: "故障描述:",
494
           props: {
504
           props: {
495
             placeholder: "请详细描述故障,并上传故障图片,例如:网络故障。"
505
             placeholder: "请详细描述故障,并上传故障图片,例如:网络故障。"
496
           },
506
           },
@@ -694,7 +704,7 @@ export default {
694
           modelKey: "requester",
704
           modelKey: "requester",
695
           label: "报修科室:",
705
           label: "报修科室:",
696
           props: {
706
           props: {
697
-            options: this.requesterList,
707
+            options: [],
698
             title: "请选择报修科室",
708
             title: "请选择报修科室",
699
             placeholder: "请选择报修科室"
709
             placeholder: "请选择报修科室"
700
           },
710
           },
@@ -736,7 +746,56 @@ export default {
736
           rules: {
746
           rules: {
737
             required: false
747
             required: false
738
           }
748
           }
739
-        }
749
+        },
750
+        {
751
+          type: "select",
752
+          modelKey: "branch",
753
+          label: "院区:",
754
+          props: {
755
+            options: this.branchArr,
756
+            title: "请选择院区",
757
+            placeholder: "请选择院区"
758
+          },
759
+          events: {
760
+            change: (value, index, text) => {
761
+              console.log(value, index, text);
762
+              console.log(this.model);
763
+              if (this.valConfig == 2) {
764
+                this.getDept();
765
+                this.getAreaData();
766
+                this.model.contactsInformation = '';
767
+                this.model.requester = '';
768
+                this.deptInpVal = '';
769
+                this.model.placeValue = [];
770
+                this.selectedPlaceTxt = '';
771
+              }
772
+            }
773
+          },
774
+          rules: {
775
+            required: true
776
+          }
777
+        },
778
+        {
779
+          type: "select",
780
+          modelKey: "requesterUser",
781
+          label: "报修人:",
782
+          props: {
783
+            options: [],
784
+            title: "请选择报修人",
785
+            placeholder: "请选择报修人"
786
+          },
787
+          rules: {
788
+            required: false
789
+          }
790
+        },
791
+        {
792
+          component: "button",
793
+          modelKey: "yyTime",
794
+          label: "预约时间:",
795
+          rules: {
796
+            required: false
797
+          }
798
+        },
740
       ]
799
       ]
741
     };
800
     };
742
   },
801
   },
@@ -765,11 +824,28 @@ export default {
765
     }
824
     }
766
   },
825
   },
767
   methods: {
826
   methods: {
827
+    // 选择预约时间
828
+    showTimePicker() {
829
+      let timePicker = this.$createTimePicker({
830
+        title: '选择预约时间',
831
+        showNow: false,
832
+        delay: 1,
833
+        minuteStep: 1,
834
+        onSelect: (selectedTime, selectedText, formatedTime) => {
835
+          console.log(selectedTime, selectedText, formatedTime);
836
+          this.selectedYytimeTxt = formatedTime;
837
+          this.selectedYytimeStamp = selectedTime;
838
+        },
839
+        onCancel: () => {}
840
+      }).show();
841
+      timePicker.setTime(this.selectedYytimeStamp)
842
+    },
768
     // 切换处理方式
843
     // 切换处理方式
769
     changeHandleTypes() {
844
     changeHandleTypes() {
770
-      let reverseArr = this.model.category.filter(Boolean).reverse(); //数组翻转,取第一项不为空的
771
-      let sjId = reverseArr[0]; //事件Id baba
772
-      let sj = this.initSjList.filter(v => v.id == sjId)[0];
845
+      // let reverseArr = this.model.category.filter(Boolean).reverse(); //数组翻转,取第一项不为空的
846
+      // let sjId = reverseArr[0]; //事件Id baba
847
+      // let sj = this.initSjList.filter(v => v.id == sjId)[0];
848
+      let sj = this.model.category;
773
       console.log(this.order, sj);
849
       console.log(this.order, sj);
774
       this.isShowDes = !(this.order == 1 && sj && sj.hasSimple == 1);
850
       this.isShowDes = !(this.order == 1 && sj && sj.hasSimple == 1);
775
     },
851
     },
@@ -823,6 +899,33 @@ export default {
823
             });
899
             });
824
           });
900
           });
825
           that.fields[5].props.options = that.sourceArr;
901
           that.fields[5].props.options = that.sourceArr;
902
+          that.model.source = 1547;//默认电话
903
+        });
904
+    },
905
+    // 获取院区
906
+    getBranch() {
907
+      this.$http
908
+        .post("service/user/data/fetchDataList/branch", {"idx":0,"sum":100})
909
+        .then((res) => {
910
+          if(res.data.status == 200){
911
+            res.data.list.forEach((v) => {
912
+              this.branchArr.push({
913
+                text: v.hosName,
914
+                value: v.id
915
+              });
916
+            });
917
+            this.fields[24].props.options = this.branchArr;
918
+            if(this.loginUser.duty){
919
+              this.model.branch = this.loginUser.duty.branch;
920
+            }else if(this.loginUser.branch){
921
+              this.model.branch = this.loginUser.branch.id;
922
+            }
923
+            // 获取报修科室
924
+            if (this.valConfig == 2) {
925
+              this.getDept();
926
+              this.getAreaData();
927
+            }
928
+          }
826
         });
929
         });
827
     },
930
     },
828
     // 获取优先级
931
     // 获取优先级
@@ -913,6 +1016,7 @@ export default {
913
             });
1016
             });
914
           });
1017
           });
915
           that.fields[12].props.options = that.closecodeArr;
1018
           that.fields[12].props.options = that.closecodeArr;
1019
+          that.model.closecode = 1572;//设计如此,默认“完全解决”
916
         });
1020
         });
917
     },
1021
     },
918
     // 获取处理人
1022
     // 获取处理人
@@ -963,12 +1067,7 @@ export default {
963
         a2 = [],
1067
         a2 = [],
964
         category = [],
1068
         category = [],
965
         solutionType = [];
1069
         solutionType = [];
966
-      that.model.category.forEach(function(v, i) {
967
-        if (v) {
968
-          a1.push(v);
969
-        }
970
-      });
971
-      category = a1;
1070
+      category = that.model.category;
972
       that.model.solutionType.forEach(function(v, i) {
1071
       that.model.solutionType.forEach(function(v, i) {
973
         if (v) {
1072
         if (v) {
974
           a2.push(v);
1073
           a2.push(v);
@@ -1089,9 +1188,6 @@ export default {
1089
       var that = this;
1188
       var that = this;
1090
       if (!that.model.title) return;
1189
       if (!that.model.title) return;
1091
       that.setLocalStroageData();
1190
       that.setLocalStroageData();
1092
-      localStorage.setItem("modelData", JSON.stringify(that.modelData));
1093
-      localStorage.setItem("model", JSON.stringify(that.model));
1094
-      localStorage.setItem("order", that.order);
1095
 
1191
 
1096
       this.$router.push({
1192
       this.$router.push({
1097
         name: "ReferenceList",
1193
         name: "ReferenceList",
@@ -1120,55 +1216,12 @@ export default {
1120
         if (inspecInfo.handlerUser) {
1216
         if (inspecInfo.handlerUser) {
1121
           that.model.handlerUser = inspecInfo.handlerUser.id;
1217
           that.model.handlerUser = inspecInfo.handlerUser.id;
1122
         }
1218
         }
1123
-        // that.modelData.incident.handlingPersonnelUser = {
1124
-        //   id: that.model.handlerUser
1125
-        // };
1126
 
1219
 
1127
         if (that.$route.params.abnormal) {
1220
         if (that.$route.params.abnormal) {
1128
           that.model.description = that.modelData.incident.description =
1221
           that.model.description = that.modelData.incident.description =
1129
             that.$route.params.abnormal;
1222
             that.$route.params.abnormal;
1130
         }
1223
         }
1131
-      } else {
1132
-        that.name = that.loginUser.name;
1133
-        that.model.contactsInformation = that.loginUser.phone;
1134
-        that.model.contacts = that.loginUser.name;
1135
-        that.model.houseNumber = that.loginUser.houseNumber;
1136
-      }
1137
-      if (that.loginUser.place && that.loginUser.place.length) {
1138
-        if (that.loginUser.place.id) {
1139
-          if (that.loginUser.place.area) {
1140
-            that.model.placeValue[0] = that.loginUser.place.area.id;
1141
-          }
1142
-          that.model.placeValue[1] = that.loginUser.place.id;
1143
-        }
1144
-      }
1145
-
1146
-      if (localStorage.getItem("model")) {
1147
-        that.model = JSON.parse(localStorage.getItem("model"));
1148
-        that.incidentTitle = that.model.title;
1149
-      }
1150
-      if (localStorage.getItem("modelData")) {
1151
-        that.modelData = JSON.parse(localStorage.getItem("modelData"));
1152
-      }
1153
-      if (localStorage.getItem("referenceInfo")) {
1154
-        that.referenceInfo = JSON.parse(localStorage.getItem("referenceInfo"));
1155
-        that.incidentTitle = that.model.title = that.referenceInfo.title;
1156
-        that.model.handleDescription = that.referenceInfo.content;
1157
-      }
1158
-      if (localStorage.getItem("order")) {
1159
-        that.order = localStorage.getItem("order") - 0;
1160
-      }
1161
-
1162
-      // if (localStorage.getItem("category")) {
1163
-      //   that.selectedCategoryTxt = JSON.parse(
1164
-      //     localStorage.getItem("category")
1165
-      //   ).txt;
1166
-      //   console.log(that.selectedCategoryTxt);
1167
-      // }
1168
-      // if (localStorage.getItem("place")) {
1169
-      //   that.selectedPlaceTxt = JSON.parse(localStorage.getItem("place")).txt;
1170
-      //   console.log(that.selectedPlaceTxt);
1171
-      // }
1224
+      } else {}
1172
     },
1225
     },
1173
     // 提交
1226
     // 提交
1174
     submitHandler() {
1227
     submitHandler() {
@@ -1350,15 +1403,6 @@ export default {
1350
 
1403
 
1351
       that.validity = result.validity;
1404
       that.validity = result.validity;
1352
       that.valid = result.valid;
1405
       that.valid = result.valid;
1353
-      // if (that.vali == true) {
1354
-      //   $("#fade").fadeIn();
1355
-      //   that.promptingConent = "提交失败,请填写必填信息!";
1356
-      //   that.promptingStatus = false;
1357
-      //   setTimeout(function() {
1358
-      //     $("#fade").fadeOut();
1359
-      //   }, 2000);
1360
-      // }
1361
-      // that.vali = false;
1362
     },
1406
     },
1363
 
1407
 
1364
     dateSelectHandler(selectedVal) {
1408
     dateSelectHandler(selectedVal) {
@@ -1370,7 +1414,7 @@ export default {
1370
     },
1414
     },
1371
     filesAdded(files) {
1415
     filesAdded(files) {
1372
       let hasIgnore = false;
1416
       let hasIgnore = false;
1373
-      const maxSize = 1000 * 1024 * 1024; // 1M
1417
+      const maxSize = 10000 * 1024 * 1024; // 1M
1374
       for (let k in files) {
1418
       for (let k in files) {
1375
         const file = files[k];
1419
         const file = files[k];
1376
         if (file.size > maxSize) {
1420
         if (file.size > maxSize) {
@@ -1382,7 +1426,7 @@ export default {
1382
         this.$createToast({
1426
         this.$createToast({
1383
           type: "warn",
1427
           type: "warn",
1384
           time: 1000,
1428
           time: 1000,
1385
-          txt: "不能上传超过100M的文件"
1429
+          txt: "不能上传超过10M的文件"
1386
         }).show();
1430
         }).show();
1387
     },
1431
     },
1388
     filesAdded1(files) {
1432
     filesAdded1(files) {
@@ -1410,31 +1454,51 @@ export default {
1410
     },
1454
     },
1411
     // 展示事件分类选择器
1455
     // 展示事件分类选择器
1412
     showCategoryPicker() {
1456
     showCategoryPicker() {
1413
-      this.categoryPicker.show();
1457
+      let other = {
1458
+        selectedPlaceTxt: this.selectedPlaceTxt,
1459
+        userInpVal: this.userInpVal,
1460
+        deptInpVal: this.deptInpVal,
1461
+        selectUserIndex: this.selectUserIndex,
1462
+        selectDeptIndex: this.selectDeptIndex,
1463
+        selectedPlaceIndex: this.selectedPlaceIndex,
1464
+        order: this.order,
1465
+        imgFiles: this.imgFiles,
1466
+        selectedYytimeTxt: this.selectedYytimeTxt,
1467
+        selectedYytimeStamp: this.selectedYytimeStamp,
1468
+      }
1469
+      console.log(this.model, '传');
1470
+      console.log(this.imgFiles);
1471
+      console.log(other)
1472
+      this.$router.push(`/searchDept?model=${JSON.stringify(this.model)}&other=${JSON.stringify(other)}`)
1473
+      // this.categoryPicker.show();
1414
     },
1474
     },
1415
     // 选择事件分类
1475
     // 选择事件分类
1416
-    selectCategoryHandler(selectedVal, selectedIndex, selectedTxt) {
1417
-      // console.log(this.initSjList, "事件分类列表");
1418
-      // console.log(this.model.category.slice(-1)[0], "事件分类");
1419
-      var selected = [];
1420
-      selectedTxt.forEach(function(v, i) {
1421
-        if (v != "") {
1422
-          selected.push(v);
1423
-        }
1424
-      });
1425
-      this.selectedCategoryTxt = this.model.title = this.model.description = this.incidentTitle =
1426
-        selected[selected.length - 1];
1427
-      this.model.category = selectedVal;
1428
-      // var category = {
1429
-      //   index: selectedIndex,
1430
-      //   txt: this.selectedCategoryTxt
1431
-      // };
1432
-      // localStorage.setItem("category", JSON.stringify(category));
1476
+    selectCategoryHandler() {
1477
+      this.$createDialog({
1478
+        type: 'confirm',
1479
+        icon: 'cubeic-alert',
1480
+        title: '提示',
1481
+        content: '是否覆盖故障描述?',
1482
+        confirmBtn: {
1483
+          text: '确认覆盖',
1484
+          active: true,
1485
+          disabled: false,
1486
+          href: 'javascript:;'
1487
+        },
1488
+        cancelBtn: {
1489
+          text: '取消操作',
1490
+          active: false,
1491
+          disabled: false,
1492
+          href: 'javascript:;'
1493
+        },
1494
+        onConfirm: () => {
1495
+          this.model.description = this.model.title = this.incidentTitle = this.model.category.mutiCategory;
1496
+        },
1497
+        onCancel: () => {}
1498
+      }).show()
1499
+      this.selectedCategoryTxt = this.model.category.mutiCategory;
1433
       // ----------------------回显其他数据---------------------
1500
       // ----------------------回显其他数据---------------------
1434
-      console.log(selectedVal, "seimin");
1435
-      let reverseArr = selectedVal.filter(Boolean).reverse(); //数组翻转,取第一项不为空的
1436
-      let sjId = reverseArr[0]; //事件Id baba
1437
-      let sj = this.initSjList.filter(v => v.id == sjId)[0];
1501
+      let sj = this.model.category;
1438
       console.log(sj);
1502
       console.log(sj);
1439
       this.model.priority = sj.priority?sj.priority.id:null;
1503
       this.model.priority = sj.priority?sj.priority.id:null;
1440
       if (sj.branchType == 0) {
1504
       if (sj.branchType == 0) {
@@ -1558,9 +1622,7 @@ export default {
1558
           that.categoryPicker = that.$createCascadePicker({
1622
           that.categoryPicker = that.$createCascadePicker({
1559
             title: "事件分类选择",
1623
             title: "事件分类选择",
1560
             data: that.selectData,
1624
             data: that.selectData,
1561
-            // selectedIndex: localStorage.getItem("category")
1562
-            //   ? JSON.parse(localStorage.getItem("category")).index
1563
-            //   : [0, 0, 0],
1625
+            // selectedIndex: [0, 0, 0],
1564
             selectedIndex:[0, 0, 0],
1626
             selectedIndex:[0, 0, 0],
1565
             onSelect: that.selectCategoryHandler
1627
             onSelect: that.selectCategoryHandler
1566
           });
1628
           });
@@ -1596,7 +1658,8 @@ export default {
1596
       console.log(selectedVal, selectedIndex, selectedTxt);
1658
       console.log(selectedVal, selectedIndex, selectedTxt);
1597
       console.log(selectedVal[0], "区域");
1659
       console.log(selectedVal[0], "区域");
1598
       console.log(this.initSjList, "事件分类列表");
1660
       console.log(this.initSjList, "事件分类列表");
1599
-      console.log(this.model.category.slice(-1)[0], "事件分类");
1661
+      this.selectedPlaceIndex = selectedIndex;
1662
+      // console.log(this.model.category.slice(-1)[0], "事件分类");
1600
       if (this.ifRoom == 1) {
1663
       if (this.ifRoom == 1) {
1601
         this.getRoomData(selectedVal[1]);
1664
         this.getRoomData(selectedVal[1]);
1602
       }
1665
       }
@@ -1604,10 +1667,11 @@ export default {
1604
       this.selectedPlaceTxt = selectedTxt.join(" ");
1667
       this.selectedPlaceTxt = selectedTxt.join(" ");
1605
       // 分院区
1668
       // 分院区
1606
       // --------------------start---------------------
1669
       // --------------------start---------------------
1607
-      let categoryId = this.model.category.slice(-1)[0];
1670
+      // let categoryId = this.model.category.slice(-1)[0];
1671
+      let categoryId = this.model.category.id;
1608
       if (categoryId) {
1672
       if (categoryId) {
1609
-        // 选择了事件分类 liaomingming
1610
-        let categoryObj = this.initSjList.find(v => v.id == categoryId);
1673
+        // 选择了事件分类
1674
+        let categoryObj = this.model.category;
1611
         if (categoryObj) {
1675
         if (categoryObj) {
1612
           if (categoryObj.branchType == 1) {
1676
           if (categoryObj.branchType == 1) {
1613
             // 分院区开关打开的情况下
1677
             // 分院区开关打开的情况下
@@ -1656,40 +1720,42 @@ export default {
1656
         this.model.candidateGroups = "";
1720
         this.model.candidateGroups = "";
1657
       }
1721
       }
1658
       // --------------------end---------------------
1722
       // --------------------end---------------------
1659
-      // var place = {
1660
-      //   index: selectedIndex,
1661
-      //   txt: this.model.houseNumber
1662
-      // };
1663
-      // localStorage.setItem("place", JSON.stringify(place));
1664
     },
1723
     },
1665
     // 报修科室
1724
     // 报修科室
1666
     showDeptPicker() {
1725
     showDeptPicker() {
1726
+      this.deptList = [];
1667
       this.deptPicker.show();
1727
       this.deptPicker.show();
1728
+      this.getDept(true);
1729
+    },
1730
+    // 报修人
1731
+    showUserPicker() {
1732
+      this.userList = [];
1733
+      this.userPicker.show();
1734
+      this.getUser(true);
1668
     },
1735
     },
1669
     // 选中报修科室
1736
     // 选中报修科室
1670
     selectDeptHandler(selectedVal, selectedIndex, selectedTxt) {
1737
     selectDeptHandler(selectedVal, selectedIndex, selectedTxt) {
1671
       console.log(selectedVal, selectedIndex, selectedTxt);
1738
       console.log(selectedVal, selectedIndex, selectedTxt);
1672
-      this.deptInpVal = selectedTxt;
1673
-      this.model.requester = this.deptRes[selectedIndex];
1674
-      console.log(this.deptRes[selectedIndex]);
1675
-      this.inpLocalVal = this.model.address = this.deptRes[selectedIndex].place
1676
-        .area
1677
-        ? this.deptRes[selectedIndex].place.area.area
1678
-          ? this.deptRes[selectedIndex].place.place
1679
-            ? this.deptRes[selectedIndex].place.area.area +
1680
-              this.deptRes[selectedIndex].place.place
1681
-            : this.deptRes[selectedIndex].place.area.area
1682
-          : this.deptRes[selectedIndex].place.area
1683
-        : this.deptRes[selectedIndex].place.place;
1684
-      if (this.deptRes[selectedIndex].phone) {
1685
-        this.model.contactsInformation = this.deptRes[selectedIndex].phone;
1739
+      this.deptInpVal = selectedTxt[0];
1740
+      this.selectDeptIndex = selectedIndex;
1741
+      if(!selectedVal[0]){
1742
+        return;
1743
+      }
1744
+      let index = selectedIndex[0].toString();
1745
+      this.model.requester = this.deptRes[index];
1746
+      console.log(this.deptRes[index]);
1747
+      console.log(this.model);
1748
+      if(this.deptRes[index].place){
1749
+        console.log(this.placeSelectData);
1750
+        this.model.placeValue = [this.deptRes[index].place.area.id, this.deptRes[index].place.id];
1751
+        this.selectedPlaceTxt = `${this.deptRes[index].place.area.area} ${this.deptRes[index].place.place}`;
1752
+        let areaIndex = this.placeSelectData.findIndex(v=>v.value == this.deptRes[index].place.area.id);
1753
+        let placeIndex = this.placeSelectData[areaIndex].children.findIndex(v=>v.value == this.deptRes[index].place.id);
1754
+        this.placePicker.setData(this.placeSelectData, [areaIndex, placeIndex]);
1755
+      }
1756
+      if (this.deptRes[index].phone) {
1757
+        this.model.contactsInformation = this.deptRes[index].phone;
1686
       }
1758
       }
1687
-      // this.model.houseNumber = this.selectedPlaceTxt = selectedTxt.join(" ");
1688
-      // var place = {
1689
-      //   index: selectedIndex,
1690
-      //   txt: this.model.houseNumber
1691
-      // };
1692
-      // localStorage.setItem("place", JSON.stringify(place));
1693
     },
1759
     },
1694
     // 取消选中报修科室
1760
     // 取消选中报修科室
1695
     cancelDeptHandler() {
1761
     cancelDeptHandler() {
@@ -1699,12 +1765,53 @@ export default {
1699
         this.deptInpVal = "";
1765
         this.deptInpVal = "";
1700
         this.model.requester = "";
1766
         this.model.requester = "";
1701
       }
1767
       }
1702
-      // this.model.houseNumber = this.selectedPlaceTxt = selectedTxt.join(" ");
1703
-      // var place = {
1704
-      //   index: selectedIndex,
1705
-      //   txt: this.model.houseNumber
1706
-      // };
1707
-      // localStorage.setItem("place", JSON.stringify(place));
1768
+    },
1769
+    // 选中报修人
1770
+    selectUserHandler(selectedVal, selectedIndex, selectedTxt) {
1771
+      console.log(selectedVal, selectedIndex, selectedTxt);
1772
+      this.userInpVal = selectedTxt[0];
1773
+      this.selectUserIndex = selectedIndex;
1774
+      if(!selectedVal[0]){
1775
+        return;
1776
+      }
1777
+      let index = selectedIndex[0].toString();
1778
+      console.log(this.model,'model');
1779
+      this.model.contacts = this.userRes[index].name;
1780
+      this.model.requesterUser = this.userRes[index];
1781
+      console.log(this.userRes[index]);
1782
+      // if (this.userRes[index].mphone) {
1783
+      this.$createDialog({
1784
+        type: 'confirm',
1785
+        icon: 'cubeic-alert',
1786
+        title: '提示',
1787
+        content: '是否覆盖联系电话?',
1788
+        confirmBtn: {
1789
+          text: '确认覆盖',
1790
+          active: true,
1791
+          disabled: false,
1792
+          href: 'javascript:;'
1793
+        },
1794
+        cancelBtn: {
1795
+          text: '取消操作',
1796
+          active: false,
1797
+          disabled: false,
1798
+          href: 'javascript:;'
1799
+        },
1800
+        onConfirm: () => {
1801
+          this.model.contactsInformation = this.userRes[index].mphone;
1802
+        },
1803
+        onCancel: () => {}
1804
+      }).show()
1805
+      // }
1806
+    },
1807
+    // 取消选中报修人
1808
+    cancelUserHandler() {
1809
+      if (this.model.requesterUser) {
1810
+        this.userInpVal = this.model.requesterUser.name + '('+ this.model.requesterUser.account +')';
1811
+      } else if (!this.model.requesterUser) {
1812
+        this.userInpVal = "";
1813
+        this.model.requesterUser = "";
1814
+      }
1708
     },
1815
     },
1709
     getAreaData() {
1816
     getAreaData() {
1710
       this.$http
1817
       this.$http
@@ -1712,12 +1819,14 @@ export default {
1712
           idx: 0,
1819
           idx: 0,
1713
           sum: 1000,
1820
           sum: 1000,
1714
           area: {
1821
           area: {
1822
+            branch: this.model.branch,
1715
             wechatArea: true
1823
             wechatArea: true
1716
           }
1824
           }
1717
         })
1825
         })
1718
         .then(res => {
1826
         .then(res => {
1719
           this.initAreaList = JSON.parse(JSON.stringify(res.data.list));
1827
           this.initAreaList = JSON.parse(JSON.stringify(res.data.list));
1720
           var data = res.data.list;
1828
           var data = res.data.list;
1829
+          this.placeSelectData = [];
1721
           for (var i = 0; i < data.length; i++) {
1830
           for (var i = 0; i < data.length; i++) {
1722
             this.placeSelectData.push({
1831
             this.placeSelectData.push({
1723
               text: data[i].area,
1832
               text: data[i].area,
@@ -1725,6 +1834,7 @@ export default {
1725
               children: []
1834
               children: []
1726
             });
1835
             });
1727
           }
1836
           }
1837
+          this.getPlaceData();
1728
         });
1838
         });
1729
     },
1839
     },
1730
     getPlaceData() {
1840
     getPlaceData() {
@@ -1737,7 +1847,7 @@ export default {
1737
             wechatAreaId: ""
1847
             wechatAreaId: ""
1738
           }
1848
           }
1739
         })
1849
         })
1740
-        .then(function(res) {
1850
+        .then((res) => {
1741
           var data = res.data.list;
1851
           var data = res.data.list;
1742
           for (var i = 0; i < data.length; i++) {
1852
           for (var i = 0; i < data.length; i++) {
1743
             for (var j = 0; j < that.placeSelectData.length; j++) {
1853
             for (var j = 0; j < that.placeSelectData.length; j++) {
@@ -1751,14 +1861,37 @@ export default {
1751
           }
1861
           }
1752
 
1862
 
1753
           that.placePicker = that.$createCascadePicker({
1863
           that.placePicker = that.$createCascadePicker({
1754
-            title: "区域地点选择",
1864
+            title: "院区楼栋选择",
1755
             data: that.placeSelectData,
1865
             data: that.placeSelectData,
1756
-            // selectedIndex: localStorage.getItem("place")
1757
-            //   ? JSON.parse(localStorage.getItem("place")).index
1758
-            //   : [0, 0],
1866
+            selectedIndex: this.selectedPlaceIndex || [0, 0],
1759
             selectedIndex: [0, 0],
1867
             selectedIndex: [0, 0],
1760
             onSelect: that.selectPlaceHandler
1868
             onSelect: that.selectPlaceHandler
1761
           });
1869
           });
1870
+          console.log(this.$route,'路由参数');
1871
+          if(this.$route.params.id){
1872
+            let other = this.$route.params.other;
1873
+            this.model = this.$route.params.model;
1874
+            this.selectedPlaceTxt = other.selectedPlaceTxt;
1875
+            this.userInpVal = other.userInpVal;
1876
+            this.deptInpVal = other.deptInpVal;
1877
+            this.selectUserIndex = other.selectUserIndex;
1878
+            this.selectDeptIndex = other.selectDeptIndex;
1879
+            this.selectedPlaceIndex = other.selectedPlaceIndex;
1880
+            this.order = other.order;
1881
+            this.imgFiles = other.imgFiles;
1882
+            this.selectedYytimeTxt = other.selectedYytimeTxt,
1883
+            this.selectedYytimeStamp = other.selectedYytimeStamp,
1884
+
1885
+
1886
+            this.placePicker.setData(this.placeSelectData, this.selectedPlaceIndex);
1887
+            console.log(this.model);
1888
+            console.log(other);
1889
+            this.selectCategoryHandler();
1890
+            //回显事件分类
1891
+            // this.$http.get(`service/bpm/data/fetchData/incidentcategory/${this.$route.query.id}`).then(res=>{
1892
+            //   console.log(res);
1893
+            // })
1894
+          }
1762
         });
1895
         });
1763
     },
1896
     },
1764
     // 故障地点
1897
     // 故障地点
@@ -1793,9 +1926,7 @@ export default {
1793
           that.placePicker = that.$createCascadePicker({
1926
           that.placePicker = that.$createCascadePicker({
1794
             title: "区域地点选择",
1927
             title: "区域地点选择",
1795
             data: that.faultLocationList,
1928
             data: that.faultLocationList,
1796
-            // selectedIndex: localStorage.getItem("place")
1797
-            //   ? JSON.parse(localStorage.getItem("place")).index
1798
-            //   : [0, 0],
1929
+            // selectedIndex: [0, 0],
1799
             onSelect: that.selectPlaceHandler
1930
             onSelect: that.selectPlaceHandler
1800
           });
1931
           });
1801
           // that.fields[19].props.options = that.faultLocationList;
1932
           // that.fields[19].props.options = that.faultLocationList;
@@ -1812,47 +1943,85 @@ export default {
1812
       }, 600);
1943
       }, 600);
1813
     },
1944
     },
1814
     // 报修科室
1945
     // 报修科室
1815
-    getDept(type) {
1816
-      var that = this;
1946
+    getDept(isFirst) {
1817
       this.$http
1947
       this.$http
1818
         .post("service/user/data/fetchDataList/department", {
1948
         .post("service/user/data/fetchDataList/department", {
1819
           idx: 0,
1949
           idx: 0,
1820
-          sum: 50,
1821
-          department: { dept: that.deptInpVal || "" }
1950
+          sum: 1000,
1951
+          department: {
1952
+            branch: this.model.branch,
1953
+            selectType:"pinyin_qs",
1954
+            dept: isFirst ? '': (this.deptInpVal || "")
1955
+          }
1822
         })
1956
         })
1823
-        .then(function(res) {
1957
+        .then((res) => {
1824
           var data = res.data.list;
1958
           var data = res.data.list;
1825
-          if (type == 1) {
1826
-            that.deptList.length = 0;
1827
-            that.$set(that.deptList, true, []);
1828
-            that.deptList;
1829
-          }
1830
-          that.deptRes = res.data.list;
1959
+          this.deptRes = res.data.list;
1960
+          this.deptList = [];
1831
           for (var i = 0; i < data.length; i++) {
1961
           for (var i = 0; i < data.length; i++) {
1832
-            that.deptList.push({
1962
+            this.deptList.push({
1833
               text: data[i].dept,
1963
               text: data[i].dept,
1834
               value: data[i].id
1964
               value: data[i].id
1835
             });
1965
             });
1836
           }
1966
           }
1837
-
1838
-          that.deptPicker = that.$createCascadePicker({
1839
-            title: "报修科室选择",
1840
-            data: that.deptList,
1841
-            onSelect: that.selectDeptHandler,
1842
-            onCancel: that.cancelDeptHandler
1843
-          });
1967
+          console.log(this.deptList)
1968
+          this.deptPicker.setData(this.deptList, isFirst?this.selectDeptIndex:[0])
1969
+        });
1970
+    },
1971
+    // 报修人
1972
+    getUser(isFirst) {
1973
+      this.$http
1974
+        .post("service/user/data/fetchDataList/requester", {
1975
+          idx: 0,
1976
+          sum: 1000,
1977
+          requester: {
1978
+            searchKey: isFirst ? '': (this.userInpVal || "")
1979
+          }
1980
+        })
1981
+        .then((res) => {
1982
+          var data = res.data.list;
1983
+          this.userRes = res.data.list;
1984
+          this.userList = [];
1985
+          for (var i = 0; i < data.length; i++) {
1986
+            this.userList.push({
1987
+              text: data[i].name + '('+ data[i].account +')',
1988
+              value: data[i].id
1989
+            });
1990
+          }
1991
+          console.log(this.userList)
1992
+          this.userPicker.setData(this.userList, isFirst?this.selectUserIndex:[0])
1844
         });
1993
         });
1845
     },
1994
     },
1846
     changeDeptList() {
1995
     changeDeptList() {
1847
       var that = this;
1996
       var that = this;
1848
       clearTimeout(that.timer);
1997
       clearTimeout(that.timer);
1849
       that.timer = setTimeout(() => {
1998
       that.timer = setTimeout(() => {
1850
-        this.getDept(1);
1999
+        this.getDept();
2000
+      }, 600);
2001
+    },
2002
+    changeUserList() {
2003
+      clearTimeout(this.timer);
2004
+      this.timer = setTimeout(() => {
2005
+        this.getUser();
1851
       }, 600);
2006
       }, 600);
1852
     }
2007
     }
1853
   },
2008
   },
1854
   created() {
2009
   created() {
1855
     console.log(this.$route.params.data);
2010
     console.log(this.$route.params.data);
2011
+    this.deptPicker = this.$createCascadePicker({
2012
+      title: "报修科室选择",
2013
+      data: this.deptList,
2014
+      onSelect: this.selectDeptHandler,
2015
+      onCancel: this.cancelDeptHandler
2016
+    });
2017
+    this.userPicker = this.$createCascadePicker({
2018
+      title: "报修人选择",
2019
+      data: this.userList,
2020
+      onSelect: this.selectUserHandler,
2021
+      onCancel: this.cancelUserHandler
2022
+    });
2023
+    //获取院区
2024
+    this.getBranch();
1856
     //获取事件来源
2025
     //获取事件来源
1857
     this.getSource();
2026
     this.getSource();
1858
     // 优先级
2027
     // 优先级
@@ -1874,14 +2043,11 @@ export default {
1874
     // 事件单号
2043
     // 事件单号
1875
     this.getsjnum();
2044
     this.getsjnum();
1876
     // 事件分类
2045
     // 事件分类
1877
-    this.getIncidentcategory();
1878
-    this.getAreaData();
1879
-    this.getPlaceData();
2046
+    // this.getIncidentcategory();
2047
+    // this.getAreaData();
2048
+    // this.getPlaceData();
1880
     // 获取故障地点
2049
     // 获取故障地点
1881
     // this.getFaultLocation();
2050
     // this.getFaultLocation();
1882
-    if (this.valConfig == 2) {
1883
-      this.getDept();
1884
-    }
1885
   },
2051
   },
1886
   beforeRouteLeave(to, from, next) {
2052
   beforeRouteLeave(to, from, next) {
1887
     console.log(to);
2053
     console.log(to);
@@ -1925,9 +2091,9 @@ export default {
1925
   border: none;
2091
   border: none;
1926
 }
2092
 }
1927
 
2093
 
1928
-.btn_local {
1929
-  /* z-index: 101; */
1930
-}
2094
+/* .btn_local {
2095
+  z-index: 101;
2096
+} */
1931
 .inp_local {
2097
 .inp_local {
1932
   outline: none;
2098
   outline: none;
1933
   width: 100%;
2099
   width: 100%;

+ 255 - 224
src/views/searchDept.vue

@@ -1,32 +1,49 @@
1
 <template>
1
 <template>
2
   <div class="content">
2
   <div class="content">
3
     <div class="search-box">
3
     <div class="search-box">
4
-      <seiminSearch class="mSearch-input-box" :mode="2" button="inside" placeholder="输入关键字"
5
-        @search="doSearch(false)" @input="changeInp" @confirm="doSearch(false)" v-model="keyword"></seiminSearch>
4
+      <seiminSearch
5
+        class="mSearch-input-box"
6
+        :mode="2"
7
+        button="inside"
8
+        placeholder="输入关键字"
9
+        @search="doSearch(false)"
10
+        @input="changeInp"
11
+        @confirm="doSearch(false)"
12
+        v-model="keyword"
13
+      ></seiminSearch>
6
     </div>
14
     </div>
7
     <div class="search-keyword">
15
     <div class="search-keyword">
8
-      <cube-scroll class="keyword-list-box" v-show="isShowKeywordList" scroll-y>
9
-        <block v-for="(row, index) in keywordList" :key="index">
10
-          <div class="keyword-entry" hover-class="keyword-entry-tap">
11
-            <div class="keyword-text" @tap.stop="doSearch(keywordList[index].keyword)">
12
-              <rich-text :nodes="row.htmlStr"></rich-text>
13
-            </div>
14
-            <div class="keyword-img" @tap.stop="doSearch(keywordList[index].keyword)">
15
-              <image src="/static/HM-search/back.png"></image>
16
-            </div>
16
+      <cube-scroll class="keyword-list-box" v-show="isShowKeywordList">
17
+        <div class="keyword-entry" v-for="(row, index) in keywordList" :key="index">
18
+          <div
19
+            class="keyword-text"
20
+            @click.stop="doSearch(keywordList[index].keyword)"
21
+          >
22
+            <span v-html="row.htmlStr"></span>
23
+          </div>
24
+          <div
25
+            class="keyword-img"
26
+            @click.stop="doSearch(keywordList[index].keyword)"
27
+          >
28
+            <img src="../assets/HM-search/back.png" />
17
           </div>
29
           </div>
18
-        </block>
30
+        </div>
19
       </cube-scroll>
31
       </cube-scroll>
20
-      <cube-scroll class="keyword-box" v-show="!isShowKeywordList" scroll-y>
32
+      <cube-scroll class="keyword-box" v-show="!isShowKeywordList">
21
         <div class="keyword-block" v-if="oldKeywordList.length > 0">
33
         <div class="keyword-block" v-if="oldKeywordList.length > 0">
22
           <div class="keyword-list-header">
34
           <div class="keyword-list-header">
23
             <div>历史搜索</div>
35
             <div>历史搜索</div>
24
             <div>
36
             <div>
25
-              <image @tap="oldDelete" src="/static/HM-search/delete.png"></image>
37
+              <img @click="oldDelete" src="../assets/HM-search/delete.png" />
26
             </div>
38
             </div>
27
           </div>
39
           </div>
28
           <div class="keyword">
40
           <div class="keyword">
29
-            <div v-for="(keyword, index) in oldKeywordList" @tap="changeInp(keyword)" :key="index">{{ keyword }}
41
+            <div
42
+              v-for="(keyword, index) in oldKeywordList"
43
+              @click="changeInp(keyword)"
44
+              :key="index"
45
+            >
46
+              {{ keyword }}
30
             </div>
47
             </div>
31
           </div>
48
           </div>
32
         </div>
49
         </div>
@@ -37,14 +54,16 @@
37
 </template>
54
 </template>
38
 
55
 
39
 <script>
56
 <script>
40
-import seiminSearch from '../custom/seiminSearch.vue'
57
+import seiminSearch from "../custom/seiminSearch.vue";
41
 export default {
58
 export default {
42
-  components:{
59
+  components: {
43
     seiminSearch
60
     seiminSearch
44
   },
61
   },
45
   data() {
62
   data() {
46
     return {
63
     return {
47
-      reFresh: '',
64
+      other: {},
65
+      model: {},
66
+      reFresh: "",
48
       keyword: "",
67
       keyword: "",
49
       oldKeywordList: [],
68
       oldKeywordList: [],
50
       keywordList: [],
69
       keywordList: [],
@@ -52,7 +71,7 @@ export default {
52
       deptList: [],
71
       deptList: [],
53
       timer: null, //定时器
72
       timer: null, //定时器
54
       searchText: "", //搜索文本
73
       searchText: "", //搜索文本
55
-      searchData: [], //搜索结果
74
+      searchData: [] //搜索结果
56
     };
75
     };
57
   },
76
   },
58
   beforeDestroy() {
77
   beforeDestroy() {
@@ -62,6 +81,11 @@ export default {
62
     }
81
     }
63
   },
82
   },
64
   mounted() {
83
   mounted() {
84
+    if(this.$route.query.model){
85
+      let other = JSON.parse(this.$route.query.other);
86
+      this.model = JSON.parse(this.$route.query.model);
87
+      this.other = other;
88
+    }
65
     this.init();
89
     this.init();
66
   },
90
   },
67
   methods: {
91
   methods: {
@@ -76,7 +100,7 @@ export default {
76
     },
100
     },
77
     //加载历史搜索,自动读取本地Storage
101
     //加载历史搜索,自动读取本地Storage
78
     loadOldKeyword() {
102
     loadOldKeyword() {
79
-      this.oldKeywordList = JSON.parse(localStorage.getItem('OldKeys'));
103
+      this.oldKeywordList = JSON.parse(localStorage.getItem("OldKeys")) || [];
80
     },
104
     },
81
     //防抖搜索
105
     //防抖搜索
82
     changeInp(event) {
106
     changeInp(event) {
@@ -87,9 +111,9 @@ export default {
87
       }, 500);
111
       }, 500);
88
     },
112
     },
89
     //监听输入
113
     //监听输入
90
-    inputChange(event) {
114
+    inputChange(event = "") {
91
       //兼容引入组件时传入参数情况
115
       //兼容引入组件时传入参数情况
92
-      var keyword = event.detail ? event.detail.value : event;
116
+      var keyword = event.target ? event.target.value : event;
93
       if (!keyword) {
117
       if (!keyword) {
94
         this.keywordList = [];
118
         this.keywordList = [];
95
         this.isShowKeywordList = false;
119
         this.isShowKeywordList = false;
@@ -99,42 +123,49 @@ export default {
99
       this.isShowKeywordList = true;
123
       this.isShowKeywordList = true;
100
       let postData = {
124
       let postData = {
101
         idx: 0,
125
         idx: 0,
102
-        sum: 20,
103
-        department: {},
126
+        sum: 9999,
127
+        incidentcategory: {
128
+          category: keyword,
129
+          selectType: "pinyin_qs",
130
+          hierarchyQuery: "three"
131
+        }
104
       };
132
       };
105
       this.toast = this.$createToast({
133
       this.toast = this.$createToast({
106
         time: 0,
134
         time: 0,
107
         mask: true,
135
         mask: true,
108
-        txt: "正在加载中",
136
+        txt: "正在加载中"
109
       });
137
       });
110
       this.toast.show();
138
       this.toast.show();
111
-      reqFetchDataList("data", "department", postData).then((res) => {
112
-        this.toast.hide();
113
-        if (res.status == 200) {
114
-          this.searchData.push({
115
-            name: keyword,
116
-            list: res.list || [],
117
-          });
118
-          let searchText = this.searchText.detail ?
119
-            this.searchText.detail.value :
120
-            this.searchText;
121
-          let index = this.searchData.findIndex(
122
-            (item) => item.name === searchText
123
-          );
124
-          this.deptList = index >= 0 ? this.searchData[index].list : [];
125
-          this.keywordList = this.drawCorrelativeKeyword(
126
-            this.deptList,
127
-            keyword
128
-          );
129
-        } else {
130
-          this.$refs.seiminModel.show({
131
-            skin: "toast",
132
-            icon: "error",
133
-            content: res.msg || "获取数据失败",
134
-          });
135
-          throw new Error(res.msg || "获取数据失败");
136
-        }
137
-      });
139
+      this.$http
140
+        .post("service/user/data/fetchDataList/incidentcategory", postData)
141
+        .then(res => {
142
+          res = res.data;
143
+          this.toast.hide();
144
+          if (res.status == 200) {
145
+            this.searchData.push({
146
+              name: keyword,
147
+              list: res.list || []
148
+            });
149
+            let searchText = this.searchText.detail
150
+              ? this.searchText.detail.value
151
+              : this.searchText;
152
+            let index = this.searchData.findIndex(
153
+              item => item.name === searchText
154
+            );
155
+            this.deptList = index >= 0 ? this.searchData[index].list : [];
156
+            this.keywordList = this.drawCorrelativeKeyword(
157
+              this.deptList,
158
+              keyword
159
+            );
160
+          } else {
161
+            this.$refs.seiminModel.show({
162
+              skin: "toast",
163
+              icon: "error",
164
+              content: res.msg || "获取数据失败"
165
+            });
166
+            throw new Error(res.msg || "获取数据失败");
167
+          }
168
+        });
138
     },
169
     },
139
     //高亮关键字
170
     //高亮关键字
140
     drawCorrelativeKeyword(keywords, keyword) {
171
     drawCorrelativeKeyword(keywords, keyword) {
@@ -144,23 +175,15 @@ export default {
144
         var row = keywords[i];
175
         var row = keywords[i];
145
         //定义高亮#9f9f9f
176
         //定义高亮#9f9f9f
146
         var html = "";
177
         var html = "";
147
-        if (this.deptDisplay == 1) {
148
-          // 科室名称
149
-          html = row.dept.replace(
150
-            keyword,
151
-            "<span style='color: #9f9f9f;'>" + keyword + "</span>"
152
-          );
153
-        } else if (this.deptDisplay == 2) {
154
-          // 科室别称
155
-          html = row.deptalias.replace(
156
-            keyword,
157
-            "<span style='color: #9f9f9f;'>" + keyword + "</span>"
158
-          );
159
-        }
178
+        // 科室名称
179
+        html = row.mutiCategory.replace(
180
+          keyword,
181
+          "<span style='color: #9f9f9f;'>" + keyword + "</span>"
182
+        );
160
         html = "<div>" + html + "</div>";
183
         html = "<div>" + html + "</div>";
161
         var tmpObj = {
184
         var tmpObj = {
162
-          keyword: this.deptDisplay == 1 ? row.dept : row.deptalias,
163
-          htmlStr: html,
185
+          keyword: row.mutiCategory,
186
+          htmlStr: html
164
         };
187
         };
165
         keywordArr.push(tmpObj);
188
         keywordArr.push(tmpObj);
166
       }
189
       }
@@ -169,47 +192,55 @@ export default {
169
     //清除历史搜索
192
     //清除历史搜索
170
     oldDelete() {
193
     oldDelete() {
171
       this.$createDialog({
194
       this.$createDialog({
172
-        type: 'confirm',
173
-        icon: 'cubeic-alert',
174
-        title: '提示',
175
-        content: '确定清除历史搜索记录?',
195
+        type: "confirm",
196
+        icon: "cubeic-alert",
197
+        title: "提示",
198
+        content: "确定清除历史搜索记录?",
176
         confirmBtn: {
199
         confirmBtn: {
177
-          text: '确定',
200
+          text: "确定",
178
           active: true,
201
           active: true,
179
           disabled: false,
202
           disabled: false,
180
-          href: 'javascript:;'
203
+          href: "javascript:;"
181
         },
204
         },
182
         cancelBtn: {
205
         cancelBtn: {
183
-          text: '取消',
206
+          text: "取消",
184
           active: false,
207
           active: false,
185
           disabled: false,
208
           disabled: false,
186
-          href: 'javascript:;'
209
+          href: "javascript:;"
187
         },
210
         },
188
         onConfirm: () => {
211
         onConfirm: () => {
189
           this.oldKeywordList = [];
212
           this.oldKeywordList = [];
190
-          localStorage.removeItem('OldKeys');
213
+          localStorage.removeItem("OldKeys");
191
         },
214
         },
192
         onCancel: () => {}
215
         onCancel: () => {}
193
-      }).show()
216
+      }).show();
194
     },
217
     },
195
     //执行搜索
218
     //执行搜索
196
     doSearch(keyword) {
219
     doSearch(keyword) {
197
       keyword = keyword === false ? this.keyword : keyword;
220
       keyword = keyword === false ? this.keyword : keyword;
198
       this.keyword = keyword;
221
       this.keyword = keyword;
199
       this.saveKeyword(keyword); //保存为历史
222
       this.saveKeyword(keyword); //保存为历史
200
-      let arr = this.deptList.filter((item) => {
201
-        return this.deptDisplay == 1 ?
202
-          item.dept === keyword :
203
-          item.deptalias === keyword;
223
+      let arr = this.deptList.filter(item => {
224
+        return item.mutiCategory === keyword;
204
       });
225
       });
205
       if (arr.length) {
226
       if (arr.length) {
206
-        this.changeSearchDeptResult(arr[0]);
227
+        // model
228
+        this.model.category = arr[0];
229
+        // this.$router.push(`/newIncident?id=${arr[0].id}&model=${JSON.stringify(this.model)}&other=${JSON.stringify(this.other)}`);
230
+        this.$router.push({
231
+          name: 'NewIncident',
232
+          params: {
233
+            id: arr[0].id,
234
+            model: this.model,
235
+            other: this.other,
236
+          },
237
+        })
207
       }
238
       }
208
     },
239
     },
209
     //保存关键字到历史记录
240
     //保存关键字到历史记录
210
     saveKeyword(keyword) {
241
     saveKeyword(keyword) {
211
-      var OldKeys = JSON.parse(localStorage.getItem('OldKeys'));
212
-      if(OldKeys){
242
+      var OldKeys = JSON.parse(localStorage.getItem("OldKeys"));
243
+      if (OldKeys) {
213
         var findIndex = OldKeys.indexOf(keyword);
244
         var findIndex = OldKeys.indexOf(keyword);
214
         if (findIndex == -1) {
245
         if (findIndex == -1) {
215
           OldKeys.unshift(keyword);
246
           OldKeys.unshift(keyword);
@@ -219,172 +250,172 @@ export default {
219
         }
250
         }
220
         //最多10个纪录
251
         //最多10个纪录
221
         OldKeys.length > 10 && OldKeys.pop();
252
         OldKeys.length > 10 && OldKeys.pop();
222
-        localStorage.setItem('OldKeys',JSON.stringify(OldKeys))
253
+        localStorage.setItem("OldKeys", JSON.stringify(OldKeys));
223
         this.oldKeywordList = OldKeys; //更新历史搜索
254
         this.oldKeywordList = OldKeys; //更新历史搜索
224
-      }else{
255
+      } else {
225
         OldKeys = [keyword];
256
         OldKeys = [keyword];
226
-        localStorage.setItem('OldKeys',JSON.stringify(OldKeys))
257
+        localStorage.setItem("OldKeys", JSON.stringify(OldKeys));
227
         this.oldKeywordList = OldKeys; //更新历史搜索
258
         this.oldKeywordList = OldKeys; //更新历史搜索
228
       }
259
       }
229
-    },
230
-  },
260
+    }
261
+  }
231
 };
262
 };
232
 </script>
263
 </script>
233
 <style lang="less" scoped>
264
 <style lang="less" scoped>
234
-  view {
235
-    display: block;
236
-  }
265
+view {
266
+  display: block;
267
+}
237
 
268
 
238
-  .search-box {
239
-    background-color: rgb(242, 242, 242);
240
-    padding: 15upx 2.5%;
241
-    display: flex;
242
-    justify-content: space-between;
243
-    position: sticky;
244
-    top: 0;
245
-  }
269
+.search-box {
270
+  background-color: rgb(242, 242, 242);
271
+  padding: 0.15rem 2.5%;
272
+  display: flex;
273
+  justify-content: space-between;
274
+  position: sticky;
275
+  top: 0;
276
+}
246
 
277
 
247
-  .search-box .mSearch-input-box {
248
-    width: 100%;
249
-  }
278
+.search-box .mSearch-input-box {
279
+  width: 100%;
280
+}
250
 
281
 
251
-  .search-box .input-box {
252
-    width: 85%;
253
-    flex-shrink: 1;
254
-    display: flex;
255
-    justify-content: center;
256
-    align-items: center;
257
-  }
282
+.search-box .input-box {
283
+  width: 85%;
284
+  flex-shrink: 1;
285
+  display: flex;
286
+  justify-content: center;
287
+  align-items: center;
288
+}
258
 
289
 
259
-  .search-box .search-btn {
260
-    width: 15%;
261
-    margin: 0 0 0 2%;
262
-    display: flex;
263
-    justify-content: center;
264
-    align-items: center;
265
-    flex-shrink: 0;
266
-    font-size: 28upx;
267
-    color: #fff;
268
-    background: linear-gradient(to right, #ff9801, #ff570a);
269
-    border-radius: 60upx;
270
-  }
290
+.search-box .search-btn {
291
+  width: 15%;
292
+  margin: 0 0 0 2%;
293
+  display: flex;
294
+  justify-content: center;
295
+  align-items: center;
296
+  flex-shrink: 0;
297
+  font-size: 0.28rem;
298
+  color: #fff;
299
+  background: linear-gradient(to right, #ff9801, #ff570a);
300
+  border-radius: 0.6rem;
301
+}
271
 
302
 
272
-  .search-box .input-box>input {
273
-    width: 100%;
274
-    height: 60upx;
275
-    font-size: 32upx;
276
-    border: 0;
277
-    border-radius: 60upx;
278
-    -webkit-appearance: none;
279
-    -moz-appearance: none;
280
-    appearance: none;
281
-    padding: 0 3%;
282
-    margin: 0;
283
-    background-color: #ffffff;
284
-  }
303
+.search-box .input-box > input {
304
+  width: 100%;
305
+  height: 0.6rem;
306
+  font-size: 0.32rem;
307
+  border: 0;
308
+  border-radius: 0.6rem;
309
+  -webkit-appearance: none;
310
+  -moz-appearance: none;
311
+  appearance: none;
312
+  padding: 0 3%;
313
+  margin: 0;
314
+  background-color: #ffffff;
315
+}
285
 
316
 
286
-  .placeholder-class {
287
-    color: #9e9e9e;
288
-  }
317
+.placeholder-class {
318
+  color: #9e9e9e;
319
+}
289
 
320
 
290
-  .search-keyword {
291
-    width: 100%;
292
-    background-color: rgb(242, 242, 242);
293
-  }
321
+.search-keyword {
322
+  width: 100%;
323
+  background-color: rgb(242, 242, 242);
324
+}
294
 
325
 
295
-  .keyword-list-box {
296
-    height: calc(100vh - 110upx);
297
-    padding-top: 10upx;
298
-    border-radius: 20upx 20upx 0 0;
299
-    background-color: #fff;
300
-  }
326
+.keyword-list-box {
327
+  height: calc(100vh - 1.1rem);
328
+  padding-top: 0.1rem;
329
+  border-radius: 0.2rem 0.2rem 0 0;
330
+  background-color: #fff;
331
+}
301
 
332
 
302
-  .keyword-entry-tap {
303
-    background-color: #eee;
304
-  }
333
+.keyword-entry-tap {
334
+  background-color: #eee;
335
+}
305
 
336
 
306
-  .keyword-entry {
307
-    width: 94%;
308
-    height: 80upx;
309
-    margin: 0 3%;
310
-    font-size: 30upx;
311
-    color: #333;
312
-    display: flex;
313
-    justify-content: space-between;
314
-    align-items: center;
315
-    border-bottom: solid 1upx #e7e7e7;
316
-  }
337
+.keyword-entry {
338
+  width: 94%;
339
+  height: 0.8rem;
340
+  margin: 0 3%;
341
+  font-size: 0.3rem;
342
+  color: #333;
343
+  display: flex;
344
+  justify-content: space-between;
345
+  align-items: center;
346
+  border-bottom: solid 1px #e7e7e7;
347
+}
317
 
348
 
318
-  .keyword-entry image {
319
-    width: 60upx;
320
-    height: 60upx;
321
-  }
349
+.keyword-entry img {
350
+  width: 0.6rem;
351
+  height: 0.6rem;
352
+}
322
 
353
 
323
-  .keyword-entry .keyword-text,
324
-  .keyword-entry .keyword-img {
325
-    height: 80upx;
326
-    display: flex;
327
-    align-items: center;
328
-  }
354
+.keyword-entry .keyword-text,
355
+.keyword-entry .keyword-img {
356
+  height: 0.8rem;
357
+  display: flex;
358
+  align-items: center;
359
+}
329
 
360
 
330
-  .keyword-entry .keyword-text {
331
-    width: 90%;
332
-  }
361
+.keyword-entry .keyword-text {
362
+  width: 90%;
363
+}
333
 
364
 
334
-  .keyword-entry .keyword-img {
335
-    width: 10%;
336
-    justify-content: center;
337
-  }
365
+.keyword-entry .keyword-img {
366
+  width: 10%;
367
+  justify-content: center;
368
+}
338
 
369
 
339
-  .keyword-box {
340
-    height: calc(100vh - 110upx);
341
-    border-radius: 20upx 20upx 0 0;
342
-    background-color: #fff;
343
-  }
370
+.keyword-box {
371
+  height: calc(100vh - 1.1rem);
372
+  border-radius: 0.2rem 0.2rem 0 0;
373
+  background-color: #fff;
374
+}
344
 
375
 
345
-  .keyword-box .keyword-block {
346
-    padding: 10upx 0;
347
-  }
376
+.keyword-box .keyword-block {
377
+  padding: 0.1rem 0;
378
+}
348
 
379
 
349
-  .keyword-box .keyword-block .keyword-list-header {
350
-    width: 94%;
351
-    padding: 10upx 3%;
352
-    font-size: 27upx;
353
-    color: #333;
354
-    display: flex;
355
-    justify-content: space-between;
356
-  }
380
+.keyword-box .keyword-block .keyword-list-header {
381
+  width: 94%;
382
+  padding: 0.1rem 3%;
383
+  font-size: 0.27rem;
384
+  color: #333;
385
+  display: flex;
386
+  justify-content: space-between;
387
+}
357
 
388
 
358
-  .keyword-box .keyword-block .keyword-list-header image {
359
-    width: 40upx;
360
-    height: 40upx;
361
-  }
389
+.keyword-box .keyword-block .keyword-list-header img {
390
+  width: 0.4rem;
391
+  height: 0.4rem;
392
+}
362
 
393
 
363
-  .keyword-box .keyword-block .keyword {
364
-    width: 94%;
365
-    padding: 3px 3%;
366
-    display: flex;
367
-    flex-flow: wrap;
368
-    justify-content: flex-start;
369
-  }
394
+.keyword-box .keyword-block .keyword {
395
+  width: 94%;
396
+  padding: 3px 3%;
397
+  display: flex;
398
+  flex-flow: wrap;
399
+  justify-content: flex-start;
400
+}
370
 
401
 
371
-  .keyword-box .keyword-block .hide-hot-tis {
372
-    display: flex;
373
-    justify-content: center;
374
-    font-size: 28upx;
375
-    color: #6b6b6b;
376
-  }
402
+.keyword-box .keyword-block .hide-hot-tis {
403
+  display: flex;
404
+  justify-content: center;
405
+  font-size: 0.28rem;
406
+  color: #6b6b6b;
407
+}
377
 
408
 
378
-  .keyword-box .keyword-block .keyword>view {
379
-    display: flex;
380
-    justify-content: center;
381
-    align-items: center;
382
-    border-radius: 60upx;
383
-    padding: 0 20upx;
384
-    margin: 10upx 20upx 10upx 0;
385
-    height: 60upx;
386
-    font-size: 28upx;
387
-    background-color: rgb(242, 242, 242);
388
-    color: #6b6b6b;
389
-  }
409
+.keyword-box .keyword-block .keyword > view {
410
+  display: flex;
411
+  justify-content: center;
412
+  align-items: center;
413
+  border-radius: 0.6rem;
414
+  padding: 0 0.2rem;
415
+  margin: 0.1rem 0.2rem 0.1rem 0;
416
+  height: 0.6rem;
417
+  font-size: 0.28rem;
418
+  background-color: rgb(242, 242, 242);
419
+  color: #6b6b6b;
420
+}
390
 </style>
421
 </style>