safecheck-client 3.0.34-35 → 3.0.34-39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/package.json +1 -1
  2. package/src/App.vue +31 -31
  3. package/src/components/android/QRCode/QRCodePage.vue +208 -208
  4. package/src/components/android/examples/SafeListExamples.vue +96 -96
  5. package/src/components/android/examples/UserExamples.vue +126 -126
  6. package/src/filiale/bayan/android/SafecheckOrderV.vue +49 -26
  7. package/src/filiale/huaran/android/SafecheckOrderV.vue +2803 -2803
  8. package/src/filiale/huaran/android.js +12 -12
  9. package/src/filiale/huaran/pc/CheckBook.vue +313 -313
  10. package/src/filiale/huaran/pc/CheckBookAll.vue +69 -69
  11. package/src/filiale/huaran/pc/CheckBookArea.vue +170 -170
  12. package/src/filiale/huaran/pc/CheckBookCompany.vue +166 -166
  13. package/src/filiale/huaran/pc/CheckBookDetails.vue +196 -196
  14. package/src/filiale/huaran/pc/CheckBookEntry.vue +61 -61
  15. package/src/filiale/huaran/pc/CheckBookList.vue +386 -386
  16. package/src/filiale/huaran/pc/CheckBookSearchArea.vue +564 -564
  17. package/src/filiale/huaran/pc/CheckBookSearchUnit.vue +229 -229
  18. package/src/filiale/huaran/pc/CheckBookSearchUser.vue +604 -604
  19. package/src/filiale/huaran/pc/CheckBookUser.vue +112 -112
  20. package/src/filiale/huaran/pc/PaperList.vue +822 -822
  21. package/src/filiale/huaran/pc/PlanManage.vue +887 -887
  22. package/src/filiale/huaran/pc/checkPlanList.vue +419 -419
  23. package/src/filiale/huaran/pc/checkUserList.vue +867 -867
  24. package/src/filiale/huaran/pc.js +27 -27
  25. package/src/filiale/ruihua/android/SafecheckOrderV.vue +2747 -0
  26. package/src/filiale/ruihua/android/SafecheckUserInfo.vue +804 -0
  27. package/src/filiale/ruihua/android.js +11 -0
  28. package/src/filiale/weinan/android/SafecheckDevices.vue +1295 -1295
  29. package/src/filiale/weinan/android/SafecheckOrderV.vue +3335 -3335
  30. package/src/filiale/weinan/pc/DeviceChange.vue +1088 -1088
  31. package/src/filiale/weinan/pc.js +47 -47
  32. package/src/main.js +33 -33
