maotao 8 kuukautta sitten
vanhempi
commit
0e8359f5fb
28 muutettua tiedostoa jossa 1145 lisäystä ja 395 poistoa
  1. 1 0
      README.md
  2. 1 1
      proxy.conf.json
  3. 1 1
      src/app/components/configurationCenter/configuration-category/configuration-category.component.html
  4. 182 0
      src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component.html
  5. 289 0
      src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component.less
  6. 346 0
      src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component.ts
  7. 23 0
      src/app/components/select-menu/select-menu.component.html
  8. 76 0
      src/app/components/select-menu/select-menu.component.less
  9. 31 0
      src/app/components/select-menu/select-menu.component.ts
  10. 6 0
      src/app/services/main.service.ts
  11. 0 63
      src/app/share/allocation-worker copy/allocation-worker.component.html
  12. 0 110
      src/app/share/allocation-worker copy/allocation-worker.component.less
  13. 0 168
      src/app/share/allocation-worker copy/allocation-worker.component.ts
  14. 8 1
      src/app/views/incident-config/incident-config.component.less
  15. 2 0
      src/app/views/main/main.component.html
  16. 9 1
      src/app/views/main/main.component.ts
  17. 2 0
      src/app/views/main/main.module.ts
  18. 5 5
      src/app/views/other-config/other-config.component.html
  19. 8 1
      src/app/views/other-config/other-config.component.less
  20. 3 3
      src/app/views/other-config/other-config.component.ts
  21. 9 0
      src/app/views/other-config/other-config.module.ts
  22. 95 26
      src/assets/iconfont/demo_index.html
  23. 19 7
      src/assets/iconfont/iconfont.css
  24. 1 1
      src/assets/iconfont/iconfont.js
  25. 28 7
      src/assets/iconfont/iconfont.json
  26. BIN
      src/assets/iconfont/iconfont.ttf
  27. BIN
      src/assets/iconfont/iconfont.woff
  28. BIN
      src/assets/iconfont/iconfont.woff2

+ 1 - 0
README.md

@@ -6,6 +6,7 @@
6 6
 - services     存放服务
7 7
 - views        存放视图
8 8
 - share        存放共享组件
9
+- components   存放复用性不高的组件
9 10
 
10 11
 # 后端提示-seimin(2021-07-05)
11 12
 - /simple/data/fetchDataList/{model}            查询列表

+ 1 - 1
proxy.conf.json

