浏览代码

新增其他部门的考核表

余思翰 1年前
父节点
当前提交
8efcef5756

+ 187
- 0
oa-ui/src/assets/datas/JSContent.js 查看文件

@@ -0,0 +1,187 @@
1
+export const JSContent = [
2
+  {
3
+    label: '参与生产',
4
+    value: 'f01',
5
+    children: [
6
+      {
7
+        label: '项目负责',
8
+        value: 'f0101',
9
+        unit: '项'
10
+      },
11
+      {
12
+        label: '外业负责',
13
+        value: 'f0102',
14
+        unit: '项'
15
+      },
16
+      {
17
+        label: '内业负责',
18
+        value: 'f0103',
19
+        unit: '项'
20
+      },
21
+      {
22
+        label: '参与外业',
23
+        value: 'f0104',
24
+        unit: '项'
25
+      },
26
+      {
27
+        label: '参与内业',
28
+        value: 'f0105',
29
+        unit: '项'
30
+      },
31
+      {
32
+        label: '资料整编',
33
+        value: 'f0106',
34
+        unit: '项'
35
+      }
36
+    ]
37
+  },
38
+  {
39
+    label: '技术设计',
40
+    value: 'f02',
41
+    children: [
42
+      {
43
+        label: '承担技术负责人',
44
+        value: 'f0201',
45
+        unit: '项'
46
+      },
47
+      {
48
+        label: '技术设计书编写',
49
+        value: 'f0202',
50
+        unit: '项'
51
+      },
52
+      {
53
+        label: '投标技术文件编写',
54
+        value: 'f0203',
55
+        unit: '项'
56
+      },
57
+      {
58
+        label: '技术设计书审核',
59
+        value: 'f0204',
60
+        unit: '项'
61
+      }
62
+    ]
63
+  },
64
+  {
65
+    label: '质量检查',
66
+    value: 'f03',
67
+    children: [
68
+      {
69
+        label: '承担项目质量负责人',
70
+        value: 'f0301',
71
+        unit: '项'
72
+      },
73
+      {
74
+        label: '控制测量资料检查',
75
+        value: 'f0302',
76
+        unit: '项'
77
+      },
78
+      {
79
+        label: '监测、施控网资料检查',
80
+        value: 'f0303',
81
+        unit: '项'
82
+      },
83
+      {
84
+        label: 'DOM检查',
85
+        value: 'f0304',
86
+        unit: '幅'
87
+      },
88
+      {
89
+        label: 'DEM检查',
90
+        value: 'f0305',
91
+        unit: '幅'
92
+      },
93
+      {
94
+        label: '地形图检查',
95
+        value: 'f0306',
96
+        unit: '幅'
97
+      },
98
+      {
99
+        label: '三维地形面检查',
100
+        value: 'f0307',
101
+        unit: '幅'
102
+      },
103
+      {
104
+        label: '项目空三检查',
105
+        value: 'f0308',
106
+        unit: '项'
107
+      },
108
+      {
109
+        label: '点云分类检查',
110
+        value: 'f0309',
111
+        unit: '幅'
112
+      },
113
+      {
114
+        label: '断面检查',
115
+        value: 'f0310',
116
+        unit: '项'
117
+      },
118
+      {
119
+        label: '外业检查、配合外业检查',
120
+        value: 'f0311',
121
+        unit: '人天'
122
+      },
123
+      {
124
+        label: '编写项目质量检查报告',
125
+        value: 'f0312',
126
+        unit: '项'
127
+      },
128
+      {
129
+        label: '质量问题处理',
130
+        value: 'f0313',
131
+        unit: '项'
132
+      }
133
+    ]
134
+  },
135
+  {
136
+    label: '资料管理',
137
+    value: 'f04',
138
+    children: [
139
+      {
140
+        label: '报奖资料整理',
141
+        value: 'f0401',
142
+        unit: '项'
143
+      },
144
+      {
145
+        label: '外部资料收集',
146
+        value: 'f0402',
147
+        unit: '项'
148
+      },
149
+      {
150
+        label: '项目资料内部归档',
151
+        value: 'f0403',
152
+        unit: '项'
153
+      },
154
+      {
155
+        label: '项目资料提交甲方',
156
+        value: 'f0404',
157
+        unit: '项'
158
+      },
159
+      {
160
+        label: '项目资料提交甲方归档',
161
+        value: 'f0405',
162
+        unit: '项'
163
+      }
164
+    ]
165
+  },
166
+  {
167
+    label: '体系维护',
168
+    value: 'f05',
169
+    children: [
170
+      {
171
+        label: '体系内审',
172
+        value: 'f0501',
173
+        unit: '项'
174
+      },
175
+      {
176
+        label: '协助外审',
177
+        value: 'f0502',
178
+        unit: '项'
179
+      },
180
+      {
181
+        label: '体系文件修编',
182
+        value: 'f0503',
183
+        unit: '项'
184
+      }
185
+    ]
186
+  }
187
+]

+ 126
- 0
oa-ui/src/assets/datas/JYContent.js 查看文件

@@ -0,0 +1,126 @@
1
+export const JYContent = [
2
+  {
3
+    label: '参与生产',
4
+    value: 'f01',
5
+    children: [
6
+      {
7
+        label: '项目负责',
8
+        value: 'f0101',
9
+        unit: '项'
10
+      },
11
+      {
12
+        label: '外业负责',
13
+        value: 'f0102',
14
+        unit: '项'
15
+      },
16
+      {
17
+        label: '内业负责',
18
+        value: 'f0103',
19
+        unit: '项'
20
+      },
21
+      {
22
+        label: '参与外业',
23
+        value: 'f0104',
24
+        unit: '项'
25
+      },
26
+      {
27
+        label: '参与内业',
28
+        value: 'f0105',
29
+        unit: '项'
30
+      },
31
+      {
32
+        label: '资料整编',
33
+        value: 'f0106',
34
+        unit: '项'
35
+      }
36
+    ]
37
+  },
38
+  {
39
+    label: '商务标书',
40
+    value: 'f02',
41
+    children: [
42
+      {
43
+        label: '编写',
44
+        value: 'f0201',
45
+        unit: '项'
46
+      },
47
+      {
48
+        label: '校核',
49
+        value: 'f0202',
50
+        unit: '项'
51
+      },
52
+      {
53
+        label: '审查',
54
+        value: 'f0203',
55
+        unit: '项'
56
+      }
57
+    ]
58
+  },
59
+  {
60
+    label: '报价标书',
61
+    value: 'f03',
62
+    children: [
63
+      {
64
+        label: '编写',
65
+        value: 'f0301',
66
+        unit: '项'
67
+      },
68
+      {
69
+        label: '校核',
70
+        value: 'f0302',
71
+        unit: '项'
72
+      },
73
+      {
74
+        label: '审查',
75
+        value: 'f0303',
76
+        unit: '项'
77
+      }
78
+    ]
79
+  },
80
+  {
81
+    label: '项目合同',
82
+    value: 'f04',
83
+    children: [
84
+      {
85
+        label: '项目前期沟通',
86
+        value: 'f0401',
87
+        unit: '项'
88
+      },
89
+      {
90
+        label: '合同谈判',
91
+        value: 'f0402',
92
+        unit: '项'
93
+      },
94
+      {
95
+        label: '合同拟定',
96
+        value: 'f0403',
97
+        unit: '项'
98
+      },
99
+      {
100
+        label: '合同校核',
101
+        value: 'f0404',
102
+        unit: '项'
103
+      },
104
+      {
105
+        label: '合同审查',
106
+        value: 'f0405',
107
+        unit: '项'
108
+      },
109
+      {
110
+        label: '合同台账维护',
111
+        value: 'f0406',
112
+        unit: '项'
113
+      },
114
+      {
115
+        label: '项目请款办理',
116
+        value: 'f0407',
117
+        unit: '项'
118
+      },
119
+      {
120
+        label: '内部结算审核',
121
+        value: 'f0408',
122
+        unit: '项'
123
+      }
124
+    ]
125
+  },
126
+]

+ 101
- 0
oa-ui/src/assets/datas/XMContent.js 查看文件

@@ -0,0 +1,101 @@
1
+/*
2
+ * @Author: ysh
3
+ * @Date: 2024-02-20 14:59:59
4
+ * @LastEditors: 
5
+ * @LastEditTime: 2024-02-20 15:04:24
6
+ */
7
+export const XMContent = [
8
+  {
9
+    label: '参与生产',
10
+    value: 'f01',
11
+    children: [
12
+      {
13
+        label: '项目负责',
14
+        value: 'f0101',
15
+        unit: '项'
16
+      },
17
+      {
18
+        label: '外业负责',
19
+        value: 'f0102',
20
+        unit: '项'
21
+      },
22
+      {
23
+        label: '内业负责',
24
+        value: 'f0103',
25
+        unit: '项'
26
+      },
27
+      {
28
+        label: '参与外业',
29
+        value: 'f0104',
30
+        unit: '项'
31
+      },
32
+      {
33
+        label: '参与内业',
34
+        value: 'f0105',
35
+        unit: '项'
36
+      },
37
+      {
38
+        label: '资料整编',
39
+        value: 'f0106',
40
+        unit: '项'
41
+      }
42
+    ]
43
+  },
44
+  {
45
+    label: '项目管理',
46
+    value: 'f02',
47
+    children: [
48
+      {
49
+        label: '项目备案',
50
+        value: 'f0201',
51
+        unit: '项'
52
+      },
53
+      {
54
+        label: '项目预算',
55
+        value: 'f0202',
56
+        unit: '项'
57
+      },
58
+      {
59
+        label: '任务分发',
60
+        value: 'f0203',
61
+        unit: '项'
62
+      },
63
+      {
64
+        label: '项目交底',
65
+        value: 'f0204',
66
+        unit: '项'
67
+      },
68
+      {
69
+        label: '项目内部结算',
70
+        value: 'f0205',
71
+        unit: '项'
72
+      },
73
+      {
74
+        label: '顾客回访',
75
+        value: 'f0206',
76
+        unit: '项'
77
+      }
78
+    ]
79
+  },
80
+  {
81
+    label: '委外管理',
82
+    value: 'f03',
83
+    children: [
84
+      {
85
+        label: '委外合同办理',
86
+        value: 'f0301',
87
+        unit: '项'
88
+      },
89
+      {
90
+        label: '委外支付办理',
91
+        value: 'f0302',
92
+        unit: '项'
93
+      },
94
+      {
95
+        label: '合格分包商管理',
96
+        value: 'f0303',
97
+        unit: '项'
98
+      }
99
+    ]
100
+  }
101
+]

+ 284
- 0
oa-ui/src/assets/datas/ZHContent.js 查看文件

@@ -0,0 +1,284 @@
1
+export const ZHContent = [
2
+  {
3
+    label: '劳动组织',
4
+    value: 'f01',
5
+    children: [
6
+      {
7
+        label: '组织会议',
8
+        value: 'f0101',
9
+        unit: '次'
10
+      },
11
+      {
12
+        label: '组织培训',
13
+        value: 'f0102',
14
+        unit: '次'
15
+      },
16
+      {
17
+        label: '组织考察',
18
+        value: 'f0103',
19
+        unit: '次'
20
+      },
21
+      {
22
+        label: '组织接待',
23
+        value: 'f0104',
24
+        unit: '次'
25
+      },
26
+      {
27
+        label: '组织宣传',
28
+        value: 'f0105',
29
+        unit: '次'
30
+      },
31
+      {
32
+        label: '公司发文管理',
33
+        value: 'f0106',
34
+        unit: '次'
35
+      },
36
+      {
37
+        label: '企业微信、公司官方群、公司网站维护',
38
+        value: 'f0107',
39
+        unit: '次'
40
+      },
41
+      {
42
+        label: '公司资质、员工信息更新、维护(含OA)',
43
+        value: 'f0108',
44
+        unit: '次'
45
+      }
46
+    ]
47
+  },
48
+  {
49
+    label: '安全管理',
50
+    value: 'f02',
51
+    children: [
52
+      {
53
+        label: '安全培训',
54
+        value: 'f0201',
55
+        unit: '次'
56
+      },
57
+      {
58
+        label: '安全交底',
59
+        value: 'f0202',
60
+        unit: '次'
61
+      },
62
+      {
63
+        label: '组织演练',
64
+        value: 'f0203',
65
+        unit: '次'
66
+      },
67
+      {
68
+        label: '外业现场安全检查',
69
+        value: 'f0204',
70
+        unit: '人天'
71
+      },
72
+      {
73
+        label: '办公场所安全检查',
74
+        value: 'f0205',
75
+        unit: '次'
76
+      },
77
+      {
78
+        label: '商业保险办理',
79
+        value: 'f0206',
80
+        unit: '次'
81
+      },
82
+      {
83
+        label: '工伤保险办理',
84
+        value: 'f0207',
85
+        unit: '次'
86
+      },
87
+      {
88
+        label: '组织体检',
89
+        value: 'f0208',
90
+        unit: '人次'
91
+      }
92
+    ]
93
+  },
94
+  {
95
+    label: '设备物资',
96
+    value: 'f03',
97
+    children: [
98
+      {
99
+        label: '设备、物资采购',
100
+        value: 'f0301',
101
+        unit: '次'
102
+      },
103
+      {
104
+        label: '物资、仪器设备领用、归还',
105
+        value: 'f0302',
106
+        unit: '项'
107
+      },
108
+      {
109
+        label: '设备维修',
110
+        value: 'f0303',
111
+        unit: '次'
112
+      },
113
+      {
114
+        label: '设备检定',
115
+        value: 'f0304',
116
+        unit: '台套'
117
+      },
118
+      {
119
+        label: '设备保险办理',
120
+        value: 'f0305',
121
+        unit: '次'
122
+      }
123
+    ]
124
+  },
125
+  {
126
+    label: '人力资源',
127
+    value: 'f04',
128
+    children: [
129
+      {
130
+        label: '招聘(校招、社招、内部竞聘)',
131
+        value: 'f0401',
132
+        unit: '次'
133
+      },
134
+      {
135
+        label: '薪酬、考勤休假办理',
136
+        value: 'f0402',
137
+        unit: '次'
138
+      },
139
+      {
140
+        label: '社保三险办理',
141
+        value: 'f0403',
142
+        unit: '次'
143
+      },
144
+      {
145
+        label: '入、离职、退休办理',
146
+        value: 'f0404',
147
+        unit: '次'
148
+      },
149
+      {
150
+        label: '劳动合同办理',
151
+        value: 'f0405',
152
+        unit: '次'
153
+      },
154
+      {
155
+        label: '绩效考评管理',
156
+        value: 'f0406',
157
+        unit: '次'
158
+      },
159
+      {
160
+        label: '职称管理',
161
+        value: 'f0407',
162
+        unit: '次'
163
+      }
164
+    ]
165
+  },
166
+  {
167
+    label: '车辆管理',
168
+    value: 'f05',
169
+    children: [
170
+      {
171
+        label: '车辆采购',
172
+        value: 'f0501',
173
+        unit: '次'
174
+      },
175
+      {
176
+        label: '车辆保险购置',
177
+        value: 'f0502',
178
+        unit: '次'
179
+      },
180
+      {
181
+        label: '车辆处置',
182
+        value: 'f0503',
183
+        unit: '次'
184
+      },
185
+      {
186
+        label: '生产项目用车(安排)',
187
+        value: 'f0504',
188
+        unit: '次'
189
+      },
190
+      {
191
+        label: '出差用车(安排)',
192
+        value: 'f0505',
193
+        unit: '次'
194
+      },
195
+      {
196
+        label: '市周边临时驾驶接送(安排)',
197
+        value: 'f0506',
198
+        unit: '次'
199
+      },
200
+      {
201
+        label: '驾驶车辆参与项目生产',
202
+        value: 'f0507',
203
+        unit: '人天'
204
+      },
205
+      {
206
+        label: '驾驶车辆参与出差',
207
+        value: 'f0508',
208
+        unit: '人天'
209
+      },
210
+      {
211
+        label: '年度驾驶里程',
212
+        value: 'f0509',
213
+        unit: 'km'
214
+      },
215
+      {
216
+        label: '车辆维修保养',
217
+        value: 'f0510',
218
+        unit: '次'
219
+      },
220
+      {
221
+        label: '车辆保险理赔',
222
+        value: 'f0511',
223
+        unit: '次'
224
+      }
225
+    ]
226
+  },
227
+  {
228
+    label: '办公区维护',
229
+    value: 'f06',
230
+    children: [
231
+      {
232
+        label: '办公区办公设施检修',
233
+        value: 'f0601',
234
+        unit: '次'
235
+      },
236
+      {
237
+        label: '办公区安全检查',
238
+        value: 'f0602',
239
+        unit: '次'
240
+      },
241
+      {
242
+        label: '办公区绿植、送水统计',
243
+        value: 'f0603',
244
+        unit: '次'
245
+      },
246
+      {
247
+        label: '办公区电子显示屏展示宣传',
248
+        value: 'f0604',
249
+        unit: '次'
250
+      },
251
+      {
252
+        label: '办公区电子信息维护(电话、网络、电脑)',
253
+        value: 'f0605',
254
+        unit: '次'
255
+      },
256
+      {
257
+        label: '会议室管理',
258
+        value: 'f0606',
259
+        unit: '次'
260
+      },
261
+      {
262
+        label: '工作餐订制、快递、报纸收发',
263
+        value: 'f0607',
264
+        unit: '次'
265
+      }
266
+    ]
267
+  },
268
+  {
269
+    label: '党群、董事会',
270
+    value: 'f07',
271
+    children: [
272
+      {
273
+        label: '党总支日常工作',
274
+        value: 'f0701',
275
+        unit: '次'
276
+      },
277
+      {
278
+        label: '董事会日常工作',
279
+        value: 'f0702',
280
+        unit: '次'
281
+      }
282
+    ]
283
+  }
284
+]

+ 248
- 0
oa-ui/src/views/flowable/form/cwForm.vue 查看文件