@@ -1,386 +1,386 @@
1
- <template>
2
- <div class="flex">
3
- <criteria-paged :model="model" v-ref:paged>
4
- <criteria partial='criteria' @condition-changed='$parent.search' v-ref:criteria>
5
- <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
- <div class="row" v-show="!$parent.$parent.$parent.showItemAll">
7
- <div :class="$parent.$parent.style2" style="margin: 0px">
8
- <role-selector-safe
9
- role-name="安检员"
10
- role-lable="安&nbsp;检&nbsp;员&nbsp;"
11
- @re-res="$parent.$parent.getRes"
12
- :value.sync="model.f_checker_id"
13
- v-model="model.f_checker_id"
14
- :value-multiple="true"
15
- condition=" f_checker_name in {}">
16
- </role-selector-safe>
17
- </div>
18
- <div :class="$parent.$parent.style">
19
- <label class="font_normal_body">安检册名称</label>
20
- <v-select :value.sync="model.f_check_book_id" v-model='model.f_check_book_id'
21
- :value-single="true" style="width: 60%"
22
- class="select_list select"
23
- :options='$parent.$parent.checkBooks' placeholder='安检册名称'
24
- close-on-select
25
- condition="tcb.id ='{}'"></v-select>
26
- </div>
27
- <!-- <div :class="$parent.$parent.style">-->
28
- <!-- <label class="font_normal_body">表册类型</label>-->
29
- <!-- <v-select :value.sync="model.f_check_book_type" v-model='model.f_check_book_type'-->
30
- <!-- :value-single="true" style="width: 60%"-->
31
- <!-- class="select_list select"-->
32
- <!-- :options='$parent.$parent.bookTypes' placeholder='表册类型'-->
33
- <!-- close-on-select-->
34
- <!-- condition="tcb.f_check_book_type ='{}'"></v-select>-->
35
- <!-- </div>-->
36
- <!-- <div :class="$parent.$parent.style">-->
37
- <!-- <label class="font_normal_body">用户类型</label>-->
38
- <!-- <v-select :value.sync="model.f_user_type" v-model='model.f_user_type'-->
39
- <!-- :value-single="true" style="width: 60%"-->
40
- <!-- class="select_list select"-->
41
- <!-- :options='$parent.$parent.userTypes' placeholder='用户类型'-->
42
- <!-- close-on-select-->
43
- <!-- condition="tcb.f_user_type ='{}'"></v-select>-->
44
- <!-- </div>-->
45
- <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
46
- <button type="button" class="button_search button_spacing" @click="search()">查询</button>
47
- <button type="button" class="button_new button_spacing" @click="$parent.$parent.add()">新增安检册</button>
48
- <button type="button" class="button_new button_spacing" @click="$parent.$parent.showModal = true">
49
- 安检册用户管理
50
- </button>
51
- <div style="float: right" class="button_spacing"
52
- v-show="$parent.$parent.$parent.showItem ||$parent.$parent.$parent.showItemUser"
53
- :class="{'button_shrink_left':$parent.$parent.$parent.showItemAll,'button_shrink_right':!$parent.$parent.$parent.showItemAll}"
54
- @click="($parent.$parent.$parent.showItem =false) || ($parent.$parent.$parent.showItemUser =false)"></div>
55
- </div>
56
-
57
-
58
- </div>
59
-
60
-
61
- <div class="row" v-show="$parent.$parent.$parent.showItemAll">
62
- <div :class="$parent.$parent.style2" style="margin: 0px">
63
- <role-selector-safe
64
- role-name="安检员"
65
- role-lable="安&nbsp;检&nbsp;员&nbsp;"
66
- @re-res="$parent.$parent.getRes"
67
- :value.sync="model.f_checker_id"
68
- v-model="model.f_checker_id"
69
- :value-multiple="true"
70
- condition=" f_checker_name in {}">
71
- </role-selector-safe>
72
- </div>
73
- <div :class="$parent.$parent.style">
74
- <label class="font_normal_body">安检册名</label>
75
- <v-select :value.sync="model.f_check_book_id" v-model='model.f_check_book_id'
76
- :value-single="true" style="width: 60%"
77
- class="select_list select"
78
- :options='$parent.$parent.checkBooks' placeholder='安检册名称'
79
- close-on-select
80
- condition="tcb.id ='{}'"></v-select>
81
- </div>
82
- <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
83
- <button type="button" class="button_search button_spacing" @click="search()">查询</button>
84
- <button type="button" class="button_new button_spacing" @click="$parent.$parent.add()">新增安检册</button>
85
- <button type="button" class="button_new button_spacing" @click="$parent.$parent.showModal = true">
86
- 安检册用户管理
87
- </button>
88
- <div style="float: right" class="button_spacing"
89
- v-show="$parent.$parent.$parent.showItem ||$parent.$parent.$parent.showItemUser"
90
- :class="{'button_shrink_left':$parent.$parent.$parent.showItemAll,'button_shrink_right':!$parent.$parent.$parent.showItemAll}"
91
- @click="($parent.$parent.$parent.showItem =false) || ($parent.$parent.$parent.showItemUser =false)"></div>
92
- <!-- <div style="float: right" class="button_spacing"-->
93
- <!-- :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"-->
94
- <!-- @click="$parent.$parent.hidden()">-->
95
- <!-- </div>-->
96
- </div>
97
-
98
- </div>
99
-
100
- </div>
101
- </criteria>
102
- <data-grid :model="model" partial="list" class="list_area table_sy" v-ref:grid>
103
- <template partial='head'>
104
- <tr>
105
- <th>
106
- <nobr>所属安检员</nobr>
107
- </th>
108
- <th>
109
- <nobr>安检册名称</nobr>
110
- </th>
111
- <!-- <th>-->
112
- <!-- <nobr>安检册类型</nobr>-->
113
- <!-- </th>-->
114
- <th>
115
- <nobr>用户类型</nobr>
116
- </th>
117
- <th>
118
- <nobr>创建日期</nobr>
119
- </th>
120
- <th>
121
- <nobr>创建人</nobr>
122
- </th>
123
-
124
- <th>
125
- <nobr>执行日期</nobr>
126
- </th>
127
- <th>
128
- <nobr>执行周期</nobr>
129
- </th>
130
- <th>
131
- <nobr>小区/单位数量</nobr>
132
- </th>
133
- <th>
134
- <nobr>已下发</nobr>
135
- </th>
136
- <th>
137
- <nobr>未下发</nobr>
138
- </th>
139
- <th>
140
- <nobr>已检</nobr>
141
- </th>
142
- <th>
143
- <nobr>未检</nobr>
144
- </th>
145
- <!-- <th v-show="$parent.$parent.$parent.showCaoZuo">-->
146
- <!-- <nobr>操作</nobr>-->
147
- <!-- </th>-->
148
- </tr>
149
- </template>
150
- <template partial='body'>
151
- <td style="text-align: center;">{{ row.f_checker_name }}</td>
152
- <td style="text-align: center;">{{ row.f_check_book_name }}</td>
153
- <!-- <td style="text-align: center;">{{ row.f_check_book_type }}</td>-->
154
- <td style="text-align: center;">{{ row.f_user_type }}</td>
155
- <td style="text-align: center;">{{ row.f_create_date }}</td>
156
- <td style="text-align: center;">{{ row.f_create_person }}</td>
157
- <td style="text-align: center;">{{ row.f_run_date }}</td>
158
- <td style="text-align: center;">{{ row.f_around_time }}{{ row.f_around_unit }}</td>
159
- <td style="text-align: center;">
160
- <button @click.stop="$parent.$parent.$parent.details(row)" class="btn btn-link">
161
- <b>{{ row.f_user_type === '民用' ? row.num2 : row.num3 }}</b></button>
162
- </td>
163
- <td style="text-align: center;">{{ row.xiafa }}</td>
164
- <td style="text-align: center;">
165
- {{ row.f_user_type == '民用' ? Number(row.num - row.xiafa) : Number(row.num4 - row.xiafa) }}
166
- </td>
167
- <td style="text-align: center;">{{ row.yijian }}</td>
168
- <td style="text-align: center;">{{ row.weijian }}</td>
169
- <!-- <td v-show="row.f_check_book_type!='小区'" style="text-align: center;"><button class="button_spacing button_search-1" @click.stop='$parent.$parent.$parent.send(row)'>下发</button></td>-->
170
- </template>
171
- </data-grid>
172
- </criteria-paged>
173
- <modal :show.sync="showModal" :backdrop="false" id="checkbookEntryShow">
174
- <article slot="modal-body" class="modal-body">
175
- <check-book-entry v-if="showModal" @select-changed="selectedEntry"></check-book-entry>
176
- </article>
177
- <footer slot="modal-footer">
178
- </footer>
179
-
180
- </modal>
181
- <modal :show.sync="showSendModal" :backdrop="false" width="90%" height="90%">
182
- <article slot="modal-body" class="modal-body" style="height: 80vh">
183
- <check-book-search-user-list v-if="showSendModal" :row="checkBookRow" :bookrow="checkBookRow"
184
- :needprops="needprops" :userlogin="userlogin"></check-book-search-user-list>
185
- </article>
186
- <footer slot="modal-footer">
187
- </footer>
188
-
189
- </modal>
190
- </div>
191
- </template>
192
-
193
- <script>
194
- import {PagedList} from 'vue-client'
195
- import {HttpResetClass} from 'vue-client'
196
- import bus from "../../../bus";
197
-
198
- export default {
199
- title: '用户安检情况',
200
- data() {
201
- return {
202
- showSendModal: false,
203
- searchData: {
204
- condition: '1=1'
205
- },
206
- showCaoZuo: false,
207
- userlogin: {
208
- id: this.$login.f.id,
209
- name: this.$login.f.name,
210
- orgid: this.$login.f.orgid,
211
- orgstr: this.$login.f.orgs,
212
- },
213
- checkBooks: [],
214
- bookTypes: [{label: '全部', value: ''}, {label: '用户', value: '用户'}, {label: '小区', value: '小区'}],
215
- userTypes: [{label: '全部', value: ''}, {label: '民用', value: '民用'}, {label: '非民用', value: '非民用'}],
216
- aroundUnit: [{label: '年', value: '年'}, {label: '月', value: '月'}, {label: '日', value: '日'}],
217
- showModal: false,
218
- excelHeaders: {
219
-
220
- 'f_userinfo_code': '用户编号',
221
- 'f_user_name': '用户名称',
222
- 'f_user_phone': '用户电话',
223
- 'f_meternumber': '用户表号',
224
- 'f_user_type': '用户类型',
225
- 'f_last_checker': '安检员',
226
- 'f_residential_area': '小区名称',
227
- 'f_address': '地址',
228
- 'f_last_check_date': '安检日期',
229
- 'f_last_check_state': '安检状态',
230
- 'f_last_check_result': '安检结果'
231
- },
232
- model: new PagedList('rs/sql/QueryCheckBook', 20),
233
- checkBookRow: {},
234
- checkBook: {
235
- f_check_book_name: '',
236
- f_run_date: '',
237
- f_around_time: '',
238
- f_around_unit: '',
239
- f_create_date: '',
240
- f_create_person: '',
241
- f_orgid: '',
242
- f_checker_name: ''
243
- }
244
- }
245
- },
246
- props: {
247
- style: {
248
- type: String,
249
- default: 'col-sm-2 form-group'
250
- },
251
- style2: {
252
- type: String,
253
- default: 'col-sm-4 form-group'
254
- },
255
- needprops: {
256
- type: Object,
257
- default: {}
258
- },
259
- showtype: {
260
- type: String
261
- }
262
- },
263
- ready() {
264
- bus.$on('fresh-main', () => {
265
- console.log("进入方法")
266
- this.$refs.paged.$refs.criteria.search()
267
- })
268
- this.freshCheckBook()
269
- },
270
- beforeDestroy() {
271
- //tag
272
- bus.$off('fresh-main')
273
- },
274
- methods: {
275
- send(row) {
276
- console.log("7758521", row)
277
- this.checkBookRow = row
278
- this.showSendModal = true
279
- },
280
- freshCheckBook() {
281
- this.checkBooks = []
282
- new HttpResetClass().load('POST', `/rs/sql/safe_singleTable_OrderBy`, {
283
- data: {
284
- items: 'id,f_check_book_name',
285
- tablename: 't_check_book',
286
- condition: this.$refs.paged.$refs.criteria.model.f_orgid ? `f_orgid in ${this.$refs.paged.$refs.criteria.model.f_orgid} and f_user_type ='${this.showtype}' ` : `f_user_type ='${this.showtype}'`,
287
- orderitem: 'id desc'
288
- }
289
- }, {resolveMsg: null, rejectMsg: null}).then(res => {
290
- this.checkBooks.push({label: '全部', value: ''})
291
- res.data.forEach(ress => {
292
- this.checkBooks.push({
293
- label: ress.f_check_book_name,
294
- value: ress.id
295
- })
296
- })
297
- })
298
- },
299
- selectedEntry() {
300
- console.log("666666666666666666")
301
- },
302
- details(row) {
303
- this.$emit('showdetails', row)
304
- },
305
- add() {
306
- this.$emit('addbook')
307
- },
308
- ok() {
309
- //tag
310
- let http = new HttpResetClass()
311
- http.load('POST', 'rs/logic/safeEntity', {data: {tableName: 't_check_book', entityData: this.checkBook}},
312
- {resolveMsg: '更新安检册信息成功', rejectMsg: '保存安检册信息成功'}).then(res => {
313
- if (res.data.code === 200) {
314
- this.$showMessage('修改成功')
315
- this.showModal = false
316
- this.checkBook = {}
317
- }
318
- })
319
- },
320
- cancel() {
321
- this.showModal = false
322
- this.checkBook = {}
323
- },
324
- updateCheckBook(val) {
325
- this.checkBook = val
326
- this.showModal = true
327
- },
328
- search(args) {
329
- // //tag
330
- this.$parent.showItem = false
331
- this.$parent.showItemUser = false
332
- args.condition += ` and f_orgid in ${this.model.f_filialeids}`
333
- args.condition += ` and tcb.f_user_type ='${this.showtype}' `
334
- return this.model.search(args.condition, args.model)
335
- },
336
- getRes(obj) {
337
- this.model.f_filialeids = this.$login.convertToIn(obj.resids)
338
- },
339
- async deleteCheckBook(val) {
340
- try {
341
- //tag
342
- let http = new HttpResetClass()
343
- let upAddress = `update t_user_address set f_check_book_id = null where f_check_book_id = '${val.id}'`
344
- let delCheckBook = `delete from t_check_book where id ='${val.id}'`
345
- await http.load('POST', 'rs/logic/runSQL', {data: {sql: upAddress}},
346
- {resolveMsg: null, rejectMsg: '删除安检册失败'})
347
- await http.load('POST', 'rs/logic/runSQL', {data: {sql: delCheckBook}},
348
- {resolveMsg: null, rejectMsg: '删除安检册失败'})
349
- this.$showMessage('删除成功')
350
- this.$refs.paged.$refs.criteria.search()
351
- } catch (e) {
352
- this.$showMessage('删除失败', e)
353
- }
354
- }
355
- },
356
-
357
- watch: {
358
- 'model.rows'(val) {
359
- console.log("997997", val)
360
- this.showCaoZuo = val.filter(item => item.f_check_book_type != '小区').length > 0
361
- }
362
- },
363
- computed: {
364
- selected() {
365
- return this.$refs.paged.$refs.grid.selected
366
- }
367
- }
368
- }
369
- </script>
370
- <style scoped>
371
- .newcolor {
372
- color: red;
373
- }
374
-
375
- .table th {
376
- background-color: #f2f6fa;
377
- color: black;
378
- }
379
- </style>
380
- <style lang="less">
381
- #checkbookEntryShow {
382
- .modal-dialog {
383
- width: 80%;
384
- }
385
- }
386
- </style>
1
+ <template>
2
+ <div class="flex">
3
+ <criteria-paged :model="model" v-ref:paged>
4
+ <criteria partial='criteria' @condition-changed='$parent.search' v-ref:criteria>
5
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
+ <div class="row" v-show="!$parent.$parent.$parent.showItemAll">
7
+ <div :class="$parent.$parent.style2" style="margin: 0px">
8
+ <role-selector-safe
9
+ role-name="安检员"
10
+ role-lable="安&nbsp;检&nbsp;员&nbsp;"
11
+ @re-res="$parent.$parent.getRes"
12
+ :value.sync="model.f_checker_id"
13
+ v-model="model.f_checker_id"
14
+ :value-multiple="true"
15
+ condition=" f_checker_name in {}">
16
+ </role-selector-safe>
17
+ </div>
18
+ <div :class="$parent.$parent.style">
19
+ <label class="font_normal_body">安检册名称</label>
20
+ <v-select :value.sync="model.f_check_book_id" v-model='model.f_check_book_id'
21
+ :value-single="true" style="width: 60%"
22
+ class="select_list select"
23
+ :options='$parent.$parent.checkBooks' placeholder='安检册名称'
24
+ close-on-select
25
+ condition="tcb.id ='{}'"></v-select>
26
+ </div>
27
+ <!-- <div :class="$parent.$parent.style">-->
28
+ <!-- <label class="font_normal_body">表册类型</label>-->
29
+ <!-- <v-select :value.sync="model.f_check_book_type" v-model='model.f_check_book_type'-->
30
+ <!-- :value-single="true" style="width: 60%"-->
31
+ <!-- class="select_list select"-->
32
+ <!-- :options='$parent.$parent.bookTypes' placeholder='表册类型'-->
33
+ <!-- close-on-select-->
34
+ <!-- condition="tcb.f_check_book_type ='{}'"></v-select>-->
35
+ <!-- </div>-->
36
+ <!-- <div :class="$parent.$parent.style">-->
37
+ <!-- <label class="font_normal_body">用户类型</label>-->
38
+ <!-- <v-select :value.sync="model.f_user_type" v-model='model.f_user_type'-->
39
+ <!-- :value-single="true" style="width: 60%"-->
40
+ <!-- class="select_list select"-->
41
+ <!-- :options='$parent.$parent.userTypes' placeholder='用户类型'-->
42
+ <!-- close-on-select-->
43
+ <!-- condition="tcb.f_user_type ='{}'"></v-select>-->
44
+ <!-- </div>-->
45
+ <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
46
+ <button type="button" class="button_search button_spacing" @click="search()">查询</button>
47
+ <button type="button" class="button_new button_spacing" @click="$parent.$parent.add()">新增安检册</button>
48
+ <button type="button" class="button_new button_spacing" @click="$parent.$parent.showModal = true">
49
+ 安检册用户管理
50
+ </button>
51
+ <div style="float: right" class="button_spacing"
52
+ v-show="$parent.$parent.$parent.showItem ||$parent.$parent.$parent.showItemUser"
53
+ :class="{'button_shrink_left':$parent.$parent.$parent.showItemAll,'button_shrink_right':!$parent.$parent.$parent.showItemAll}"
54
+ @click="($parent.$parent.$parent.showItem =false) || ($parent.$parent.$parent.showItemUser =false)"></div>
55
+ </div>
56
+
57
+
58
+ </div>
59
+
60
+
61
+ <div class="row" v-show="$parent.$parent.$parent.showItemAll">
62
+ <div :class="$parent.$parent.style2" style="margin: 0px">
63
+ <role-selector-safe
64
+ role-name="安检员"
65
+ role-lable="安&nbsp;检&nbsp;员&nbsp;"
66
+ @re-res="$parent.$parent.getRes"
67
+ :value.sync="model.f_checker_id"
68
+ v-model="model.f_checker_id"
69
+ :value-multiple="true"
70
+ condition=" f_checker_name in {}">
71
+ </role-selector-safe>
72
+ </div>
73
+ <div :class="$parent.$parent.style">
74
+ <label class="font_normal_body">安检册名</label>
75
+ <v-select :value.sync="model.f_check_book_id" v-model='model.f_check_book_id'
76
+ :value-single="true" style="width: 60%"
77
+ class="select_list select"
78
+ :options='$parent.$parent.checkBooks' placeholder='安检册名称'
79
+ close-on-select
80
+ condition="tcb.id ='{}'"></v-select>
81
+ </div>
82
+ <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
83
+ <button type="button" class="button_search button_spacing" @click="search()">查询</button>
84
+ <button type="button" class="button_new button_spacing" @click="$parent.$parent.add()">新增安检册</button>
85
+ <button type="button" class="button_new button_spacing" @click="$parent.$parent.showModal = true">
86
+ 安检册用户管理
87
+ </button>
88
+ <div style="float: right" class="button_spacing"
89
+ v-show="$parent.$parent.$parent.showItem ||$parent.$parent.$parent.showItemUser"
90
+ :class="{'button_shrink_left':$parent.$parent.$parent.showItemAll,'button_shrink_right':!$parent.$parent.$parent.showItemAll}"
91
+ @click="($parent.$parent.$parent.showItem =false) || ($parent.$parent.$parent.showItemUser =false)"></div>
92
+ <!-- <div style="float: right" class="button_spacing"-->
93
+ <!-- :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"-->
94
+ <!-- @click="$parent.$parent.hidden()">-->
95
+ <!-- </div>-->
96
+ </div>
97
+
98
+ </div>
99
+
100
+ </div>
101
+ </criteria>
102
+ <data-grid :model="model" partial="list" class="list_area table_sy" v-ref:grid>
103
+ <template partial='head'>
104
+ <tr>
105
+ <th>
106
+ <nobr>所属安检员</nobr>
107
+ </th>
108
+ <th>
109
+ <nobr>安检册名称</nobr>
110
+ </th>
111
+ <!-- <th>-->
112
+ <!-- <nobr>安检册类型</nobr>-->
113
+ <!-- </th>-->
114
+ <th>
115
+ <nobr>用户类型</nobr>
116
+ </th>
117
+ <th>
118
+ <nobr>创建日期</nobr>
119
+ </th>
120
+ <th>
121
+ <nobr>创建人</nobr>
122
+ </th>
123
+
124
+ <th>
125
+ <nobr>执行日期</nobr>
126
+ </th>
127
+ <th>
128
+ <nobr>执行周期</nobr>
129
+ </th>
130
+ <th>
131
+ <nobr>小区/单位数量</nobr>
132
+ </th>
133
+ <th>
134
+ <nobr>已下发</nobr>
135
+ </th>
136
+ <th>
137
+ <nobr>未下发</nobr>
138
+ </th>
139
+ <th>
140
+ <nobr>已检</nobr>
141
+ </th>
142
+ <th>
143
+ <nobr>未检</nobr>
144
+ </th>
145
+ <!-- <th v-show="$parent.$parent.$parent.showCaoZuo">-->
146
+ <!-- <nobr>操作</nobr>-->
147
+ <!-- </th>-->
148
+ </tr>
149
+ </template>
150
+ <template partial='body'>
151
+ <td style="text-align: center;">{{ row.f_checker_name }}</td>
152
+ <td style="text-align: center;">{{ row.f_check_book_name }}</td>
153
+ <!-- <td style="text-align: center;">{{ row.f_check_book_type }}</td>-->
154
+ <td style="text-align: center;">{{ row.f_user_type }}</td>
155
+ <td style="text-align: center;">{{ row.f_create_date }}</td>
156
+ <td style="text-align: center;">{{ row.f_create_person }}</td>
157
+ <td style="text-align: center;">{{ row.f_run_date }}</td>
158
+ <td style="text-align: center;">{{ row.f_around_time }}{{ row.f_around_unit }}</td>
159
+ <td style="text-align: center;">
160
+ <button @click.stop="$parent.$parent.$parent.details(row)" class="btn btn-link">
161
+ <b>{{ row.f_user_type === '民用' ? row.num2 : row.num3 }}</b></button>
162
+ </td>
163
+ <td style="text-align: center;">{{ row.xiafa }}</td>
164
+ <td style="text-align: center;">
165
+ {{ row.f_user_type == '民用' ? Number(row.num - row.xiafa) : Number(row.num4 - row.xiafa) }}
166
+ </td>
167
+ <td style="text-align: center;">{{ row.yijian }}</td>
168
+ <td style="text-align: center;">{{ row.weijian }}</td>
169
+ <!-- <td v-show="row.f_check_book_type!='小区'" style="text-align: center;"><button class="button_spacing button_search-1" @click.stop='$parent.$parent.$parent.send(row)'>下发</button></td>-->
170
+ </template>
171
+ </data-grid>
172
+ </criteria-paged>
173
+ <modal :show.sync="showModal" :backdrop="false" id="checkbookEntryShow">
174
+ <article slot="modal-body" class="modal-body">
175
+ <check-book-entry v-if="showModal" @select-changed="selectedEntry"></check-book-entry>
176
+ </article>
177
+ <footer slot="modal-footer">
178
+ </footer>
179
+
180
+ </modal>
181
+ <modal :show.sync="showSendModal" :backdrop="false" width="90%" height="90%">
182
+ <article slot="modal-body" class="modal-body" style="height: 80vh">
183
+ <check-book-search-user-list v-if="showSendModal" :row="checkBookRow" :bookrow="checkBookRow"
184
+ :needprops="needprops" :userlogin="userlogin"></check-book-search-user-list>
185
+ </article>
186
+ <footer slot="modal-footer">
187
+ </footer>
188
+
189
+ </modal>
190
+ </div>
191
+ </template>
192
+
193
+ <script>
194
+ import {PagedList} from 'vue-client'
195
+ import {HttpResetClass} from 'vue-client'
196
+ import bus from "../../../bus";
197
+
198
+ export default {
199
+ title: '用户安检情况',
200
+ data() {
201
+ return {
202
+ showSendModal: false,
203
+ searchData: {
204
+ condition: '1=1'
205
+ },
206
+ showCaoZuo: false,
207
+ userlogin: {
208
+ id: this.$login.f.id,
209
+ name: this.$login.f.name,
210
+ orgid: this.$login.f.orgid,
211
+ orgstr: this.$login.f.orgs,
212
+ },
213
+ checkBooks: [],
214
+ bookTypes: [{label: '全部', value: ''}, {label: '用户', value: '用户'}, {label: '小区', value: '小区'}],
215
+ userTypes: [{label: '全部', value: ''}, {label: '民用', value: '民用'}, {label: '非民用', value: '非民用'}],
216
+ aroundUnit: [{label: '年', value: '年'}, {label: '月', value: '月'}, {label: '日', value: '日'}],
217
+ showModal: false,
218
+ excelHeaders: {
219
+
220
+ 'f_userinfo_code': '用户编号',
221
+ 'f_user_name': '用户名称',
222
+ 'f_user_phone': '用户电话',
223
+ 'f_meternumber': '用户表号',
224
+ 'f_user_type': '用户类型',
225
+ 'f_last_checker': '安检员',
226
+ 'f_residential_area': '小区名称',
227
+ 'f_address': '地址',
228
+ 'f_last_check_date': '安检日期',
229
+ 'f_last_check_state': '安检状态',
230
+ 'f_last_check_result': '安检结果'
231
+ },
232
+ model: new PagedList('rs/sql/QueryCheckBook', 20),
233
+ checkBookRow: {},
234
+ checkBook: {
235
+ f_check_book_name: '',
236
+ f_run_date: '',
237
+ f_around_time: '',
238
+ f_around_unit: '',
239
+ f_create_date: '',
240
+ f_create_person: '',
241
+ f_orgid: '',
242
+ f_checker_name: ''
243
+ }
244
+ }
245
+ },
246
+ props: {
247
+ style: {
248
+ type: String,
249
+ default: 'col-sm-2 form-group'
250
+ },
251
+ style2: {
252
+ type: String,
253
+ default: 'col-sm-4 form-group'
254
+ },
255
+ needprops: {
256
+ type: Object,
257
+ default: {}
258
+ },
259
+ showtype: {
260
+ type: String
261
+ }
262
+ },
263
+ ready() {
264
+ bus.$on('fresh-main', () => {
265
+ console.log("进入方法")
266
+ this.$refs.paged.$refs.criteria.search()
267
+ })
268
+ this.freshCheckBook()
269
+ },
270
+ beforeDestroy() {
271
+ //tag
272
+ bus.$off('fresh-main')
273
+ },
274
+ methods: {
275
+ send(row) {
276
+ console.log("7758521", row)
277
+ this.checkBookRow = row
278
+ this.showSendModal = true
279
+ },
280
+ freshCheckBook() {
281
+ this.checkBooks = []
282
+ new HttpResetClass().load('POST', `/rs/sql/safe_singleTable_OrderBy`, {
283
+ data: {
284
+ items: 'id,f_check_book_name',
285
+ tablename: 't_check_book',
286
+ condition: this.$refs.paged.$refs.criteria.model.f_orgid ? `f_orgid in ${this.$refs.paged.$refs.criteria.model.f_orgid} and f_user_type ='${this.showtype}' ` : `f_user_type ='${this.showtype}'`,
287
+ orderitem: 'id desc'
288
+ }
289
+ }, {resolveMsg: null, rejectMsg: null}).then(res => {
290
+ this.checkBooks.push({label: '全部', value: ''})
291
+ res.data.forEach(ress => {
292
+ this.checkBooks.push({
293
+ label: ress.f_check_book_name,
294
+ value: ress.id
295
+ })
296
+ })
297
+ })
298
+ },
299
+ selectedEntry() {
300
+ console.log("666666666666666666")
301
+ },
302
+ details(row) {
303
+ this.$emit('showdetails', row)
304
+ },
305
+ add() {
306
+ this.$emit('addbook')
307
+ },
308
+ ok() {
309
+ //tag
310
+ let http = new HttpResetClass()
311
+ http.load('POST', 'rs/logic/safeEntity', {data: {tableName: 't_check_book', entityData: this.checkBook}},
312
+ {resolveMsg: '更新安检册信息成功', rejectMsg: '保存安检册信息成功'}).then(res => {
313
+ if (res.data.code === 200) {
314
+ this.$showMessage('修改成功')
315
+ this.showModal = false
316
+ this.checkBook = {}
317
+ }
318
+ })
319
+ },
320
+ cancel() {
321
+ this.showModal = false
322
+ this.checkBook = {}
323
+ },
324
+ updateCheckBook(val) {
325
+ this.checkBook = val
326
+ this.showModal = true
327
+ },
328
+ search(args) {
329
+ // //tag
330
+ this.$parent.showItem = false
331
+ this.$parent.showItemUser = false
332
+ args.condition += ` and f_orgid in ${this.model.f_filialeids}`
333
+ args.condition += ` and tcb.f_user_type ='${this.showtype}' `
334
+ return this.model.search(args.condition, args.model)
335
+ },
336
+ getRes(obj) {
337
+ this.model.f_filialeids = this.$login.convertToIn(obj.resids)
338
+ },
339
+ async deleteCheckBook(val) {
340
+ try {
341
+ //tag
342
+ let http = new HttpResetClass()
343
+ let upAddress = `update t_user_address set f_check_book_id = null where f_check_book_id = '${val.id}'`
344
+ let delCheckBook = `delete from t_check_book where id ='${val.id}'`
345
+ await http.load('POST', 'rs/logic/runSQL', {data: {sql: upAddress}},
346
+ {resolveMsg: null, rejectMsg: '删除安检册失败'})
347
+ await http.load('POST', 'rs/logic/runSQL', {data: {sql: delCheckBook}},
348
+ {resolveMsg: null, rejectMsg: '删除安检册失败'})
349
+ this.$showMessage('删除成功')
350
+ this.$refs.paged.$refs.criteria.search()
351
+ } catch (e) {
352
+ this.$showMessage('删除失败', e)
353
+ }
354
+ }
355
+ },
356
+
357
+ watch: {
358
+ 'model.rows'(val) {
359
+ console.log("997997", val)
360
+ this.showCaoZuo = val.filter(item => item.f_check_book_type != '小区').length > 0
361
+ }
362
+ },
363
+ computed: {
364
+ selected() {
365
+ return this.$refs.paged.$refs.grid.selected
366
+ }
367
+ }
368
+ }
369
+ </script>
370
+ <style scoped>
371
+ .newcolor {
372
+ color: red;
373
+ }
374
+
375
+ .table th {
376
+ background-color: #f2f6fa;
377
+ color: black;
378
+ }
379
+ </style>
380
+ <style lang="less">
381
+ #checkbookEntryShow {
382
+ .modal-dialog {
383
+ width: 80%;
384
+ }
385
+ }
386
+ </style>