@@ -1,6 +1,6 @@
1 1
 {
2 2
   "/service": {
3
-		"target": "http://192.168.4.105",
3
+		"target": "http://192.168.3.108",
4 4
     "logLevel": "debug",
5 5
     "changeOrigin": true,
6 6
     "pathRewrite": {

+ 1 - 1
src/app/components/configurationCenter/configuration-category/configuration-category.component.html

@@ -139,7 +139,7 @@
139 139
         </nz-form-item>
140 140
         <nz-form-item>
141 141
           <nz-form-label [nzSpan]="5" nzRequired nzFor="userGroup">分配方式</nz-form-label>
142
-          <nz-form-control [nzSpan]="19" nzErrorTip="请选择分!">
142
+          <nz-form-control [nzSpan]="19" nzErrorTip="请选择分配方式!">
143 143
             <nz-radio-group formControlName="userGroup" (ngModelChange)="changeUserGroup($event)">
144 144
               <label nz-radio [nzValue]="1">人</label>
145 145
               <label nz-radio [nzValue]="2">组</label>

+ 182 - 0
src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component.html

@@ -0,0 +1,182 @@
1
+<div class="content priority">
2
+  <div class="contentInner">
3
+    <div class="list-template" id="wechatTable">
4
+      <div class="list-template__content">
5
+        <div class="list-template__bottom">
6
+          <div class="list-template__top" nz-row>
7
+            <div nz-col nzLg="24" class="list-template__btns">
8
+              <button nz-button class="btn default" (click)="addWechatModal()">新增</button>
9
+            </div>
10
+          </div>
11
+          <nz-table class="list-template__nzTable" [nzData]="wechatList" nzSize="middle" [nzShowPagination]="false"
12
+            [nzLoading]="loading1" [nzScroll]="{ y: tableWechatHeight + 'px' }">
13
+            <thead>
14
+              <tr class="thead">
15
+                <th nzWidth="14%">名称|appId</th>
16
+                <th nzWidth="22%">appSecret|agentId</th>
17
+                <th nzWidth="8%">是否企业号</th>
18
+                <th nzWidth="12%">token更新时间</th>
19
+                <th nzWidth="20%">服务地址|服务域名</th>
20
+                <th nzWidth="8%">是否启用</th>
21
+                <th nzWidth="16%">操作</th>
22
+              </tr>
23
+            </thead>
24
+            <tbody>
25
+              <tr *ngFor="let data of wechatList;let i = index">
26
+                <td>{{data.name}}<br>{{data.appId}}</td>
27
+                <td>{{data.appSecret}}<br>{{data.agentId}}</td>
28
+                <td>{{data.qy ? '是' : '否'}}</td>
29
+                <td>{{data.atuTime | date: 'yyyy-MM-dd HH:mm:ss'}}</td>
30
+                <td>{{data.url}}<br>{{data.domain}}</td>
31
+                <td>{{data.active ? '是' : '否'}}</td>
32
+                <td>
33
+                  <div class="coop">
34
+                    <span (click)="showDelModal(data,'您确认要删除吗?','删除','del')">删除</span>
35
+                    <span (click)="editWechat(data)">编辑</span>
36
+                    <span (click)="showDelModal(data,'您确认要重置获取token吗?','重置','delToken')">重置token</span>
37
+                  </div>
38
+                </td>
39
+              </tr>
40
+            </tbody>
41
+          </nz-table>
42
+        </div>
43
+      </div>
44
+    </div>
45
+  </div>
46
+</div>
47
+
48
+<!-- 操作成功/失败提示框 -->
49
+<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
50
+  [info]="promptInfo">
51
+</app-prompt-modal>
52
+
53
+<!-- 删除模态框 -->
54
+<app-dialog-delete [delModal]="delModal" (hideDelModalEvent)="hideDelModal()" [btnLoading]="btnLoading"
55
+(confirmDelEvent)="confirmDel()" [content]="tipsMsg1"></app-dialog-delete>
56
+
57
+<!-- 新增/编辑模态框 -->
58
+<div class="save display_flex justify-content_flex-center align-items_center add" *ngIf="modalWechat">
59
+  <div class="modalBody">
60
+    <div class="title">{{modelName}}<i class="icon_transport transport-guanbi" (click)="hideWechatModal()"></i></div>
61
+    <div class="content">
62
+      <form nz-form [formGroup]="validateWechatForm" class="addForm">
63
+        <nz-form-item>
64
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="name">名称</nz-form-label>
65
+          <nz-form-control [nzSpan]="18" nzErrorTip="请输入名称!">
66
+            <nz-input-group>
67
+              <input formControlName="name" nz-input placeholder="请输入名称">
68
+            </nz-input-group>
69
+          </nz-form-control>
70
+        </nz-form-item>
71
+        <nz-form-item>
72
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="appId">appId</nz-form-label>
73
+          <nz-form-control [nzSpan]="18" nzErrorTip="请输入appId!">
74
+            <nz-input-group>
75
+              <input formControlName="appId" nz-input placeholder="请输入appId">
76
+            </nz-input-group>
77
+          </nz-form-control>
78
+        </nz-form-item>
79
+        <nz-form-item>
80
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="appSecret">appSecret</nz-form-label>
81
+          <nz-form-control [nzSpan]="18" nzErrorTip="请输入appSecret!">
82
+            <nz-input-group>
83
+              <input formControlName="appSecret" nz-input placeholder="请输入appSecret">
84
+            </nz-input-group>
85
+          </nz-form-control>
86
+        </nz-form-item>
87
+        <nz-form-item>
88
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="agentId">agentId</nz-form-label>
89
+          <nz-form-control [nzSpan]="18" nzErrorTip="请输入agentId!">
90
+            <nz-input-group>
91
+              <input formControlName="agentId" nz-input placeholder="请输入agentId">
92
+            </nz-input-group>
93
+          </nz-form-control>
94
+        </nz-form-item>
95
+        <nz-form-item>
96
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="url">服务地址</nz-form-label>
97
+          <nz-form-control [nzSpan]="18" nzErrorTip="请输入服务地址!">
98
+            <nz-input-group>
99
+              <input formControlName="url" nz-input placeholder="请输入服务地址">
100
+            </nz-input-group>
101
+          </nz-form-control>
102
+        </nz-form-item>
103
+        <nz-form-item>
104
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="domain">服务域名</nz-form-label>
105
+          <nz-form-control [nzSpan]="18" nzErrorTip="请输入服务域名!">
106
+            <nz-input-group>
107
+              <input formControlName="domain" nz-input placeholder="请输入服务域名">
108
+            </nz-input-group>
109
+          </nz-form-control>
110
+        </nz-form-item>
111
+        <nz-form-item>
112
+          <nz-form-label [nzSpan]="7" nzRequired nzFor="active">是否启用</nz-form-label>
113
+          <nz-form-control [nzSpan]="17" nzErrorTip="请选择是否启用!">
114
+            <nz-radio-group formControlName="active">
115
+              <label nz-radio [nzValue]="true">是</label>
116
+              <label nz-radio [nzValue]="false">否</label>
117
+            </nz-radio-group>
118
+          </nz-form-control>
119
+        </nz-form-item>
120
+        <nz-form-item>
121
+          <nz-form-label [nzSpan]="7" nzRequired nzFor="qy">是否企业号</nz-form-label>
122
+          <nz-form-control [nzSpan]="17" nzErrorTip="请选择是否企业号!">
123
+            <nz-radio-group formControlName="qy">
124
+              <label nz-radio [nzValue]="true">是</label>
125
+              <label nz-radio [nzValue]="false">否</label>
126
+            </nz-radio-group>
127
+          </nz-form-control>
128
+        </nz-form-item>
129
+        <nz-form-item>
130
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="type">类型</nz-form-label>
131
+          <nz-form-control [nzSpan]="18" nzErrorTip="请选择类型!">
132
+            <nz-select [nzDropdownMatchSelectWidth]="false" formControlName="type" nzShowSearch
133
+              nzPlaceHolder="请选择类型" nzServerSearch>
134
+              <ng-container *ngFor="let data of typeList">
135
+                <nz-option *ngIf="!isLoading" [nzLabel]="data.name" [nzValue]="data.id"></nz-option>
136
+              </ng-container>
137
+              <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
138
+                <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
139
+              </nz-option>
140
+            </nz-select>
141
+          </nz-form-control>
142
+        </nz-form-item>
143
+        <nz-form-item>
144
+          <nz-form-label [nzSpan]="7" nzRequired nzFor="bindAccount">绑定工号</nz-form-label>
145
+          <nz-form-control [nzSpan]="17" nzErrorTip="请选择绑定工号!">
146
+            <nz-radio-group formControlName="bindAccount" (ngModelChange)="changeBindAccount($event)">
147
+              <label nz-radio [nzValue]="true">是</label>
148
+              <label nz-radio [nzValue]="false">否</label>
149
+            </nz-radio-group>
150
+          </nz-form-control>
151
+        </nz-form-item>
152
+        <nz-form-item *ngIf="!validateWechatForm.value.bindAccount">
153
+          <nz-form-label [nzSpan]="7" nzRequired nzFor="createUser">自动创建用户</nz-form-label>
154
+          <nz-form-control [nzSpan]="17" nzErrorTip="请选择自动创建用户!">
155
+            <nz-radio-group formControlName="createUser" (ngModelChange)="changeCreateUser($event)">
156
+              <label nz-radio [nzValue]="true">是</label>
157
+              <label nz-radio [nzValue]="false">否</label>
158
+            </nz-radio-group>
159
+          </nz-form-control>
160
+        </nz-form-item>
161
+        <nz-form-item *ngIf="validateWechatForm.value.createUser">
162
+          <nz-form-label [nzSpan]="6" nzRequired nzFor="defaultRole">关联角色</nz-form-label>
163
+          <nz-form-control [nzSpan]="18" nzErrorTip="请选择关联角色!">
164
+            <nz-select [nzDropdownMatchSelectWidth]="false" formControlName="defaultRole" nzShowSearch
165
+            nzPlaceHolder="请选择关联角色" nzServerSearch>
166
+              <ng-container *ngFor="let option of defaultRoleList">
167
+                <nz-option *ngIf="!isLoading" [nzLabel]="option.role" [nzValue]="option.id"></nz-option>
168
+              </ng-container>
169
+              <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
170
+                <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
171
+              </nz-option>
172
+            </nz-select>
173
+          </nz-form-control>
174
+        </nz-form-item>
175
+      </form>
176
+    </div>
177
+    <div class=" display_flex justify-content_flex-center">
178
+      <button nzType="primary" nz-button (click)="submitWechatForm()" [nzLoading]="btnLoading">确认</button>
179
+      <button class="btn cancel" nz-button nzType="default" (click)="hideWechatModal()">取消</button>
180
+    </div>
181
+  </div>
182
+</div>

+ 289 - 0
src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component.less

@@ -0,0 +1,289 @@
1
+@import "../../../../../src/theme.less";
2
+:host {
3
+  height: 100%;
4
+  display: flex;
5
+  flex-direction: column;
6
+  justify-content: space-between;
7
+  background-color: #F0F2F5;
8
+  .list-template__nzTable,
9
+  .list-template__bottom{
10
+    padding: 0!important;
11
+    border: none!important;
12
+    background: #fff!important;
13
+  }
14
+  .list-template{
15
+    width: 100%!important;
16
+    height: 100%!important;
17
+  }
18
+  .content{
19
+    flex: 1;
20
+    min-height: 0;
21
+    display: flex;
22
+    flex-direction: column;
23
+    justify-content: space-between;
24
+    border: 1px solid #EEF3F9;
25
+    &.priority{
26
+      margin: 24px 16px 0;
27
+      background-color: #fff;
28
+      .contentInner{
29
+        padding: 48px 16px;
30
+        border: 1px solid #E8EBEF;
31
+      }
32
+    }
33
+    .contentItem{
34
+      padding: 4px 16px;
35
+      cursor: pointer;
36
+      overflow: hidden;
37
+      text-overflow: ellipsis;
38
+      white-space: nowrap;
39
+      &.active{
40
+        color: @primary-color;
41
+        background-color: #F0F6ED;
42
+        border-radius: 4px;
43
+      }
44
+    }
45
+    .contentInner{
46
+      flex: 1;
47
+      display: flex;
48
+      justify-content: space-between;
49
+      align-items: center;
50
+      padding: 0 16px;
51
+      gap: 16px;
52
+      .contentHead{
53
+        height: 45px;
54
+        display: flex;
55
+        justify-content: space-between;
56
+        align-items: center;
57
+        gap: 16px;
58
+        padding: 0 16px;
59
+        font-size: 16px;
60
+        font-weight: bold;
61
+        border-bottom: 1px solid #D9D9D9;
62
+        .title{
63
+          overflow: hidden;
64
+          text-overflow: ellipsis;
65
+          white-space: nowrap;
66
+        }
67
+        .btns{
68
+          flex-shrink: 0;
69
+        }
70
+      }
71
+      .contentBody{
72
+        padding: 0 8px;
73
+        margin: 4px 0;
74
+        flex: 1;
75
+      }
76
+      .address{
77
+        flex: 1;
78
+        height: 100%;
79
+        background: #FFFFFF;
80
+        border: 1px solid #E8EBEF;
81
+        display: flex;
82
+        flex-direction: column;
83
+        width: 0;
84
+      }
85
+      .addressAssign{
86
+        flex: 3;
87
+        height: 100%;
88
+        background: #FFFFFF;
89
+        border: 1px solid #E8EBEF;
90
+        display: flex;
91
+        flex-direction: column;
92
+        width: 0;
93
+      }
94
+      .list-template__searchItem {
95
+        margin-bottom: 16px;
96
+        .label {
97
+          color: #333;
98
+          display: inline-block;
99
+          width: 70px;
100
+          text-align-last: justify;
101
+          text-align: justify;
102
+          &.label--big {
103
+            width: 100px;
104
+          }
105
+        }
106
+        .formItem {
107
+          width: 135px;
108
+        }
109
+      }
110
+    }
111
+    .contentBtns{
112
+      margin-bottom: 16px;
113
+      display: flex;
114
+      justify-content: center;
115
+      align-items: center;
116
+    }
117
+  }
118
+
119
+  .save {
120
+    position: fixed;
121
+    left: 0;
122
+    top: 0;
123
+    width: 100%;
124
+    height: 100%;
125
+    background: rgba(0, 0, 0, 0.4);
126
+    z-index: 99;
127
+
128
+    .tips{
129
+      margin-bottom: 16px!important;
130
+    }
131
+
132
+    .modalBody {
133
+      width: 350px;
134
+      background: #fff;
135
+      border-radius: 5px;
136
+      padding: 10px 20px;
137
+      color: #333;
138
+
139
+      .title {
140
+        width: 100%;
141
+        text-align: center;
142
+        font-size: 18px;
143
+        position: relative;
144
+
145
+        i {
146
+          position: absolute;
147
+          right: 0;
148
+          top: 0;
149
+          font-size: 20px;
150
+          color: #666;
151
+          cursor: pointer;
152
+          padding: 0 5px;
153
+        }
154
+      }
155
+
156
+      .content {
157
+        width: 310px;
158
+        background: #f9fafb;
159
+        border: 1px solid #e5e9ed;
160
+        border-radius: 5px;
161
+        overflow: hidden;
162
+        margin-top: 12px;
163
+        padding: 16px 0;
164
+
165
+        .busyList{
166
+          display: flex;
167
+          margin-bottom: 8px;
168
+          .busyContent{
169
+            margin-right: 8px;
170
+            flex: 1;
171
+          }
172
+        }
173
+
174
+        & > div {
175
+          text-align: center;
176
+          margin: 0;
177
+
178
+          &.icon {
179
+            // margin-top: 17px;
180
+
181
+            i {
182
+              color: #34b349;
183
+              font-size: 30px !important;
184
+
185
+              &.transport-wenhao {
186
+                color: #f5a523;
187
+              }
188
+
189
+              &.transport-shibai {
190
+                color: #ff3a52;
191
+              }
192
+            }
193
+          }
194
+
195
+          &.defeat {
196
+            color: #333;
197
+            font-size: 14px;
198
+          }
199
+
200
+          &:nth-child(3) {
201
+            font-size: 14px;
202
+            color: #666;
203
+          }
204
+        }
205
+        .workAssignmentTips {
206
+          font-size: 12px;
207
+        }
208
+      }
209
+
210
+      button {
211
+        margin-top: 10px;
212
+
213
+        &.btn {
214
+          margin-left: 8px;
215
+        }
216
+      }
217
+    }
218
+
219
+    // 新增
220
+    &.add {
221
+      .modalBody {
222
+        width: 480px;
223
+        height: auto;
224
+
225
+        .content {
226
+          width: 100%;
227
+          height: auto;
228
+          padding: 16px;
229
+          max-height: 497px;
230
+          overflow-y: auto;
231
+
232
+          .addForm {
233
+            .ant-form-item {
234
+              margin-bottom: 0;
235
+
236
+              .ant-form-item-label {
237
+                text-align: left;
238
+              }
239
+
240
+              .desc {
241
+                margin-top: 5px;
242
+              }
243
+            }
244
+
245
+            .datesControl {
246
+              margin-top: -16px;
247
+
248
+              .ant-form-item-label {
249
+                line-height: 40px;
250
+              }
251
+            }
252
+
253
+            .timer {
254
+              .ant-form-item-label {
255
+                width: 100%;
256
+                text-align: left;
257
+              }
258
+
259
+              .numInp {
260
+                margin-right: 5px;
261
+              }
262
+
263
+              .line {
264
+                margin-right: 5px;
265
+              }
266
+            }
267
+
268
+            .timer2 {
269
+              .ant-form-item-label {
270
+                line-height: 20px;
271
+              }
272
+            }
273
+          }
274
+
275
+          .editForm {
276
+            .ant-form-item {
277
+              margin-bottom: 15px;
278
+
279
+              .ant-form-item-label {
280
+                line-height: 14px;
281
+                text-align: left;
282
+              }
283
+            }
284
+          }
285
+        }
286
+      }
287
+    }
288
+  }
289
+}

+ 346 - 0
src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component.ts

@@ -0,0 +1,346 @@
1
+import { Component, OnInit } from "@angular/core";
2
+import { ActivatedRoute } from "@angular/router";
3
+import { Subject } from 'rxjs';
4
+import { debounceTime } from 'rxjs/operators';
5
+import { MainService } from "../../../services/main.service";
6
+import { Validators, FormGroup, FormBuilder } from '@angular/forms';
7
+import { ToolService } from 'src/app/services/tool.service';
8
+import { NzMessageService } from 'ng-zorro-antd';
9
+
10
+@Component({
11
+  selector: "app-configuration-wechat",
12
+  templateUrl: "./configuration-wechat.component.html",
13
+  styleUrls: ["./configuration-wechat.component.less"],
14
+})
15
+export class ConfigurationWechatComponent implements OnInit {
16
+  constructor(
17
+    private route: ActivatedRoute,
18
+    private mainService: MainService,
19
+    private fb: FormBuilder,
20
+    private tool: ToolService,
21
+    private message: NzMessageService,
22
+  ) {}
23
+
24
+  coopData: any = {}; //当前操作列
25
+  currentHospital; //当前院区
26
+
27
+  formatterMinute = (value: number) => `${value} 分钟`;
28
+  parserMinute = (value: string) => value.replace(' 分钟', '');
29
+
30
+  ngOnInit() {
31
+    this.currentHospital = this.tool.getCurrentHospital();
32
+    setTimeout(() => {
33
+      this.tableWechatHeight = document.querySelector('#wechatTable').clientHeight - document.querySelector('#wechatTable .list-template__top').clientHeight - 8 - document.querySelector('#wechatTable .thead').clientHeight;
34
+    }, 0)
35
+    this.getWechatList();
36
+    this.getTypes();
37
+    this.getRoles();
38
+  }
39
+
40
+  // 新增弹框
41
+  modelName = ""; //模态框名称
42
+  modalWechat: boolean = false; //新增/编辑模态框
43
+  add: boolean; //true:新增;false:编辑
44
+  addWechatModal() {
45
+    this.modelName = "新增";
46
+    this.add = true; //新增
47
+    this.modalWechat = true;
48
+    this.initWechatForm();
49
+    this.requiredConfigChange('createUser', false);
50
+    this.requiredConfigChange('defaultRole', false);
51
+  }
52
+  //关闭新增/编辑弹框
53
+  hideWechatModal() {
54
+    this.modalWechat = false;
55
+  }
56
+
57
+  // 编辑
58
+  editWechat(data) {
59
+    console.log(data);
60
+    this.modelName = "编辑";
61
+    this.add = false;
62
+    this.modalWechat = true;
63
+    this.initWechatForm();
64
+    if(data.bindAccount){
65
+      this.requiredConfigChange('createUser', false);
66
+    }else{
67
+      this.requiredConfigChange('createUser', true);
68
+    }
69
+
70
+    if(data.createUser){
71
+      this.requiredConfigChange('defaultRole', true);
72
+    }else{
73
+      this.requiredConfigChange('defaultRole', false);
74
+    }
75
+    this.coopData = data;
76
+    this.validateWechatForm.controls.name.setValue(data.name);
77
+    this.validateWechatForm.controls.appId.setValue(data.appId);
78
+    this.validateWechatForm.controls.appSecret.setValue(data.appSecret);
79
+    this.validateWechatForm.controls.agentId.setValue(data.agentId);
80
+    this.validateWechatForm.controls.url.setValue(data.url);
81
+    this.validateWechatForm.controls.domain.setValue(data.domain);
82
+    this.validateWechatForm.controls.active.setValue(data.active);
83
+    this.validateWechatForm.controls.qy.setValue(data.qy);
84
+    this.validateWechatForm.controls.type.setValue(data.type ? data.type.id : null);
85
+    this.validateWechatForm.controls.bindAccount.setValue(data.bindAccount);
86
+    this.validateWechatForm.controls.createUser.setValue(data.createUser);
87
+    this.validateWechatForm.controls.defaultRole.setValue(data.defaultRole);
88
+  }
89
+
90
+  // 新增/编辑表单提交
91
+  btnLoading: boolean = false; //提交按钮loading状态
92
+  submitWechatForm(): void {
93
+    for (const i in this.validateWechatForm.controls) {
94
+      this.validateWechatForm.controls[i].markAsDirty();
95
+      this.validateWechatForm.controls[i].updateValueAndValidity();
96
+    }
97
+    if (this.validateWechatForm.invalid) {
98
+      return;
99
+    }
100
+    console.log(this.validateWechatForm.value);
101
+    this.btnLoading = true;
102
+    let postData:any = {};
103
+
104
+    if (this.add) {
105
+      //增加
106
+      postData = {
107
+        // wechatConfig: {
108
+          hospital: this.currentHospital.id,
109
+          name: this.validateWechatForm.value.name,
110
+          appId: this.validateWechatForm.value.appId,
111
+          appSecret: this.validateWechatForm.value.appSecret,
112
+          agentId: this.validateWechatForm.value.agentId,
113
+          url: this.validateWechatForm.value.url,
114
+          domain: this.validateWechatForm.value.domain,
115
+          active: this.validateWechatForm.value.active,
116
+          qy: this.validateWechatForm.value.qy,
117
+          type: { id: this.validateWechatForm.value.type },
118
+          bindAccount: this.validateWechatForm.value.bindAccount,
119
+          createUser: this.validateWechatForm.value.createUser,
120
+          defaultRole: this.validateWechatForm.value.defaultRole,
121
+        // }
122
+      };
123
+    } else {
124
+      //编辑
125
+      postData = {
126
+        // wechatConfig: {
127
+          ...this.coopData,
128
+          ...{
129
+            hospital: this.currentHospital.id,
130
+            name: this.validateWechatForm.value.name,
131
+            appId: this.validateWechatForm.value.appId,
132
+            appSecret: this.validateWechatForm.value.appSecret,
133
+            agentId: this.validateWechatForm.value.agentId,
134
+            url: this.validateWechatForm.value.url,
135
+            domain: this.validateWechatForm.value.domain,
136
+            active: this.validateWechatForm.value.active,
137
+            qy: this.validateWechatForm.value.qy,
138
+            type: { id: this.validateWechatForm.value.type },
139
+            bindAccount: this.validateWechatForm.value.bindAccount,
140
+            createUser: this.validateWechatForm.value.createUser,
141
+            defaultRole: this.validateWechatForm.value.defaultRole,
142
+          }
143
+        // }
144
+      };
145
+    }
146
+    this.mainService
147
+      .simplePost("addData", "wechatConfig", postData)
148
+      .subscribe((result) => {
149
+        this.btnLoading = false;
150
+        this.hideWechatModal();
151
+        let msg = "";
152
+        if (this.add) {
153
+          msg = "新增";
154
+        } else {
155
+          msg = "修改";
156
+        }
157
+        if (result.status == 200) {
158
+          this.showPromptModal(msg, true, '');
159
+        } else {
160
+          this.showPromptModal(msg, false, result.msg);
161
+        }
162
+      });
163
+  }
164
+
165
+  // 初始化新增form表单
166
+  validateWechatForm: FormGroup; //新增/编辑表单
167
+  initWechatForm() {
168
+    this.validateWechatForm = this.fb.group({
169
+      name: [null, [Validators.required]],
170
+      appId: [null, [Validators.required]],
171
+      appSecret: [null, [Validators.required]],
172
+      agentId: [null, [Validators.required]],
173
+      url: [null, [Validators.required]],
174
+      domain: [null, [Validators.required]],
175
+      active: [false, [Validators.required]],
176
+      qy: [false, [Validators.required]],
177
+      type: [null, [Validators.required]],
178
+      bindAccount: [true, [Validators.required]],
179
+      createUser: [false,],
180
+      defaultRole: [null,],
181
+    });
182
+    console.log(this.validateWechatForm.controls)
183
+  }
184
+
185
+  requiredConfigChange(name: string, required: boolean): void {
186
+    if (!required) {
187
+      this.validateWechatForm.get(name)!.clearValidators();
188
+      this.validateWechatForm.get(name)!.markAsPristine();
189
+    } else {
190
+      this.validateWechatForm.get(name)!.setValidators(Validators.required);
191
+      this.validateWechatForm.get(name)!.markAsDirty();
192
+    }
193
+    this.validateWechatForm.get(name)!.updateValueAndValidity();
194
+  }
195
+
196
+  changeBindAccount(e){
197
+    if(e){
198
+      this.requiredConfigChange('createUser', false);
199
+      this.requiredConfigChange('defaultRole', false);
200
+    }else{
201
+      this.requiredConfigChange('createUser', true);
202
+      this.requiredConfigChange('defaultRole', false);
203
+    }
204
+
205
+    this.validateWechatForm.controls.createUser.setValue(false);
206
+    this.validateWechatForm.controls.defaultRole.setValue(null);
207
+  }
208
+
209
+  changeCreateUser(e){
210
+    if(e){
211
+      this.requiredConfigChange('createUser', true);
212
+      this.requiredConfigChange('defaultRole', true);
213
+    }else{
214
+      this.requiredConfigChange('createUser', true);
215
+      this.requiredConfigChange('defaultRole', false);
216
+    }
217
+
218
+    this.validateWechatForm.controls.defaultRole.setValue(null);
219
+  }
220
+
221
+  // 获取列表
222
+  loading1:boolean = false;
223
+  wechatList: any[] = []; //表格数据
224
+  tableWechatHeight:number = 0;
225
+  getWechatList() {
226
+    let data = {
227
+      idx: 0,
228
+      sum: 9999,
229
+      wechatConfig: {},
230
+    };
231
+    this.loading1 = true;
232
+    this.mainService
233
+      .getFetchDataList("simple/data", "wechatConfig", data)
234
+      .subscribe((data) => {
235
+        this.loading1 = false;
236
+        if (data.status == 200) {
237
+          this.wechatList = data.list || [];
238
+        }else{
239
+          this.message.error(data.msg || "请求数据失败");
240
+        }
241
+      });
242
+  }
243
+
244
+  // 获取角色
245
+  defaultRoleList: any = [];
246
+  getRoles() {
247
+    let postData = {
248
+      role: {},
249
+      idx: 0,
250
+      sum: 9999,
251
+    };
252
+    this.mainService
253
+      .getFetchDataList("simple/data", "role", postData)
254
+      .subscribe((data) => {
255
+        this.isLoading = false;
256
+        this.defaultRoleList = data.list || [];
257
+      });
258
+  }
259
+
260
+  // 获取类型
261
+  isLoading:boolean = false;
262
+  typeList: any = [];
263
+  getTypes() {
264
+    let postData = {
265
+      dictionary: {
266
+        key: "wechat_config_type"
267
+      },
268
+      idx: 0,
269
+      sum: 9999,
270
+    };
271
+    this.mainService
272
+      .getFetchDataList("simple/data", "dictionary", postData)
273
+      .subscribe((data) => {
274
+        this.isLoading = false;
275
+        this.typeList = data.list || [];
276
+      });
277
+  }
278
+
279
+  delModal: boolean = false; //删除模态框
280
+  tipsMsg1: string; //提示框信息
281
+  tipsMsg2: string; //操作后信息
282
+  confirmDelType: string; //确认的类型(启用/停用,删除)
283
+  showDelModal(
284
+    data,
285
+    tipsMsg1: string,
286
+    tipsMsg2: string,
287
+    type: string,
288
+  ) {
289
+    this.confirmDelType = type;
290
+    this.delModal = true;
291
+    this.coopData = data;
292
+    this.tipsMsg1 = tipsMsg1;
293
+    this.tipsMsg2 = tipsMsg2;
294
+  }
295
+  // 隐藏删除框
296
+  hideDelModal() {
297
+    this.delModal = false;
298
+  }
299
+  // 确认删除
300
+  confirmDel() {
301
+    this.btnLoading = true;
302
+    if (this.confirmDelType === "del") {
303
+      //删除
304
+      this.mainService
305
+        .simplePost("rmvData", "wechatConfig", [this.coopData.id])
306
+        .subscribe((data) => {
307
+          this.btnLoading = false;
308
+          this.delModal = false;
309
+          if (data.status == 200) {
310
+            this.showPromptModal(this.tipsMsg2, true, "");
311
+          } else {
312
+            this.showPromptModal(this.tipsMsg2, false, data.msg);
313
+          }
314
+        });
315
+    }else if(this.confirmDelType === "delToken"){
316
+      //重置token
317
+      this.mainService
318
+        .refreshToken("refreshToken", { wechatConfigId: this.coopData.id })
319
+        .subscribe((data) => {
320
+          this.btnLoading = false;
321
+          this.delModal = false;
322
+          if (data.status == 200) {
323
+            this.showPromptModal(this.tipsMsg2, true, "");
324
+          } else {
325
+            this.showPromptModal(this.tipsMsg2, false, data.msg);
326
+          }
327
+        });
328
+    }
329
+  }
330
+
331
+  // 展示信息提示框(con:提示信息,success:操作是否成功,promptInfo:操作结果提示信息)
332
+  promptContent: string; //操作提示框提示信息
333
+  ifSuccess: boolean; //操作成功/失败
334
+  promptInfo: string; //操作结果提示信息
335
+  promptModalShow: boolean; //操作提示框是否展示
336
+  showPromptModal(con, success, promptInfo?) {
337
+    this.promptModalShow = false;
338
+    this.promptContent = con;
339
+    this.ifSuccess = success;
340
+    this.promptInfo = promptInfo;
341
+    setTimeout(() => {
342
+      this.promptModalShow = true;
343
+    }, 100);
344
+    this.getWechatList();
345
+  }
346
+}

+ 23 - 0
src/app/components/select-menu/select-menu.component.html

@@ -0,0 +1,23 @@
1
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="iShowMenuModal">
2
+  <div class="modalBody">
3
+    <div class="title">配置中心<i class="icon_transport transport-guanbi" (click)="hideModal()"></i>
4
+    </div>
5
+    <div class="content">
6
+      <div class="content_item" (click)="toIncidentConfig()">
7
+        <div class="name">
8
+          <i class="icon_transport transport-shijianpeizhi5"></i>事件配置
9
+        </div>
10
+        <div class="tips">故障现象、优先级、数据字典、系统配置、消息通知、科室绑定人员...</div>
11
+      </div>
12
+      <div class="content_item" (click)="toOtherConfig()">
13
+        <div class="name">
14
+          <i class="icon_transport transport-disanfang"></i>第三方配置
15
+        </div>
16
+        <div class="tips">微信配置、呼叫中心...</div>
17
+      </div>
18
+    </div>
19
+    <div class="display_flex justify-content_flex-center">
20
+      <button nzType="primary" nz-button (click)="hideModal()">知道了</button>
21
+    </div>
22
+  </div>
23
+</div>

+ 76 - 0
src/app/components/select-menu/select-menu.component.less

@@ -0,0 +1,76 @@
1
+@import "../../../../src/theme.less";
2
+.save {
3
+  position: fixed;
4
+  left: 0;
5
+  top: 0;
6
+  width: 100%;
7
+  height: 100%;
8
+  background: rgba(0, 0, 0, 0.4);
9
+  z-index: 99;
10
+
11
+  .modalBody {
12
+    width: 467px;
13
+    background: #fff;
14
+    border-radius: 5px;
15
+    padding: 10px 20px;
16
+    color: #333;
17
+
18
+    .title {
19
+      width: 100%;
20
+      text-align: center;
21
+      font-size: 18px;
22
+      position: relative;
23
+
24
+      i {
25
+        position: absolute;
26
+        right: 0;
27
+        top: 0;
28
+        font-size: 20px;
29
+        color: #666;
30
+        cursor: pointer;
31
+        padding: 0 5px;
32
+      }
33
+    }
34
+
35
+    .content {
36
+      width: 100%;
37
+      margin-top: 12px;
38
+      display: flex;
39
+      flex-wrap: wrap;
40
+      gap: 16px;
41
+      .content_item{
42
+        flex: 1;
43
+        height: 97px;
44
+        background-color: #F9FAFB;
45
+        border: 1px solid #EEEEEE;
46
+        padding: 16px 8px 8px;
47
+        cursor: pointer;
48
+        .name{
49
+          font-size: 16px;
50
+          color: rgba(0,0,0,0.85);
51
+          display: flex;
52
+          align-items: center;
53
+          .icon_transport{
54
+            color: @primary-color;
55
+            font-size: 22px;
56
+            margin-right: 8px;
57
+          }
58
+        }
59
+        .tips{
60
+          font-size: 10px;
61
+          color: rgba(0,0,0,0.45);
62
+          margin-top: 8px;
63
+          text-align: justify;
64
+        }
65
+      }
66
+    }
67
+
68
+    button {
69
+      margin-top: 10px;
70
+
71
+      &.btn {
72
+        margin-left: 8px;
73
+      }
74
+    }
75
+  }
76
+}

+ 31 - 0
src/app/components/select-menu/select-menu.component.ts

@@ -0,0 +1,31 @@
1
+import { Component, OnInit, Output, Input } from '@angular/core';
2
+import { EventEmitter } from '@angular/core';
3
+import { Router } from "@angular/router";
4
+import { ToolService } from '../../services/tool.service';
5
+
6
+@Component({
7
+  selector: 'app-select-menu',
8
+  templateUrl: './select-menu.component.html',
9
+  styleUrls: ['./select-menu.component.less']
10
+})
11
+export class SelectMenuComponent implements OnInit {
12
+  @Output() cancelMenuModal = new EventEmitter();
13
+  @Input() iShowMenuModal: boolean = false;//模态框
14
+  allHospital: any;//所有院区
15
+  hosLoading: boolean = false;//确定按钮的loading
16
+  constructor(
17
+    private router: Router,
18
+  ) { }
19
+
20
+  ngOnInit() {}
21
+  toIncidentConfig(){
22
+    this.router.navigateByUrl("configurationCenter/incidentConfig");
23
+  }
24
+  toOtherConfig(){
25
+    this.router.navigateByUrl("configurationCenter/otherConfig");
26
+  }
27
+  // 隐藏模态框
28
+  hideModal() {
29
+    this.cancelMenuModal.emit(false)
30
+  }
31
+}

+ 6 - 0
src/app/services/main.service.ts

@@ -852,4 +852,10 @@ export class MainService {
852 852
 	  });
853 853
 	}
854 854
 	
855
+	// wechat相关-重置token
856
+	refreshToken(type, data): any {
857
+	  return this.http.post(host.host + "/wechat/" + type, data, {
858
+	    headers: this.headers,
859
+	  });
860
+	}
855 861
 }