@@ -0,0 +1,248 @@
1
+<!--
2
+ * @Author: ysh
3
+ * @Date: 2024-01-19 16:29:01
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-02-20 17:17:50
6
+-->
7
+<template>
8
+  <div>
9
+    <el-form ref="scform" :model="form">
10
+      <el-form-item label="工作自述:">
11
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="请输入内容" v-model="form['selfAssess']">
12
+        </el-input>
13
+      </el-form-item>
14
+      <el-form-item label="选择考核项:">
15
+        <el-checkbox-group v-model="checkedBtn" @change="assessChangeFn">
16
+          <el-checkbox v-for="sc, index in AssessmentContent" :label="sc.label" :key="index">{{ sc.label
17
+          }}</el-checkbox>
18
+        </el-checkbox-group>
19
+      </el-form-item>
20
+      <div class="tips" v-if="tipsShow">请至少选择一项考核项</div>
21
+      <el-row type="flex" style="flex-wrap:wrap;">
22
+        <el-card v-for="item, index in checkedBtn" style="flex:1;margin:10px;min-width: 400px;max-width: 450px;"
23
+          :key="index">
24
+          <div slot="header" class="clearfix">
25
+            <strong>{{ item }}</strong>
26
+            <el-button style="float: right; padding: 3px 0" type="text" @click="closeItem(item)">关闭</el-button>
27
+          </div>
28
+          <el-scrollbar style="height: 500px;">
29
+            <div v-for="ass in AssessmentContent" v-if="ass.label == item">
30
+              <table border="1" cellspacing="0" align="center" cellpadding="5">
31
+                <tr style="background-color:#409EFF;color: #fff;">
32
+                  <td>等级、比例尺等</td>
33
+                  <td>工作量</td>
34
+                  <td>单位</td>
35
+                </tr>
36
+                <tr v-for="child in ass.children">
37
+                  <td v-if="!Array.isArray(child.label)">{{ child.label }}</td>
38
+                  <td v-else>
39
+                    <el-checkbox-group v-model="form.f07">
40
+                      <el-checkbox v-for="label, index in child.label" :label="label" :key="'k' + index"></el-checkbox>
41
+                    </el-checkbox-group>
42
+                  </td>
43
+                  <td v-if="Array.isArray(child.label)">
44
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
45
+                  </td>
46
+                  <td v-if="!Array.isArray(child.label)">
47
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
48
+                  </td>
49
+                  <td>{{ child.unit }}</td>
50
+                </tr>
51
+                <tr>
52
+                  <td>参与情况</td>
53
+                  <td colspan="2">
54
+                    <el-radio-group v-model="form['role' + ass.value.slice(-2)]">
55
+                      <el-radio label="00">主办</el-radio>
56
+                      <el-radio label="01">参与</el-radio>
57
+                      <el-radio label="02">协助</el-radio>
58
+                    </el-radio-group>
59
+                  </td>
60
+                </tr>
61
+                <tr>
62
+                  <td>备注</td>
63
+                  <td colspan="2">
64
+                    <el-input type="textarea" :rows="2" placeholder="请输入内容"
65
+                      v-model="form['remark' + ass.value.slice(-2)]">
66
+                    </el-input>
67
+                  </td>
68
+                </tr>
69
+              </table>
70
+              <div class="tips" v-if="inputTips">工作量只能输入数字</div>
71
+            </div>
72
+          </el-scrollbar>
73
+        </el-card>
74
+      </el-row>
75
+      <el-form-item label="其他工作:">
76
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="有其他工作请在此写入内容" v-model="form['otherWork']">
77
+        </el-input>
78
+      </el-form-item>
79
+      <el-row>
80
+        <el-button @click="generateForm" type="primary">生成考核表</el-button>
81
+      </el-row>
82
+    </el-form>
83
+    <el-dialog title="" :visible.sync="taskOpen" width="65%" append-to-body>
84
+      <ZhTable :tableForm="noNullForm" ref="zhTable" @submit="submit"></ZhTable>
85
+    </el-dialog>
86
+  </div>
87
+</template>
88
+
89
+<script>
90
+import { ZHContent } from '@/assets/datas/ZHContent'
91
+import { MessageBox } from 'element-ui'
92
+import { Snowflake } from '@/utils/snowFlake.js'
93
+import { submitAssess } from '@/api/oa/assess/assess.js'
94
+import { listProject } from '@/api/oa/project/project.js'
95
+import { getProject } from '@/api/oa/project/project'
96
+import ZhTable from './zhTable.vue';
97
+export default {
98
+  dicts: ['cmc_skill'],
99
+  components: { ZhTable },
100
+  data() {
101
+    return {
102
+      checkedBtn: [],
103
+      AssessmentContent: ZHContent,
104
+      projectList: [],
105
+      form: {},
106
+      noNullForm: {},
107
+      taskOpen: false,
108
+      tipsShow: false,
109
+      inputTips: false
110
+    };
111
+  },
112
+  created() {
113
+    this.initForm();
114
+  },
115
+  watch: {},
116
+  mounted() {
117
+
118
+  },
119
+  methods: {
120
+    initForm() {
121
+      listProject({ pageSize: 200 }).then(res => {
122
+        this.projectList = res.rows;
123
+      })
124
+    },
125
+    // 提交表单
126
+    submit(tableForm) {
127
+      MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
128
+        tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
129
+        tableForm.disabled = true;
130
+        console.log(tableForm);
131
+        let formData = new FormData();
132
+        let form = JSON.stringify(tableForm);
133
+        formData.append("form", form);
134
+        submitAssess(formData).then(res => {
135
+        debugger
136
+          this.taskOpen = false;
137
+          this.$emit('submit', tableForm);
138
+        });
139
+      }).catch(() => {
140
+      });
141
+    },
142
+    // 生成考核表格
143
+    generateForm() {
144
+      let flag = 0;
145
+      if (this.checkedBtn.length == 0) {
146
+        this.tipsShow = true;
147
+        return
148
+      }
149
+      for (let f in this.form) {
150
+        if (this.form[f] != "" && this.form[f] != [] && this.form[f] !== undefined) {
151
+          this.$set(this.noNullForm, f, this.form[f])
152
+        }
153
+        if (f.indexOf('familiar') != -1) {
154
+          this.$set(this.noNullForm, f, this.form[f])
155
+        }
156
+      }
157
+      for (let btn of this.checkedBtn) {
158
+        let ids = this.changeLabelToValue(btn);
159
+        if (this.form['familiar' + ids] == undefined) {
160
+          this.$message.error('熟练程度为必填项,请完善!');
161
+          flag = 0
162
+          break
163
+        } else {
164
+          flag = 1
165
+        }
166
+      }
167
+      if (flag) {
168
+        this.taskOpen = true;
169
+        if (this.$refs.zhTable != undefined) {
170
+          this.$refs.zhTable.formatForm();
171
+        }
172
+      }
173
+    },
174
+    getProjectById(id) {
175
+      getProject(id).then(res => {
176
+        if (res.data != undefined) {
177
+          this.form.projectName = res.data.projectName;
178
+          this.form.projectNumber = res.data.projectNumber;
179
+        }
180
+      })
181
+    },
182
+    closeItem(item) {
183
+      let index = this.checkedBtn.indexOf(item);
184
+      let number;
185
+      if (index !== -1) {
186
+        this.checkedBtn.splice(index, 1);
187
+      }
188
+      for (let i of ZHContent) {
189
+        if (i.label == item) {
190
+          number = i.value;
191
+        }
192
+      }
193
+      for (let fkey in this.form) {
194
+        if (fkey.substring(0, 3) == number) {
195
+          if (typeof (this.form[fkey]) == 'string') {
196
+            this.form[fkey] = "";
197
+          }
198
+          else if (Array.isArray(this.form[fkey])) {
199
+            this.form[fkey] = [];
200
+          }
201
+        }
202
+        this.form['familiar' + number.substring(1, 3)] = undefined;
203
+        this.form['remark' + number.substring(1, 3)] = "";
204
+      }
205
+    },
206
+    assessChangeFn(val) {
207
+      if (val.length != 0) {
208
+        this.tipsShow = false;
209
+      }
210
+    },
211
+    mustNumber(val, event) {
212
+      let regex = /^\d+(\.\d{1,2})?$/;
213
+      let newElement = document.createElement("div");
214
+      newElement.innerHTML = '工作量必须是数字';
215
+      newElement.classList.add('inputTips');
216
+      if (regex.test(val) || val == "") {
217
+        this.inputTips = false;
218
+      } else {
219
+        this.inputTips = true;
220
+        event.target.parentNode.appendChild(newElement, event.target)
221
+      }
222
+    },
223
+    changeLabelToValue(label) {
224
+      for (let s of ZHContent) {
225
+        if (s.label == label) {
226
+          return s.value.slice(-2)
227
+        }
228
+      }
229
+    }
230
+  }
231
+}
232
+</script>
233
+
234
+<style lang="scss" scoped>
235
+.tips {
236
+  color: #f00;
237
+  font-size: 12px;
238
+  line-height: 18px;
239
+}
240
+</style>
241
+<style>
242
+.inputTips {
243
+  color: #f00;
244
+  font-size: 12px;
245
+  line-height: 18px;
246
+  display: block;
247
+}
248
+</style>

+ 0
- 0
oa-ui/src/views/flowable/form/cwTable.vue 查看文件


+ 249
- 0
oa-ui/src/views/flowable/form/jsForm.vue 查看文件

@@ -0,0 +1,249 @@
1
+<!--
2
+ * @Author: ysh
3
+ * @Date: 2024-02-20 10:40:26
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-02-20 10:58:38
6
+-->
7
+<template>
8
+  <!-- 技术质量部 -->
9
+  <div>
10
+    <el-form ref="scform" :model="form">
11
+      <el-form-item label="工作自述:">
12
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="请输入内容" v-model="form['selfAssess']">
13
+        </el-input>
14
+      </el-form-item>
15
+      <el-form-item label="选择考核项:">
16
+        <el-checkbox-group v-model="checkedBtn" @change="assessChangeFn">
17
+          <el-checkbox v-for="sc, index in AssessmentContent" :label="sc.label" :key="index">{{ sc.label
18
+          }}</el-checkbox>
19
+        </el-checkbox-group>
20
+      </el-form-item>
21
+      <div class="tips" v-if="tipsShow">请至少选择一项考核项</div>
22
+      <el-row type="flex" style="flex-wrap:wrap;">
23
+        <el-card v-for="item, index in checkedBtn" style="flex:1;margin:10px;min-width: 400px;max-width: 450px;"
24
+          :key="index">
25
+          <div slot="header" class="clearfix">
26
+            <strong>{{ item }}</strong>
27
+            <el-button style="float: right; padding: 3px 0" type="text" @click="closeItem(item)">关闭</el-button>
28
+          </div>
29
+          <el-scrollbar style="height: 500px;">
30
+            <div v-for="ass in AssessmentContent" v-if="ass.label == item">
31
+              <table border="1" cellspacing="0" align="center" cellpadding="5">
32
+                <tr style="background-color:#409EFF;color:#fff;">
33
+                  <td>工作内容</td>
34
+                  <td>工作量</td>
35
+                  <td>单位</td>
36
+                </tr>
37
+                <tr v-for="child in ass.children">
38
+                  <td v-if="!Array.isArray(child.label)">{{ child.label }}</td>
39
+                  <td v-else>
40
+                    <el-checkbox-group v-model="form.f07">
41
+                      <el-checkbox v-for="label, index in child.label" :label="label" :key="'k' + index"></el-checkbox>
42
+                    </el-checkbox-group>
43
+                  </td>
44
+                  <td v-if="Array.isArray(child.label)">
45
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
46
+                  </td>
47
+                  <td v-if="!Array.isArray(child.label)">
48
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
49
+                  </td>
50
+                  <td>{{ child.unit }}</td>
51
+                </tr>
52
+                <tr>
53
+                  <td>熟练程度</td>
54
+                  <td colspan="2">
55
+                    <el-radio-group v-model="form['familiar' + ass.value.slice(-2)]">
56
+                      <el-radio :label="0">生疏</el-radio>
57
+                      <el-radio :label="2">熟练</el-radio>
58
+                      <el-radio :label="3">精通</el-radio>
59
+                    </el-radio-group>
60
+                  </td>
61
+                </tr>
62
+                <tr>
63
+                  <td>备注</td>
64
+                  <td colspan="2">
65
+                    <el-input type="textarea" :rows="2" placeholder="请输入内容"
66
+                      v-model="form['remark' + ass.value.slice(-2)]">
67
+                    </el-input>
68
+                  </td>
69
+                </tr>
70
+              </table>
71
+              <div class="tips" v-if="inputTips">工作量只能输入数字</div>
72
+            </div>
73
+          </el-scrollbar>
74
+        </el-card>
75
+      </el-row>
76
+      <el-form-item label="其他工作:">
77
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="有其他工作请在此写入内容" v-model="form['otherWork']">
78
+        </el-input>
79
+      </el-form-item>
80
+      <el-row>
81
+        <el-button @click="generateForm" type="primary">生成考核表</el-button>
82
+      </el-row>
83
+    </el-form>
84
+    <el-dialog title="" :visible.sync="taskOpen" width="65%" append-to-body>
85
+      <JsTable :tableForm="noNullForm" ref="jsTable" @submit="submit"></JsTable>
86
+    </el-dialog>
87
+  </div>
88
+</template>
89
+
90
+<script>
91
+import { JSContent } from '@/assets/datas/JSContent'
92
+import { MessageBox } from 'element-ui'
93
+import { Snowflake } from '@/utils/snowFlake.js'
94
+import { submitAssess } from '@/api/oa/assess/assess.js'
95
+import { listProject } from '@/api/oa/project/project.js'
96
+import { getProject } from '@/api/oa/project/project'
97
+import JsTable from './jsTable.vue'
98
+export default {
99
+  dicts: ['cmc_skill'],
100
+  components: { JsTable },
101
+  data() {
102
+    return {
103
+      checkedBtn: [],
104
+      AssessmentContent: JSContent,
105
+      projectList: [],
106
+      form: {},
107
+      noNullForm: {},
108
+      taskOpen: false,
109
+      tipsShow: false,
110
+      inputTips: false
111
+    };
112
+  },
113
+  created() {
114
+    this.initForm();
115
+  },
116
+  watch: {},
117
+  mounted() {
118
+
119
+  },
120
+  methods: {
121
+    initForm() {
122
+      listProject({ pageSize: 200 }).then(res => {
123
+        this.projectList = res.rows;
124
+      })
125
+    },
126
+    // 提交表单
127
+    submit(tableForm) {
128
+      MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
129
+        tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
130
+        tableForm.disabled = true;
131
+        console.log(tableForm);
132
+        let formData = new FormData();
133
+        let form = JSON.stringify(tableForm);
134
+        formData.append("form", form);
135
+        submitAssess(formData).then(res => {
136
+        debugger
137
+          this.taskOpen = false;
138
+          this.$emit('submit', tableForm);
139
+        });
140
+      }).catch(() => {
141
+      });
142
+    },
143
+    // 生成考核表格
144
+    generateForm() {
145
+      let flag = 0;
146
+      if (this.checkedBtn.length == 0) {
147
+        this.tipsShow = true;
148
+        return
149
+      }
150
+      for (let f in this.form) {
151
+        if (this.form[f] != "" && this.form[f] != [] && this.form[f] !== undefined) {
152
+          this.$set(this.noNullForm, f, this.form[f])
153
+        }
154
+        if (f.indexOf('familiar') != -1) {
155
+          this.$set(this.noNullForm, f, this.form[f])
156
+        }
157
+      }
158
+      for (let btn of this.checkedBtn) {
159
+        let ids = this.changeLabelToValue(btn);
160
+        if (this.form['familiar' + ids] == undefined) {
161
+          this.$message.error('熟练程度为必填项,请完善!');
162
+          flag = 0
163
+          break
164
+        } else {
165
+          flag = 1
166
+        }
167
+      }
168
+      if (flag) {
169
+        this.taskOpen = true;
170
+        if (this.$refs.jsTable != undefined) {
171
+          this.$refs.jsTable.formatForm();
172
+        }
173
+      }
174
+    },
175
+    getProjectById(id) {
176
+      getProject(id).then(res => {
177
+        if (res.data != undefined) {
178
+          this.form.projectName = res.data.projectName;
179
+          this.form.projectNumber = res.data.projectNumber;
180
+        }
181
+      })
182
+    },
183
+    closeItem(item) {
184
+      let index = this.checkedBtn.indexOf(item);
185
+      let number;
186
+      if (index !== -1) {
187
+        this.checkedBtn.splice(index, 1);
188
+      }
189
+      for (let i of JSContent) {
190
+        if (i.label == item) {
191
+          number = i.value;
192
+        }
193
+      }
194
+      for (let fkey in this.form) {
195
+        if (fkey.substring(0, 3) == number) {
196
+          if (typeof (this.form[fkey]) == 'string') {
197
+            this.form[fkey] = "";
198
+          }
199
+          else if (Array.isArray(this.form[fkey])) {
200
+            this.form[fkey] = [];
201
+          }
202
+        }
203
+        this.form['familiar' + number.substring(1, 3)] = undefined;
204
+        this.form['remark' + number.substring(1, 3)] = "";
205
+      }
206
+    },
207
+    assessChangeFn(val) {
208
+      if (val.length != 0) {
209
+        this.tipsShow = false;
210
+      }
211
+    },
212
+    mustNumber(val, event) {
213
+      let regex = /^\d+(\.\d{1,2})?$/;
214
+      let newElement = document.createElement("div");
215
+      newElement.innerHTML = '工作量必须是数字';
216
+      newElement.classList.add('inputTips');
217
+      if (regex.test(val) || val == "") {
218
+        this.inputTips = false;
219
+      } else {
220
+        this.inputTips = true;
221
+        event.target.parentNode.appendChild(newElement, event.target)
222
+      }
223
+    },
224
+    changeLabelToValue(label) {
225
+      for (let s of JSContent) {
226
+        if (s.label == label) {
227
+          return s.value.slice(-2)
228
+        }
229
+      }
230
+    }
231
+  }
232
+}
233
+</script>
234
+
235
+<style lang="scss" scoped>
236
+.tips {
237
+  color: #f00;
238
+  font-size: 12px;
239
+  line-height: 18px;
240
+}
241
+</style>
242
+<style>
243
+.inputTips {
244
+  color: #f00;
245
+  font-size: 12px;
246
+  line-height: 18px;
247
+  display: block;
248
+}
249
+</style>

+ 752
- 0
oa-ui/src/views/flowable/form/jsTable.vue 查看文件

