apply-clients 7.1.36-yuchuan-1 → 7.1.36-yuchuan-2

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.
@@ -1,369 +1,370 @@
1
- <template>
2
- <div>
3
- <criteria-paged :model="model" v-ref:cp>
4
- <criteria partial='criteria' @condition-changed='$parent.searchCondition' v-ref:cri>
5
- <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
- <div class="row">
7
- <div class="form-group col-sm-2">
8
- <label class="font_normal_body">工程编号:</label>
9
- <input type="text" style="width:60%" class="input_search" placeholder='工程编号' v-model="model.f_apply_num"
10
- v-on:keyup.enter="$parent.$parent.search()"
11
- condition="f_apply_num like '%{}%'">
12
- </div>
13
- <div class="form-group col-sm-2">
14
- <label class="font_normal_body">客户名称:</label>
15
- <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
16
- v-on:keyup.enter="$parent.$parent.search()" condition="f_user_name like '%{}%'" placeholder='客户名称'>
17
- </div>
18
- <div class="form-group col-sm-2">
19
- <label class="font_normal_body">联系电话:</label>
20
- <input type="text" style="width:60%" class="input_search" placeholder='联系电话' v-model="model.f_phone"
21
- v-on:keyup.enter="$parent.$parent.search()"
22
- condition="f_phone like '%{}%'">
23
- </div>
24
- <div class="form-group col-sm-2">
25
- <label class="font_normal_body">联&ensp;系&ensp;人:</label>
26
- <input type="text" style="width:60%" class="input_search" placeholder='联系人' v-model="model.f_contact"
27
- v-on:keyup.enter="$parent.$parent.search()"
28
- condition="f_contact like '%{}%'">
29
- </div>
30
- <div class="form-group col-sm-2">
31
- <label class="font_normal_body">设计人员:</label>
32
- <v-select class="select select_list"
33
- placeholder='设计人员'
34
- v-model="model.f_designer_people"
35
- :value.sync="model.f_designer_people"
36
- :options='$parent.$parent.designerPeoples'
37
- :value-single="true"
38
- close-on-select
39
- condition="f_designer_people = '{}'">
40
- </v-select>
41
- </div>
42
- <div class="form-group col-sm-3 button-range">
43
- <button class="button_search button_spacing" @click="$parent.$parent.search()" v-el:cx>查询</button>
44
- <button class="button_search button_spacing" @click="$parent.$parent.loadPage()">返回</button>
45
- <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
46
- <div
47
- :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
48
- @click="$parent.$parent.criteriaShow = !$parent.$parent.criteriaShow"
49
- class="button_spacing"
50
- style="float: right">
51
- </div>
52
- </div>
53
- </div>
54
- <div class="row" v-show="$parent.$parent.criteriaShow">
55
- <div class="form-group col-sm-2">
56
- <label class="font_normal_body">合同编号:</label>
57
- <input type="text" style="width:60%" class="input_search" placeholder='合同编号' v-model="model.f_contract_number"
58
- v-on:keyup.enter="$parent.$parent.search()"
59
- condition="f_contract_number like '%{}%'">
60
- </div>
61
- <div class="form-group col-sm-2">
62
- <label class="font_normal_body">报建类型:</label>
63
- <v-select
64
- v-model="model.f_apply_type"
65
- placeholder='报建类型'
66
- condition="f_apply_type in {}"
67
- :value.sync="model.f_apply_type"
68
- :options='$parent.$parent.applytype'
69
- class="select select_list"
70
- multiple
71
- @change="$parent.$parent.applyTypeChange()"></v-select>
72
- </div>
73
- <div class="form-group col-sm-2">
74
- <label class="font_normal_body">办理环节:</label>
75
- <v-select
76
- v-model="model.defname"
77
- placeholder='办理环节'
78
- condition="defname = '{}'"
79
- :value.sync="model.defname"
80
- :options='$parent.$parent.defnames'
81
- class="select select_list"
82
- :value-single="true"
83
- close-on-select ></v-select>
84
- </div>
85
- <div class="form-group col-sm-2" v-if="false">
86
- <label class="font_normal_body">报建性质:</label>
87
- <v-select
88
- v-model="model.f_apply_nature"
89
- placeholder='报建性质'
90
- condition="f_apply_nature = '{}'"
91
- :value.sync="model.f_apply_nature"
92
- :options='$parent.$parent.applyNatures'
93
- class="select select_list"
94
- :value-single="true"
95
- close-on-select ></v-select>
96
- </div>
97
- <div class="form-group col-sm-2">
98
- <label class="font_normal_body">用户地址:</label>
99
- <input type="text" style="width:60%" class="input_search" placeholder='用户地址' v-model="model.f_address"
100
- v-on:keyup.enter="$parent.$parent.search()"
101
- condition="f_address like '%{}%'">
102
- </div>
103
- <div class="form-group col-sm-2">
104
- <label for="startDate" class="font_normal_body">开始时间:</label>
105
- <datepicker id="startDate" placeholder="开始日期"
106
- style="width: 60%!important;"
107
- v-model="model.startDate"
108
- :value.sync="model.startDate"
109
- :format="'yyyy-MM-dd 00:00:00'"
110
- :show-reset-button="true"
111
- condition="f_apply_date >= '{}'">
112
- </datepicker>
113
- </div>
114
- <div class="form-group col-sm-2">
115
- <label for="endDate" class="font_normal_body">结束时间:</label>
116
- <datepicker id="endDate" placeholder="结束日期"
117
- style="width: 60%!important;"
118
- v-model="model.endDate"
119
- :value.sync="model.endDate"
120
- :format="'yyyy-MM-dd 23:59:59'"
121
- :show-reset-button="true"
122
- condition="f_apply_date <= '{}'">
123
- </datepicker>
124
- </div>
125
- <div class="form-group col-sm-2">
126
- <label class="font_normal_body">来&emsp;&emsp;源:</label>
127
- <v-select
128
- v-model="model.f_apply_source"
129
- placeholder='来源'
130
- condition="u.f_apply_source = '{}'"
131
- :value.sync="model.f_apply_source"
132
- :options='$parent.$parent.sources'
133
- class="select select_list"
134
- :value-single="true"
135
- close-on-select >
136
- </v-select>
137
- </div>
138
- </div>
139
- </div>
140
- </criteria>
141
- <data-grid v-if="$parent.showData" :model="model" partial='list' v-ref:grid class="list_area table_sy">
142
- <template partial='head'>
143
- <tr class="title">
144
- <th style="white-space: nowrap;">序号</th>
145
- <th style="white-space: nowrap;">工程编号</th>
146
- <th style="white-space: nowrap;">客户名称</th>
147
- <th style="white-space: nowrap;">联系人</th>
148
- <th style="white-space: nowrap;">合同编号</th>
149
- <th style="white-space: nowrap;">电话</th>
150
- <th style="white-space: nowrap;">地址</th>
151
- <th style="white-space: nowrap;">来源</th>
152
- <th style="white-space: nowrap;">报建类型</th>
153
- <th style="white-space: nowrap;">报建性质</th>
154
- <th style="white-space: nowrap;">办理环节</th>
155
- <th style="white-space: nowrap;">流程状态</th>
156
- <th style="white-space: nowrap;">报建日期</th>
157
- <th style="white-space: nowrap;">操作</th>
158
- </tr>
159
- </template>
160
- <template partial='body'>
161
- <tr>
162
- <td style="text-align: center;">
163
- <nobr><font>{{$index+1}}</font></nobr>
164
- </td>
165
- <td style="text-align: center;">
166
- <nobr><font>{{row.f_apply_num}}</font></nobr>
167
- </td>
168
- <td style="text-align: center;">
169
- <nobr><font>{{row.f_user_name}}</font></nobr>
170
- </td>
171
- <td style="text-align: center;">
172
- <nobr><font>{{row.f_contact}}</font></nobr>
173
- </td>
174
- <td style="text-align: center;">
175
- <nobr><font>{{row.f_contract_number}}</font></nobr>
176
- </td>
177
- <td style="text-align: center;">
178
- <nobr><font>{{row.f_phone}}</font></nobr>
179
- </td>
180
- <td style="text-align: center;">
181
- <nobr><font>{{row.f_address}}</font></nobr>
182
- </td>
183
- <td style="text-align: center;">
184
- <nobr><font>{{row.f_apply_source}}</font></nobr>
185
- </td>
186
- <td style="text-align: center;">
187
- <nobr><font>{{row.f_apply_type}}</font></nobr>
188
- </td>
189
- <td style="text-align: center;">
190
- <nobr><font>{{row.f_apply_nature}}</font></nobr>
191
- </td>
192
- <td style="text-align: center;">
193
- <nobr><font>{{row.defname}}</font></nobr>
194
- </td>
195
- <td style="text-align: center;">
196
- <nobr><font>{{row.f_sub_state}}</font></nobr>
197
- </td>
198
- <td style="text-align: center;">
199
- <nobr><font>{{row.f_apply_date}}</font></nobr>
200
- </td>
201
- <td style="text-align: center;">
202
- <dropdown>
203
- <button @click="$parent.$parent.$parent.checkfuncs(row)" type="button" data-toggle="dropdown" style="border: 0px;background: none;">
204
- <span class="glyphicon glyphicon-th-list" style="position: inherit;"></span>
205
- </button>
206
- <ul slot="dropdown-menu" class="dropdown-menu dropdown-menu-right">
207
- <li v-for="(index,func) in $parent.$parent.$parent.funcs" v-if="$parent.$parent.$parent.$parent.showFunc(func.personexpression)">
208
- <a href="#" @click="$parent.$parent.$parent.$parent.func(func,row)">{{func.title}}</a>
209
- </li>
210
- </ul>
211
- </dropdown>
212
- </td>
213
- </tr>
214
- </template>
215
- </data-grid>
216
- </criteria-paged>
217
- </div>
218
- </template>
219
- <script>
220
- import {PagedList} from 'vue-client'
221
- import {isEmpty} from '../../Util'
222
- export default {
223
- title: '报建业务信息',
224
- props: ['showData'],
225
- data () {
226
- return {
227
- model: new PagedList('rs/sql/checkuserfunction', 20, {
228
- data: {
229
- f_filiale: this.$login.f.f_fengongsi
230
- }
231
- }),
232
- funcs: [], // 功能列表
233
- applytype: [{label: '全部', value: ''}, ...this.$appdata.getParam('报建类型')],
234
- defnames: isEmpty(this.$appdata.getParam('办理环节')) ? [{label: '全部', value: ''}] : [{label: '全部', value: ''}, ...this.$appdata.getParam('办理环节')], // 流程节点
235
- criteriaShow: false,
236
- sources:[{label: '微信公众号', value: '微信公众号'},{label: '线下发起', value: '线下发起'}],
237
- designerPeoples: this.getDesigner()
238
- }
239
- },
240
- ready () {
241
- // 调用查询
242
- this.search()
243
- },
244
- methods: {
245
- searchCondition (args) {
246
- args.condition = args.condition
247
- if (args.condition.includes('民用报建')) {
248
- args.condition = args.condition.replace('f_apply_type = \'民用报建\'', '(f_apply_type = \'民用报建\' or f_apply_type = \'分户挂表\')');
249
- }
250
- console.log("args.condition",args.condition)
251
- this.model.search(args.condition, args.model)
252
- },
253
- // 查询
254
- search () {
255
- this.$dispatch('search')
256
- },
257
- loadPage () {
258
- this.$dispatch('loadPage')
259
- },
260
- // 获取配置
261
- async checkfuncs (row) {
262
-
263
- this.funcs = []
264
- let functions = JSON.parse(JSON.stringify(this.$function_vue.functions))
265
-
266
- for (const item of functions) {
267
- // 显示类型
268
- if (item.showApplyTypes) {
269
- if (item.showApplyTypes.indexOf(row.f_apply_type) === -1) {
270
- continue
271
- }
272
- }
273
- // 显示节点
274
- if (item.showDefnames) {
275
- if (item.showDefnames.indexOf(row.defname) === -1) {
276
- continue
277
- }
278
- }
279
- // 显示设备
280
- if (item.device && item.device !== 'pc') {
281
- continue
282
- }
283
- this.funcs.push(item)
284
- }
285
- },
286
- // 点击功能操作
287
- func (func, row) {
288
- this.$dispatch('func', func, row)
289
- },
290
- // 权限控制
291
- showFunc (personexpression) {
292
-
293
- if (isEmpty(personexpression)) {
294
- return true
295
- }
296
-
297
- let mark = personexpression.charAt(0)
298
-
299
- let str = personexpression.substring(2, personexpression.length-1)
300
-
301
- if (mark === 'D' && this.$login.f.f_parentname.includes(str)) {
302
- return true
303
- }
304
- if (mark === 'R' && this.$login.f.rolesnames.includes(str)) {
305
- return true
306
- }
307
- if (personexpression.indexOf('RS') === 0) {
308
- for (str of personexpression.substring(3, personexpression.length-1).split(',')) {
309
- if(this.$login.f.rolesnames.includes(str)){
310
- return true
311
- }
312
- }
313
- }
314
- if (mark === 'P' && this.$login.f.id.includes(str)) {
315
- return true
316
- }
317
-
318
- return false
319
- },
320
- async applyTypeChange () {
321
- if (!isEmpty(this.$refs.cp.$refs.cri.model.f_apply_type)) {
322
- let res = await this.$resetpost('rs/logic/getDefnameByType',
323
- { f_apply_type: this.$refs.cp.$refs.cri.model.f_apply_type },
324
- {resolveMsg: null, rejectMsg: '节点信息获取失败!!!'}
325
- )
326
-
327
- this.defnames = [{label: '全部', value: ''}, ...res.data]
328
- } else {
329
- this.defnames = isEmpty(this.$appdata.getParam('办理环节')) ? [{label: '全部', value: ''}] : [{label: '全部', value: ''}, ...this.$appdata.getParam('办理环节')]
330
- }
331
- },
332
- async getDesigner() {
333
- let data = {
334
- source: 'this.getParentByType($organization$).getChildByName($设计人员$).getChildren()',
335
- userid: this.$login.f.id
336
- }
337
-
338
- let res = await this.$resetpost(
339
- 'rs/search',
340
- {data: data},
341
- {resolveMsg: null, rejectMsg: '设计人员人员查询失败!!!'}
342
- )
343
- console.log("ces",res.data.map(item => {
344
- return {
345
- label: item.name,
346
- value: item.name
347
- }
348
- }))
349
- this.designerPeoples = res.data.map(item => {
350
- return {
351
- label: item.name,
352
- value: item.name
353
- }
354
- })
355
- },
356
- clear () {
357
- Object.keys(this.$refs.cp.$refs.cri.model).forEach((key) => {
358
- this.$refs.cp.$refs.cri.model[key] = null
359
- })
360
- }
361
- },
362
- computed: {
363
- },
364
- events: {
365
- }
366
- }
367
- </script>
368
- <style scoped>
369
- </style>
1
+ <template>
2
+ <div>
3
+ <criteria-paged :model="model" v-ref:cp>
4
+ <criteria partial='criteria' @condition-changed='$parent.searchCondition' v-ref:cri>
5
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
+ <div class="row">
7
+ <div class="form-group col-sm-2">
8
+ <label class="font_normal_body">工程编号:</label>
9
+ <input type="text" style="width:60%" class="input_search" placeholder='工程编号' v-model="model.f_apply_num"
10
+ v-on:keyup.enter="$parent.$parent.search()"
11
+ condition="f_apply_num like '%{}%'">
12
+ </div>
13
+ <div class="form-group col-sm-2">
14
+ <label class="font_normal_body">客户名称:</label>
15
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
16
+ v-on:keyup.enter="$parent.$parent.search()" condition="f_user_name like '%{}%'" placeholder='客户名称'>
17
+ </div>
18
+ <div class="form-group col-sm-2">
19
+ <label class="font_normal_body">联系电话:</label>
20
+ <input type="text" style="width:60%" class="input_search" placeholder='联系电话' v-model="model.f_phone"
21
+ v-on:keyup.enter="$parent.$parent.search()"
22
+ condition="f_phone like '%{}%'">
23
+ </div>
24
+ <div class="form-group col-sm-2">
25
+ <label class="font_normal_body">联&ensp;系&ensp;人:</label>
26
+ <input type="text" style="width:60%" class="input_search" placeholder='联系人' v-model="model.f_contact"
27
+ v-on:keyup.enter="$parent.$parent.search()"
28
+ condition="f_contact like '%{}%'">
29
+ </div>
30
+ <div class="form-group col-sm-2">
31
+ <label class="font_normal_body">设计人员:</label>
32
+ <v-select class="select select_list"
33
+ placeholder='设计人员'
34
+ v-model="model.f_designer_people"
35
+ :value.sync="model.f_designer_people"
36
+ :options='$parent.$parent.designerPeoples'
37
+ :value-single="true"
38
+ close-on-select
39
+ condition="f_designer_people = '{}'">
40
+ </v-select>
41
+ </div>
42
+ <div class="form-group col-sm-3 button-range">
43
+ <button class="button_search button_spacing" @click="$parent.$parent.search()" v-el:cx>查询</button>
44
+ <button class="button_search button_spacing" @click="$parent.$parent.loadPage()">返回</button>
45
+ <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
46
+ <div
47
+ :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
48
+ @click="$parent.$parent.criteriaShow = !$parent.$parent.criteriaShow"
49
+ class="button_spacing"
50
+ style="float: right">
51
+ </div>
52
+ </div>
53
+ </div>
54
+ <div class="row" v-show="$parent.$parent.criteriaShow">
55
+ <div class="form-group col-sm-2">
56
+ <label class="font_normal_body">合同编号:</label>
57
+ <input type="text" style="width:60%" class="input_search" placeholder='合同编号' v-model="model.f_contract_number"
58
+ v-on:keyup.enter="$parent.$parent.search()"
59
+ condition="f_contract_number like '%{}%'">
60
+ </div>
61
+ <div class="form-group col-sm-2">
62
+ <label class="font_normal_body">报建类型:</label>
63
+ <v-select
64
+ v-model="model.f_apply_type"
65
+ placeholder='报建类型'
66
+ condition="f_apply_type in {}"
67
+ :value.sync="model.f_apply_type"
68
+ :options='$parent.$parent.applytype'
69
+ class="select select_list"
70
+ multiple
71
+ @change="$parent.$parent.applyTypeChange()"></v-select>
72
+ </div>
73
+ <div class="form-group col-sm-2">
74
+ <label class="font_normal_body">办理环节:</label>
75
+ <v-select
76
+ v-model="model.defname"
77
+ placeholder='办理环节'
78
+ condition="defname = '{}'"
79
+ :value.sync="model.defname"
80
+ :options='$parent.$parent.defnames'
81
+ class="select select_list"
82
+ :value-single="true"
83
+ close-on-select ></v-select>
84
+ </div>
85
+ <div class="form-group col-sm-2" v-if="false">
86
+ <label class="font_normal_body">报建性质:</label>
87
+ <v-select
88
+ v-model="model.f_apply_nature"
89
+ placeholder='报建性质'
90
+ condition="f_apply_nature = '{}'"
91
+ :value.sync="model.f_apply_nature"
92
+ :options='$parent.$parent.applyNatures'
93
+ class="select select_list"
94
+ :value-single="true"
95
+ close-on-select ></v-select>
96
+ </div>
97
+ <div class="form-group col-sm-2">
98
+ <label class="font_normal_body">用户地址:</label>
99
+ <input type="text" style="width:60%" class="input_search" placeholder='用户地址' v-model="model.f_address"
100
+ v-on:keyup.enter="$parent.$parent.search()"
101
+ condition="f_address like '%{}%'">
102
+ </div>
103
+ <div class="form-group col-sm-2">
104
+ <label for="startDate" class="font_normal_body">开始时间:</label>
105
+ <datepicker id="startDate" placeholder="开始日期"
106
+ style="width: 60%!important;"
107
+ v-model="model.startDate"
108
+ :value.sync="model.startDate"
109
+ :format="'yyyy-MM-dd 00:00:00'"
110
+ :show-reset-button="true"
111
+ condition="f_apply_date >= '{}'">
112
+ </datepicker>
113
+ </div>
114
+ <div class="form-group col-sm-2">
115
+ <label for="endDate" class="font_normal_body">结束时间:</label>
116
+ <datepicker id="endDate" placeholder="结束日期"
117
+ style="width: 60%!important;"
118
+ v-model="model.endDate"
119
+ :value.sync="model.endDate"
120
+ :format="'yyyy-MM-dd 23:59:59'"
121
+ :show-reset-button="true"
122
+ condition="f_apply_date <= '{}'">
123
+ </datepicker>
124
+ </div>
125
+ <div class="form-group col-sm-2">
126
+ <label class="font_normal_body">来&emsp;&emsp;源:</label>
127
+ <v-select
128
+ v-model="model.f_apply_source"
129
+ placeholder='来源'
130
+ condition="u.f_apply_source = '{}'"
131
+ :value.sync="model.f_apply_source"
132
+ :options='$parent.$parent.sources'
133
+ class="select select_list"
134
+ :value-single="true"
135
+ close-on-select >
136
+ </v-select>
137
+ </div>
138
+ </div>
139
+ </div>
140
+ </criteria>
141
+ <data-grid v-if="$parent.showData" :model="model" partial='list' v-ref:grid class="list_area table_sy">
142
+ <template partial='head'>
143
+ <tr class="title">
144
+ <th style="white-space: nowrap;">序号</th>
145
+ <th style="white-space: nowrap;">工程编号</th>
146
+ <th style="white-space: nowrap;">客户名称</th>
147
+ <th style="white-space: nowrap;">联系人</th>
148
+ <th style="white-space: nowrap;">合同编号</th>
149
+ <th style="white-space: nowrap;">电话</th>
150
+ <th style="white-space: nowrap;">地址</th>
151
+ <th style="white-space: nowrap;">来源</th>
152
+ <th style="white-space: nowrap;">报建类型</th>
153
+ <th style="white-space: nowrap;">报建性质</th>
154
+ <th style="white-space: nowrap;">办理环节</th>
155
+ <th style="white-space: nowrap;">流程状态</th>
156
+ <th style="white-space: nowrap;">报建日期</th>
157
+ <th style="white-space: nowrap;">操作</th>
158
+ </tr>
159
+ </template>
160
+ <template partial='body'>
161
+ <tr>
162
+ <td style="text-align: center;">
163
+ <nobr><font>{{$index+1}}</font></nobr>
164
+ </td>
165
+ <td style="text-align: center;">
166
+ <nobr><font>{{row.f_apply_num}}</font></nobr>
167
+ </td>
168
+ <td style="text-align: center;">
169
+ <nobr><font>{{row.f_user_name}}</font></nobr>
170
+ </td>
171
+ <td style="text-align: center;">
172
+ <nobr><font>{{row.f_contact}}</font></nobr>
173
+ </td>
174
+ <td style="text-align: center;">
175
+ <nobr><font>{{row.f_contract_number}}</font></nobr>
176
+ </td>
177
+ <td style="text-align: center;">
178
+ <nobr><font>{{row.f_phone}}</font></nobr>
179
+ </td>
180
+ <td style="text-align: center;">
181
+ <nobr><font>{{row.f_address}}</font></nobr>
182
+ </td>
183
+ <td style="text-align: center;">
184
+ <nobr><font>{{row.f_apply_source}}</font></nobr>
185
+ </td>
186
+ <td style="text-align: center;">
187
+ <nobr><font>{{row.f_apply_type}}</font></nobr>
188
+ </td>
189
+ <td style="text-align: center;">
190
+ <nobr><font>{{row.f_apply_nature}}</font></nobr>
191
+ </td>
192
+ <td style="text-align: center;">
193
+ <nobr><font>{{row.defname}}</font></nobr>
194
+ </td>
195
+ <td style="text-align: center;">
196
+ <nobr><font>{{row.f_sub_state}}</font></nobr>
197
+ </td>
198
+ <td style="text-align: center;">
199
+ <nobr><font>{{row.f_apply_date}}</font></nobr>
200
+ </td>
201
+ <td style="text-align: center;">
202
+ <dropdown>
203
+ <button @click="$parent.$parent.$parent.checkfuncs(row)" type="button" data-toggle="dropdown" style="border: 0px;background: none;">
204
+ <span class="glyphicon glyphicon-th-list" style="position: inherit;"></span>
205
+ </button>
206
+ <ul slot="dropdown-menu" class="dropdown-menu dropdown-menu-right">
207
+ <li v-for="(index,func) in $parent.$parent.$parent.funcs" v-if="$parent.$parent.$parent.$parent.showFunc(func.personexpression)">
208
+ <a href="#" @click="$parent.$parent.$parent.$parent.func(func,row)">{{func.title}}</a>
209
+ </li>
210
+ </ul>
211
+ </dropdown>
212
+ </td>
213
+ </tr>
214
+ </template>
215
+ </data-grid>
216
+ </criteria-paged>
217
+ </div>
218
+ </template>
219
+ <script>
220
+ import {PagedList} from 'vue-client'
221
+ import {isEmpty} from '../../Util'
222
+ export default {
223
+ title: '报建业务信息',
224
+ props: ['showData'],
225
+ data () {
226
+ return {
227
+ model: new PagedList('rs/sql/checkuserfunction', 20, {
228
+ data: {
229
+ f_filiale: this.$login.f.f_fengongsi
230
+ }
231
+ }),
232
+ funcs: [], // 功能列表
233
+ applytype: [{label: '全部', value: ''}, ...this.$appdata.getParam('报建类型')],
234
+ defnames: isEmpty(this.$appdata.getParam('办理环节')) ? [{label: '全部', value: ''}] : [{label: '全部', value: ''}, ...this.$appdata.getParam('办理环节')], // 流程节点
235
+ criteriaShow: false,
236
+ sources:[{label: '微信公众号', value: '微信公众号'},{label: '线下发起', value: '线下发起'}],
237
+ designerPeoples: this.getDesigner()
238
+ }
239
+ },
240
+ ready () {
241
+ // 调用查询
242
+ this.search()
243
+ },
244
+ methods: {
245
+ searchCondition (args) {
246
+ args.condition = args.condition
247
+ if (args.condition.includes('民用报建')) {
248
+ args.condition = args.condition.replace('f_apply_type = \'民用报建\'', '(f_apply_type = \'民用报建\' or f_apply_type = \'分户挂表\')');
249
+ }
250
+ console.log("args.condition",args.condition)
251
+ this.model.search(args.condition, args.model)
252
+ },
253
+ // 查询
254
+ search () {
255
+ this.$dispatch('search')
256
+ },
257
+ loadPage () {
258
+ this.$dispatch('loadPage')
259
+ },
260
+ // 获取配置
261
+ async checkfuncs (row) {
262
+
263
+ this.funcs = []
264
+ let functions = JSON.parse(JSON.stringify(this.$function_vue.functions))
265
+
266
+ for (const item of functions) {
267
+ // 显示类型
268
+ if (item.showApplyTypes) {
269
+ if (item.showApplyTypes.indexOf(row.f_apply_type) === -1) {
270
+ continue
271
+ }
272
+ }
273
+ // 显示节点
274
+ if (item.showDefnames) {
275
+ if (item.showDefnames.indexOf(row.defname) === -1) {
276
+ continue
277
+ }
278
+ }
279
+ // 显示设备
280
+ if (item.device && item.device !== 'pc') {
281
+ continue
282
+ }
283
+ this.funcs.push(item)
284
+ }
285
+ },
286
+ // 点击功能操作
287
+ func (func, row) {
288
+ this.$dispatch('func', func, row)
289
+ },
290
+ // 权限控制
291
+ showFunc (personexpression) {
292
+
293
+ if (isEmpty(personexpression)) {
294
+ return true
295
+ }
296
+
297
+ let mark = personexpression.charAt(0)
298
+
299
+ let str = personexpression.substring(2, personexpression.length-1)
300
+
301
+ if (mark === 'D' && this.$login.f.f_parentname.includes(str)) {
302
+ return true
303
+ }
304
+ if (mark === 'R' && this.$login.f.rolesnames.includes(str)) {
305
+ return true
306
+ }
307
+ if (personexpression.indexOf('RS') === 0) {
308
+ for (str of personexpression.substring(3, personexpression.length-1).split(',')) {
309
+ if(this.$login.f.rolesnames.includes(str)){
310
+ return true
311
+ }
312
+ }
313
+ }
314
+ if (mark === 'P' && this.$login.f.id.includes(str)) {
315
+ return true
316
+ }
317
+
318
+ return false
319
+ },
320
+ async applyTypeChange () {
321
+ if (!isEmpty(this.$refs.cp.$refs.cri.model.f_apply_type)) {
322
+ let res = await this.$resetpost('rs/logic/getDefnameByType',
323
+ { f_apply_type: this.$refs.cp.$refs.cri.model.f_apply_type },
324
+ {resolveMsg: null, rejectMsg: '节点信息获取失败!!!'}
325
+ )
326
+
327
+ this.defnames = [{label: '全部', value: ''}, ...res.data]
328
+ } else {
329
+ this.defnames = isEmpty(this.$appdata.getParam('办理环节')) ? [{label: '全部', value: ''}] : [{label: '全部', value: ''}, ...this.$appdata.getParam('办理环节')]
330
+ }
331
+ },
332
+ async getDesigner() {
333
+ let data = {
334
+ source: 'this.getParentByType($organization$).getChildByName($设计人员$).getChildren()',
335
+ userid: this.$login.f.id
336
+ }
337
+
338
+ let res = await this.$resetpost(
339
+ 'rs/search',
340
+ {data: data},
341
+ {resolveMsg: null, rejectMsg: '设计人员人员查询失败!!!'}
342
+ )
343
+ console.log("ces",res.data.map(item => {
344
+ return {
345
+ label: item.name,
346
+ value: item.name
347
+ }
348
+ }))
349
+ this.designerPeoples = res.data.map(item => {
350
+ return {
351
+ label: item.name,
352
+ value: item.name
353
+ }
354
+ })
355
+ },
356
+ clear () {
357
+ Object.keys(this.$refs.cp.$refs.cri.model).forEach((key) => {
358
+ this.$refs.cp.$refs.cri.model[key] = null
359
+ this.$refs.cp.$refs.cri.model.f_apply_type = []
360
+ })
361
+ }
362
+ },
363
+ computed: {
364
+ },
365
+ events: {
366
+ }
367
+ }
368
+ </script>
369
+ <style scoped>
370
+ </style>