+ 0 - 63
src/app/share/allocation-worker copy/allocation-worker.component.html

@@ -1,63 +0,0 @@
1
-<div class="detail">
2
-  <div class="title">分配配送人员<i class="icon_transport transport-guanbi" (click)="close()"></i></div>
3
-  <div class="content">
4
-    <div nz-row class="select">
5
-      <div nz-col nzSpan="6">
6
-        <div class="label">人员姓名:</div>
7
-        <input [disabled]="nameMask" nz-input placeholder="请输入人员姓名" [(ngModel)]="searchName" nzSize="default"
8
-          (ngModelChange)="searchInp('worker')" />
9
-      </div>
10
-      <div nz-col nzSpan="6" class="ml8">
11
-        <div class="label">人员分组:</div>
12
-        <nz-select nzAllowClear [nzDisabled]="groupMask" style="width: 220px;" [nzDropdownMatchSelectWidth]="false"
13
-          [(ngModel)]="checkedGroup" (ngModelChange)="searchInp('group')" nzPlaceHolder="请选择人员分组">
14
-          <nz-option *ngFor="let optionData of groupList" [nzLabel]="optionData.groupName" [nzValue]="optionData.id">
15
-          </nz-option>
16
-        </nz-select>
17
-      </div>
18
-    </div>
19
-    <div class="table">
20
-      <div class="box">
21
-        <nz-table class="allotWorkerTable" [nzShowPagination]="false" #rowSelectionTable [nzData]="workerList"
22
-          nzSize="small" [nzScroll]="{ y: '270px' }" [nzLoading]="loading1">
23
-          <thead>
24
-            <tr class="thead">
25
-              <th nzWidth="30px" style="text-align: center"></th>
26
-              <th style="text-align: center">姓名</th>
27
-              <th nzWidth="202px" style="text-align: center" *ngIf="workerDispatchUserList === 'dynamic'">分组名称</th>
28
-              <th nzWidth="202px" style="text-align: center" *ngIf="workerDispatchUserList === 'dynamic'">工单数</th>
29
-              <th nzWidth="202px" style="text-align: center" *ngIf="workerDispatchUserList === 'dynamic'">空闲时间</th>
30
-            </tr>
31
-          </thead>
32
-          <tbody>
33
-            <tr *ngFor="let data of rowSelectionTable.data" (click)="checkAllotWorker(data.id,true)">
34
-              <td nzShowCheckbox [(nzChecked)]="mapOfCheckedId[data.id]" (nzCheckedChange)="checkAllotWorker(data.id)">
35
-              </td>
36
-              <td nzAlign="center">{{ data.name }}</td>
37
-              <td nzAlign="center" *ngIf="workerDispatchUserList === 'dynamic'">{{ data.groupDTO?.groupName }}</td>
38
-              <td nzAlign="center" *ngIf="workerDispatchUserList === 'dynamic'">{{ data.totalCount }}</td>
39
-              <td nzAlign="center" *ngIf="workerDispatchUserList === 'dynamic'" [ngClass]="{red: data.workStateRemark ? true : !data.freetime, green: !data.workStateRemark && data.freetime}">{{ data.workStateRemark ? '示忙-' + data.workStateRemark : (data.freetime || '忙碌中') }}</td>
40
-            </tr>
41
-          </tbody>
42
-        </nz-table>
43
-        <div class="pagination">
44
-          <nz-pagination [(nzPageIndex)]="pageIndex" [(nzTotal)]="listLength" nzShowSizeChanger
45
-            [(nzPageSize)]="pageSize" (nzPageIndexChange)="getWorkerList()" (nzPageSizeChange)="getWorkerList()">
46
-          </nz-pagination>
47
-        </div>
48
-      </div>
49
-    </div>
50
-  </div>
51
-  <div class="btns display_flex justify-content_flex-center">
52
-    <button nz-button nzType="primary" [nzLoading]="btnLoading" (click)="submit()"
53
-      *ngIf="mapOfCheckedId[worderId]">确认</button>
54
-    <button class=" btn cancel" nz-button nzType="default" (click)="close()">取消</button>
55
-  </div>
56
-</div>
57
-
58
-
59
-<!-- 操作成功/失败提示框 -->
60
-<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
61
-  [info]="promptInfo" (closeModel)="close()">
62
-  <!-- 2.父组件调用子组件时绑定到这个事件属性,并在事件发生时作出回应。(closeModel)="close()" -->
63
-</app-prompt-modal>