@@ -0,0 +1,752 @@
1
+<template>
2
+  <!-- 技术质量部表格 -->
3
+  <div style="padding:10px">
4
+    <h2 style="text-align: center;">技术质量部考核表</h2>
5
+    <table class="table" ref="tableDatas">
6
+      <tr>
7
+        <td class="table-title">姓名</td>
8
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.nickName }}</td>
9
+        <td class="table-title">考核年度</td>
10
+        <td> {{ tableForm.assessTime }}</td>
11
+        <td colspan="3" class="table-title">部门负责人考核意见</td>
12
+        <td colspan="3" class="table-title">分管领导考核意见</td>
13
+      </tr>
14
+      <tr>
15
+        <td class="table-title">所在部门</td>
16
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.deptName }}</td>
17
+        <td colspan="3">
18
+          <el-radio-group v-model="tableForm.deptAssessment" :disabled="!isDeptLeader">
19
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
20
+              {{ dict.label }}
21
+            </el-radio>
22
+          </el-radio-group>
23
+        </td>
24
+        <td colspan="3">
25
+          <el-radio-group v-model="tableForm.managerAssessment" :disabled="!isManager">
26
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
27
+              {{ dict.label }}
28
+            </el-radio>
29
+          </el-radio-group>
30
+        </td>
31
+      </tr>
32
+      <tr>
33
+        <td class="table-title">部门职务</td>
34
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.postGroup }}</td>
35
+        <td colspan="3" rowspan="4">
36
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.deptAdvice" :disabled="!isDeptLeader">
37
+          </el-input>
38
+          <el-row justify="center" type="flex">
39
+            <el-col :span="12">考核人:<el-input v-model="tableForm.deptAssesser" style="width:150px;" placeholder="请输入考核人" :disabled="!isDeptLeader"></el-input> </el-col>
40
+            <el-col :span="12">日期:<el-date-picker type="date"  placeholder="请选择考核日期" v-model="tableForm.deptTime" style="width:150px;" :disabled="!isDeptLeader"></el-date-picker> </el-col>
41
+          </el-row>
42
+        </td>
43
+        <td colspan="3" rowspan="4">
44
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.managerAdvice" :disabled="!isManager">
45
+          </el-input>
46
+          <el-row justify="center">
47
+            <el-col :span="12">考核人:<el-input v-model="tableForm.managerAssesser" style="width:150px;" placeholder="请输入考核人" :disabled="!isManager"></el-input></el-col>
48
+            <el-col :span="12">日期:<el-date-picker type="date"  placeholder="请选择考核日期" v-model="tableForm.managerTime" style="width:150px;" :disabled="!isManager"></el-date-picker></el-col>
49
+          </el-row>
50
+        </td>
51
+      </tr>
52
+      <tr>
53
+        <td class="table-title">工程师岗级</td>
54
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.pmLevel }}</td>
55
+      </tr>
56
+      <tr>
57
+        <td class="table-title">技术职称</td>
58
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.titles }}</td>
59
+      </tr>
60
+      <tr>
61
+        <td class="table-title">入职年月</td>
62
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.entryDate }}</td>
63
+        <td class="table-title">年龄</td>
64
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.age }}</td>
65
+      </tr>
66
+      <tr>
67
+        <td rowspan="2" class="table-title">考核内容</td>
68
+        <td colspan="5" class="table-title">被考核人填写</td>
69
+        <td colspan="4" class="table-title" style="width:300px;">项目负责人考核</td>
70
+      </tr>
71
+      <tr>
72
+        <td class="table-title">工作内容</td>
73
+        <td class="table-title">单位</td>
74
+        <td class="table-title">工作量</td>
75
+        <td class="table-title">熟练程度</td>
76
+        <td class="table-title">备注</td>
77
+        <td class="table-title">工作量</td>
78
+        <td class="table-title">技能掌握</td>
79
+        <td class="table-title">岗位综合表现</td>
80
+        <td class="table-title">考核建议</td>
81
+      </tr>
82
+      <tr>
83
+        <td rowspan="6">参与生产</td>
84
+        <td>项目负责</td>
85
+        <td>项</td>
86
+        <td class="personInput">
87
+          <span v-if="!isStaff">{{ tableForm.f0101 }}</span>
88
+          <el-input v-if="isStaff" v-model="tableForm.f0101"></el-input>
89
+        </td>
90
+        <td rowspan="6">
91
+          <el-radio-group v-model="tableForm.familiar01" :disabled="!isStaff">
92
+            <div><el-radio :label="0">生疏</el-radio></div>
93
+            <div><el-radio :label="2">熟练</el-radio></div>
94
+            <div><el-radio :label="3">精通</el-radio></div>
95
+          </el-radio-group>
96
+        </td>
97
+        
98
+        <td rowspan="6">
99
+          <div>{{ tableForm.remark01 }}</div>
100
+        </td>
101
+        <!-- 工作量 -->
102
+        <td rowspan="6">
103
+          <el-radio-group v-model="tableForm.workload01" :disabled="!isPiLeader">
104
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
105
+              <el-radio :key="dict.value" :label="dict.value"
106
+                @click.native.prevent="cancelSelect(dict.value, 'workload05')">
107
+                {{ dict.label }}
108
+              </el-radio>
109
+            </div>
110
+          </el-radio-group>
111
+        </td>
112
+        <td rowspan="6">
113
+          <el-radio-group v-model="tableForm.skill01" :disabled="!isPiLeader">
114
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
115
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill01')">
116
+                {{ dict.label }}
117
+              </el-radio>
118
+            </div>
119
+          </el-radio-group>
120
+        </td>
121
+        <td rowspan="6">
122
+          <el-radio-group v-model="tableForm.assessment01" :disabled="!isPiLeader">
123
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
124
+              <el-radio :key="dict.value" :label="dict.value"
125
+                @click.native.prevent="cancelSelect(dict.value, 'assessment01')">
126
+                {{ dict.label }}
127
+              </el-radio>
128
+            </div>
129
+          </el-radio-group>
130
+        </td>
131
+        <td rowspan="6" >
132
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice01" :disabled="!isPiLeader">
133
+          </el-input>
134
+        </td>
135
+      </tr>
136
+      <tr>
137
+        <td>外业负责</td>
138
+        <td>项</td>
139
+        <td class="personInput">
140
+          <span v-if="!isStaff">{{ tableForm.f0102 }}</span>
141
+          <el-input v-if="isStaff" v-model="tableForm.f0102"></el-input>
142
+        </td>
143
+      </tr>
144
+      <tr>
145
+        <td>内业负责</td>
146
+        <td>项</td>
147
+        <td class="personInput">
148
+          <span v-if="!isStaff">{{ tableForm.f0103 }}</span>
149
+          <el-input v-if="isStaff" v-model="tableForm.f0103"></el-input>
150
+        </td>
151
+      </tr>
152
+      <tr>
153
+        <td>参与外业</td>
154
+        <td>项</td>
155
+        <td class="personInput">
156
+          <span v-if="!isStaff">{{ tableForm.f0104 }}</span>
157
+          <el-input v-if="isStaff" v-model="tableForm.f0104"></el-input>
158
+        </td>
159
+      </tr>
160
+      <tr>
161
+        <td>参与内业</td>
162
+        <td>项</td>
163
+        <td class="personInput">
164
+          <span v-if="!isStaff">{{ tableForm.f0105 }}</span>
165
+          <el-input v-if="isStaff" v-model="tableForm.f0105"></el-input>
166
+        </td>
167
+      </tr>
168
+      <tr>
169
+        <td>资料整编</td>
170
+        <td>项</td>
171
+        <td class="personInput">
172
+          <span v-if="!isStaff">{{ tableForm.f0106 }}</span>
173
+          <el-input v-if="isStaff" v-model="tableForm.f0106">
174
+          </el-input>
175
+        </td>
176
+      </tr>
177
+
178
+      <!--  -->
179
+      <tr>
180
+        <td rowspan="4">技术设计</td>
181
+        <td>承担技术负责人</td>
182
+        <td>项</td>
183
+        <td class="personInput">
184
+          <span v-if="!isStaff">{{ tableForm.f0201 }}</span>
185
+          <el-input v-if="isStaff" v-model="tableForm.f0201"></el-input>
186
+        </td>
187
+        <td rowspan="4">
188
+          <el-radio-group v-model="tableForm.familiar02" :disabled="!isStaff">
189
+            <div><el-radio :label="0">生疏</el-radio></div>
190
+            <div><el-radio :label="2">熟练</el-radio></div>
191
+            <div><el-radio :label="3">精通</el-radio></div>
192
+          </el-radio-group>
193
+        </td>
194
+        <td rowspan="4">
195
+          <div>{{ tableForm.remark02 }}</div>
196
+        </td>
197
+        <!-- 工作量 -->
198
+        <td rowspan="4">
199
+          <el-radio-group v-model="tableForm.workload02" :disabled="!isPiLeader">
200
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
201
+              <el-radio :key="dict.value" :label="dict.value"
202
+                @click.native.prevent="cancelSelect(dict.value, 'workload05')">
203
+                {{ dict.label }}
204
+              </el-radio>
205
+            </div>
206
+          </el-radio-group>
207
+        </td>
208
+        <td rowspan="4">
209
+          <el-radio-group v-model="tableForm.skill02" :disabled="!isPiLeader">
210
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
211
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill02')">
212
+                {{ dict.label }}
213
+              </el-radio>
214
+            </div>
215
+          </el-radio-group>
216
+        </td>
217
+        <td rowspan="4">
218
+          <el-radio-group v-model="tableForm.assessment02" :disabled="!isPiLeader">
219
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
220
+              <el-radio :key="dict.value" :label="dict.value"
221
+                @click.native.prevent="cancelSelect(dict.value, 'assessment02')">
222
+                {{ dict.label }}
223
+              </el-radio>
224
+            </div>
225
+          </el-radio-group>
226
+        </td>
227
+        <td rowspan="4">
228
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice02" :disabled="!isPiLeader">
229
+          </el-input>
230
+        </td>
231
+      </tr>
232
+      <tr>
233
+        <td>技术设计书编写</td>
234
+        <td>项</td>
235
+        <td>
236
+          <span v-if="!isStaff">{{ tableForm.f0202 }}</span>
237
+          <el-input v-if="isStaff" v-model="tableForm.f0202"></el-input>
238
+        </td>
239
+      </tr>
240
+      <tr>
241
+        <td>投标技术文件编写</td>
242
+        <td>项</td>
243
+        <td>
244
+          <span v-if="!isStaff">{{ tableForm.f0203 }}</span>
245
+          <el-input v-if="isStaff" v-model="tableForm.f0203"></el-input>
246
+        </td>
247
+      </tr>
248
+      <tr>
249
+        <td>技术设计书审核</td>
250
+        <td>项</td>
251
+        <td>
252
+          <span v-if="!isStaff">{{ tableForm.f0204 }}</span>
253
+          <el-input v-if="isStaff" v-model="tableForm.f0204"></el-input>
254
+        </td>
255
+      </tr>
256
+<!--  -->
257
+
258
+      <tr>
259
+        <td rowspan="13">质量检查</td>
260
+        <td>承担项目质量负责人</td>
261
+        <td>项</td>
262
+        <td class="personInput">
263
+          <span v-if="!isStaff">{{ tableForm.f0301 }}</span>
264
+          <el-input v-if="isStaff" v-model="tableForm.f0301"></el-input>
265
+        </td>
266
+        <td rowspan="13">
267
+          <el-radio-group v-model="tableForm.familiar03" :disabled="!isStaff">
268
+            <div><el-radio :label="0">生疏</el-radio></div>
269
+            <div><el-radio :label="2">熟练</el-radio></div>
270
+            <div><el-radio :label="3">精通</el-radio></div>
271
+          </el-radio-group>
272
+        </td>
273
+        <td rowspan="13">
274
+          <div>{{ tableForm.remark03 }}</div>
275
+        </td>
276
+        <!-- 工作量 -->
277
+        <td rowspan="13">
278
+          <el-radio-group v-model="tableForm.workload03" :disabled="!isPiLeader">
279
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
280
+              <el-radio :key="dict.value" :label="dict.value"
281
+                @click.native.prevent="cancelSelect(dict.value, 'workload05')">
282
+                {{ dict.label }}
283
+              </el-radio>
284
+            </div>
285
+          </el-radio-group>
286
+        </td>
287
+        <td rowspan="13">
288
+          <el-radio-group v-model="tableForm.skill03" :disabled="!isPiLeader">
289
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
290
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill03')">
291
+                {{ dict.label }}
292
+              </el-radio>
293
+            </div>
294
+          </el-radio-group>
295
+        </td>
296
+        <td rowspan="13">
297
+          <el-radio-group v-model="tableForm.assessment03" :disabled="!isPiLeader">
298
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
299
+              <el-radio :key="dict.value" :label="dict.value"
300
+                @click.native.prevent="cancelSelect(dict.value, 'assessment03')">
301
+                {{ dict.label }}
302
+              </el-radio>
303
+            </div>
304
+          </el-radio-group>
305
+        </td>
306
+        <td rowspan="13">
307
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice03" :disabled="!isPiLeader">
308
+          </el-input>
309
+        </td>
310
+      </tr>
311
+      <tr>
312
+        <td>控制测量资料检查</td>
313
+        <td>项</td>
314
+        <td>
315
+          <span v-if="!isStaff">{{ tableForm.f0302 }}</span>
316
+          <el-input v-if="isStaff" v-model="tableForm.f0302"></el-input>
317
+        </td>
318
+      </tr>
319
+      <tr>
320
+        <td>监测、施控网资料检查</td>
321
+        <td>项</td>
322
+        <td>
323
+          <span v-if="!isStaff">{{ tableForm.f0303 }}</span>
324
+          <el-input v-if="isStaff" v-model="tableForm.f0303"></el-input>
325
+        </td>
326
+      </tr>
327
+      <tr>
328
+        <td>DOM检查</td>
329
+        <td>幅</td>
330
+        <td>
331
+          <span v-if="!isStaff">{{ tableForm.f0304 }}</span>
332
+          <el-input v-if="isStaff" v-model="tableForm.f0304"></el-input>
333
+        </td>
334
+      </tr>
335
+      <tr>
336
+        <td>DEM检查</td>
337
+        <td>幅</td>
338
+        <td>
339
+          <span v-if="!isStaff">{{ tableForm.f0305 }}</span>
340
+          <el-input v-if="isStaff" v-model="tableForm.f0305"></el-input>
341
+        </td>
342
+      </tr>
343
+      <tr>
344
+        <td>地形图检查</td>
345
+        <td>幅</td>
346
+        <td>
347
+          <span v-if="!isStaff">{{ tableForm.f0306 }}</span>
348
+          <el-input v-if="isStaff" v-model="tableForm.f0306"></el-input>
349
+        </td>
350
+      </tr>
351
+      <tr>
352
+        <td>三维地形面检查</td>
353
+        <td>幅</td>
354
+        <td>
355
+          <span v-if="!isStaff">{{ tableForm.f0307 }}</span>
356
+          <el-input v-if="isStaff" v-model="tableForm.f0307"></el-input>
357
+        </td>
358
+      </tr>
359
+      <tr>
360
+        <td>项目空三检查</td>
361
+        <td>项</td>
362
+        <td>
363
+          <span v-if="!isStaff">{{ tableForm.f0308 }}</span>
364
+          <el-input v-if="isStaff" v-model="tableForm.f0308"></el-input>
365
+        </td>
366
+      </tr>
367
+      <tr>
368
+        <td>点云分类检查</td>
369
+        <td>幅</td>
370
+        <td>
371
+          <span v-if="!isStaff">{{ tableForm.f0309 }}</span>
372
+          <el-input v-if="isStaff" v-model="tableForm.f0309"></el-input>
373
+        </td>
374
+      </tr>
375
+      <tr>
376
+        <td>断面检查</td>
377
+        <td>项</td>
378
+        <td>
379
+          <span v-if="!isStaff">{{ tableForm.f0310 }}</span>
380
+          <el-input v-if="isStaff" v-model="tableForm.f0310"></el-input>
381
+        </td>
382
+      </tr>
383
+      <tr>
384
+        <td>外业检查、配合外业检查</td>
385
+        <td>人天</td>
386
+        <td>
387
+          <span v-if="!isStaff">{{ tableForm.f0311 }}</span>
388
+          <el-input v-if="isStaff" v-model="tableForm.f0311"></el-input>
389
+        </td>
390
+      </tr>
391
+      <tr>
392
+        <td>编写项目质量检查报告</td>
393
+        <td>项</td>
394
+        <td>
395
+          <span v-if="!isStaff">{{ tableForm.f0312 }}</span>
396
+          <el-input v-if="isStaff" v-model="tableForm.f0312"></el-input>
397
+        </td>
398
+      </tr>
399
+      <tr>
400
+        <td>质量问题处理</td>
401
+        <td>项</td>
402
+        <td>
403
+          <span v-if="!isStaff">{{ tableForm.f0313 }}</span>
404
+          <el-input v-if="isStaff" v-model="tableForm.f0313"></el-input>
405
+        </td>
406
+      </tr>
407
+
408
+      <!--  -->
409
+
410
+      <tr>
411
+        <td rowspan="5">资料管理</td>
412
+        <td>报奖资料整理</td>
413
+        <td>项</td>
414
+        <td class="personInput">
415
+          <span v-if="!isStaff">{{ tableForm.f0401 }}</span>
416
+          <el-input v-if="isStaff" v-model="tableForm.f0401"></el-input>
417
+        </td>
418
+        <td rowspan="5">
419
+          <el-radio-group v-model="tableForm.familiar04" :disabled="!isStaff">
420
+            <div><el-radio :label="0">生疏</el-radio></div>
421
+            <div><el-radio :label="2">熟练</el-radio></div>
422
+            <div><el-radio :label="3">精通</el-radio></div>
423
+          </el-radio-group>
424
+        </td>
425
+        <td rowspan="5">
426
+          <div>{{ tableForm.remark04 }}</div>
427
+        </td>
428
+        <!-- 工作量 -->
429
+        <td rowspan="5">
430
+          <el-radio-group v-model="tableForm.workload04" :disabled="!isPiLeader">
431
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
432
+              <el-radio :key="dict.value" :label="dict.value"
433
+                @click.native.prevent="cancelSelect(dict.value, 'workload05')">
434
+                {{ dict.label }}
435
+              </el-radio>
436
+            </div>
437
+          </el-radio-group>
438
+        </td>
439
+        <td rowspan="5">
440
+          <el-radio-group v-model="tableForm.skill04" :disabled="!isPiLeader">
441
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
442
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill04')">
443
+                {{ dict.label }}
444
+              </el-radio>
445
+            </div>
446
+          </el-radio-group>
447
+        </td>
448
+        <td rowspan="5">
449
+          <el-radio-group v-model="tableForm.assessment04" :disabled="!isPiLeader">
450
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
451
+              <el-radio :key="dict.value" :label="dict.value"
452
+                @click.native.prevent="cancelSelect(dict.value, 'assessment04')">
453
+                {{ dict.label }}
454
+              </el-radio>
455
+            </div>
456
+          </el-radio-group>
457
+        </td>
458
+        <td rowspan="5">
459
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice04" :disabled="!isPiLeader">
460
+          </el-input>
461
+        </td>
462
+      </tr>
463
+      <tr>
464
+        <td>外部资料收集</td>
465
+        <td>项</td>
466
+        <td>
467
+          <span v-if="!isStaff">{{ tableForm.f0402 }}</span>
468
+          <el-input v-if="isStaff" v-model="tableForm.f0402"></el-input>
469
+        </td>
470
+      </tr>
471
+      <tr>
472
+        <td>项目资料内部归档</td>
473
+        <td>项</td>
474
+        <td>
475
+          <span v-if="!isStaff">{{ tableForm.f0403 }}</span>
476
+          <el-input v-if="isStaff" v-model="tableForm.f0403"></el-input>
477
+        </td>
478
+      </tr>
479
+      <tr>
480
+        <td>项目资料提交甲方</td>
481
+        <td>项</td>
482
+        <td>
483
+          <span v-if="!isStaff">{{ tableForm.f0404 }}</span>
484
+          <el-input v-if="isStaff" v-model="tableForm.f0404"></el-input>
485
+        </td>
486
+      </tr>
487
+      <tr>
488
+        <td>项目资料提交甲方归档</td>
489
+        <td>项</td>
490
+        <td>
491
+          <span v-if="!isStaff">{{ tableForm.f0405 }}</span>
492
+          <el-input v-if="isStaff" v-model="tableForm.f0405"></el-input>
493
+        </td>
494
+      </tr>
495
+
496
+      <!--  -->
497
+
498
+      <tr>
499
+        <td rowspan="3">体系维护</td>
500
+        <td>体系内审</td>
501
+        <td>项</td>
502
+        <td class="personInput">
503
+          <span v-if="!isStaff">{{ tableForm.f0501 }}</span>
504
+          <el-input v-if="isStaff" v-model="tableForm.f0501"></el-input>
505
+        </td>
506
+        <td rowspan="3">
507
+          <el-radio-group v-model="tableForm.familiar05" :disabled="!isStaff">
508
+            <div><el-radio :label="0">生疏</el-radio></div>
509
+            <div><el-radio :label="2">熟练</el-radio></div>
510
+            <div><el-radio :label="3">精通</el-radio></div>
511
+          </el-radio-group>
512
+        </td>
513
+        <td rowspan="3">
514
+          <div>{{ tableForm.remark05 }}</div>
515
+        </td>
516
+        <!-- 工作量 -->
517
+        <td rowspan="3">
518
+          <el-radio-group v-model="tableForm.workload05" :disabled="!isPiLeader">
519
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
520
+              <el-radio :key="dict.value" :label="dict.value"
521
+                @click.native.prevent="cancelSelect(dict.value, 'workload05')">
522
+                {{ dict.label }}
523
+              </el-radio>
524
+            </div>
525
+          </el-radio-group>
526
+        </td>
527
+        <td rowspan="3">
528
+          <el-radio-group v-model="tableForm.skill05" :disabled="!isPiLeader">
529
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
530
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill05')">
531
+                {{ dict.label }}
532
+              </el-radio>
533
+            </div>
534
+          </el-radio-group>
535
+        </td>
536
+        <td rowspan="3">
537
+          <el-radio-group v-model="tableForm.assessment05" :disabled="!isPiLeader">
538
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
539
+              <el-radio :key="dict.value" :label="dict.value"
540
+                @click.native.prevent="cancelSelect(dict.value, 'assessment05')">
541
+                {{ dict.label }}
542
+              </el-radio>
543
+            </div>
544
+          </el-radio-group>
545
+        </td>
546
+        <td rowspan="3">
547
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice05" :disabled="!isPiLeader">
548
+          </el-input>
549
+        </td>
550
+      </tr>
551
+      <tr>
552
+        <td>协助外审</td>
553
+        <td>项</td>
554
+        <td>
555
+          <span v-if="!isStaff">{{ tableForm.f0502 }}</span>
556
+          <el-input v-if="isStaff" v-model="tableForm.f0502"></el-input>
557
+        </td>
558
+      </tr>
559
+      <tr>
560
+        <td>体系文件修编</td>
561
+        <td>项</td>
562
+        <td>
563
+          <span v-if="!isStaff">{{ tableForm.f0503 }}</span>
564
+          <el-input v-if="isStaff" v-model="tableForm.f0503"></el-input>
565
+        </td>
566
+      </tr>
567
+
568
+      <!--  -->
569
+
570
+      <tr style="height:90px;">
571
+        <td>其他工作</td>
572
+        <td colspan="9">
573
+          <span v-if="!isStaff">{{ tableForm.otherWork }}</span>
574
+          <el-input v-if="isStaff" v-model="tableForm.otherWork" type="textarea" :rows="2"></el-input>
575
+        </td>
576
+      </tr>
577
+      <tr style="height:90px;">
578
+        <td>年度自述</td>
579
+        <td colspan="9">
580
+          <span v-if="!isStaff">{{ tableForm.selfAssess }}</span>
581
+          <el-input v-if="isStaff" v-model="tableForm.selfAssess" type="textarea" :rows="2"></el-input>
582
+        </td>
583
+      </tr>
584
+    </table>
585
+    <el-row justify="center" type="flex" style="margin-top:20px;"
586
+      v-if="tableForm.taskName == undefined || tableForm.taskName == '员工修改'">
587
+      <el-button type="primary" @click="submit">提交</el-button>
588
+      <el-button>取消</el-button>
589
+    </el-row>
590
+  </div>
591
+</template>
592
+
593
+<script>
594
+import { JYContent } from '@/assets/datas/JYContent'
595
+import { getDicts as getDicts } from '@/api/system/dict/data'
596
+export default {
597
+  dicts: ['cmc_role', 'cmc_skill', 'cmc_accessment','cmc_workload'],
598
+  props: {
599
+    tableForm: {
600
+      type: Object,
601
+      required: true
602
+    },
603
+  },
604
+  watch: {
605
+    tableForm: function (newval, oldval) {
606
+      this.formatForm();
607
+    }
608
+  },
609
+  data() {
610
+    return {
611
+      form: {},
612
+      radio1: "",
613
+      radio2: "",
614
+      textarea1: "",
615
+      textarea2: "",
616
+      isDeptLeader: false,
617
+      isPiLeader: false,
618
+      isManager: false,
619
+      isStaff: false,
620
+    }
621
+  },
622
+  created() {
623
+    this.initForm();
624
+  },
625
+  mounted() {
626
+    this.formatForm();
627
+  },
628
+  methods: {
629
+    initForm() {
630
+
631
+    },
632
+    formatForm() {
633
+      if (this.tableForm.taskName == '项目负责人审核') {
634
+        this.isPiLeader = true;
635
+        this.isDeptLeader = false;
636
+        this.isManager = false;
637
+        this.isStaff = false;
638
+      } else if (this.tableForm.taskName == '部门审核') {
639
+        this.isPiLeader = false;
640
+        this.isDeptLeader = true;
641
+        this.isManager = false;
642
+        this.isStaff = false;
643
+      } else if (this.tableForm.taskName == '分管领导审核') {
644
+        this.isPiLeader = false;
645
+        this.isDeptLeader = false;
646
+        this.isManager = true;
647
+        this.isStaff = false;
648
+      } else if (this.tableForm.taskName == '员工修改') {
649
+        this.isPiLeader = false;
650
+        this.isDeptLeader = false;
651
+        this.isManager = false;
652
+        this.isStaff = true;
653
+      }
654
+    },
655
+    submit() {
656
+      if(!this.isStaff){
657
+        this.$emit('submit', this.tableForm);
658
+      }else{
659
+        this.$emit('submit', this.tableForm);
660
+      }
661
+      
662
+    },
663
+    cancelSelect(value, name) {
664
+      debugger
665
+      if (!this.isPiLeader) {
666
+        return
667
+      }
668
+      if (this.tableForm[name] == value) {
669
+        this.tableForm[name] = null
670
+      } else {
671
+
672
+        if (this.tableForm[name] !== undefined)
673
+          this.tableForm[name] = value
674
+      }
675
+    }
676
+  },
677
+}
678
+</script>
679
+
680
+<style lang="scss" scoped>
681
+.table {
682
+  border-collapse: collapse;
683
+  width: 100%;
684
+}
685
+
686
+.table-title {
687
+  background-color: #dad4d4;
688
+  font-weight: bold;
689
+}
690
+
691
+.table,
692
+th,
693
+td {
694
+  border: 1px solid black;
695
+  text-align: center;
696
+}
697
+
698
+td {
699
+  height: 24px;
700
+  width: 100px;
701
+}
702
+
703
+.head {
704
+  background-color: #ccc;
705
+}
706
+
707
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after {
708
+  border-color: #fff;
709
+}
710
+
711
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
712
+  background-color: #409eff;
713
+  border-color: #409eff;
714
+}
715
+
716
+::v-deep .el-checkbox__input.is-disabled+span.el-checkbox__label {
717
+  color: #000;
718
+}
719
+
720
+::v-deep .el-checkbox__label {
721
+  font-size: 12px;
722
+}
723
+
724
+::v-deep .el-radio__input.is-disabled .el-radio__inner,
725
+.el-radio__input.is-disabled.is-checked .el-radio__inner {
726
+  background-color: #f1f1f1;
727
+  border-color: #f1f1f1;
728
+}
729
+
730
+::v-deep .el-radio__input.is-disabled+span.el-radio__label {
731
+  color: #000;
732
+}
733
+
734
+
735
+::v-deep .el-radio__input.is-checked .el-radio__inner::after {
736
+  content: "";
737
+  width: 10px;
738
+  height: 5px;
739
+  border: 2px solid #409eff;
740
+  border-top: transparent;
741
+  border-right: transparent;
742
+  text-align: center;
743
+  display: block;
744
+  position: absolute;
745
+  top: 2px;
746
+  left: 2px;
747
+  vertical-align: middle;
748
+  transform: rotate(-45deg);
749
+  border-radius: 0px;
750
+  background: none;
751
+}
752
+</style>

