system-clients 3.2.93 → 3.2.94-temp

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 (66) hide show
  1. package/.gradle/7.4/checksums/checksums.lock +0 -0
  2. package/.gradle/7.4/dependencies-accessors/dependencies-accessors.lock +0 -0
  3. package/.gradle/7.4/dependencies-accessors/gc.properties +0 -0
  4. package/.gradle/7.4/executionHistory/executionHistory.bin +0 -0
  5. package/.gradle/7.4/executionHistory/executionHistory.lock +0 -0
  6. package/.gradle/7.4/fileChanges/last-build.bin +0 -0
  7. package/.gradle/7.4/fileHashes/fileHashes.bin +0 -0
  8. package/.gradle/7.4/fileHashes/fileHashes.lock +0 -0
  9. package/.gradle/7.4/gc.properties +0 -0
  10. package/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  11. package/.gradle/buildOutputCleanup/cache.properties +2 -0
  12. package/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
  13. package/.gradle/file-system.probe +0 -0
  14. package/.gradle/vcs-1/gc.properties +0 -0
  15. package/package.json +2 -2
  16. package/src/components/Main.vue +42 -18
  17. package/src/components/equipment/EquipmentManage.vue +83 -83
  18. package/src/components/equipment/PcAdd.vue +115 -115
  19. package/src/components/equipment/PcList.vue +119 -119
  20. package/src/components/equipment/PcManage.vue +61 -61
  21. package/src/components/equipment/PhoneAdd.vue +118 -118
  22. package/src/components/equipment/PhoneList.vue +113 -113
  23. package/src/components/equipment/PhoneManage.vue +61 -61
  24. package/src/components/equipment/PosAdd.vue +10 -6
  25. package/src/components/equipment/PosList.vue +5 -3
  26. package/src/components/equipment/PosParamAdd.vue +1 -1
  27. package/src/components/equipment/PosParamList.vue +2 -2
  28. package/src/components/parammanage/ParamPage.vue +12 -12
  29. package/src/components/parammanage/SinglePage.vue +8 -8
  30. package/src/components/server/Login.vue +35 -17
  31. package/src/components/server/ModifyPw.vue +0 -1
  32. package/src/components/server/PcdBuildingSelect.vue +0 -2
  33. package/src/components/server/ResSelect.vue +166 -169
  34. package/src/components/server/ResSelectGroup.vue +211 -211
  35. package/src/components/server/RoleSelector.vue +2 -3
  36. package/src/filiale/baole/Login.vue +0 -2
  37. package/src/filiale/bayan/PosAdd.vue +369 -0
  38. package/src/filiale/bayan/PosList.vue +349 -0
  39. package/src/filiale/bayan/PosManage.vue +138 -0
  40. package/src/filiale/bayan/system.js +6 -0
  41. package/src/filiale/chengtou/Login.vue +0 -2
  42. package/src/filiale/dongguan/Login.vue +0 -2
  43. package/src/filiale/dongguan/Main.vue +0 -2
  44. package/src/filiale/furuike/Login.vue +0 -4
  45. package/src/filiale/furuike/Main.vue +0 -2
  46. package/src/filiale/gehua/Main.vue +0 -2
  47. package/src/filiale/konggang/Login.vue +0 -2
  48. package/src/filiale/qianneng/Login.vue +582 -584
  49. package/src/filiale/qianneng/Main.vue +2 -4
  50. package/src/filiale/qianneng/ModifyPw.vue +0 -1
  51. package/src/filiale/rizhao/Login.vue +0 -2
  52. package/src/filiale/rizhao/Main.vue +1 -1
  53. package/src/filiale/shiquan/Login.vue +0 -2
  54. package/src/filiale/tianyi/Login.vue +0 -2
  55. package/src/filiale/tongchuan/Login.vue +0 -2
  56. package/src/filiale/tongchuan/Main.vue +1 -3
  57. package/src/filiale/weinan/Main.vue +923 -924
  58. package/src/filiale/weinan/system.js +7 -7
  59. package/src/filiale/wenxi/Login.vue +0 -2
  60. package/src/filiale/wenxi/Main.vue +0 -2
  61. package/src/filiale/wuhai/Main.vue +0 -3
  62. package/src/filiale/yuchuan/Login.vue +0 -2
  63. package/src/filiale/yuchuan/Main.vue +0 -2
  64. package/src/filiale/zhoukou/Main.vue +0 -2
  65. package/src/plugins/GetLoginInfoService.js +75 -13
  66. package/src/stores/AppData.js +1 -1