+ 0 - 110
src/app/share/allocation-worker copy/allocation-worker.component.less

@@ -1,110 +0,0 @@
1
-@import "../../../../src/theme.less";
2
-:host {
3
-  width: 100%;
4
-  height: 100%;
5
-  position: fixed;
6
-  left: 0;
7
-  top: 0;
8
-  background: rgba(0, 0, 0, 0.4);
9
-  z-index: 999;
10
-
11
-  display: flex;
12
-  justify-content: center;
13
-  align-items: center;
14
-}
15
-
16
-.detail {
17
-  width: 1000px;
18
-  min-height: 580px;
19
-  border-radius: 5px;
20
-  background: #fff;
21
-  color: #333;
22
-  font-size: 14px;
23
-  padding: 12px 20px;
24
-  padding-bottom: 70px;
25
-  position: relative;
26
-
27
-  .title {
28
-    font-size: 18px;
29
-    text-align: center;
30
-    line-height: 24px;
31
-    margin: 0;
32
-    margin-bottom: 12px;
33
-    position: relative;
34
-
35
-    i {
36
-      position: absolute;
37
-      right: 0;
38
-      top: 0;
39
-      font-size: 20px;
40
-      color: #666;
41
-      cursor: pointer;
42
-      padding: 0 5px;
43
-    }
44
-  }
45
-
46
-  .content {
47
-    width: 960px;
48
-    overflow: hidden;
49
-
50
-    .select {
51
-      width: 100%;
52
-      background: #f9fafb;
53
-      border: 1px solid #e5e9ed;
54
-      border-radius: 5px;
55
-      padding: 13px 20px;
56
-
57
-      .label {
58
-        margin-bottom: 8px;
59
-      }
60
-    }
61
-
62
-    .table {
63
-      width: 100%;
64
-      margin-top: 15px;
65
-
66
-      .thead {
67
-        background-image: repeating-linear-gradient(
68
-          to right,
69
-          @bg-start,
70
-          @bg-end 100%
71
-        ) !important;
72
-
73
-        th {
74
-          color: #fff !important;
75
-          text-align: center;
76
-          font-size: 12px;
77
-          border: none;
78
-        }
79
-      }
80
-
81
-      .box {
82
-        min-height: 380px;
83
-        border-radius: 5px;
84
-        background: #f9fafb;
85
-        border: 1px solid #e5e9ed;
86
-        padding-bottom: 60px;
87
-        position: relative;
88
-
89
-        .pagination {
90
-          margin-top: 14px;
91
-          position: absolute;
92
-          bottom: 12px;
93
-          right: 5px;
94
-        }
95
-      }
96
-    }
97
-  }
98
-
99
-  .btns {
100
-    width: 100%;
101
-    position: absolute;
102
-    left: 0;
103
-    bottom: 20px;
104
-
105
-    button {
106
-      margin: 9px;
107
-      margin-bottom: 0;
108
-    }
109
-  }
110
-}