+ 248
- 0
oa-ui/src/views/flowable/form/jyForm.vue 查看文件

@@ -0,0 +1,248 @@
1
+<!--
2
+ * @Author: ysh
3
+ * @Date: 2024-01-19 16:29:01
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-02-19 14:36:21
6
+-->
7
+<template>
8
+  <div>
9
+    <el-form ref="scform" :model="form">
10
+      <el-form-item label="工作自述:">
11
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="请输入内容" v-model="form['selfAssess']">
12
+        </el-input>
13
+      </el-form-item>
14
+      <el-form-item label="选择考核项:">
15
+        <el-checkbox-group v-model="checkedBtn" @change="assessChangeFn">
16
+          <el-checkbox v-for="sc, index in AssessmentContent" :label="sc.label" :key="index">{{ sc.label
17
+          }}</el-checkbox>
18
+        </el-checkbox-group>
19
+      </el-form-item>
20
+      <div class="tips" v-if="tipsShow">请至少选择一项考核项</div>
21
+      <el-row type="flex" style="flex-wrap:wrap;">
22
+        <el-card v-for="item, index in checkedBtn" style="flex:1;margin:10px;min-width: 400px;max-width: 450px;"
23
+          :key="index">
24
+          <div slot="header" class="clearfix">
25
+            <strong>{{ item }}</strong>
26
+            <el-button style="float: right; padding: 3px 0" type="text" @click="closeItem(item)">关闭</el-button>
27
+          </div>
28
+          <el-scrollbar style="height: 500px;">
29
+            <div v-for="ass in AssessmentContent" v-if="ass.label == item">
30
+              <table border="1" cellspacing="0" align="center" cellpadding="5">
31
+                <tr style="background-color:#409EFF;color:#fff;">
32
+                  <td>等级、比例尺等</td>
33
+                  <td>工作量</td>
34
+                  <td>单位</td>
35
+                </tr>
36
+                <tr v-for="child in ass.children">
37
+                  <td v-if="!Array.isArray(child.label)">{{ child.label }}</td>
38
+                  <td v-else>
39
+                    <el-checkbox-group v-model="form.f07">
40
+                      <el-checkbox v-for="label, index in child.label" :label="label" :key="'k' + index"></el-checkbox>
41
+                    </el-checkbox-group>
42
+                  </td>
43
+                  <td v-if="Array.isArray(child.label)">
44
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
45
+                  </td>
46
+                  <td v-if="!Array.isArray(child.label)">
47
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
48
+                  </td>
49
+                  <td>{{ child.unit }}</td>
50
+                </tr>
51
+                <tr>
52
+                  <td>熟练程度</td>
53
+                  <td colspan="2">
54
+                    <el-radio-group v-model="form['familiar' + ass.value.slice(-2)]">
55
+                      <el-radio :label="0">生疏</el-radio>
56
+                      <el-radio :label="2">熟练</el-radio>
57
+                      <el-radio :label="3">精通</el-radio>
58
+                    </el-radio-group>
59
+                  </td>
60
+                </tr>
61
+                <tr>
62
+                  <td>备注</td>
63
+                  <td colspan="2">
64
+                    <el-input type="textarea" :rows="2" placeholder="请输入内容"
65
+                      v-model="form['remark' + ass.value.slice(-2)]">
66
+                    </el-input>
67
+                  </td>
68
+                </tr>
69
+              </table>
70
+              <div class="tips" v-if="inputTips">工作量只能输入数字</div>
71
+            </div>
72
+          </el-scrollbar>
73
+        </el-card>
74
+      </el-row>
75
+      <el-form-item label="其他工作:">
76
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="有其他工作请在此写入内容" v-model="form['otherWork']">
77
+        </el-input>
78
+      </el-form-item>
79
+      <el-row>
80
+        <el-button @click="generateForm" type="primary">生成考核表</el-button>
81
+      </el-row>
82
+    </el-form>
83
+    <el-dialog title="" :visible.sync="taskOpen" width="65%" append-to-body>
84
+      <JyTable :tableForm="noNullForm" ref="jyTable" @submit="submit"></JyTable>
85
+    </el-dialog>
86
+  </div>
87
+</template>
88
+
89
+<script>
90
+import { JYContent } from '@/assets/datas/JYContent'
91
+import { MessageBox } from 'element-ui'
92
+import { Snowflake } from '@/utils/snowFlake.js'
93
+import { submitAssess } from '@/api/oa/assess/assess.js'
94
+import { listProject } from '@/api/oa/project/project.js'
95
+import { getProject } from '@/api/oa/project/project'
96
+import JyTable from './jyTable.vue';
97
+export default {
98
+  dicts: ['cmc_skill'],
99
+  components: { JyTable },
100
+  data() {
101
+    return {
102
+      checkedBtn: [],
103
+      AssessmentContent: JYContent,
104
+      projectList: [],
105
+      form: {},
106
+      noNullForm: {},
107
+      taskOpen: false,
108
+      tipsShow: false,
109
+      inputTips: false
110
+    };
111
+  },
112
+  created() {
113
+    this.initForm();
114
+  },
115
+  watch: {},
116
+  mounted() {
117
+
118
+  },
119
+  methods: {
120
+    initForm() {
121
+      listProject({ pageSize: 200 }).then(res => {
122
+        this.projectList = res.rows;
123
+      })
124
+    },
125
+    // 提交表单
126
+    submit(tableForm) {
127
+      MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
128
+        tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
129
+        tableForm.disabled = true;
130
+        console.log(tableForm);
131
+        let formData = new FormData();
132
+        let form = JSON.stringify(tableForm);
133
+        formData.append("form", form);
134
+        submitAssess(formData).then(res => {
135
+        debugger
136
+          this.taskOpen = false;
137
+          this.$emit('submit', tableForm);
138
+        });
139
+      }).catch(() => {
140
+      });
141
+    },
142
+    // 生成考核表格
143
+    generateForm() {
144
+      let flag = 0;
145
+      if (this.checkedBtn.length == 0) {
146
+        this.tipsShow = true;
147
+        return
148
+      }
149
+      for (let f in this.form) {
150
+        if (this.form[f] != "" && this.form[f] != [] && this.form[f] !== undefined) {
151
+          this.$set(this.noNullForm, f, this.form[f])
152
+        }
153
+        if (f.indexOf('familiar') != -1) {
154
+          this.$set(this.noNullForm, f, this.form[f])
155
+        }
156
+      }
157
+      for (let btn of this.checkedBtn) {
158
+        let ids = this.changeLabelToValue(btn);
159
+        if (this.form['familiar' + ids] == undefined) {
160
+          this.$message.error('熟练程度为必填项,请完善!');
161
+          flag = 0
162
+          break
163
+        } else {
164
+          flag = 1
165
+        }
166
+      }
167
+      if (flag) {
168
+        this.taskOpen = true;
169
+        if (this.$refs.jyTable != undefined) {
170
+          this.$refs.jyTable.formatForm();
171
+        }
172
+      }
173
+    },
174
+    getProjectById(id) {
175
+      getProject(id).then(res => {
176
+        if (res.data != undefined) {
177
+          this.form.projectName = res.data.projectName;
178
+          this.form.projectNumber = res.data.projectNumber;
179
+        }
180
+      })
181
+    },
182
+    closeItem(item) {
183
+      let index = this.checkedBtn.indexOf(item);
184
+      let number;
185
+      if (index !== -1) {
186
+        this.checkedBtn.splice(index, 1);
187
+      }
188
+      for (let i of JYContent) {
189
+        if (i.label == item) {
190
+          number = i.value;
191
+        }
192
+      }
193
+      for (let fkey in this.form) {
194
+        if (fkey.substring(0, 3) == number) {
195
+          if (typeof (this.form[fkey]) == 'string') {
196
+            this.form[fkey] = "";
197
+          }
198
+          else if (Array.isArray(this.form[fkey])) {
199
+            this.form[fkey] = [];
200
+          }
201
+        }
202
+        this.form['familiar' + number.substring(1, 3)] = undefined;
203
+        this.form['remark' + number.substring(1, 3)] = "";
204
+      }
205
+    },
206
+    assessChangeFn(val) {
207
+      if (val.length != 0) {
208
+        this.tipsShow = false;
209
+      }
210
+    },
211
+    mustNumber(val, event) {
212
+      let regex = /^\d+(\.\d{1,2})?$/;
213
+      let newElement = document.createElement("div");
214
+      newElement.innerHTML = '工作量必须是数字';
215
+      newElement.classList.add('inputTips');
216
+      if (regex.test(val) || val == "") {
217
+        this.inputTips = false;
218
+      } else {
219
+        this.inputTips = true;
220
+        event.target.parentNode.appendChild(newElement, event.target)
221
+      }
222
+    },
223
+    changeLabelToValue(label) {
224
+      for (let s of JYContent) {
225
+        if (s.label == label) {
226
+          return s.value.slice(-2)
227
+        }
228
+      }
229
+    }
230
+  }
231
+}
232
+</script>
233
+
234
+<style lang="scss" scoped>
235
+.tips {
236
+  color: #f00;
237
+  font-size: 12px;
238
+  line-height: 18px;
239
+}
240
+</style>
241
+<style>
242
+.inputTips {
243
+  color: #f00;
244
+  font-size: 12px;
245
+  line-height: 18px;
246
+  display: block;
247
+}
248
+</style>

+ 476
- 0
oa-ui/src/views/flowable/form/jyTable.vue 查看文件

@@ -0,0 +1,476 @@
1
+<template>
2
+  <div style="padding:10px">
3
+    <h2 style="text-align: center;">经营发展部考核表</h2>
4
+    <table class="table" ref="tableDatas">
5
+      <tr>
6
+        <td class="table-title">项目编号</td>
7
+        <td colspan="1" style="text-align:left;padding-left:10px;">
8
+          {{ tableForm.projectNumber }}
9
+        </td>
10
+        <td class="table-title">项目名称</td>
11
+        <td colspan="9" style="text-align:left;padding-left:10px;">
12
+          {{ tableForm.projectName }}
13
+        </td>
14
+      </tr>
15
+      <tr>
16
+        <td class="table-title">姓名</td>
17
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.nickName }}</td>
18
+        <td class="table-title">考核年度</td>
19
+        <td> {{ tableForm.assessTime }}</td>
20
+        <td colspan="3" class="table-title">部门负责人考核意见</td>
21
+        <td colspan="3" class="table-title">分管领导考核意见</td>
22
+      </tr>
23
+      <tr>
24
+        <td class="table-title">所在部门</td>
25
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.deptName }}</td>
26
+        <td colspan="3">
27
+          <el-radio-group v-model="tableForm.deptAssessment" :disabled="!isDeptLeader">
28
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
29
+              {{ dict.label }}
30
+            </el-radio>
31
+          </el-radio-group>
32
+        </td>
33
+        <td colspan="3">
34
+          <el-radio-group v-model="tableForm.managerAssessment" :disabled="!isManager">
35
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
36
+              {{ dict.label }}
37
+            </el-radio>
38
+          </el-radio-group>
39
+        </td>
40
+      </tr>
41
+      <tr>
42
+        <td class="table-title">部门职务</td>
43
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.postGroup }}</td>
44
+        <td colspan="3" rowspan="5">
45
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.deptAdvice" :disabled="!isDeptLeader">
46
+          </el-input>
47
+          <el-row justify="center" type="flex">
48
+            <el-col :span="12">考核人:<el-input v-model="tableForm.deptAssesser" style="width:150px;" placeholder="请输入考核人" :disabled="!isDeptLeader"></el-input> </el-col>
49
+            <el-col :span="12">日期:<el-date-picker type="date"  placeholder="请选择考核日期" v-model="tableForm.deptTime" style="width:150px;" :disabled="!isDeptLeader"></el-date-picker> </el-col>
50
+          </el-row>
51
+        </td>
52
+        <td colspan="3" rowspan="5">
53
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.managerAdvice" :disabled="!isManager">
54
+          </el-input>
55
+          <el-row justify="center">
56
+            <el-col :span="12">考核人:<el-input v-model="tableForm.managerAssesser" style="width:150px;" placeholder="请输入考核人" :disabled="!isManager"></el-input></el-col>
57
+            <el-col :span="12">日期:<el-date-picker type="date"  placeholder="请选择考核日期" v-model="tableForm.managerTime" style="width:150px;" :disabled="!isManager"></el-date-picker></el-col>
58
+          </el-row>
59
+        </td>
60
+      </tr>
61
+      <tr>
62
+        <td class="table-title">项目经理</td>
63
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.pmLevel }}</td>
64
+      </tr>
65
+      <tr>
66
+        <td class="table-title">技术职称</td>
67
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.titles }}</td>
68
+      </tr>
69
+      <tr>
70
+        <td class="table-title">作业类别</td>
71
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.remark }}</td>
72
+      </tr>
73
+      <tr>
74
+        <td class="table-title">入职年月</td>
75
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.entryDate }}</td>
76
+        <td class="table-title">年龄</td>
77
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.age }}</td>
78
+      </tr>
79
+      <tr>
80
+        <td rowspan="2" class="table-title">考核内容</td>
81
+        <td colspan="5" class="table-title">被考核人填写</td>
82
+        <td colspan="3" class="table-title" style="width:300px;">项目负责人考核</td>
83
+      </tr>
84
+      <tr>
85
+        <td class="table-title">等级、比例尺等</td>
86
+        <td class="table-title">单位</td>
87
+        <td class="table-title">工作量</td>
88
+        <td class="table-title">熟练程度</td>
89
+        <td class="table-title">备注</td>
90
+        <td class="table-title">产品质量</td>
91
+        <td class="table-title">技能掌握</td>
92
+        <td class="table-title">考核建议</td>
93
+      </tr>
94
+      <tr>
95
+        <td rowspan="6">参与生产</td>
96
+        <td>项目负责</td>
97
+        <td>项</td>
98
+        <td class="personInput">
99
+          <span v-if="!isStaff">{{ tableForm.f0101 }}</span>
100
+          <el-input v-if="isStaff" v-model="tableForm.f0101"></el-input>
101
+        </td>
102
+        <td rowspan="6">
103
+          <el-radio-group v-model="tableForm.familiar01" :disabled="!isStaff">
104
+            <div><el-radio :label="0">生疏</el-radio></div>
105
+            <div><el-radio :label="2">熟练</el-radio></div>
106
+            <div><el-radio :label="3">精通</el-radio></div>
107
+          </el-radio-group>
108
+        </td>
109
+        
110
+        <td rowspan="6">
111
+          <div>{{ tableForm.remark01 }}</div>
112
+        </td>
113
+        <td rowspan="6">
114
+          <el-radio-group v-model="tableForm.quality01" :disabled="!isPiLeader">
115
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
116
+              <el-radio :key="dict.value" :label="dict.value"
117
+                @click.native.prevent="cancelSelect(dict.value, 'quality01')">
118
+                {{ dict.label }}
119
+              </el-radio>
120
+            </div>
121
+          </el-radio-group>
122
+        </td>
123
+        <td rowspan="6">
124
+          <el-radio-group v-model="tableForm.skill01" :disabled="!isPiLeader">
125
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
126
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill01')">
127
+                {{ dict.label }}
128
+              </el-radio>
129
+            </div>
130
+          </el-radio-group>
131
+        </td>
132
+        <td rowspan="6" >
133
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice01" :disabled="!isPiLeader">
134
+          </el-input>
135
+        </td>
136
+      </tr>
137
+      <tr>
138
+        <td>外业负责</td>
139
+        <td>项</td>
140
+        <td class="personInput">
141
+          <span v-if="!isStaff">{{ tableForm.f0102 }}</span>
142
+          <el-input v-if="isStaff" v-model="tableForm.f0102"></el-input>
143
+        </td>
144
+      </tr>
145
+      <tr>
146
+        <td>内业负责</td>
147
+        <td>项</td>
148
+        <td class="personInput">
149
+          <span v-if="!isStaff">{{ tableForm.f0103 }}</span>
150
+          <el-input v-if="isStaff" v-model="tableForm.f0103"></el-input>
151
+        </td>
152
+      </tr>
153
+      <tr>
154
+        <td>参与外业</td>
155
+        <td>项</td>
156
+        <td class="personInput">
157
+          <span v-if="!isStaff">{{ tableForm.f0104 }}</span>
158
+          <el-input v-if="isStaff" v-model="tableForm.f0104"></el-input>
159
+        </td>
160
+      </tr>
161
+      <tr>
162
+        <td>参与内业</td>
163
+        <td>项</td>
164
+        <td class="personInput">
165
+          <span v-if="!isStaff">{{ tableForm.f0105 }}</span>
166
+          <el-input v-if="isStaff" v-model="tableForm.f0105"></el-input>
167
+        </td>
168
+      </tr>
169
+      <tr>
170
+        <td>资料整编</td>
171
+        <td>项</td>
172
+        <td class="personInput">
173
+          <span v-if="!isStaff">{{ tableForm.f0106 }}</span>
174
+          <el-input v-if="isStaff" v-model="tableForm.f0106">
175
+          </el-input>
176
+        </td>
177
+      </tr>
178
+      <tr>
179
+        <td rowspan="3">商务标书</td>
180
+        <td>编写</td>
181
+        <td>项</td>
182
+        <td class="personInput">
183
+          <span v-if="!isStaff">{{ tableForm.f0201 }}</span>
184
+          <el-input v-if="isStaff" v-model="tableForm.f0201"></el-input>
185
+        </td>
186
+        <td rowspan="3">
187
+          <el-radio-group v-model="tableForm.familiar02" :disabled="!isStaff">
188
+            <div><el-radio :label="0">生疏</el-radio></div>
189
+            <div><el-radio :label="2">熟练</el-radio></div>
190
+            <div><el-radio :label="3">精通</el-radio></div>
191
+          </el-radio-group>
192
+        </td>
193
+        <td rowspan="3">
194
+          <div>{{ tableForm.remark02 }}</div>
195
+        </td>
196
+        <td rowspan="3">
197
+          <el-radio-group v-model="tableForm.quality02" :disabled="!isPiLeader">
198
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
199
+              <el-radio :key="dict.value" :label="dict.value"
200
+                @click.native.prevent="cancelSelect(dict.value, 'quality02')">
201
+                {{ dict.label }}
202
+              </el-radio>
203
+            </div>
204
+          </el-radio-group>
205
+        </td>
206
+        <td rowspan="3">
207
+          <el-radio-group v-model="tableForm.skill02" :disabled="!isPiLeader">
208
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
209
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill02')">
210
+                {{ dict.label }}
211
+              </el-radio>
212
+            </div>
213
+          </el-radio-group>
214
+        </td>
215
+        <td rowspan="3">
216
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice02" :disabled="!isPiLeader">
217
+          </el-input>
218
+        </td>
219
+      </tr>
220
+      <tr>
221
+        <td>校核</td>
222
+        <td>项</td>
223
+        <td>
224
+          <span v-if="!isStaff">{{ tableForm.f0202 }}</span>
225
+          <el-input v-if="isStaff" v-model="tableForm.f0202"></el-input>
226
+        </td>
227
+      </tr>
228
+      <tr>
229
+        <td>审查</td>
230
+        <td>项</td>
231
+        <td>
232
+          <span v-if="!isStaff">{{ tableForm.f0203 }}</span>
233
+          <el-input v-if="isStaff" v-model="tableForm.f0203"></el-input>
234
+        </td>
235
+      </tr>
236
+      <tr>
237
+        <td rowspan="3">报价标书</td>
238
+        <td>编写</td>
239
+        <td>项</td>
240
+        <td class="personInput">
241
+          <span v-if="!isStaff">{{ tableForm.f0301 }}</span>
242
+          <el-input v-if="isStaff" v-model="tableForm.f0301"></el-input>
243
+        </td>
244
+        <td rowspan="3">
245
+          <el-radio-group v-model="tableForm.familiar03" :disabled="!isStaff">
246
+            <div><el-radio :label="0">生疏</el-radio></div>
247
+            <div><el-radio :label="2">熟练</el-radio></div>
248
+            <div><el-radio :label="3">精通</el-radio></div>
249
+          </el-radio-group>
250
+        </td>
251
+        <td rowspan="3">
252
+          <div>{{ tableForm.remark03 }}</div>
253
+        </td>
254
+        <td rowspan="3">
255
+          <el-radio-group v-model="tableForm.quality03" :disabled="!isPiLeader">
256
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
257
+              <el-radio :key="dict.value" :label="dict.value"
258
+                @click.native.prevent="cancelSelect(dict.value, 'quality03')">
259
+                {{ dict.label }}
260
+              </el-radio>
261
+            </div>
262
+          </el-radio-group>
263
+        </td>
264
+        <td rowspan="3">
265
+          <el-radio-group v-model="tableForm.skill03" :disabled="!isPiLeader">
266
+            <div v-for="dict in dict.type.cmc_skill" style="text-align:left">
267
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'skill03')">
268
+                {{ dict.label }}
269
+              </el-radio>
270
+            </div>
271
+          </el-radio-group>
272
+        </td>
273
+        <td rowspan="3">
274
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice03" :disabled="!isPiLeader">
275
+          </el-input>
276
+        </td>
277
+      </tr>
278
+      <tr>
279
+        <td>校核</td>
280
+        <td>项</td>
281
+        <td>
282
+          <span v-if="!isStaff">{{ tableForm.f0302 }}</span>
283
+          <el-input v-if="isStaff" v-model="tableForm.f0302"></el-input>
284
+        </td>
285
+      </tr>
286
+      <tr>
287
+        <td>审查</td>
288
+        <td>项</td>
289
+        <td>
290
+          <span v-if="!isStaff">{{ tableForm.f0303 }}</span>
291
+          <el-input v-if="isStaff" v-model="tableForm.f0303"></el-input>
292
+        </td>
293
+      </tr>
294
+
295
+      <tr style="height:90px;">
296
+        <td>其他工作</td>
297
+        <td colspan="9">
298
+          <span v-if="!isStaff">{{ tableForm.otherWork }}</span>
299
+          <el-input v-if="isStaff" v-model="tableForm.otherWork" type="textarea" :rows="2"></el-input>
300
+        </td>
301
+      </tr>
302
+      <tr style="height:90px;">
303
+        <td>年度自述</td>
304
+        <td colspan="9">
305
+          <span v-if="!isStaff">{{ tableForm.selfAssess }}</span>
306
+          <el-input v-if="isStaff" v-model="tableForm.selfAssess" type="textarea" :rows="2"></el-input>
307
+        </td>
308
+      </tr>
309
+    </table>
310
+    <el-row justify="center" type="flex" style="margin-top:20px;"
311
+      v-if="tableForm.taskName == undefined || tableForm.taskName == '员工修改'">
312
+      <el-button type="primary" @click="submit">提交</el-button>
313
+      <el-button>取消</el-button>
314
+    </el-row>
315
+  </div>
316
+</template>
317
+
318
+<script>
319
+import { JYContent } from '@/assets/datas/JYContent'
320
+import { getDicts as getDicts } from '@/api/system/dict/data'
321
+export default {
322
+  dicts: ['cmc_role', 'cmc_skill', 'cmc_accessment'],
323
+  props: {
324
+    tableForm: {
325
+      type: Object,
326
+      required: true
327
+    },
328
+  },
329
+  watch: {
330
+    tableForm: function (newval, oldval) {
331
+      this.formatForm();
332
+    }
333
+  },
334
+  data() {
335
+    return {
336
+      form: {},
337
+      radio1: "",
338
+      radio2: "",
339
+      textarea1: "",
340
+      textarea2: "",
341
+      isDeptLeader: false,
342
+      isPiLeader: false,
343
+      isManager: false,
344
+      isStaff: false,
345
+    }
346
+  },
347
+  created() {
348
+    this.initForm();
349
+  },
350
+  mounted() {
351
+    this.formatForm();
352
+  },
353
+  methods: {
354
+    initForm() {
355
+
356
+    },
357
+    formatForm() {
358
+      if (this.tableForm.taskName == '项目负责人审核') {
359
+        this.isPiLeader = true;
360
+        this.isDeptLeader = false;
361
+        this.isManager = false;
362
+        this.isStaff = false;
363
+      } else if (this.tableForm.taskName == '部门审核') {
364
+        this.isPiLeader = false;
365
+        this.isDeptLeader = true;
366
+        this.isManager = false;
367
+        this.isStaff = false;
368
+      } else if (this.tableForm.taskName == '分管领导审核') {
369
+        this.isPiLeader = false;
370
+        this.isDeptLeader = false;
371
+        this.isManager = true;
372
+        this.isStaff = false;
373
+      } else if (this.tableForm.taskName == '员工修改') {
374
+        this.isPiLeader = false;
375
+        this.isDeptLeader = false;
376
+        this.isManager = false;
377
+        this.isStaff = true;
378
+      }
379
+    },
380
+    submit() {
381
+      if(!this.isStaff){
382
+        this.$emit('submit', this.tableForm);
383
+      }else{
384
+        this.$emit('submit', this.tableForm);
385
+      }
386
+      
387
+    },
388
+    cancelSelect(value, name) {
389
+      debugger
390
+      if (!this.isPiLeader) {
391
+        return
392
+      }
393
+      if (this.tableForm[name] == value) {
394
+        this.tableForm[name] = null
395
+      } else {
396
+
397
+        if (this.tableForm[name] !== undefined)
398
+          this.tableForm[name] = value
399
+      }
400
+    }
401
+  },
402
+}
403
+</script>
404
+
405
+<style lang="scss" scoped>
406
+.table {
407
+  border-collapse: collapse;
408
+  width: 100%;
409
+}
410
+
411
+.table-title {
412
+  background-color: #dad4d4;
413
+}
414
+
415
+.table,
416
+th,
417
+td {
418
+  border: 1px solid black;
419
+  text-align: center;
420
+}
421
+
422
+td {
423
+  height: 24px;
424
+  width: 100px;
425
+}
426
+
427
+.head {
428
+  background-color: #ccc;
429
+}
430
+
431
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after {
432
+  border-color: #fff;
433
+}
434
+
435
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
436
+  background-color: #409eff;
437
+  border-color: #409eff;
438
+}
439
+
440
+::v-deep .el-checkbox__input.is-disabled+span.el-checkbox__label {
441
+  color: #000;
442
+}
443
+
444
+::v-deep .el-checkbox__label {
445
+  font-size: 12px;
446
+}
447
+
448
+::v-deep .el-radio__input.is-disabled .el-radio__inner,
449
+.el-radio__input.is-disabled.is-checked .el-radio__inner {
450
+  background-color: #f1f1f1;
451
+  border-color: #f1f1f1;
452
+}
453
+
454
+::v-deep .el-radio__input.is-disabled+span.el-radio__label {
455
+  color: #000;
456
+}
457
+
458
+
459
+::v-deep .el-radio__input.is-checked .el-radio__inner::after {
460
+  content: "";
461
+  width: 10px;
462
+  height: 5px;
463
+  border: 2px solid #409eff;
464
+  border-top: transparent;
465
+  border-right: transparent;
466
+  text-align: center;
467
+  display: block;
468
+  position: absolute;
469
+  top: 2px;
470
+  left: 2px;
471
+  vertical-align: middle;
472
+  transform: rotate(-45deg);
473
+  border-radius: 0px;
474
+  background: none;
475
+}
476
+</style>