@@ -0,0 +1,369 @@
1
+ <template>
2
+ <div class="auto select-overspread">
3
+ <validator name='v'>
4
+ <ul class="nav nav-tabs" >
5
+ <li role="presentation" class="active"><a href="#">POS</a></li>
6
+ </ul>
7
+ <form novalidate class="form-horizontal" >
8
+ <div class="row">
9
+ <div class="col-sm-6 form-group">
10
+ <label class="font_normal_body">&ensp;公&emsp;&emsp;司&ensp;</label>
11
+ <right-tree @re-res="getRes1"></right-tree>
12
+ </div>
13
+ <div class="col-sm-6 form-group">
14
+ <label class="font_normal_body">设备负责人</label>
15
+ <right-tree @re-res="getRes" :source="source"></right-tree>
16
+ </div>
17
+ <div class="col-sm-6 form-group" :class="[$v.f_terminal_number.required ? 'has-error' : '']">
18
+ <label class="font_normal_body">设备编号</label>
19
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_terminal_number" placeholder="设备编号" v-el:f_terminal_number
20
+ v-validate:f_terminal_number='{required :true}' />
21
+ </div>
22
+ <div class="col-sm-6 form-group" :class="[$v.f_terminal_name.required ? 'has-error' : '']">
23
+ <label class="font_normal_body">&ensp;设备名称&ensp;</label>
24
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_terminal_name" placeholder="设备名称"
25
+ v-validate:f_terminal_name='{required: true}' />
26
+ </div>
27
+ <div class="col-sm-6 form-group" :class="{'has-error': $v.f_equipment_type.required}">
28
+ <label class="font_normal_body">设备类型</label>
29
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_equipment_type" placeholder="设备类型"
30
+ v-validate:f_equipment_type="{required: true}" />
31
+ </div>
32
+ <div class="col-sm-6 form-group">
33
+ <label class="font_normal_body" >&ensp;MAC&nbsp;号&nbsp;&ensp;</label>
34
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_mac_number" placeholder="MAC号" >
35
+ </div>
36
+ <div class="col-sm-6 form-group">
37
+ <label class="font_normal_body" >机器编号</label>
38
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_machine_number" placeholder="机器编号" >
39
+ </div>
40
+ <div class="col-sm-6 form-group" :class="{'has-error': $v.f_phone.required}">
41
+ <label class="font_normal_body">&ensp;联系电话&ensp;</label>
42
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_phone" placeholder="联系电话"
43
+ v-validate:f_phone="{required: true, minlength:7, maxlength: 11}" title="手机号必须7-11位">
44
+ <!-- <div class="font_normal_body" v-if="$v.f_phone.minlength || $v.f_phone.maxlength"><span>手机号必须7-11位</span></div>-->
45
+ </div>
46
+ <div class="col-sm-6 form-group" :class="{'has-error': $v.f_bank_name.required}">
47
+ <label class="font_normal_body">所属银行</label>
48
+ <v-select id="f_charge_type"
49
+ v-model="model.f_bank_name"
50
+ placeholder='所属银行'
51
+ :value.sync="model.f_bank_name"
52
+ :options='bankAffiliation'
53
+ :value-single="true"
54
+ v-validate:f_bank_name="{ required: true }"
55
+ close-on-select clear-button>
56
+ </v-select>
57
+ </div>
58
+ <div class="col-sm-6 form-group">
59
+ <label class="font_normal_body">&ensp;所属参数&ensp;</label>
60
+ <v-select id="f_charge_type"
61
+ v-model="model.f_param_id"
62
+ placeholder='所属参数'
63
+ :value.sync="model.f_param_id"
64
+ :options='ParamTypeItems'
65
+ close-on-select clear-button>
66
+ </v-select>
67
+ </div>
68
+ <div class="col-sm-6 form-group">
69
+ <label class="font_normal_body">所属部门</label>
70
+ <res-select restype='department'
71
+ :is-mul="false"
72
+ @res-select="getdep"
73
+ :parentresid="depresid"
74
+ :initresid="initresid">
75
+ </res-select>
76
+ </div>
77
+
78
+ </div>
79
+ <div class="col-sm-12 form-group" :class="{'has-error': $v.f_address.required}">
80
+ <label class="font_normal_body">&ensp;放置地点&ensp;</label>
81
+ <textarea class="input_textarea" style="width: 80%" v-model="model.f_address" placeholder="所在地"
82
+ v-validate:f_address="{required: true}" rows="2"></textarea>
83
+ </div>
84
+ <div class="col-sm-12 form-group">
85
+ <label class="font_normal_body " >&ensp;&nbsp;&nbsp;&nbsp;&nbsp;备注&nbsp;&nbsp;&nbsp;&ensp;</label>
86
+ <textarea class="input_textarea" rows="3" style="width:80%;margin-top:5px" v-model="model.f_comments"></textarea>
87
+ </div>
88
+ </form>
89
+ <div style="text-align:right;height:auto;">
90
+ <button class="button_search" @click="uploadFiles()" v-if="info">上传图片</button>
91
+ <button class="btn btn-info" @click="upgrade()" v-if="info && data.f_state==='正常'">升级</button>
92
+ <button class="btn btn-success" @click="getEditState()" v-if="model.f_state === '停用' && info" >启用</button>
93
+ <button class="btn btn-danger" @click="getEditState()" v-if="model.f_state === '正常' && info" >停用</button>
94
+ <button class="btn button_search" @click="confirm()" :disabled="!$v.valid" >确认</button>
95
+ <button class="btn button_clear " @click="cancel()" >取消</button>
96
+ </div>
97
+ <modal :show.sync="showfiles" width="80%" style="width:auto;" v-ref:modal middle backdrop="false">
98
+ <article slot="modal-body" style="height: 500px">
99
+ <upload v-show="showfiles" :businessid="model.id" v-ref:upload fusetype="POS" isremark="true" style="width:auto" ></upload>
100
+ </article>
101
+ <footer slot="modal-footer" class="modal-footer">
102
+ </footer>
103
+ </modal>
104
+ <modal v-if="show" :show.sync="show" v-ref:modal backdrop="false" >
105
+ <header slot="modal-header" class="modal-header">
106
+ <button type="button" class="close" @click="close"><span>&times;</span></button>
107
+ <h4 class="modal-title">pos机升级</h4>
108
+ </header>
109
+ <article slot="modal-body" class="modal-body">
110
+ <form class="form-horizontal">
111
+ <div class="row">
112
+ <div>
113
+ <h4>是否升级?</h4>
114
+ </div>
115
+ <!-- <div class="col-sm-6 form-group">-->
116
+ <!-- <label class="font_normal_body">参数名称</label>-->
117
+ <!-- <input type="text" class="input_search" style="width: 60%" v-model="modifyItem.name" @keyup.enter="confirm">-->
118
+ <!-- </div>-->
119
+ <!-- <div class="col-sm-6 form-group" v-if="modifyItem.EntityType === 't_parameter'">-->
120
+ <!-- <div class="checkbox">-->
121
+ <!-- <label>-->
122
+ <!-- <input type="checkbox" v-model="modifyItem.isGlobal" :checked="modifyItem.isGlobal">是否全局-->
123
+ <!-- </label>-->
124
+ <!-- </div>-->
125
+ <!-- </div>-->
126
+ </div>
127
+ </form>
128
+ </article>
129
+ <footer slot="modal-footer" class="modal-footer">
130
+ <button type="button" class="button_search button_spacing" @click='upgradeRoot()'>是</button>
131
+ <button type="button" class="button_clear button_spacing" @click='close'>否</button>
132
+ </footer>
133
+ </modal>
134
+ </validator>
135
+
136
+ </div>
137
+ </template>
138
+ <script>
139
+ import {HttpResetClass, PagedList} from 'vue-client'
140
+ export default {
141
+ data () {
142
+ return {
143
+ depname: '',
144
+ f_depid: '',
145
+ orgname: '',
146
+ initresid: [], // 用于存放初始化选中的部门 ID
147
+ depresid: [this.$login.f.depids],
148
+ depid: [this.f_depid],
149
+ f_orgid: this.$login.f.orgid,
150
+ userresid: [this.$login.f.id],
151
+ checkparam: false,
152
+ bankAffiliation: this.$appdata.getParam('所属银行'),
153
+ source: `tool.getFullTree(this.getRights().where(row.getType() != $zone$).where(row.getType() != $role$))`,
154
+ userid: this.$login.f.id,
155
+ model: {
156
+ f_terminal_number: '',
157
+ f_terminal_name: '',
158
+ f_depname: '',
159
+ f_mac_number:'',
160
+ // f_username:'',
161
+ f_bank_name: '微信',
162
+ f_equipment_type: 'POS',
163
+ f_state: '正常',
164
+ f_machine_number: '',
165
+ f_phone:'',
166
+ f_comments:'',
167
+ f_address:'',
168
+ f_filialeids: '',
169
+ f_orgid:'',
170
+ f_param_id:''
171
+ },
172
+ ParamTypeItems:[],
173
+ showfiles: false,
174
+ show:false,
175
+ infoadd: this.infoadd,
176
+ isSelPop: false
177
+ }
178
+ },
179
+ props: ['data', 'f_filialeids','info'],
180
+
181
+ watch: {
182
+ 'data' (val) {
183
+ if (val) {
184
+ this.edit(val)
185
+ } else {
186
+ this.initModel()
187
+ }
188
+ }
189
+ },
190
+ async ready () {
191
+ console.log('mac信息:', this.data)
192
+ if (this.data) {
193
+ this.edit(this.data)
194
+ }
195
+ console.log('查看是否隐藏', this.info)
196
+ try {
197
+ // 获取参数
198
+ let http = new HttpResetClass()
199
+ let res = await http.load('POST', 'rs/sql/get_posParam', {data: {condition : ' 1 = 1 '}}, {
200
+ resolveMsg: null,
201
+ rejectMsg: '获取参数出错!!'
202
+ })
203
+ this.ParamTypeItems = res.data.map(item=>{
204
+ return {
205
+ label:item.name,
206
+ value:item.f_param_id
207
+ }
208
+ })
209
+ } catch (e) {
210
+ console.log(e)
211
+ }
212
+ },
213
+
214
+ methods: {
215
+ getRes1 (obj) {
216
+ this.orgname = obj.res[0]
217
+ this.depresid = obj.resids
218
+ this.f_orgid = obj.resids
219
+ this.userresid = obj.resids
220
+ },
221
+ getdep (obj, val) {
222
+ this.depname = val
223
+ // this.userresid = obj
224
+ this.f_depid = obj
225
+ },
226
+ recursiveSelOrg(val, flag){
227
+ if(val.parent){
228
+ if(val.parent.resourcetype===flag){
229
+ return {id: val.parent.id, name: val.parent.name}
230
+ } else {
231
+ return this.recursiveSelOrg(val.parent,flag)
232
+ }
233
+ } else {
234
+ return {id: '', name: ''}
235
+ }
236
+ },
237
+ getRes(val){
238
+ console.log('====================', val)
239
+ if (val.orgobj.length === 1 && val.orgobj[0].resourcetype === 'user'){
240
+
241
+ let org = this.recursiveSelOrg(val.orgobj[0], 'organization')
242
+ this.model.f_orgid=org.id
243
+ this.model.f_orgname=org.name
244
+ let dep = this.recursiveSelOrg(val.orgobj[0], 'department')
245
+ this.model.f_depid=dep.id
246
+ this.model.f_depname=dep.name
247
+
248
+ this.model.f_operatorid = val.orgobj[0].userid
249
+ this.model.f_operator=val.orgobj[0].name
250
+ this.isSelPop = true
251
+ } else {
252
+ // 不可提交
253
+ this.isSelPop = false
254
+ }
255
+ },
256
+ close () {
257
+ this.show = false
258
+ },
259
+ uploadFiles(){
260
+ this.showfiles= !this.showfiles
261
+ },
262
+ getEditState () {
263
+ if (this.model.f_state === '正常') {
264
+ this.$showMessage(`当前设备号: ${this.model.f_terminal_number} ,确认停用该设备?`, ['confirm', 'cancel']).then((res) => {
265
+ if (res === 'confirm') {
266
+ this.$showAlert(`已向设备号: ${this.model.f_terminal_number}发送停用指令,请稍后查看执行结果!`, 'success', 2500)
267
+ this.model.f_state = '停用'
268
+ try {
269
+ // 测试接口
270
+ // this.$resetpost('rs/logic/updatePosState', {data: {number: this.model.f_terminal_number, state: '停用'}}, {resolveMsg: null, rejectMsg: null}, 0)
271
+ // .then((res) => {})
272
+ this.$resetpost('rs/logic/batchPos',{data: {tasks: [this.data], taskState: 0}}, {rejectMsg: null, resolveMsg: null})
273
+ } catch (error) {
274
+ this.search()
275
+ }
276
+ }
277
+ })
278
+ } else if (this.model.f_state === '停用'){
279
+ this.$showMessage(`当前设备号: ${this.model.f_terminal_number} ,确认启用该设备?`, ['confirm', 'cancel']).then((res) => {
280
+ if (res === 'confirm') {
281
+ this.$showAlert(`已向设备号: ${this.model.f_terminal_number}发送启用指令,请稍后查看执行结果!`, 'success', 2500)
282
+ this.model.f_state = '正常'
283
+ try {
284
+ // 测试接口
285
+ // this.$resetpost('rs/logic/getEditPosState', {data: {number: this.model.f_terminal_number, state: '正常'}}, {resolveMsg: null, rejectMsg: null}, 0)
286
+ // .then((res) => {})
287
+ this.$resetpost('rs/logic/batchPos',{data: {tasks: [this.data], taskState: 1}}, {rejectMsg: null, resolveMsg: null})
288
+ } catch (error) {
289
+ this.search()
290
+ }
291
+ }
292
+ })
293
+ }
294
+ },
295
+ editBeizhu (val) {
296
+ this.editshow = true
297
+ this.posBase = val
298
+ },
299
+
300
+ //升级
301
+ upgrade(){
302
+ this.show=true
303
+ },
304
+ upgradeRoot() {
305
+ this.$resetpost('rs/logic/batchPos',{data: {tasks: [this.data], taskState: 2}}, {rejectMsg: null, resolveMsg: null})
306
+ this.$dispatch('refresh')
307
+ },
308
+ search () {
309
+ this.$refs.paged.$refs.cri.search()
310
+ },
311
+ confirm () {
312
+ // 如果是修改的话,只修改页面上用户填写的信息
313
+ this.model.f_depname = this.depname[0]
314
+ this.model.f_depid = this.f_depid[0]
315
+ if (!this.info) {
316
+ this.model.f_online = '离线'
317
+ this.model.f_operator = this.$login.f.name
318
+ this.model.f_orgid = this.$login.f.orgid
319
+ this.model.f_filialeids = this.$login.f.orgid
320
+ this.model.f_operatorid = this.$login.f.id
321
+ this.model.f_orgname = this.$login.f.orgs
322
+ // this.model.f_depname=this.depname[0]
323
+ this.model.f_orgstr = this.$login.f.fullids
324
+ }
325
+ this.$resetpost('rs/entity/t_equipment', this.model, {resolveMsg: '保存成功', rejectMsg: '保存失败'}).then((res) => {
326
+ this.$dispatch('refresh')
327
+ }).catch((error) => {
328
+ this.$dispatch('refresh')
329
+ })
330
+
331
+ },
332
+ edit (row) {
333
+ this.model.f_terminal_number = row.f_terminal_number
334
+ this.model.f_terminal_name = row.f_terminal_name
335
+ this.model.f_bank_name = row.f_bank_name
336
+ this.model.f_machine_number = row.f_machine_number
337
+ this.model.f_mac_number = row.f_mac_number
338
+ this.model.f_address = row.f_address
339
+ this.model.f_phone = row.f_phone
340
+ this.model.f_state = row.f_state
341
+ this.model.f_comments=row.f_comments
342
+ this.model.f_param_id=row.f_param_id
343
+ // this.model.f_username=row.f_username
344
+ this.model.id = row.id
345
+ this.model.f_filialeids=row.f_filialeids
346
+ this.model.f_orgid = row.f_orgid
347
+ this.model.f_depname = row.f_depname
348
+ this.initresid = [row.f_depid]
349
+ },
350
+ initModel() {
351
+ delete this.model.id
352
+ this.model.f_terminal_number = ''
353
+ this.model.f_terminal_name = ''
354
+ this.model.f_bank_name = ''
355
+ this.model.f_machine_number = ''
356
+ this.model.f_state = '正常'
357
+ this.model.f_phone = ''
358
+ this.model.f_param_id = ''
359
+ this.model.f_address = ''
360
+ this.model.f_filialeids = ''
361
+ this.model.f_orgid = ''
362
+ this.model.f_comments = ''
363
+ },
364
+ cancel() {
365
+ this.$dispatch('close')
366
+ }
367
+ }
368
+ }
369
+ </script>