+ 0 - 168
src/app/share/allocation-worker copy/allocation-worker.component.ts

@@ -1,168 +0,0 @@
1
-import { Component, OnInit } from "@angular/core";
2
-import { ActivatedRoute } from "@angular/router";
3
-import { MainService } from "../../services/main.service";
4
-
5
-@Component({
6
-  selector: "app-allocation-worker",
7
-  templateUrl: "./allocation-worker.component.html",
8
-  styleUrls: ["./allocation-worker.component.less"],
9
-})
10
-export class AllocationWorkerComponent implements OnInit {
11
-  constructor(
12
-    private route: ActivatedRoute,
13
-    private mainService: MainService
14
-  ) {}
15
-
16
-  ngOnInit() {
17
-    this.groupList = JSON.parse(localStorage.getItem("user")).user.scope ? JSON.parse(localStorage.getItem("user")).user.scope.groupIds : [];
18
-    this.getWorkerList();
19
-  }
20
-  // 配送人员数据
21
-  workerList = [];
22
-
23
-  id; //工单id
24
-  stateId; //工单状态id
25
-  listOfDisplayData: any[] = [];
26
-  mapOfCheckedId: { [key: string]: boolean } = {};
27
-  searchName: string = ""; //搜索框内容
28
-  checkedGroup; //选中人员分组
29
-  pageIndex: number = 1; //表格当前页码
30
-  pageSize: number = 10; //表格每页展示条数
31
-  listLength: number = 10; //表格总数据量
32
-
33
-  promptContent: string; //操作提示框提示信息
34
-  ifSuccess: boolean; //操作成功/失败
35
-  promptInfo: string; //操作结果提示信息
36
-  promptModalShow: boolean; //是否展示提示框
37
-
38
-  btnLoading: boolean = false; //提交按钮loading状态
39
-
40
-  // 配送人员数据
41
-  groupList: Array<{ groupName: string; id: string }> = []; //分组下拉框
42
-  snum = 0;
43
-  loading1 = false;
44
-  nameMask = false; //是否禁用
45
-  groupMask = false; //是否禁用
46
-  workerDispatchUserList = '';
47
-  getWorkerList(pageIndex?) {
48
-    this.id = this.route.snapshot.paramMap.get("id");
49
-    this.stateId = this.route.snapshot.paramMap.get("stateId");
50
-    this.pageIndex = pageIndex ? pageIndex : this.pageIndex;
51
-
52
-    let groupsId = [];
53
-    JSON.parse(localStorage.getItem("user")).infoPermission.groups.forEach(
54
-      (e) => {
55
-        groupsId.push(e.id);
56
-      }
57
-    );
58
-
59
-    let postData: any = {
60
-      idx: this.pageIndex - 1,
61
-      sum: this.pageSize,
62
-      groupIds: "",
63
-      hosId: this.route.snapshot.paramMap.get("hosId"),
64
-    };
65
-    if (this.searchName) {
66
-      postData.name = this.searchName;
67
-    } else {
68
-      delete postData.name;
69
-    }
70
-    if (this.checkedGroup) {
71
-      postData.groupId = this.checkedGroup;
72
-    } else {
73
-      delete postData.groupId;
74
-    }
75
-    this.snum++;
76
-    this.loading1 = true;
77
-    this.mainService
78
-      .getSerInfo("getOnlineWorker", postData)
79
-      .subscribe((data) => {
80
-        this.snum--;
81
-        if (this.snum == 0) {
82
-          this.loading1 = false;
83
-        }
84
-        console.log(data);
85
-        this.workerDispatchUserList = data.type;
86
-        this.workerList = data.data;
87
-        this.listLength = data.totalNum;
88
-      });
89
-  }
90
-
91
-  // 输入用户信息搜索节流阀
92
-  time: any;
93
-  searchInp(type) {
94
-    this.getWorkerList(1);
95
-    console.log(type);
96
-    if (type == "worker") {
97
-      this.groupMask = Boolean(this.searchName);
98
-    } else if (type == "group") {
99
-      this.nameMask = Boolean(this.checkedGroup);
100
-    }
101
-  }
102
-
103
-  // 选择分配配送人员
104
-  worderId = 0; //配送人员id
105
-  checkAllotWorker(id, flag?): void {
106
-    this.mapOfCheckedId = {
107
-      [id]: flag ? !this.mapOfCheckedId[id] : this.mapOfCheckedId[id],
108
-    };
109
-    this.worderId = id;
110
-  }
111
-
112
-  // 分配
113
-  submit() {
114
-    let that = this;
115
-    that.btnLoading = true;
116
-    let flag: any = that.route.snapshot.paramMap.get("flag");
117
-
118
-    let postData: any = {};
119
-    let flags = "";
120
-    if (that.id.includes("_")) {
121
-      flags = "batchExcuteWorkOrder";
122
-      let ids_types = that.id.split("-");
123
-      let stateIds = that.stateId.split("-");
124
-      postData.workOrders = [];
125
-      stateIds.forEach((item, i) => {
126
-        postData.workOrders.push({
127
-          id: ids_types[i].split("_")[0],
128
-          type: ids_types[i].split("_")[1],
129
-          worker: { id: that.worderId },
130
-          gdState: { id: item },
131
-        });
132
-      });
133
-    } else {
134
-      flags = flag == 1 ? "excuteWorkOrder/reassign" : "excuteWorkOrder/assign";
135
-      postData = {
136
-        workOrder: {
137
-          id: that.id,
138
-          worker: { id: that.worderId },
139
-          gdState: { id: that.stateId },
140
-        },
141
-      };
142
-    }
143
-    that.mainService.assignWorker(postData, flags).subscribe((data) => {
144
-      that.btnLoading = false;
145
-      if (data.status == 200) {
146
-        that.showPromptModal("分配", true, "");
147
-      } else {
148
-        that.showPromptModal("分配", false, data.msg);
149
-      }
150
-    });
151
-  }
152
-
153
-  // 关闭弹框
154
-  close() {
155
-    history.go(-1);
156
-  }
157
-
158
-  // 展示信息提示框(con:提示信息,success:操作是否成功,promptInfo:操作结果提示信息)(con:提示信息,success:操作是否成功,promptInfo:操作结果提示信息)
159
-  showPromptModal(con, success, promptInfo?) {
160
-    this.promptModalShow = false;
161
-    this.promptContent = con;
162
-    this.ifSuccess = success;
163
-    this.promptInfo = promptInfo;
164
-    setTimeout(() => {
165
-      this.promptModalShow = true;
166
-    }, 100);
167
-  }
168
-}