+ 248
- 0
oa-ui/src/views/flowable/form/xmForm.vue 查看文件

@@ -0,0 +1,248 @@
1
+<!--
2
+ * @Author: ysh
3
+ * @Date: 2024-01-19 16:29:01
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-02-20 15:08:09
6
+-->
7
+<template>
8
+  <div>
9
+    <el-form ref="scform" :model="form">
10
+      <el-form-item label="工作自述:">
11
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="请输入内容" v-model="form['selfAssess']">
12
+        </el-input>
13
+      </el-form-item>
14
+      <el-form-item label="选择考核项:">
15
+        <el-checkbox-group v-model="checkedBtn" @change="assessChangeFn">
16
+          <el-checkbox v-for="sc, index in AssessmentContent" :label="sc.label" :key="index">{{ sc.label
17
+          }}</el-checkbox>
18
+        </el-checkbox-group>
19
+      </el-form-item>
20
+      <div class="tips" v-if="tipsShow">请至少选择一项考核项</div>
21
+      <el-row type="flex" style="flex-wrap:wrap;">
22
+        <el-card v-for="item, index in checkedBtn" style="flex:1;margin:10px;min-width: 400px;max-width: 450px;"
23
+          :key="index">
24
+          <div slot="header" class="clearfix">
25
+            <strong>{{ item }}</strong>
26
+            <el-button style="float: right; padding: 3px 0" type="text" @click="closeItem(item)">关闭</el-button>
27
+          </div>
28
+          <el-scrollbar style="height: 500px;">
29
+            <div v-for="ass in AssessmentContent" v-if="ass.label == item">
30
+              <table border="1" cellspacing="0" align="center" cellpadding="5">
31
+                <tr style="background-color:#409EFF;color:#fff;">
32
+                  <td>等级、比例尺等</td>
33
+                  <td>工作量</td>
34
+                  <td>单位</td>
35
+                </tr>
36
+                <tr v-for="child in ass.children">
37
+                  <td v-if="!Array.isArray(child.label)">{{ child.label }}</td>
38
+                  <td v-else>
39
+                    <el-checkbox-group v-model="form.f07">
40
+                      <el-checkbox v-for="label, index in child.label" :label="label" :key="'k' + index"></el-checkbox>
41
+                    </el-checkbox-group>
42
+                  </td>
43
+                  <td v-if="Array.isArray(child.label)">
44
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
45
+                  </td>
46
+                  <td v-if="!Array.isArray(child.label)">
47
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
48
+                  </td>
49
+                  <td>{{ child.unit }}</td>
50
+                </tr>
51
+                <tr>
52
+                  <td>熟练程度</td>
53
+                  <td colspan="2">
54
+                    <el-radio-group v-model="form['familiar' + ass.value.slice(-2)]">
55
+                      <el-radio :label="0">生疏</el-radio>
56
+                      <el-radio :label="2">熟练</el-radio>
57
+                      <el-radio :label="3">精通</el-radio>
58
+                    </el-radio-group>
59
+                  </td>
60
+                </tr>
61
+                <tr>
62
+                  <td>备注</td>
63
+                  <td colspan="2">
64
+                    <el-input type="textarea" :rows="2" placeholder="请输入内容"
65
+                      v-model="form['remark' + ass.value.slice(-2)]">
66
+                    </el-input>
67
+                  </td>
68
+                </tr>
69
+              </table>
70
+              <div class="tips" v-if="inputTips">工作量只能输入数字</div>
71
+            </div>
72
+          </el-scrollbar>
73
+        </el-card>
74
+      </el-row>
75
+      <el-form-item label="其他工作:">
76
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="有其他工作请在此写入内容" v-model="form['otherWork']">
77
+        </el-input>
78
+      </el-form-item>
79
+      <el-row>
80
+        <el-button @click="generateForm" type="primary">生成考核表</el-button>
81
+      </el-row>
82
+    </el-form>
83
+    <el-dialog title="" :visible.sync="taskOpen" width="65%" append-to-body>
84
+      <XmTable :tableForm="noNullForm" ref="xmTable" @submit="submit"></XmTable>
85
+    </el-dialog>
86
+  </div>
87
+</template>
88
+
89
+<script>
90
+import { XMContent } from '@/assets/datas/XMContent'
91
+import { MessageBox } from 'element-ui'
92
+import { Snowflake } from '@/utils/snowFlake.js'
93
+import { submitAssess } from '@/api/oa/assess/assess.js'
94
+import { listProject } from '@/api/oa/project/project.js'
95
+import { getProject } from '@/api/oa/project/project'
96
+import XmTable from './xmTable.vue'
97
+export default {
98
+  dicts: ['cmc_skill'],
99
+  components: { XmTable },
100
+  data() {
101
+    return {
102
+      checkedBtn: [],
103
+      AssessmentContent: XMContent,
104
+      projectList: [],
105
+      form: {},
106
+      noNullForm: {},
107
+      taskOpen: false,
108
+      tipsShow: false,
109
+      inputTips: false
110
+    };
111
+  },
112
+  created() {
113
+    this.initForm();
114
+  },
115
+  watch: {},
116
+  mounted() {
117
+
118
+  },
119
+  methods: {
120
+    initForm() {
121
+      listProject({ pageSize: 200 }).then(res => {
122
+        this.projectList = res.rows;
123
+      })
124
+    },
125
+    // 提交表单
126
+    submit(tableForm) {
127
+      MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
128
+        tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
129
+        tableForm.disabled = true;
130
+        console.log(tableForm);
131
+        let formData = new FormData();
132
+        let form = JSON.stringify(tableForm);
133
+        formData.append("form", form);
134
+        submitAssess(formData).then(res => {
135
+        debugger
136
+          this.taskOpen = false;
137
+          this.$emit('submit', tableForm);
138
+        });
139
+      }).catch(() => {
140
+      });
141
+    },
142
+    // 生成考核表格
143
+    generateForm() {
144
+      let flag = 0;
145
+      if (this.checkedBtn.length == 0) {
146
+        this.tipsShow = true;
147
+        return
148
+      }
149
+      for (let f in this.form) {
150
+        if (this.form[f] != "" && this.form[f] != [] && this.form[f] !== undefined) {
151
+          this.$set(this.noNullForm, f, this.form[f])
152
+        }
153
+        if (f.indexOf('familiar') != -1) {
154
+          this.$set(this.noNullForm, f, this.form[f])
155
+        }
156
+      }
157
+      for (let btn of this.checkedBtn) {
158
+        let ids = this.changeLabelToValue(btn);
159
+        if (this.form['familiar' + ids] == undefined) {
160
+          this.$message.error('熟练程度为必填项,请完善!');
161
+          flag = 0
162
+          break
163
+        } else {
164
+          flag = 1
165
+        }
166
+      }
167
+      if (flag) {
168
+        this.taskOpen = true;
169
+        if (this.$refs.xmTable != undefined) {
170
+          this.$refs.xmTable.formatForm();
171
+        }
172
+      }
173
+    },
174
+    getProjectById(id) {
175
+      getProject(id).then(res => {
176
+        if (res.data != undefined) {
177
+          this.form.projectName = res.data.projectName;
178
+          this.form.projectNumber = res.data.projectNumber;
179
+        }
180
+      })
181
+    },
182
+    closeItem(item) {
183
+      let index = this.checkedBtn.indexOf(item);
184
+      let number;
185
+      if (index !== -1) {
186
+        this.checkedBtn.splice(index, 1);
187
+      }
188
+      for (let i of XMContent) {
189
+        if (i.label == item) {
190
+          number = i.value;
191
+        }
192
+      }
193
+      for (let fkey in this.form) {
194
+        if (fkey.substring(0, 3) == number) {
195
+          if (typeof (this.form[fkey]) == 'string') {
196
+            this.form[fkey] = "";
197
+          }
198
+          else if (Array.isArray(this.form[fkey])) {
199
+            this.form[fkey] = [];
200
+          }
201
+        }
202
+        this.form['familiar' + number.substring(1, 3)] = undefined;
203
+        this.form['remark' + number.substring(1, 3)] = "";
204
+      }
205
+    },
206
+    assessChangeFn(val) {
207
+      if (val.length != 0) {
208
+        this.tipsShow = false;
209
+      }
210
+    },
211
+    mustNumber(val, event) {
212
+      let regex = /^\d+(\.\d{1,2})?$/;
213
+      let newElement = document.createElement("div");
214
+      newElement.innerHTML = '工作量必须是数字';
215
+      newElement.classList.add('inputTips');
216
+      if (regex.test(val) || val == "") {
217
+        this.inputTips = false;
218
+      } else {
219
+        this.inputTips = true;
220
+        event.target.parentNode.appendChild(newElement, event.target)
221
+      }
222
+    },
223
+    changeLabelToValue(label) {
224
+      for (let s of XMContent) {
225
+        if (s.label == label) {
226
+          return s.value.slice(-2)
227
+        }
228
+      }
229
+    }
230
+  }
231
+}
232
+</script>
233
+
234
+<style lang="scss" scoped>
235
+.tips {
236
+  color: #f00;
237
+  font-size: 12px;
238
+  line-height: 18px;
239
+}
240
+</style>
241
+<style>
242
+.inputTips {
243
+  color: #f00;
244
+  font-size: 12px;
245
+  line-height: 18px;
246
+  display: block;
247
+}
248
+</style>

+ 488
- 0
oa-ui/src/views/flowable/form/xmTable.vue 查看文件

@@ -0,0 +1,488 @@
1
+<template>
2
+  <div style="padding:10px">
3
+    <h2 style="text-align: center;">项目管理部考核表</h2>
4
+    <table class="table" ref="tableDatas">
5
+      <tr>
6
+        <td class="table-title">姓名</td>
7
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.nickName }}</td>
8
+        <td class="table-title">考核年度</td>
9
+        <td> {{ tableForm.assessTime }}</td>
10
+        <td colspan="3" class="table-title">部门负责人考核意见</td>
11
+        <td colspan="3" class="table-title" style="width:300px;">分管领导考核意见</td>
12
+      </tr>
13
+      <tr>
14
+        <td class="table-title">所在部门</td>
15
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.deptName }}</td>
16
+        <td colspan="3">
17
+          <el-radio-group v-model="tableForm.deptAssessment" :disabled="!isDeptLeader">
18
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
19
+              {{ dict.label }}
20
+            </el-radio>
21
+          </el-radio-group>
22
+        </td>
23
+        <td colspan="3">
24
+          <el-radio-group v-model="tableForm.managerAssessment" :disabled="!isManager">
25
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
26
+              {{ dict.label }}
27
+            </el-radio>
28
+          </el-radio-group>
29
+        </td>
30
+      </tr>
31
+      <tr>
32
+        <td class="table-title">部门职务</td>
33
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.postGroup }}</td>
34
+        <td colspan="3" rowspan="3">
35
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.deptAdvice" :disabled="!isDeptLeader">
36
+          </el-input>
37
+          <el-row justify="center" type="flex">
38
+            <el-col :span="12">考核人:<el-input v-model="tableForm.deptAssesser" style="width:150px;" placeholder="请输入考核人" :disabled="!isDeptLeader"></el-input> </el-col>
39
+            <el-col :span="12">日期:<el-date-picker type="date"  placeholder="请选择考核日期" v-model="tableForm.deptTime" style="width:150px;" :disabled="!isDeptLeader"></el-date-picker> </el-col>
40
+          </el-row>
41
+        </td>
42
+        <td colspan="3" rowspan="3">
43
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.managerAdvice" :disabled="!isManager">
44
+          </el-input>
45
+          <el-row justify="center">
46
+            <el-col :span="12">考核人:<el-input v-model="tableForm.managerAssesser" style="width:150px;" placeholder="请输入考核人" :disabled="!isManager"></el-input></el-col>
47
+            <el-col :span="12">日期:<el-date-picker type="date"  placeholder="请选择考核日期" v-model="tableForm.managerTime" style="width:150px;" :disabled="!isManager"></el-date-picker></el-col>
48
+          </el-row>
49
+        </td>
50
+      </tr>
51
+      <tr>
52
+        <td class="table-title">技术职称</td>
53
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.titles }}</td>
54
+      </tr>
55
+      <tr>
56
+        <td class="table-title">入职年月</td>
57
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.entryDate }}</td>
58
+        <td class="table-title">年龄</td>
59
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.age }}</td>
60
+      </tr>
61
+      <tr>
62
+        <td rowspan="2" class="table-title">考核内容</td>
63
+        <td colspan="5" class="table-title">被考核人填写</td>
64
+        <td colspan="3" class="table-title" style="width:300px;">项目负责人考核</td>
65
+      </tr>
66
+      <tr>
67
+        <td class="table-title">工作内容</td>
68
+        <td class="table-title">单位</td>
69
+        <td class="table-title">工作量</td>
70
+        <td class="table-title">熟练程度</td>
71
+        <td class="table-title">备注</td>
72
+        <td class="table-title">工作量</td>
73
+        <td class="table-title">岗位综合表现</td>
74
+        <td class="table-title">考核建议</td>
75
+      </tr>
76
+      <tr>
77
+        <td rowspan="6">参与生产</td>
78
+        <td>项目负责</td>
79
+        <td>项</td>
80
+        <td class="personInput">
81
+          <span v-if="!isStaff">{{ tableForm.f0101 }}</span>
82
+          <el-input v-if="isStaff" v-model="tableForm.f0101"></el-input>
83
+        </td>
84
+        <td rowspan="6">
85
+          <el-radio-group v-model="tableForm.familiar01" :disabled="!isStaff">
86
+            <div><el-radio :label="0">生疏</el-radio></div>
87
+            <div><el-radio :label="2">熟练</el-radio></div>
88
+            <div><el-radio :label="3">精通</el-radio></div>
89
+          </el-radio-group>
90
+        </td>
91
+        
92
+        <td rowspan="6">
93
+          <div>{{ tableForm.remark01 }}</div>
94
+        </td>
95
+        <td rowspan="6">
96
+          <el-radio-group v-model="tableForm.quality01" :disabled="!isPiLeader">
97
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
98
+              <el-radio :key="dict.value" :label="dict.value"
99
+                @click.native.prevent="cancelSelect(dict.value, 'quality01')">
100
+                {{ dict.label }}
101
+              </el-radio>
102
+            </div>
103
+          </el-radio-group>
104
+        </td>
105
+        <td rowspan="6">
106
+          <el-radio-group v-model="tableForm.assessment01" :disabled="!isPiLeader">
107
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
108
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'assessment01')">
109
+                {{ dict.label }}
110
+              </el-radio>
111
+            </div>
112
+          </el-radio-group>
113
+        </td>
114
+        <td rowspan="6" >
115
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice01" :disabled="!isPiLeader">
116
+          </el-input>
117
+        </td>
118
+      </tr>
119
+      <tr>
120
+        <td>外业负责</td>
121
+        <td>项</td>
122
+        <td class="personInput">
123
+          <span v-if="!isStaff">{{ tableForm.f0102 }}</span>
124
+          <el-input v-if="isStaff" v-model="tableForm.f0102"></el-input>
125
+        </td>
126
+      </tr>
127
+      <tr>
128
+        <td>内业负责</td>
129
+        <td>项</td>
130
+        <td class="personInput">
131
+          <span v-if="!isStaff">{{ tableForm.f0103 }}</span>
132
+          <el-input v-if="isStaff" v-model="tableForm.f0103"></el-input>
133
+        </td>
134
+      </tr>
135
+      <tr>
136
+        <td>参与外业</td>
137
+        <td>项</td>
138
+        <td class="personInput">
139
+          <span v-if="!isStaff">{{ tableForm.f0104 }}</span>
140
+          <el-input v-if="isStaff" v-model="tableForm.f0104"></el-input>
141
+        </td>
142
+      </tr>
143
+      <tr>
144
+        <td>参与内业</td>
145
+        <td>项</td>
146
+        <td class="personInput">
147
+          <span v-if="!isStaff">{{ tableForm.f0105 }}</span>
148
+          <el-input v-if="isStaff" v-model="tableForm.f0105"></el-input>
149
+        </td>
150
+      </tr>
151
+      <tr>
152
+        <td>资料整编</td>
153
+        <td>项</td>
154
+        <td class="personInput">
155
+          <span v-if="!isStaff">{{ tableForm.f0106 }}</span>
156
+          <el-input v-if="isStaff" v-model="tableForm.f0106">
157
+          </el-input>
158
+        </td>
159
+      </tr>
160
+
161
+      <!--  -->
162
+      <tr>
163
+        <td rowspan="6">项目管理</td>
164
+        <td>项目备案</td>
165
+        <td>项</td>
166
+        <td class="personInput">
167
+          <span v-if="!isStaff">{{ tableForm.f0201 }}</span>
168
+          <el-input v-if="isStaff" v-model="tableForm.f0201"></el-input>
169
+        </td>
170
+        <td rowspan="6">
171
+          <el-radio-group v-model="tableForm.familiar02" :disabled="!isStaff">
172
+            <div><el-radio :label="0">生疏</el-radio></div>
173
+            <div><el-radio :label="2">熟练</el-radio></div>
174
+            <div><el-radio :label="3">精通</el-radio></div>
175
+          </el-radio-group>
176
+        </td>
177
+        <td rowspan="6">
178
+          <div>{{ tableForm.remark02 }}</div>
179
+        </td>
180
+        <td rowspan="6">
181
+          <el-radio-group v-model="tableForm.quality02" :disabled="!isPiLeader">
182
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
183
+              <el-radio :key="dict.value" :label="dict.value"
184
+                @click.native.prevent="cancelSelect(dict.value, 'quality02')">
185
+                {{ dict.label }}
186
+              </el-radio>
187
+            </div>
188
+          </el-radio-group>
189
+        </td>
190
+        <td rowspan="6">
191
+          <el-radio-group v-model="tableForm.assessment02" :disabled="!isPiLeader">
192
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
193
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'assessment02')">
194
+                {{ dict.label }}
195
+              </el-radio>
196
+            </div>
197
+          </el-radio-group>
198
+        </td>
199
+        <td rowspan="6">
200
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice02" :disabled="!isPiLeader">
201
+          </el-input>
202
+        </td>
203
+      </tr>
204
+      <tr>
205
+        <td>项目预算</td>
206
+        <td>项</td>
207
+        <td>
208
+          <span v-if="!isStaff">{{ tableForm.f0202 }}</span>
209
+          <el-input v-if="isStaff" v-model="tableForm.f0202"></el-input>
210
+        </td>
211
+      </tr>
212
+      <tr>
213
+        <td>任务分发</td>
214
+        <td>项</td>
215
+        <td>
216
+          <span v-if="!isStaff">{{ tableForm.f0203 }}</span>
217
+          <el-input v-if="isStaff" v-model="tableForm.f0203"></el-input>
218
+        </td>
219
+      </tr>
220
+      <tr>
221
+        <td>项目交底</td>
222
+        <td>项</td>
223
+        <td>
224
+          <span v-if="!isStaff">{{ tableForm.f0204 }}</span>
225
+          <el-input v-if="isStaff" v-model="tableForm.f0204"></el-input>
226
+        </td>
227
+      </tr>
228
+      <tr>
229
+        <td>项目内部结算</td>
230
+        <td>项</td>
231
+        <td>
232
+          <span v-if="!isStaff">{{ tableForm.f0205 }}</span>
233
+          <el-input v-if="isStaff" v-model="tableForm.f0205"></el-input>
234
+        </td>
235
+      </tr>
236
+      <tr>
237
+        <td>顾客回访</td>
238
+        <td>项</td>
239
+        <td>
240
+          <span v-if="!isStaff">{{ tableForm.f0206 }}</span>
241
+          <el-input v-if="isStaff" v-model="tableForm.f0206"></el-input>
242
+        </td>
243
+      </tr>
244
+
245
+
246
+
247
+      <!--  -->
248
+      <tr>
249
+        <td rowspan="3">委外管理</td>
250
+        <td>委外合同办理</td>
251
+        <td>项</td>
252
+        <td class="personInput">
253
+          <span v-if="!isStaff">{{ tableForm.f0301 }}</span>
254
+          <el-input v-if="isStaff" v-model="tableForm.f0301"></el-input>
255
+        </td>
256
+        <td rowspan="3">
257
+          <el-radio-group v-model="tableForm.familiar03" :disabled="!isStaff">
258
+            <div><el-radio :label="0">生疏</el-radio></div>
259
+            <div><el-radio :label="2">熟练</el-radio></div>
260
+            <div><el-radio :label="3">精通</el-radio></div>
261
+          </el-radio-group>
262
+        </td>
263
+        <td rowspan="3">
264
+          <div>{{ tableForm.remark03 }}</div>
265
+        </td>
266
+        <td rowspan="3">
267
+          <el-radio-group v-model="tableForm.quality03" :disabled="!isPiLeader">
268
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
269
+              <el-radio :key="dict.value" :label="dict.value"
270
+                @click.native.prevent="cancelSelect(dict.value, 'quality03')">
271
+                {{ dict.label }}
272
+              </el-radio>
273
+            </div>
274
+          </el-radio-group>
275
+        </td>
276
+        <td rowspan="3">
277
+          <el-radio-group v-model="tableForm.assessment03" :disabled="!isPiLeader">
278
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
279
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'assessment03')">
280
+                {{ dict.label }}
281
+              </el-radio>
282
+            </div>
283
+          </el-radio-group>
284
+        </td>
285
+        <td rowspan="3">
286
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice03" :disabled="!isPiLeader">
287
+          </el-input>
288
+        </td>
289
+      </tr>
290
+      <tr>
291
+        <td>委外支付办理</td>
292
+        <td>项</td>
293
+        <td>
294
+          <span v-if="!isStaff">{{ tableForm.f0302 }}</span>
295
+          <el-input v-if="isStaff" v-model="tableForm.f0302"></el-input>
296
+        </td>
297
+      </tr>
298
+      <tr>
299
+        <td>合格分包商管理</td>
300
+        <td>项</td>
301
+        <td>
302
+          <span v-if="!isStaff">{{ tableForm.f0303 }}</span>
303
+          <el-input v-if="isStaff" v-model="tableForm.f0303"></el-input>
304
+        </td>
305
+      </tr>
306
+<!--  -->
307
+      <tr style="height:90px;">
308
+        <td>其他工作</td>
309
+        <td colspan="9">
310
+          <span v-if="!isStaff">{{ tableForm.otherWork }}</span>
311
+          <el-input v-if="isStaff" v-model="tableForm.otherWork" type="textarea" :rows="2"></el-input>
312
+        </td>
313
+      </tr>
314
+      <tr style="height:90px;">
315
+        <td>年度自述</td>
316
+        <td colspan="9">
317
+          <span v-if="!isStaff">{{ tableForm.selfAssess }}</span>
318
+          <el-input v-if="isStaff" v-model="tableForm.selfAssess" type="textarea" :rows="2"></el-input>
319
+        </td>
320
+      </tr>
321
+    </table>
322
+    <el-row justify="center" type="flex" style="margin-top:20px;"
323
+      v-if="tableForm.taskName == undefined || tableForm.taskName == '员工修改'">
324
+      <el-button type="primary" @click="submit">提交</el-button>
325
+      <el-button>取消</el-button>
326
+    </el-row>
327
+  </div>
328
+</template>
329
+
330
+<script>
331
+import { XMContent } from '@/assets/datas/XMContent'
332
+import { getDicts as getDicts } from '@/api/system/dict/data'
333
+export default {
334
+  dicts: ['cmc_role', 'cmc_skill', 'cmc_accessment','cmc_workload'],
335
+  props: {
336
+    tableForm: {
337
+      type: Object,
338
+      required: true
339
+    },
340
+  },
341
+  watch: {
342
+    tableForm: function (newval, oldval) {
343
+      this.formatForm();
344
+    }
345
+  },
346
+  data() {
347
+    return {
348
+      form: {},
349
+      radio1: "",
350
+      radio2: "",
351
+      textarea1: "",
352
+      textarea2: "",
353
+      isDeptLeader: false,
354
+      isPiLeader: false,
355
+      isManager: false,
356
+      isStaff: false,
357
+    }
358
+  },
359
+  created() {
360
+    this.initForm();
361
+  },
362
+  mounted() {
363
+    this.formatForm();
364
+  },
365
+  methods: {
366
+    initForm() {
367
+
368
+    },
369
+    formatForm() {
370
+      if (this.tableForm.taskName == '项目负责人审核') {
371
+        this.isPiLeader = true;
372
+        this.isDeptLeader = false;
373
+        this.isManager = false;
374
+        this.isStaff = false;
375
+      } else if (this.tableForm.taskName == '部门审核') {
376
+        this.isPiLeader = false;
377
+        this.isDeptLeader = true;
378
+        this.isManager = false;
379
+        this.isStaff = false;
380
+      } else if (this.tableForm.taskName == '分管领导审核') {
381
+        this.isPiLeader = false;
382
+        this.isDeptLeader = false;
383
+        this.isManager = true;
384
+        this.isStaff = false;
385
+      } else if (this.tableForm.taskName == '员工修改') {
386
+        this.isPiLeader = false;
387
+        this.isDeptLeader = false;
388
+        this.isManager = false;
389
+        this.isStaff = true;
390
+      }
391
+    },
392
+    submit() {
393
+      if(!this.isStaff){
394
+        this.$emit('submit', this.tableForm);
395
+      }else{
396
+        this.$emit('submit', this.tableForm);
397
+      }
398
+      
399
+    },
400
+    cancelSelect(value, name) {
401
+      debugger
402
+      if (!this.isPiLeader) {
403
+        return
404
+      }
405
+      if (this.tableForm[name] == value) {
406
+        this.tableForm[name] = null
407
+      } else {
408
+
409
+        if (this.tableForm[name] !== undefined)
410
+          this.tableForm[name] = value
411
+      }
412
+    }
413
+  },
414
+}
415
+</script>
416
+
417
+<style lang="scss" scoped>
418
+.table {
419
+  border-collapse: collapse;
420
+  width: 100%;
421
+}
422
+
423
+.table-title {
424
+  background-color: #dad4d4;
425
+}
426
+
427
+.table,
428
+th,
429
+td {
430
+  border: 1px solid black;
431
+  text-align: center;
432
+}
433
+
434
+td {
435
+  height: 24px;
436
+  width: 100px;
437
+}
438
+
439
+.head {
440
+  background-color: #ccc;
441
+}
442
+
443
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after {
444
+  border-color: #fff;
445
+}
446
+
447
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
448
+  background-color: #409eff;
449
+  border-color: #409eff;
450
+}
451
+
452
+::v-deep .el-checkbox__input.is-disabled+span.el-checkbox__label {
453
+  color: #000;
454
+}
455
+
456
+::v-deep .el-checkbox__label {
457
+  font-size: 12px;
458
+}
459
+
460
+::v-deep .el-radio__input.is-disabled .el-radio__inner,
461
+.el-radio__input.is-disabled.is-checked .el-radio__inner {
462
+  background-color: #f1f1f1;
463
+  border-color: #f1f1f1;
464
+}
465
+
466
+::v-deep .el-radio__input.is-disabled+span.el-radio__label {
467
+  color: #000;
468
+}
469
+
470
+
471
+::v-deep .el-radio__input.is-checked .el-radio__inner::after {
472
+  content: "";
473
+  width: 10px;
474
+  height: 5px;
475
+  border: 2px solid #409eff;
476
+  border-top: transparent;
477
+  border-right: transparent;
478
+  text-align: center;
479
+  display: block;
480
+  position: absolute;
481
+  top: 2px;
482
+  left: 2px;
483
+  vertical-align: middle;
484
+  transform: rotate(-45deg);
485
+  border-radius: 0px;
486
+  background: none;
487
+}
488
+</style>

+ 248
- 0
oa-ui/src/views/flowable/form/zhForm.vue 查看文件

@@ -0,0 +1,248 @@
1
+<!--
2
+ * @Author: ysh
3
+ * @Date: 2024-01-19 16:29:01
4
+ * @LastEditors: Please set LastEditors
5
+ * @LastEditTime: 2024-02-20 16:21:05
6
+-->
7
+<template>
8
+  <div>
9
+    <el-form ref="scform" :model="form">
10
+      <el-form-item label="工作自述:">
11
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="请输入内容" v-model="form['selfAssess']">
12
+        </el-input>
13
+      </el-form-item>
14
+      <el-form-item label="选择考核项:">
15
+        <el-checkbox-group v-model="checkedBtn" @change="assessChangeFn">
16
+          <el-checkbox v-for="sc, index in AssessmentContent" :label="sc.label" :key="index">{{ sc.label
17
+          }}</el-checkbox>
18
+        </el-checkbox-group>
19
+      </el-form-item>
20
+      <div class="tips" v-if="tipsShow">请至少选择一项考核项</div>
21
+      <el-row type="flex" style="flex-wrap:wrap;">
22
+        <el-card v-for="item, index in checkedBtn" style="flex:1;margin:10px;min-width: 400px;max-width: 450px;"
23
+          :key="index">
24
+          <div slot="header" class="clearfix">
25
+            <strong>{{ item }}</strong>
26
+            <el-button style="float: right; padding: 3px 0" type="text" @click="closeItem(item)">关闭</el-button>
27
+          </div>
28
+          <el-scrollbar style="height: 500px;">
29
+            <div v-for="ass in AssessmentContent" v-if="ass.label == item">
30
+              <table border="1" cellspacing="0" align="center" cellpadding="5">
31
+                <tr style="background-color:#409EFF;color:#fff;">
32
+                  <td>等级、比例尺等</td>
33
+                  <td>工作量</td>
34
+                  <td>单位</td>
35
+                </tr>
36
+                <tr v-for="child in ass.children">
37
+                  <td v-if="!Array.isArray(child.label)">{{ child.label }}</td>
38
+                  <td v-else>
39
+                    <el-checkbox-group v-model="form.f07">
40
+                      <el-checkbox v-for="label, index in child.label" :label="label" :key="'k' + index"></el-checkbox>
41
+                    </el-checkbox-group>
42
+                  </td>
43
+                  <td v-if="Array.isArray(child.label)">
44
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
45
+                  </td>
46
+                  <td v-if="!Array.isArray(child.label)">
47
+                    <el-input v-model="form[child.value]" style="width: 100%"></el-input>
48
+                  </td>
49
+                  <td>{{ child.unit }}</td>
50
+                </tr>
51
+                <tr>
52
+                  <td>参与情况</td>
53
+                  <td colspan="2">
54
+                    <el-radio-group v-model="form['role' + ass.value.slice(-2)]">
55
+                      <el-radio label="00">主办</el-radio>
56
+                      <el-radio label="01">参与</el-radio>
57
+                      <el-radio label="02">协助</el-radio>
58
+                    </el-radio-group>
59
+                  </td>
60
+                </tr>
61
+                <tr>
62
+                  <td>备注</td>
63
+                  <td colspan="2">
64
+                    <el-input type="textarea" :rows="2" placeholder="请输入内容"
65
+                      v-model="form['remark' + ass.value.slice(-2)]">
66
+                    </el-input>
67
+                  </td>
68
+                </tr>
69
+              </table>
70
+              <div class="tips" v-if="inputTips">工作量只能输入数字</div>
71
+            </div>
72
+          </el-scrollbar>
73
+        </el-card>
74
+      </el-row>
75
+      <el-form-item label="其他工作:">
76
+        <el-input style="width:900px" type="textarea" :rows="2" placeholder="有其他工作请在此写入内容" v-model="form['otherWork']">
77
+        </el-input>
78
+      </el-form-item>
79
+      <el-row>
80
+        <el-button @click="generateForm" type="primary">生成考核表</el-button>
81
+      </el-row>
82
+    </el-form>
83
+    <el-dialog title="" :visible.sync="taskOpen" width="65%" append-to-body>
84
+      <ZhTable :tableForm="noNullForm" ref="zhTable" @submit="submit"></ZhTable>
85
+    </el-dialog>
86
+  </div>
87
+</template>
88
+
89
+<script>
90
+import { ZHContent } from '@/assets/datas/ZHContent'
91
+import { MessageBox } from 'element-ui'
92
+import { Snowflake } from '@/utils/snowFlake.js'
93
+import { submitAssess } from '@/api/oa/assess/assess.js'
94
+import { listProject } from '@/api/oa/project/project.js'
95
+import { getProject } from '@/api/oa/project/project'
96
+import ZhTable from './zhTable.vue';
97
+export default {
98
+  dicts: ['cmc_skill'],
99
+  components: { ZhTable },
100
+  data() {
101
+    return {
102
+      checkedBtn: [],
103
+      AssessmentContent: ZHContent,
104
+      projectList: [],
105
+      form: {},
106
+      noNullForm: {},
107
+      taskOpen: false,
108
+      tipsShow: false,
109
+      inputTips: false
110
+    };
111
+  },
112
+  created() {
113
+    this.initForm();
114
+  },
115
+  watch: {},
116
+  mounted() {
117
+
118
+  },
119
+  methods: {
120
+    initForm() {
121
+      listProject({ pageSize: 200 }).then(res => {
122
+        this.projectList = res.rows;
123
+      })
124
+    },
125
+    // 提交表单
126
+    submit(tableForm) {
127
+      MessageBox.confirm('确认提交?', '任务提交', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
128
+        tableForm.formId = new Snowflake(1n, 1n, 0n).nextId().toString();
129
+        tableForm.disabled = true;
130
+        console.log(tableForm);
131
+        let formData = new FormData();
132
+        let form = JSON.stringify(tableForm);
133
+        formData.append("form", form);
134
+        submitAssess(formData).then(res => {
135
+        debugger
136
+          this.taskOpen = false;
137
+          this.$emit('submit', tableForm);
138
+        });
139
+      }).catch(() => {
140
+      });
141
+    },
142
+    // 生成考核表格
143
+    generateForm() {
144
+      let flag = 0;
145
+      if (this.checkedBtn.length == 0) {
146
+        this.tipsShow = true;
147
+        return
148
+      }
149
+      for (let f in this.form) {
150
+        if (this.form[f] != "" && this.form[f] != [] && this.form[f] !== undefined) {
151
+          this.$set(this.noNullForm, f, this.form[f])
152
+        }
153
+        if (f.indexOf('familiar') != -1) {
154
+          this.$set(this.noNullForm, f, this.form[f])
155
+        }
156
+      }
157
+      for (let btn of this.checkedBtn) {
158
+        let ids = this.changeLabelToValue(btn);
159
+        if (this.form['familiar' + ids] == undefined) {
160
+          this.$message.error('熟练程度为必填项,请完善!');
161
+          flag = 0
162
+          break
163
+        } else {
164
+          flag = 1
165
+        }
166
+      }
167
+      if (flag) {
168
+        this.taskOpen = true;
169
+        if (this.$refs.zhTable != undefined) {
170
+          this.$refs.zhTable.formatForm();
171
+        }
172
+      }
173
+    },
174
+    getProjectById(id) {
175
+      getProject(id).then(res => {
176
+        if (res.data != undefined) {
177
+          this.form.projectName = res.data.projectName;
178
+          this.form.projectNumber = res.data.projectNumber;
179
+        }
180
+      })
181
+    },
182
+    closeItem(item) {
183
+      let index = this.checkedBtn.indexOf(item);
184
+      let number;
185
+      if (index !== -1) {
186
+        this.checkedBtn.splice(index, 1);
187
+      }
188
+      for (let i of ZHContent) {
189
+        if (i.label == item) {
190
+          number = i.value;
191
+        }
192
+      }
193
+      for (let fkey in this.form) {
194
+        if (fkey.substring(0, 3) == number) {
195
+          if (typeof (this.form[fkey]) == 'string') {
196
+            this.form[fkey] = "";
197
+          }
198
+          else if (Array.isArray(this.form[fkey])) {
199
+            this.form[fkey] = [];
200
+          }
201
+        }
202
+        this.form['familiar' + number.substring(1, 3)] = undefined;
203
+        this.form['remark' + number.substring(1, 3)] = "";
204
+      }
205
+    },
206
+    assessChangeFn(val) {
207
+      if (val.length != 0) {
208
+        this.tipsShow = false;
209
+      }
210
+    },
211
+    mustNumber(val, event) {
212
+      let regex = /^\d+(\.\d{1,2})?$/;
213
+      let newElement = document.createElement("div");
214
+      newElement.innerHTML = '工作量必须是数字';
215
+      newElement.classList.add('inputTips');
216
+      if (regex.test(val) || val == "") {
217
+        this.inputTips = false;
218
+      } else {
219
+        this.inputTips = true;
220
+        event.target.parentNode.appendChild(newElement, event.target)
221
+      }
222
+    },
223
+    changeLabelToValue(label) {
224
+      for (let s of ZHContent) {
225
+        if (s.label == label) {
226
+          return s.value.slice(-2)
227
+        }
228
+      }
229
+    }
230
+  }
231
+}
232
+</script>
233
+
234
+<style lang="scss" scoped>
235
+.tips {
236
+  color: #f00;
237
+  font-size: 12px;
238
+  line-height: 18px;
239
+}
240
+</style>
241
+<style>
242
+.inputTips {
243
+  color: #f00;
244
+  font-size: 12px;
245
+  line-height: 18px;
246
+  display: block;
247
+}
248
+</style>