+ 8 - 1
src/app/views/incident-config/incident-config.component.less

@@ -29,6 +29,7 @@
29 29
         }
30 30
         .tagList{
31 31
           width: 100%;
32
+          height: 100%;
32 33
           position: absolute;
33 34
           left: 0;
34 35
           top: 50%;
@@ -36,11 +37,17 @@
36 37
           display: flex;
37 38
           justify-content: center;
38 39
           align-items: center;
39
-          gap: 48px;
40 40
           span{
41
+            height: 100%;
42
+            display: inline-block;
43
+            padding: 0 24px;
41 44
             cursor: pointer;
45
+            display: flex;
46
+            justify-content: center;
47
+            align-items: center;
42 48
             &.active{
43 49
               color: @primary-color;
50
+              background: #F0F6ED;
44 51
             }
45 52
           }
46 53
         }

+ 2 - 0
src/app/views/main/main.component.html

@@ -151,5 +151,7 @@
151 151
     </div>
152 152
   </div>
153 153
 </div>
154
+<!-- 菜单选择 -->
155
+<app-select-menu (cancelMenuModal)="cancelMenuModal($event)" [iShowMenuModal]="iShowMenuModal"></app-select-menu>
154 156
 <!-- 遮罩 -->
155 157
 <app-mask *ngIf="maskFlag"></app-mask>