+ 904
- 0
oa-ui/src/views/flowable/form/zhTable.vue 查看文件

@@ -0,0 +1,904 @@
1
+<template>
2
+  <div style="padding:10px">
3
+    <h2 style="text-align: center;">综合事务部考核表</h2>
4
+    <table class="table" ref="tableDatas">
5
+      <tr>
6
+        <td class="table-title">姓名</td>
7
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.nickName }}</td>
8
+        <td class="table-title">考核年度</td>
9
+        <td> {{ tableForm.assessTime }}</td>
10
+        <td colspan="3" class="table-title">部门负责人考核意见</td>
11
+        <td colspan="3" class="table-title" style="width:300px">分管领导考核意见</td>
12
+      </tr>
13
+      <tr>
14
+        <td class="table-title">所在部门</td>
15
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.deptName }}</td>
16
+        <td colspan="3">
17
+          <el-radio-group v-model="tableForm.deptAssessment" :disabled="!isDeptLeader">
18
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
19
+              {{ dict.label }}
20
+            </el-radio>
21
+          </el-radio-group>
22
+        </td>
23
+        <td colspan="3">
24
+          <el-radio-group v-model="tableForm.managerAssessment" :disabled="!isManager">
25
+            <el-radio v-for="dict in dict.type.cmc_accessment" :key="dict.value" :label="dict.value">
26
+              {{ dict.label }}
27
+            </el-radio>
28
+          </el-radio-group>
29
+        </td>
30
+      </tr>
31
+      <tr>
32
+        <td class="table-title">部门职务</td>
33
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.postGroup }}</td>
34
+        <td colspan="3" rowspan="3">
35
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.deptAdvice"
36
+            :disabled="!isDeptLeader">
37
+          </el-input>
38
+          <el-row justify="center" type="flex">
39
+            <el-col :span="12">考核人:<el-input v-model="tableForm.deptAssesser" style="width:150px;" placeholder="请输入考核人"
40
+                :disabled="!isDeptLeader"></el-input> </el-col>
41
+            <el-col :span="12">日期:<el-date-picker type="date" placeholder="请选择考核日期" v-model="tableForm.deptTime"
42
+                style="width:150px;" :disabled="!isDeptLeader"></el-date-picker> </el-col>
43
+          </el-row>
44
+        </td>
45
+        <td colspan="3" rowspan="3">
46
+          <el-input type="textarea" :rows="4" placeholder="请输入考核意见" v-model="tableForm.managerAdvice"
47
+            :disabled="!isManager">
48
+          </el-input>
49
+          <el-row justify="center">
50
+            <el-col :span="12">考核人:<el-input v-model="tableForm.managerAssesser" style="width:150px;" placeholder="请输入考核人"
51
+                :disabled="!isManager"></el-input></el-col>
52
+            <el-col :span="12">日期:<el-date-picker type="date" placeholder="请选择考核日期" v-model="tableForm.managerTime"
53
+                style="width:150px;" :disabled="!isManager"></el-date-picker></el-col>
54
+          </el-row>
55
+        </td>
56
+      </tr>
57
+      <tr>
58
+        <td class="table-title">技术职称</td>
59
+        <td colspan="3" style="text-align:left;padding-left:10px;">{{ tableForm.titles }}</td>
60
+      </tr>
61
+      <tr>
62
+        <td class="table-title">入职年月</td>
63
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.entryDate }}</td>
64
+        <td class="table-title">年龄</td>
65
+        <td style="text-align:left;padding-left:10px;">{{ tableForm.age }}</td>
66
+      </tr>
67
+      <tr>
68
+        <td rowspan="2" class="table-title">考核内容</td>
69
+        <td colspan="5" class="table-title">被考核人填写</td>
70
+        <td colspan="3" class="table-title" style="width:300px;">项目负责人考核</td>
71
+      </tr>
72
+      <tr>
73
+        <td class="table-title">工作内容</td>
74
+        <td class="table-title">单位</td>
75
+        <td class="table-title">工作量</td>
76
+        <td class="table-title">参与情况</td>
77
+        <td class="table-title">备注</td>
78
+        <td class="table-title">工作量</td>
79
+        <td class="table-title">岗位综合表现</td>
80
+        <td class="table-title">考核建议</td>
81
+      </tr>
82
+      <tr>
83
+        <td rowspan="9">劳动组织</td>
84
+        <td>组织会议</td>
85
+        <td>次</td>
86
+        <td class="personInput">
87
+          <span v-if="!isStaff">{{ tableForm.f0101 }}</span>
88
+          <el-input v-if="isStaff" v-model="tableForm.f0101"></el-input>
89
+        </td>
90
+        <td rowspan="9">
91
+          <el-radio-group v-model="tableForm.role01" :disabled="!isStaff">
92
+            <div><el-radio label="00">主办</el-radio></div>
93
+            <div><el-radio label="01">参与</el-radio></div>
94
+            <div><el-radio label="02">协助</el-radio></div>
95
+          </el-radio-group>
96
+        </td>
97
+
98
+        <td rowspan="9">
99
+          <div>{{ tableForm.remark01 }}</div>
100
+        </td>
101
+        <td rowspan="9">
102
+          <el-radio-group v-model="tableForm.workload01" :disabled="!isPiLeader">
103
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
104
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload01')">
105
+                {{ dict.label }}
106
+              </el-radio>
107
+            </div>
108
+          </el-radio-group>
109
+        </td>
110
+        <td rowspan="9">
111
+          <el-radio-group v-model="tableForm.assessment01" :disabled="!isPiLeader">
112
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
113
+              <el-radio :key="dict.value" :label="dict.value"
114
+                @click.native.prevent="cancelSelect(dict.value, 'assessment01')">
115
+                {{ dict.label }}
116
+              </el-radio>
117
+            </div>
118
+          </el-radio-group>
119
+        </td>
120
+        <td rowspan="9">
121
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice01" :disabled="!isPiLeader">
122
+          </el-input>
123
+        </td>
124
+      </tr>
125
+      <tr>
126
+        <td>组织培训</td>
127
+        <td>次</td>
128
+        <td class="personInput">
129
+          <span v-if="!isStaff">{{ tableForm.f0102 }}</span>
130
+          <el-input v-if="isStaff" v-model="tableForm.f0102"></el-input>
131
+        </td>
132
+      </tr>
133
+      <tr>
134
+        <td>组织考察</td>
135
+        <td>次</td>
136
+        <td class="personInput">
137
+          <span v-if="!isStaff">{{ tableForm.f0103 }}</span>
138
+          <el-input v-if="isStaff" v-model="tableForm.f0103"></el-input>
139
+        </td>
140
+      </tr>
141
+      <tr>
142
+        <td>组织接待</td>
143
+        <td>次</td>
144
+        <td class="personInput">
145
+          <span v-if="!isStaff">{{ tableForm.f0104 }}</span>
146
+          <el-input v-if="isStaff" v-model="tableForm.f0104"></el-input>
147
+        </td>
148
+      </tr>
149
+      <tr>
150
+        <td>组织宣传</td>
151
+        <td>次</td>
152
+        <td class="personInput">
153
+          <span v-if="!isStaff">{{ tableForm.f0105 }}</span>
154
+          <el-input v-if="isStaff" v-model="tableForm.f0105"></el-input>
155
+        </td>
156
+      </tr>
157
+      <tr>
158
+        <td>公司发文管理</td>
159
+        <td>次</td>
160
+        <td class="personInput">
161
+          <span v-if="!isStaff">{{ tableForm.f0106 }}</span>
162
+          <el-input v-if="isStaff" v-model="tableForm.f0106">
163
+          </el-input>
164
+        </td>
165
+      </tr>
166
+      <tr>
167
+        <td>公司发文管理</td>
168
+        <td>次</td>
169
+        <td class="personInput">
170
+          <span v-if="!isStaff">{{ tableForm.f0106 }}</span>
171
+          <el-input v-if="isStaff" v-model="tableForm.f0106">
172
+          </el-input>
173
+        </td>
174
+      </tr>
175
+      <tr>
176
+        <td>企业微信、公司官方群、公司网站维护</td>
177
+        <td>次</td>
178
+        <td class="personInput">
179
+          <span v-if="!isStaff">{{ tableForm.f0107 }}</span>
180
+          <el-input v-if="isStaff" v-model="tableForm.f0107">
181
+          </el-input>
182
+        </td>
183
+      </tr>
184
+      <tr>
185
+        <td>公司资质、员工信息更新、维护(含OA)</td>
186
+        <td>次</td>
187
+        <td class="personInput">
188
+          <span v-if="!isStaff">{{ tableForm.f0108 }}</span>
189
+          <el-input v-if="isStaff" v-model="tableForm.f0108">
190
+          </el-input>
191
+        </td>
192
+      </tr>
193
+
194
+      <!--  -->
195
+
196
+      <tr>
197
+        <td rowspan="8">安全管理</td>
198
+        <td>安全培训</td>
199
+        <td>项</td>
200
+        <td class="personInput">
201
+          <span v-if="!isStaff">{{ tableForm.f0201 }}</span>
202
+          <el-input v-if="isStaff" v-model="tableForm.f0201"></el-input>
203
+        </td>
204
+        <td rowspan="8">
205
+          <el-radio-group v-model="tableForm.role02" :disabled="!isStaff">
206
+            <div><el-radio label="00">主办</el-radio></div>
207
+            <div><el-radio label="01">参与</el-radio></div>
208
+            <div><el-radio label="02">协助</el-radio></div>
209
+          </el-radio-group>
210
+        </td>
211
+        <td rowspan="8">
212
+          <div>{{ tableForm.remark02 }}</div>
213
+        </td>
214
+        <td rowspan="8">
215
+          <el-radio-group v-model="tableForm.workload02" :disabled="!isPiLeader">
216
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
217
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload02')">
218
+                {{ dict.label }}
219
+              </el-radio>
220
+            </div>
221
+          </el-radio-group>
222
+        </td>
223
+        <td rowspan="8">
224
+          <el-radio-group v-model="tableForm.assessment02" :disabled="!isPiLeader">
225
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
226
+              <el-radio :key="dict.value" :label="dict.value"
227
+                @click.native.prevent="cancelSelect(dict.value, 'assessment02')">
228
+                {{ dict.label }}
229
+              </el-radio>
230
+            </div>
231
+          </el-radio-group>
232
+        </td>
233
+        <td rowspan="8">
234
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice02" :disabled="!isPiLeader">
235
+          </el-input>
236
+        </td>
237
+      </tr>
238
+      <tr>
239
+        <td>安全交底</td>
240
+        <td>次</td>
241
+        <td>
242
+          <span v-if="!isStaff">{{ tableForm.f0202 }}</span>
243
+          <el-input v-if="isStaff" v-model="tableForm.f0202"></el-input>
244
+        </td>
245
+      </tr>
246
+      <tr>
247
+        <td>组织演练</td>
248
+        <td>项</td>
249
+        <td>
250
+          <span v-if="!isStaff">{{ tableForm.f0203 }}</span>
251
+          <el-input v-if="isStaff" v-model="tableForm.f0203"></el-input>
252
+        </td>
253
+      </tr>
254
+      <tr>
255
+        <td>外业现场安全检查</td>
256
+        <td>人天</td>
257
+        <td>
258
+          <span v-if="!isStaff">{{ tableForm.f0204 }}</span>
259
+          <el-input v-if="isStaff" v-model="tableForm.f0204"></el-input>
260
+        </td>
261
+      </tr>
262
+      <tr>
263
+        <td>办公场所安全检查</td>
264
+        <td>次</td>
265
+        <td>
266
+          <span v-if="!isStaff">{{ tableForm.f0205 }}</span>
267
+          <el-input v-if="isStaff" v-model="tableForm.f0205"></el-input>
268
+        </td>
269
+      </tr>
270
+      <tr>
271
+        <td>商业保险办理</td>
272
+        <td>次</td>
273
+        <td>
274
+          <span v-if="!isStaff">{{ tableForm.f0206 }}</span>
275
+          <el-input v-if="isStaff" v-model="tableForm.f0206"></el-input>
276
+        </td>
277
+      </tr>
278
+      <tr>
279
+        <td>工伤保险办理</td>
280
+        <td>次</td>
281
+        <td>
282
+          <span v-if="!isStaff">{{ tableForm.f0207 }}</span>
283
+          <el-input v-if="isStaff" v-model="tableForm.f0207"></el-input>
284
+        </td>
285
+      </tr>
286
+      <tr>
287
+        <td>组织体检</td>
288
+        <td>人次</td>
289
+        <td>
290
+          <span v-if="!isStaff">{{ tableForm.f0208 }}</span>
291
+          <el-input v-if="isStaff" v-model="tableForm.f0208"></el-input>
292
+        </td>
293
+      </tr>
294
+
295
+      <!--  -->
296
+
297
+      <tr>
298
+        <td rowspan="5">设备物资</td>
299
+        <td>设备、物资采购</td>
300
+        <td>次</td>
301
+        <td class="personInput">
302
+          <span v-if="!isStaff">{{ tableForm.f0301 }}</span>
303
+          <el-input v-if="isStaff" v-model="tableForm.f0301"></el-input>
304
+        </td>
305
+        <td rowspan="5">
306
+          <el-radio-group v-model="tableForm.role03" :disabled="!isStaff">
307
+            <div><el-radio label="00">主办</el-radio></div>
308
+            <div><el-radio label="01">参与</el-radio></div>
309
+            <div><el-radio label="02">协助</el-radio></div>
310
+          </el-radio-group>
311
+        </td>
312
+        <td rowspan="5">
313
+          <div>{{ tableForm.remark03 }}</div>
314
+        </td>
315
+        <td rowspan="5">
316
+          <el-radio-group v-model="tableForm.workload03" :disabled="!isPiLeader">
317
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
318
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload03')">
319
+                {{ dict.label }}
320
+              </el-radio>
321
+            </div>
322
+          </el-radio-group>
323
+        </td>
324
+        <td rowspan="5">
325
+          <el-radio-group v-model="tableForm.assessment03" :disabled="!isPiLeader">
326
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
327
+              <el-radio :key="dict.value" :label="dict.value"
328
+                @click.native.prevent="cancelSelect(dict.value, 'assessment03')">
329
+                {{ dict.label }}
330
+              </el-radio>
331
+            </div>
332
+          </el-radio-group>
333
+        </td>
334
+        <td rowspan="5">
335
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice03" :disabled="!isPiLeader">
336
+          </el-input>
337
+        </td>
338
+      </tr>
339
+      <tr>
340
+        <td>物资、仪器设备领用、归还</td>
341
+        <td>项</td>
342
+        <td>
343
+          <span v-if="!isStaff">{{ tableForm.f0302 }}</span>
344
+          <el-input v-if="isStaff" v-model="tableForm.f0302"></el-input>
345
+        </td>
346
+      </tr>
347
+      <tr>
348
+        <td>设备维修</td>
349
+        <td>次</td>
350
+        <td>
351
+          <span v-if="!isStaff">{{ tableForm.f0303 }}</span>
352
+          <el-input v-if="isStaff" v-model="tableForm.f0303"></el-input>
353
+        </td>
354
+      </tr>
355
+      <tr>
356
+        <td>设备检定</td>
357
+        <td>台套</td>
358
+        <td>
359
+          <span v-if="!isStaff">{{ tableForm.f0304 }}</span>
360
+          <el-input v-if="isStaff" v-model="tableForm.f0304"></el-input>
361
+        </td>
362
+      </tr>
363
+      <tr>
364
+        <td>设备保险办理</td>
365
+        <td>次</td>
366
+        <td>
367
+          <span v-if="!isStaff">{{ tableForm.f0305 }}</span>
368
+          <el-input v-if="isStaff" v-model="tableForm.f0305"></el-input>
369
+        </td>
370
+      </tr>
371
+      <!--  -->
372
+
373
+      <tr>
374
+        <td rowspan="7">人力资源</td>
375
+        <td>招聘(校招、社招、内部竞聘)</td>
376
+        <td>次</td>
377
+        <td class="personInput">
378
+          <span v-if="!isStaff">{{ tableForm.f0401 }}</span>
379
+          <el-input v-if="isStaff" v-model="tableForm.f0401"></el-input>
380
+        </td>
381
+        <td rowspan="7">
382
+          <el-radio-group v-model="tableForm.role04" :disabled="!isStaff">
383
+            <div><el-radio label="00">主办</el-radio></div>
384
+            <div><el-radio label="01">参与</el-radio></div>
385
+            <div><el-radio label="02">协助</el-radio></div>
386
+          </el-radio-group>
387
+        </td>
388
+        <td rowspan="7">
389
+          <div>{{ tableForm.remark04 }}</div>
390
+        </td>
391
+        <td rowspan="7">
392
+          <el-radio-group v-model="tableForm.workload04" :disabled="!isPiLeader">
393
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
394
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload04')">
395
+                {{ dict.label }}
396
+              </el-radio>
397
+            </div>
398
+          </el-radio-group>
399
+        </td>
400
+        <td rowspan="7">
401
+          <el-radio-group v-model="tableForm.assessment04" :disabled="!isPiLeader">
402
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
403
+              <el-radio :key="dict.value" :label="dict.value"
404
+                @click.native.prevent="cancelSelect(dict.value, 'assessment04')">
405
+                {{ dict.label }}
406
+              </el-radio>
407
+            </div>
408
+          </el-radio-group>
409
+        </td>
410
+        <td rowspan="7">
411
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice04" :disabled="!isPiLeader">
412
+          </el-input>
413
+        </td>
414
+      </tr>
415
+      <tr>
416
+        <td>薪酬、考勤休假办理</td>
417
+        <td>次</td>
418
+        <td>
419
+          <span v-if="!isStaff">{{ tableForm.f0402 }}</span>
420
+          <el-input v-if="isStaff" v-model="tableForm.f0402"></el-input>
421
+        </td>
422
+      </tr>
423
+      <tr>
424
+        <td>社保三险办理</td>
425
+        <td>次</td>
426
+        <td>
427
+          <span v-if="!isStaff">{{ tableForm.f0403 }}</span>
428
+          <el-input v-if="isStaff" v-model="tableForm.f0403"></el-input>
429
+        </td>
430
+      </tr>
431
+      <tr>
432
+        <td>入、离职、退休办理</td>
433
+        <td>台套</td>
434
+        <td>
435
+          <span v-if="!isStaff">{{ tableForm.f0404 }}</span>
436
+          <el-input v-if="isStaff" v-model="tableForm.f0404"></el-input>
437
+        </td>
438
+      </tr>
439
+      <tr>
440
+        <td>劳动合同办理</td>
441
+        <td>次</td>
442
+        <td>
443
+          <span v-if="!isStaff">{{ tableForm.f0405 }}</span>
444
+          <el-input v-if="isStaff" v-model="tableForm.f0405"></el-input>
445
+        </td>
446
+      </tr>
447
+      <tr>
448
+        <td>绩效考评管理</td>
449
+        <td>次</td>
450
+        <td>
451
+          <span v-if="!isStaff">{{ tableForm.f0406 }}</span>
452
+          <el-input v-if="isStaff" v-model="tableForm.f0406"></el-input>
453
+        </td>
454
+      </tr>
455
+      <tr>
456
+        <td>职称管理</td>
457
+        <td>次</td>
458
+        <td>
459
+          <span v-if="!isStaff">{{ tableForm.f0407 }}</span>
460
+          <el-input v-if="isStaff" v-model="tableForm.f0407"></el-input>
461
+        </td>
462
+      </tr>
463
+
464
+      <!--  -->
465
+      <tr>
466
+        <td rowspan="10">车辆管理</td>
467
+        <td>车辆采购</td>
468
+        <td>次</td>
469
+        <td class="personInput">
470
+          <span v-if="!isStaff">{{ tableForm.f0501 }}</span>
471
+          <el-input v-if="isStaff" v-model="tableForm.f0501"></el-input>
472
+        </td>
473
+        <td rowspan="10">
474
+          <el-radio-group v-model="tableForm.role05" :disabled="!isStaff">
475
+            <div><el-radio label="00">主办</el-radio></div>
476
+            <div><el-radio label="01">参与</el-radio></div>
477
+            <div><el-radio label="02">协助</el-radio></div>
478
+          </el-radio-group>
479
+        </td>
480
+        <td rowspan="10">
481
+          <div>{{ tableForm.remark05 }}</div>
482
+        </td>
483
+        <td rowspan="10">
484
+          <el-radio-group v-model="tableForm.workload05" :disabled="!isPiLeader">
485
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
486
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload05')">
487
+                {{ dict.label }}
488
+              </el-radio>
489
+            </div>
490
+          </el-radio-group>
491
+        </td>
492
+        <td rowspan="10">
493
+          <el-radio-group v-model="tableForm.assessment05" :disabled="!isPiLeader">
494
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
495
+              <el-radio :key="dict.value" :label="dict.value"
496
+                @click.native.prevent="cancelSelect(dict.value, 'assessment05')">
497
+                {{ dict.label }}
498
+              </el-radio>
499
+            </div>
500
+          </el-radio-group>
501
+        </td>
502
+        <td rowspan="10">
503
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice05" :disabled="!isPiLeader">
504
+          </el-input>
505
+        </td>
506
+      </tr>
507
+      <tr>
508
+        <td>车辆保险购置</td>
509
+        <td>次</td>
510
+        <td>
511
+          <span v-if="!isStaff">{{ tableForm.f0502 }}</span>
512
+          <el-input v-if="isStaff" v-model="tableForm.f0502"></el-input>
513
+        </td>
514
+      </tr>
515
+      <tr>
516
+        <td>生产项目用车(安排)</td>
517
+        <td>次</td>
518
+        <td>
519
+          <span v-if="!isStaff">{{ tableForm.f0503 }}</span>
520
+          <el-input v-if="isStaff" v-model="tableForm.f0503"></el-input>
521
+        </td>
522
+      </tr>
523
+      <tr>
524
+        <td>出差用车(安排)</td>
525
+        <td>次</td>
526
+        <td>
527
+          <span v-if="!isStaff">{{ tableForm.f0504 }}</span>
528
+          <el-input v-if="isStaff" v-model="tableForm.f0504"></el-input>
529
+        </td>
530
+      </tr>
531
+      <tr>
532
+        <td>市周边临时驾驶接送(安排)</td>
533
+        <td>次</td>
534
+        <td>
535
+          <span v-if="!isStaff">{{ tableForm.f0505 }}</span>
536
+          <el-input v-if="isStaff" v-model="tableForm.f0505"></el-input>
537
+        </td>
538
+      </tr>
539
+      <tr>
540
+        <td>驾驶车辆参与项目生产</td>
541
+        <td>人天</td>
542
+        <td>
543
+          <span v-if="!isStaff">{{ tableForm.f0506 }}</span>
544
+          <el-input v-if="isStaff" v-model="tableForm.f0506"></el-input>
545
+        </td>
546
+      </tr>
547
+      <tr>
548
+        <td>驾驶车辆参与出差</td>
549
+        <td>人天</td>
550
+        <td>
551
+          <span v-if="!isStaff">{{ tableForm.f0507 }}</span>
552
+          <el-input v-if="isStaff" v-model="tableForm.f0507"></el-input>
553
+        </td>
554
+      </tr>
555
+      <tr>
556
+        <td>年度驾驶里程</td>
557
+        <td>km</td>
558
+        <td>
559
+          <span v-if="!isStaff">{{ tableForm.f0508 }}</span>
560
+          <el-input v-if="isStaff" v-model="tableForm.f0508"></el-input>
561
+        </td>
562
+      </tr>
563
+      <tr>
564
+        <td>车辆维修保养</td>
565
+        <td>次</td>
566
+        <td>
567
+          <span v-if="!isStaff">{{ tableForm.f0509 }}</span>
568
+          <el-input v-if="isStaff" v-model="tableForm.f0509"></el-input>
569
+        </td>
570
+      </tr>
571
+      <tr>
572
+        <td>车辆保险理赔</td>
573
+        <td>次</td>
574
+        <td>
575
+          <span v-if="!isStaff">{{ tableForm.f0510 }}</span>
576
+          <el-input v-if="isStaff" v-model="tableForm.f0510"></el-input>
577
+        </td>
578
+      </tr>
579
+      <!--  -->
580
+      <tr>
581
+        <td rowspan="7">办公区维护</td>
582
+        <td>办公区办公设施检修</td>
583
+        <td>次</td>
584
+        <td class="personInput">
585
+          <span v-if="!isStaff">{{ tableForm.f0601 }}</span>
586
+          <el-input v-if="isStaff" v-model="tableForm.f0601"></el-input>
587
+        </td>
588
+        <td rowspan="7">
589
+          <el-radio-group v-model="tableForm.role06" :disabled="!isStaff">
590
+            <div><el-radio label="00">主办</el-radio></div>
591
+            <div><el-radio label="01">参与</el-radio></div>
592
+            <div><el-radio label="02">协助</el-radio></div>
593
+          </el-radio-group>
594
+        </td>
595
+        <td rowspan="7">
596
+          <div>{{ tableForm.remark06 }}</div>
597
+        </td>
598
+        <td rowspan="7">
599
+          <el-radio-group v-model="tableForm.workload06" :disabled="!isPiLeader">
600
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
601
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload06')">
602
+                {{ dict.label }}
603
+              </el-radio>
604
+            </div>
605
+          </el-radio-group>
606
+        </td>
607
+        <td rowspan="7">
608
+          <el-radio-group v-model="tableForm.assessment06" :disabled="!isPiLeader">
609
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
610
+              <el-radio :key="dict.value" :label="dict.value"
611
+                @click.native.prevent="cancelSelect(dict.value, 'assessment06')">
612
+                {{ dict.label }}
613
+              </el-radio>
614
+            </div>
615
+          </el-radio-group>
616
+        </td>
617
+        <td rowspan="7">
618
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice06" :disabled="!isPiLeader">
619
+          </el-input>
620
+        </td>
621
+      </tr>
622
+      <tr>
623
+        <td>办公区安全检查</td>
624
+        <td>次</td>
625
+        <td>
626
+          <span v-if="!isStaff">{{ tableForm.f0602 }}</span>
627
+          <el-input v-if="isStaff" v-model="tableForm.f0602"></el-input>
628
+        </td>
629
+      </tr>
630
+      <tr>
631
+        <td>办公区绿植、送水统计</td>
632
+        <td>次</td>
633
+        <td>
634
+          <span v-if="!isStaff">{{ tableForm.f0603 }}</span>
635
+          <el-input v-if="isStaff" v-model="tableForm.f0603"></el-input>
636
+        </td>
637
+      </tr>
638
+      <tr>
639
+        <td>办公区电子显示屏展示宣传</td>
640
+        <td>次</td>
641
+        <td>
642
+          <span v-if="!isStaff">{{ tableForm.f0604 }}</span>
643
+          <el-input v-if="isStaff" v-model="tableForm.f0604"></el-input>
644
+        </td>
645
+      </tr>
646
+      <tr>
647
+        <td>办公区电子信息维护(电话、网络、电脑)</td>
648
+        <td>次</td>
649
+        <td>
650
+          <span v-if="!isStaff">{{ tableForm.f0605 }}</span>
651
+          <el-input v-if="isStaff" v-model="tableForm.f0605"></el-input>
652
+        </td>
653
+      </tr>
654
+      <tr>
655
+        <td>会议室管理</td>
656
+        <td>次</td>
657
+        <td>
658
+          <span v-if="!isStaff">{{ tableForm.f0606 }}</span>
659
+          <el-input v-if="isStaff" v-model="tableForm.f0606"></el-input>
660
+        </td>
661
+      </tr>
662
+      <tr>
663
+        <td>工作餐订制、快递、报纸收发</td>
664
+        <td>次</td>
665
+        <td>
666
+          <span v-if="!isStaff">{{ tableForm.f0607 }}</span>
667
+          <el-input v-if="isStaff" v-model="tableForm.f0607"></el-input>
668
+        </td>
669
+      </tr>
670
+      <!--  -->
671
+      <tr>
672
+        <td rowspan="2">党群、董事会</td>
673
+        <td>党总支日常工作</td>
674
+        <td>次</td>
675
+        <td class="personInput">
676
+          <span v-if="!isStaff">{{ tableForm.f0701 }}</span>
677
+          <el-input v-if="isStaff" v-model="tableForm.f0701"></el-input>
678
+        </td>
679
+        <td rowspan="2">
680
+          <el-radio-group v-model="tableForm.role07" :disabled="!isStaff">
681
+            <div><el-radio label="00">主办</el-radio></div>
682
+            <div><el-radio label="01">参与</el-radio></div>
683
+            <div><el-radio label="02">协助</el-radio></div>
684
+          </el-radio-group>
685
+        </td>
686
+        <td rowspan="2">
687
+          <div>{{ tableForm.remark07 }}</div>
688
+        </td>
689
+        <td rowspan="2">
690
+          <el-radio-group v-model="tableForm.workload07" :disabled="!isPiLeader">
691
+            <div v-for="dict in dict.type.cmc_workload" style="text-align:left">
692
+              <el-radio :key="dict.value" :label="dict.value" @click.native.prevent="cancelSelect(dict.value, 'workload07')">
693
+                {{ dict.label }}
694
+              </el-radio>
695
+            </div>
696
+          </el-radio-group>
697
+        </td>
698
+        <td rowspan="2">
699
+          <el-radio-group v-model="tableForm.assessment07" :disabled="!isPiLeader">
700
+            <div v-for="dict in dict.type.cmc_accessment" style="text-align:left">
701
+              <el-radio :key="dict.value" :label="dict.value"
702
+                @click.native.prevent="cancelSelect(dict.value, 'assessment07')">
703
+                {{ dict.label }}
704
+              </el-radio>
705
+            </div>
706
+          </el-radio-group>
707
+        </td>
708
+        <td rowspan="2">
709
+          <el-input type="textarea" :rows="4" v-model="tableForm.advice07" :disabled="!isPiLeader">
710
+          </el-input>
711
+        </td>
712
+      </tr>
713
+      <tr>
714
+        <td>董事会日常工作</td>
715
+        <td>次</td>
716
+        <td>
717
+          <span v-if="!isStaff">{{ tableForm.f0702 }}</span>
718
+          <el-input v-if="isStaff" v-model="tableForm.f0702"></el-input>
719
+        </td>
720
+      </tr>
721
+      <!--  -->
722
+
723
+      <tr style="height:90px;">
724
+        <td>其他工作</td>
725
+        <td colspan="9">
726
+          <span v-if="!isStaff">{{ tableForm.otherWork }}</span>
727
+          <el-input v-if="isStaff" v-model="tableForm.otherWork" type="textarea" :rows="2"></el-input>
728
+        </td>
729
+      </tr>
730
+      <tr style="height:90px;">
731
+        <td>年度自述</td>
732
+        <td colspan="9">
733
+          <span v-if="!isStaff">{{ tableForm.selfAssess }}</span>
734
+          <el-input v-if="isStaff" v-model="tableForm.selfAssess" type="textarea" :rows="2"></el-input>
735
+        </td>
736
+      </tr>
737
+    </table>
738
+    <el-row justify="center" type="flex" style="margin-top:20px;"
739
+      v-if="tableForm.taskName == undefined || tableForm.taskName == '员工修改'">
740
+      <el-button type="primary" @click="submit">提交</el-button>
741
+      <el-button>取消</el-button>
742
+    </el-row>
743
+  </div>
744
+</template>
745
+
746
+<script>
747
+import { JYContent } from '@/assets/datas/JYContent'
748
+import { getDicts as getDicts } from '@/api/system/dict/data'
749
+export default {
750
+  dicts: ['cmc_role', 'cmc_skill', 'cmc_accessment','cmc_workload'],
751
+  props: {
752
+    tableForm: {
753
+      type: Object,
754
+      required: true
755
+    },
756
+  },
757
+  watch: {
758
+    tableForm: function (newval, oldval) {
759
+      this.formatForm();
760
+    }
761
+  },
762
+  data() {
763
+    return {
764
+      form: {},
765
+      radio1: "",
766
+      radio2: "",
767
+      textarea1: "",
768
+      textarea2: "",
769
+      isDeptLeader: false,
770
+      isPiLeader: false,
771
+      isManager: false,
772
+      isStaff: false,
773
+    }
774
+  },
775
+  created() {
776
+    this.initForm();
777
+  },
778
+  mounted() {
779
+    this.formatForm();
780
+  },
781
+  methods: {
782
+    initForm() {
783
+
784
+    },
785
+    formatForm() {
786
+      if (this.tableForm.taskName == '项目负责人审核') {
787
+        this.isPiLeader = true;
788
+        this.isDeptLeader = false;
789
+        this.isManager = false;
790
+        this.isStaff = false;
791
+      } else if (this.tableForm.taskName == '部门审核') {
792
+        this.isPiLeader = false;
793
+        this.isDeptLeader = true;
794
+        this.isManager = false;
795
+        this.isStaff = false;
796
+      } else if (this.tableForm.taskName == '分管领导审核') {
797
+        this.isPiLeader = false;
798
+        this.isDeptLeader = false;
799
+        this.isManager = true;
800
+        this.isStaff = false;
801
+      } else if (this.tableForm.taskName == '员工修改') {
802
+        this.isPiLeader = false;
803
+        this.isDeptLeader = false;
804
+        this.isManager = false;
805
+        this.isStaff = true;
806
+      }
807
+    },
808
+    submit() {
809
+      if (!this.isStaff) {
810
+        this.$emit('submit', this.tableForm);
811
+      } else {
812
+        this.$emit('submit', this.tableForm);
813
+      }
814
+
815
+    },
816
+    cancelSelect(value, name) {
817
+      debugger
818
+      if (!this.isPiLeader) {
819
+        return
820
+      }
821
+      if (this.tableForm[name] == value) {
822
+        this.tableForm[name] = null
823
+      } else {
824
+
825
+        if (this.tableForm[name] !== undefined)
826
+          this.tableForm[name] = value
827
+      }
828
+    }
829
+  },
830
+}
831
+</script>
832
+
833
+<style lang="scss" scoped>
834
+.table {
835
+  border-collapse: collapse;
836
+  width: 100%;
837
+}
838
+
839
+.table-title {
840
+  background-color: #dad4d4;
841
+}
842
+
843
+.table,
844
+th,
845
+td {
846
+  border: 1px solid black;
847
+  text-align: center;
848
+}
849
+
850
+td {
851
+  height: 24px;
852
+  width: 100px;
853
+}
854
+
855
+.head {
856
+  background-color: #ccc;
857
+}
858
+
859
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after {
860
+  border-color: #fff;
861
+}
862
+
863
+::v-deep .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
864
+  background-color: #409eff;
865
+  border-color: #409eff;
866
+}
867
+
868
+::v-deep .el-checkbox__input.is-disabled+span.el-checkbox__label {
869
+  color: #000;
870
+}
871
+
872
+::v-deep .el-checkbox__label {
873
+  font-size: 12px;
874
+}
875
+
876
+::v-deep .el-radio__input.is-disabled .el-radio__inner,
877
+.el-radio__input.is-disabled.is-checked .el-radio__inner {
878
+  background-color: #f1f1f1;
879
+  border-color: #f1f1f1;
880
+}
881
+
882
+::v-deep .el-radio__input.is-disabled+span.el-radio__label {
883
+  color: #000;
884
+}
885
+
886
+
887
+::v-deep .el-radio__input.is-checked .el-radio__inner::after {
888
+  content: "";
889
+  width: 10px;
890
+  height: 5px;
891
+  border: 2px solid #409eff;
892
+  border-top: transparent;
893
+  border-right: transparent;
894
+  text-align: center;
895
+  display: block;
896
+  position: absolute;
897
+  top: 2px;
898
+  left: 2px;
899
+  vertical-align: middle;
900
+  transform: rotate(-45deg);
901
+  border-radius: 0px;
902
+  background: none;
903
+}
904
+</style>

+ 22
- 4
oa-ui/src/views/flowable/task/myProcess/send/index.vue 查看文件

@@ -17,7 +17,17 @@
17 17
           </el-col>
18 18
         </el-tab-pane> -->
19 19
         <el-tab-pane label="表单信息" name="1">
20
-          <scform @submit="submitForm"></scform>
20
+          <sc-form @submit="submitForm" v-if="deployId == '7653'"></sc-form>
21
+          <jy-form @submit="submitForm" v-else-if="deployId == '10018'"></jy-form>
22
+          <zh-form @submit="submitForm" v-else-if="deployId == '10022'"></zh-form>
23
+          <js-form @submit="submitForm" v-else-if="deployId == '12501'"></js-form>
24
+          <xm-form @submit="submitForm" v-else-if="deployId == '12505'"></xm-form>
25
+          <el-col :span="16" :offset="4" v-else>
26
+            <div class="test-form">
27
+              <parser :key="new Date().getTime()" :form-conf="formConf" @submit="submitForm" ref="parser"
28
+                @getData="getData" />
29
+            </div>
30
+          </el-col>
21 31
         </el-tab-pane>
22 32
         <!--流程图-->
23 33
         <el-tab-pane label="流程图" name="2">
@@ -46,7 +56,11 @@ import { flowFormData } from "@/api/flowable/process";
46 56
 import { getNextFlowNodeByStart } from "@/api/flowable/todo";
47 57
 import FlowUser from '@/components/flow/User'
48 58
 import FlowRole from '@/components/flow/Role'
49
-import scform from '../../../form/scForm.vue';
59
+import ScForm from '../../../form/scForm.vue';
60
+import JyForm from '../../../form/jyForm.vue';
61
+import ZhForm from '../../../form/zhForm.vue';
62
+import JsForm from '../../../form/jsForm.vue';
63
+import XmForm from '../../../form/xmForm.vue';
50 64
 
51 65
 export default {
52 66
   name: "Record",
@@ -55,8 +69,12 @@ export default {
55 69
     flow,
56 70
     FlowUser,
57 71
     FlowRole,
58
-    scform
59
-  },
72
+    ScForm,
73
+    JyForm,
74
+    ZhForm,
75
+    JsForm,
76
+    XmForm
77
+},
60 78
   props: {},
61 79
   data() {
62 80
     return {

+ 2
- 0
oa-ui/src/views/flowable/task/todo/detail/index.vue 查看文件

@@ -398,6 +398,8 @@ export default {
398 398
     handleReject() {
399 399
       this.rejectOpen = true;
400 400
       this.rejectTitle = "驳回流程";
401
+      console.log(this.flowRecordList);
402
+      
401 403
     },
402 404
     /** 驳回任务 */
403 405
     taskReject() {

正在加载...
取消
保存