+ 9 - 1
src/app/views/main/main.component.ts

@@ -414,7 +414,8 @@ export class MainComponent implements OnInit {
414 414
   }
415 415
   // 配置中心
416 416
   toConfigurationCenter(): void {
417
-    this.router.navigateByUrl("configurationCenter");
417
+    this.iShowMenuModal = true;
418
+    // this.router.navigateByUrl("configurationCenter");
418 419
   }
419 420
   // 大屏端或视图端
420 421
   screenType;
@@ -467,6 +468,13 @@ export class MainComponent implements OnInit {
467 468
     }
468 469
   }
469 470
 
471
+
472
+  // 选择菜单-知道了
473
+  iShowMenuModal:boolean = false;
474
+  cancelMenuModal(flag) {
475
+    this.iShowMenuModal = false;
476
+  }
477
+
470 478
   // 退出
471 479
   logOut(): void {
472 480
     // 假退出

+ 2 - 0
src/app/views/main/main.module.ts

@@ -4,10 +4,12 @@ import { CommonModule } from '@angular/common';
4 4
 import { MainRoutingModule } from './main-routing.module';
5 5
 import { MainComponent } from './main.component';
6 6
 import { ShareModule } from 'src/app/share/share.module';
7
+import { SelectMenuComponent } from 'src/app/components/select-menu/select-menu.component';
7 8
 
8 9
 @NgModule({
9 10
   declarations: [
10 11
     MainComponent,
12
+    SelectMenuComponent,
11 13
   ],
12 14
   imports: [
13 15
     CommonModule,

+ 5 - 5
src/app/views/other-config/other-config.component.html

@@ -1,24 +1,24 @@
1 1
 <div class="incidentConfig">
2 2
   <div class="tagsAndTemplete">
3 3
     <div class="tags">
4
-      <div><i class="icon_transport transport-peizhizhongxin"></i>配置中心&emsp;&gt;&emsp;事件配置</div>
4
+      <div><i class="icon_transport transport-peizhizhongxin"></i>配置中心&emsp;&gt;&emsp;第三方配置</div>
5 5
       <div class="tagList">
6 6
         <span *ngFor="let tag of tagList" [ngClass]="{ active: activeTagId === tag.id }" (click)="clickTag(tag)">{{ tag.name }}</span>
7 7
       </div>
8 8
       <button nz-button class="btn default" (click)="goBack()">返回</button>
9 9
     </div>
10 10
   </div>
11
-  <!-- 故障现象 -->
11
+  <!-- 微信配置 -->
12 12
   <ng-container *ngIf="activeTagId === 1">
13
-    <app-configuration-category></app-configuration-category>
13
+    <app-configuration-wechat></app-configuration-wechat>
14 14
   </ng-container>
15 15
   <!-- 优先级 -->
16 16
   <ng-container *ngIf="activeTagId === 2">
17
-    <app-configuration-priority></app-configuration-priority>
17
+    <!-- <app-configuration-priority></app-configuration-priority> -->
18 18
   </ng-container>
19 19
   <!-- 数据字典 -->
20 20
   <ng-container *ngIf="activeTagId === 3">
21
-    <app-configuration-dictionary></app-configuration-dictionary>
21
+    <!-- <app-configuration-dictionary></app-configuration-dictionary> -->
22 22
   </ng-container>
23 23
 </div>
24 24
 

+ 8 - 1
src/app/views/other-config/other-config.component.less

@@ -29,6 +29,7 @@
29 29
         }
30 30
         .tagList{
31 31
           width: 100%;
32
+          height: 100%;
32 33
           position: absolute;
33 34
           left: 0;
34 35
           top: 50%;
@@ -36,11 +37,17 @@
36 37
           display: flex;
37 38
           justify-content: center;
38 39
           align-items: center;
39
-          gap: 48px;
40 40
           span{
41
+            height: 100%;
42
+            display: inline-block;
43
+            padding: 0 24px;
41 44
             cursor: pointer;
45
+            display: flex;
46
+            justify-content: center;
47
+            align-items: center;
42 48
             &.active{
43 49
               color: @primary-color;
50
+              background: #F0F6ED;
44 51
             }
45 52
           }
46 53
         }

+ 3 - 3
src/app/views/other-config/other-config.component.ts

@@ -13,9 +13,9 @@ export class OtherConfigComponent implements OnInit, AfterViewInit {
13 13
 
14 14
   // tab
15 15
   tagList:any = [
16
-    { id: 1, name: '故障现象',},
17
-    { id: 2, name: '优先级',},
18
-    { id: 3, name: '数据字典',},
16
+    { id: 1, name: '微信配置',},
17
+    // { id: 2, name: '优先级',},
18
+    // { id: 3, name: '数据字典',},
19 19
   ];
20 20
 
21 21
   ngOnInit(): void {}

+ 9 - 0
src/app/views/other-config/other-config.module.ts

@@ -10,6 +10,11 @@ import { ConfigurationDictionaryComponent } from 'src/app/components/configurati
10 10
 import { ConfigurationManHourComponent } from 'src/app/components/configurationCenter/configuration-manHour/configuration-manHour.component';
11 11
 import { ConfigurationDeptUserComponent } from 'src/app/components/configurationCenter/configuration-deptUser/configuration-deptUser.component';
12 12
 
13
+import { ConfigurationWechatComponent } from 'src/app/components/configurationCenter/configuration-wechat/configuration-wechat.component';
14
+// import { ConfigurationPriorityComponent } from 'src/app/components/configurationCenter/configuration-priority/configuration-priority.component';
15
+// import { ConfigurationDictionaryComponent } from 'src/app/components/configurationCenter/configuration-dictionary/configuration-dictionary.component';
16
+
17
+
13 18
 @NgModule({
14 19
   declarations: [
15 20
     OtherConfigComponent,
@@ -18,6 +23,10 @@ import { ConfigurationDeptUserComponent } from 'src/app/components/configuration
18 23
     ConfigurationDictionaryComponent,
19 24
 		ConfigurationManHourComponent,
20 25
 		ConfigurationDeptUserComponent,
26
+    ConfigurationWechatComponent,
27
+    // ConfigurationPriorityComponent,
28
+    // ConfigurationDictionaryComponent,
29
+
21 30
   ],
22 31
   imports: [
23 32
     CommonModule,

+ 95 - 26
src/assets/iconfont/demo_index.html

@@ -55,6 +55,30 @@
55 55
           <ul class="icon_lists dib-box">
56 56
           
57 57
             <li class="dib">
58
+              <span class="icon icon_transport">&#xe606;</span>
59
+                <div class="name">星号</div>
60
+                <div class="code-name">&amp;#xe606;</div>
61
+              </li>
62
+          
63
+            <li class="dib">
64
+              <span class="icon icon_transport">&#xe76e;</span>
65
+                <div class="name">第三方</div>
66
+                <div class="code-name">&amp;#xe76e;</div>
67
+              </li>
68
+          
69
+            <li class="dib">
70
+              <span class="icon icon_transport">&#xe645;</span>
71
+                <div class="name">事件配置</div>
72
+                <div class="code-name">&amp;#xe645;</div>
73
+              </li>
74
+          
75
+            <li class="dib">
76
+              <span class="icon icon_transport">&#xe635;</span>
77
+                <div class="name">失败 (1)</div>
78
+                <div class="code-name">&amp;#xe635;</div>
79
+              </li>
80
+          
81
+            <li class="dib">
58 82
               <span class="icon icon_transport">&#xe689;</span>
59 83
                 <div class="name">快速报修</div>
60 84
                 <div class="code-name">&amp;#xe689;</div>
@@ -493,12 +517,6 @@
493 517
               </li>
494 518
           
495 519
             <li class="dib">
496
-              <span class="icon icon_transport">&#xe606;</span>
497
-                <div class="name">星号</div>
498
-                <div class="code-name">&amp;#xe606;</div>
499
-              </li>
500
-          
501
-            <li class="dib">
502 520
               <span class="icon icon_transport">&#xe61b;</span>
503 521
                 <div class="name">空白页-暂无漏接诊单</div>
504 522
                 <div class="code-name">&amp;#xe61b;</div>
@@ -804,9 +822,9 @@
804 822
 <pre><code class="language-css"
805 823
 >@font-face {
806 824
   font-family: 'icon_transport';
807
-  src: url('iconfont.woff2?t=1722576999612') format('woff2'),
808
-       url('iconfont.woff?t=1722576999612') format('woff'),
809
-       url('iconfont.ttf?t=1722576999612') format('truetype');
825
+  src: url('iconfont.woff2?t=1722850118502') format('woff2'),
826
+       url('iconfont.woff?t=1722850118502') format('woff'),
827
+       url('iconfont.ttf?t=1722850118502') format('truetype');
810 828
 }
811 829
 </code></pre>
812 830
           <h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
@@ -833,6 +851,42 @@
833 851
         <ul class="icon_lists dib-box">
834 852
           
835 853
           <li class="dib">
854
+            <span class="icon icon_transport transport-required"></span>
855
+            <div class="name">
856
+              星号
857
+            </div>
858
+            <div class="code-name">.transport-required
859
+            </div>
860
+          </li>
861
+          
862
+          <li class="dib">
863
+            <span class="icon icon_transport transport-disanfang"></span>
864
+            <div class="name">
865
+              第三方
866
+            </div>
867
+            <div class="code-name">.transport-disanfang
868
+            </div>
869
+          </li>
870
+          
871
+          <li class="dib">
872
+            <span class="icon icon_transport transport-shijianpeizhi5"></span>
873
+            <div class="name">
874
+              事件配置
875
+            </div>
876
+            <div class="code-name">.transport-shijianpeizhi5
877
+            </div>
878
+          </li>
879
+          
880
+          <li class="dib">
881
+            <span class="icon icon_transport transport-shibai1"></span>
882
+            <div class="name">
883
+              失败 (1)
884
+            </div>
885
+            <div class="code-name">.transport-shibai1
886
+            </div>
887
+          </li>
888
+          
889
+          <li class="dib">
836 890
             <span class="icon icon_transport transport-kuaisubaoxiu"></span>
837 891
             <div class="name">
838 892
               快速报修
@@ -1490,15 +1544,6 @@
1490 1544
           </li>
1491 1545
           
1492 1546
           <li class="dib">
1493
-            <span class="icon icon_transport transport-required"></span>
1494
-            <div class="name">
1495
-              星号
1496
-            </div>
1497
-            <div class="code-name">.transport-required
1498
-            </div>
1499
-          </li>
1500
-          
1501
-          <li class="dib">
1502 1547
             <span class="icon icon_transport transport-yunzhuanzhentongjiicon-"></span>
1503 1548
             <div class="name">
1504 1549
               空白页-暂无漏接诊单
@@ -1959,6 +2004,38 @@
1959 2004
           
1960 2005
             <li class="dib">
1961 2006
                 <svg class="icon svg-icon" aria-hidden="true">
2007
+                  <use xlink:href="#transport-required"></use>
2008
+                </svg>
2009
+                <div class="name">星号</div>
2010
+                <div class="code-name">#transport-required</div>
2011
+            </li>
2012
+          
2013
+            <li class="dib">
2014
+                <svg class="icon svg-icon" aria-hidden="true">
2015
+                  <use xlink:href="#transport-disanfang"></use>
2016
+                </svg>
2017
+                <div class="name">第三方</div>
2018
+                <div class="code-name">#transport-disanfang</div>
2019
+            </li>
2020
+          
2021
+            <li class="dib">
2022
+                <svg class="icon svg-icon" aria-hidden="true">
2023
+                  <use xlink:href="#transport-shijianpeizhi5"></use>
2024
+                </svg>
2025
+                <div class="name">事件配置</div>
2026
+                <div class="code-name">#transport-shijianpeizhi5</div>
2027
+            </li>
2028
+          
2029
+            <li class="dib">
2030
+                <svg class="icon svg-icon" aria-hidden="true">
2031
+                  <use xlink:href="#transport-shibai1"></use>
2032
+                </svg>
2033
+                <div class="name">失败 (1)</div>
2034
+                <div class="code-name">#transport-shibai1</div>
2035
+            </li>
2036
+          
2037
+            <li class="dib">
2038
+                <svg class="icon svg-icon" aria-hidden="true">
1962 2039
                   <use xlink:href="#transport-kuaisubaoxiu"></use>
1963 2040
                 </svg>
1964 2041
                 <div class="name">快速报修</div>
@@ -2543,14 +2620,6 @@
2543 2620
           
2544 2621
             <li class="dib">
2545 2622
                 <svg class="icon svg-icon" aria-hidden="true">
2546
-                  <use xlink:href="#transport-required"></use>
2547
-                </svg>
2548
-                <div class="name">星号</div>
2549
-                <div class="code-name">#transport-required</div>
2550
-            </li>
2551
-          
2552
-            <li class="dib">
2553
-                <svg class="icon svg-icon" aria-hidden="true">
2554 2623
                   <use xlink:href="#transport-yunzhuanzhentongjiicon-"></use>
2555 2624
                 </svg>
2556 2625
                 <div class="name">空白页-暂无漏接诊单</div>

+ 19 - 7
src/assets/iconfont/iconfont.css

@@ -1,8 +1,8 @@
1 1
 @font-face {
2 2
   font-family: "icon_transport"; /* Project id 4543613 */
3
-  src: url('iconfont.woff2?t=1722576999612') format('woff2'),
4
-       url('iconfont.woff?t=1722576999612') format('woff'),
5
-       url('iconfont.ttf?t=1722576999612') format('truetype');
3
+  src: url('iconfont.woff2?t=1722850118502') format('woff2'),
4
+       url('iconfont.woff?t=1722850118502') format('woff'),
5
+       url('iconfont.ttf?t=1722850118502') format('truetype');
6 6
 }
7 7
 
8 8
 .icon_transport {
@@ -13,6 +13,22 @@
13 13
   -moz-osx-font-smoothing: grayscale;
14 14
 }
15 15
 
16
+.transport-required:before {
17
+  content: "\e606";
18
+}
19
+
20
+.transport-disanfang:before {
21
+  content: "\e76e";
22
+}
23
+
24
+.transport-shijianpeizhi5:before {
25
+  content: "\e645";
26
+}
27
+
28
+.transport-shibai1:before {
29
+  content: "\e635";
30
+}
31
+
16 32
 .transport-kuaisubaoxiu:before {
17 33
   content: "\e689";
18 34
 }
@@ -305,10 +321,6 @@
305 321
   content: "\e62f";
306 322
 }
307 323
 
308
-.transport-required:before {
309
-  content: "\e606";
310
-}
311
-
312 324
 .transport-yunzhuanzhentongjiicon-:before {
313 325
   content: "\e61b";
314 326
 }

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 1 - 1
src/assets/iconfont/iconfont.js


+ 28 - 7
src/assets/iconfont/iconfont.json

@@ -6,6 +6,34 @@
6 6
   "description": "",
7 7
   "glyphs": [
8 8
     {
9
+      "icon_id": "20719696",
10
+      "name": "星号",
11
+      "font_class": "required",
12
+      "unicode": "e606",
13
+      "unicode_decimal": 58886
14
+    },
15
+    {
16
+      "icon_id": "4561786",
17
+      "name": "第三方",
18
+      "font_class": "disanfang",
19
+      "unicode": "e76e",
20
+      "unicode_decimal": 59246
21
+    },
22
+    {
23
+      "icon_id": "36196168",
24
+      "name": "事件配置",
25
+      "font_class": "shijianpeizhi5",
26
+      "unicode": "e645",
27
+      "unicode_decimal": 58949
28
+    },
29
+    {
30
+      "icon_id": "5132740",
31
+      "name": "失败 (1)",
32
+      "font_class": "shibai1",
33
+      "unicode": "e635",
34
+      "unicode_decimal": 58933
35
+    },
36
+    {
9 37
       "icon_id": "18856229",
10 38
       "name": "快速报修",
11 39
       "font_class": "kuaisubaoxiu",
@@ -517,13 +545,6 @@
517 545
       "unicode_decimal": 58927
518 546
     },
519 547
     {
520
-      "icon_id": "2817690",
521
-      "name": "星号",
522
-      "font_class": "required",
523
-      "unicode": "e606",
524
-      "unicode_decimal": 58886
525
-    },
526
-    {
527 548
       "icon_id": "5260595",
528 549
       "name": "空白页-暂无漏接诊单",
529 550
       "font_class": "yunzhuanzhentongjiicon-",

BIN
src/assets/iconfont/iconfont.ttf


BIN
src/assets/iconfont/iconfont.woff


BIN
src/assets/iconfont/iconfont.woff2