system-clients 3.1.81 → 3.1.82-xianyang

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 (132) hide show
  1. package/CHANGELOG.md +51 -51
  2. package/package.json +1 -1
  3. package/src/components/Main.vue +1 -1
  4. package/src/components/equipment/EquipmentManage.vue +68 -65
  5. package/src/components/equipment/PcAdd.vue +5 -5
  6. package/src/components/equipment/PcList.vue +5 -5
  7. package/src/components/equipment/PhoneAdd.vue +4 -4
  8. package/src/components/equipment/PhoneList.vue +4 -4
  9. package/src/components/equipment/PosAdd.vue +205 -43
  10. package/src/components/equipment/PosList.vue +153 -63
  11. package/src/components/equipment/PosManage.vue +92 -9
  12. package/src/components/equipment/QCAdd.vue +320 -0
  13. package/src/components/equipment/QCList.vue +227 -0
  14. package/src/components/equipment/QCManage.vue +150 -0
  15. package/src/components/server/Login.vue +642 -657
  16. package/src/components/server/ModifyPw.vue +4 -5
  17. package/src/components/server/ResSelect.vue +5 -1
  18. package/src/components/server/ResSelectGroup.vue +1 -1
  19. package/src/components/server/RightTree.vue +3 -4
  20. package/src/plugins/HeatGetLoginInfoService.js +491 -491
  21. package/src/plugins/validation.js +7 -7
  22. package/src/stores/HeatAppData.js +38 -38
  23. package/src/system.js +7 -1
  24. package/test/unit/karma.conf.js +49 -49
  25. package/test/unit/specs/components/parammanage/ParamPage.spec.js +20 -20
  26. package/test/unit/specs/components/server/LeftTree/LeftTree.spec.js +22 -22
  27. package/.gradle/3.5/file-changes/last-build.bin +0 -0
  28. package/.gradle/3.5/taskHistory/taskHistory.lock +0 -0
  29. package/.gradle/3.5.1/file-changes/last-build.bin +0 -0
  30. package/.gradle/3.5.1/taskHistory/taskHistory.lock +0 -0
  31. package/.gradle/buildOutputCleanup/built.bin +0 -0
  32. package/.gradle/buildOutputCleanup/cache.properties +0 -2
  33. package/.gradle/buildOutputCleanup/cache.properties.lock +0 -1
  34. package/src/styles/fonts/PINGFANG LIGHT.TTF +0 -0
  35. package/src/styles/fonts/PingFangSC-Regular.ttf +0 -0
  36. package/src/styles/fonts/glyphicons-halflings-regular.eot +0 -0
  37. package/src/styles/fonts/glyphicons-halflings-regular.svg +0 -288
  38. package/src/styles/fonts/glyphicons-halflings-regular.ttf +0 -0
  39. package/src/styles/fonts/glyphicons-halflings-regular.woff +0 -0
  40. package/src/styles/fonts/glyphicons-halflings-regular.woff2 +0 -0
  41. package/src/styles/fonts/pingfang-bold.ttf +0 -0
  42. package/src/styles/fonts/pingfang-medium.ttf +0 -0
  43. package/src/styles/fonts/pingfang-regular.ttf +0 -0
  44. package/src/styles/fonts/trendstrends.ttf +0 -0
  45. package/src/styles/fonts//346/261/211/344/273/252/350/217/261/345/277/203/344/275/223/347/256/200.ttf +0 -0
  46. package/src/styles/less/.csscomb.json +0 -304
  47. package/src/styles/less/.csslintrc +0 -19
  48. package/src/styles/less/alerts.less +0 -73
  49. package/src/styles/less/aofeng/animate.min.css +0 -11
  50. package/src/styles/less/aofeng/expandcss.less +0 -569
  51. package/src/styles/less/aofeng/standard.less +0 -2121
  52. package/src/styles/less/aofeng/themeOne/BinaryTemplate.less +0 -686
  53. package/src/styles/less/aofeng/themeOne/loginStyle.less +0 -1586
  54. package/src/styles/less/aofeng/themeOne/systemStyle.less +0 -2650
  55. package/src/styles/less/aofeng/themeOne.less +0 -14
  56. package/src/styles/less/aofeng/themeTwo/newStyle1.less +0 -415
  57. package/src/styles/less/aofeng/themeTwo.less +0 -3
  58. package/src/styles/less/badges.less +0 -66
  59. package/src/styles/less/bootstrap.less +0 -66
  60. package/src/styles/less/breadcrumbs.less +0 -26
  61. package/src/styles/less/button-groups.less +0 -247
  62. package/src/styles/less/buttons.less +0 -172
  63. package/src/styles/less/carousel.less +0 -269
  64. package/src/styles/less/close.less +0 -34
  65. package/src/styles/less/code.less +0 -69
  66. package/src/styles/less/component-animations.less +0 -33
  67. package/src/styles/less/dropdowns.less +0 -216
  68. package/src/styles/less/fonts-list.less +0 -25
  69. package/src/styles/less/forms.less +0 -626
  70. package/src/styles/less/glyphicons.less +0 -305
  71. package/src/styles/less/grid.less +0 -84
  72. package/src/styles/less/input-groups.less +0 -167
  73. package/src/styles/less/jumbotron.less +0 -52
  74. package/src/styles/less/labels.less +0 -64
  75. package/src/styles/less/list-group.less +0 -141
  76. package/src/styles/less/manageStyle/manageChile.less +0 -180
  77. package/src/styles/less/manageStyle/manageStyle.less +0 -1102
  78. package/src/styles/less/manageStyle/safeStyle.less +0 -498
  79. package/src/styles/less/media.less +0 -66
  80. package/src/styles/less/mixins/alerts.less +0 -14
  81. package/src/styles/less/mixins/background-variant.less +0 -9
  82. package/src/styles/less/mixins/border-radius.less +0 -18
  83. package/src/styles/less/mixins/buttons.less +0 -69
  84. package/src/styles/less/mixins/center-block.less +0 -7
  85. package/src/styles/less/mixins/clearfix.less +0 -22
  86. package/src/styles/less/mixins/forms.less +0 -90
  87. package/src/styles/less/mixins/gradients.less +0 -59
  88. package/src/styles/less/mixins/grid-framework.less +0 -92
  89. package/src/styles/less/mixins/grid.less +0 -122
  90. package/src/styles/less/mixins/hide-text.less +0 -21
  91. package/src/styles/less/mixins/image.less +0 -33
  92. package/src/styles/less/mixins/labels.less +0 -12
  93. package/src/styles/less/mixins/list-group.less +0 -30
  94. package/src/styles/less/mixins/nav-divider.less +0 -10
  95. package/src/styles/less/mixins/nav-vertical-align.less +0 -9
  96. package/src/styles/less/mixins/opacity.less +0 -8
  97. package/src/styles/less/mixins/pagination.less +0 -24
  98. package/src/styles/less/mixins/panels.less +0 -24
  99. package/src/styles/less/mixins/progress-bar.less +0 -10
  100. package/src/styles/less/mixins/reset-filter.less +0 -8
  101. package/src/styles/less/mixins/reset-text.less +0 -18
  102. package/src/styles/less/mixins/resize.less +0 -6
  103. package/src/styles/less/mixins/responsive-visibility.less +0 -15
  104. package/src/styles/less/mixins/size.less +0 -10
  105. package/src/styles/less/mixins/tab-focus.less +0 -9
  106. package/src/styles/less/mixins/table-row.less +0 -44
  107. package/src/styles/less/mixins/text-emphasis.less +0 -9
  108. package/src/styles/less/mixins/text-overflow.less +0 -8
  109. package/src/styles/less/mixins/vendor-prefixes.less +0 -227
  110. package/src/styles/less/mixins.less +0 -40
  111. package/src/styles/less/modals.less +0 -151
  112. package/src/styles/less/navbar.less +0 -660
  113. package/src/styles/less/navs.less +0 -285
  114. package/src/styles/less/normalize.less +0 -424
  115. package/src/styles/less/pager.less +0 -76
  116. package/src/styles/less/pagination.less +0 -89
  117. package/src/styles/less/panels.less +0 -275
  118. package/src/styles/less/popovers.less +0 -131
  119. package/src/styles/less/print.less +0 -101
  120. package/src/styles/less/progress-bars.less +0 -87
  121. package/src/styles/less/responsive-embed.less +0 -35
  122. package/src/styles/less/responsive-utilities.less +0 -194
  123. package/src/styles/less/scaffolding.less +0 -161
  124. package/src/styles/less/stand.less +0 -207
  125. package/src/styles/less/tables.less +0 -262
  126. package/src/styles/less/theme.less +0 -291
  127. package/src/styles/less/thumbnails.less +0 -36
  128. package/src/styles/less/tooltip.less +0 -102
  129. package/src/styles/less/type.less +0 -303
  130. package/src/styles/less/utilities.less +0 -55
  131. package/src/styles/less/variables.less +0 -896
  132. package/src/styles/less/wells.less +0 -29
@@ -1,11 +1,36 @@
1
1
  <template>
2
2
  <div class="flex-row">
3
3
  <div :class="{'basic-main':!isChange,'binary-left':isChange}">
4
- <pos-list :row="row" @select-changed="selected" style="width:auto;" :f_filialeid.sync="f_filialeids" v-ref:list ></pos-list>
4
+ <pos-list :row="row" @dblclick="selected" style="width:auto;" :f_filialeid.sync="f_filialeids" :isshowless="isChange" v-ref:list ></pos-list>
5
5
  </div>
6
- <div class="binary-right" style="margin-left: 10px; width: 50%;" v-if="isChange">
7
- <pos-add :data="row" :f_filialeids.sync="f_filialeids" v-ref:addbox></pos-add>
6
+ <div class="binary-right" style="margin-left: 10px; width: 40%;" v-if="isChange">
7
+ <pos-add :data="row" :info="infoadd" :f_filialeids.sync="f_filialeids" v-ref:addbox></pos-add>
8
8
  </div>
9
+
10
+ <modal v-if="batchPos" :show.sync="batchPos" backdrop="false" >
11
+ <header slot="modal-header" class="modal-header">
12
+ <button type="button" class="close" @click="close"><span>&times;</span></button>
13
+ <h4 class="modal-title">批量操作</h4>
14
+ </header>
15
+ <article slot="modal-body" class="modal-body">
16
+ <form class="form-horizontal">
17
+ <div class="row">
18
+ <div>
19
+ <h4>注意事项</h4>
20
+ <p>1.如果需要对POS设备进行升级,批量选择的POS设备包含非正常状态,则只会对状态为正常的设备进行升级。</p>
21
+ <p>2.如果POS设备处于停用状态,则可以进行启用操作。如果设备处于启用状态,则可以进行停用和升级操作。</p>
22
+ <p>3.批量操作可能耗时较长,请刷新列表查看结果。</p>
23
+ </div>
24
+ </div>
25
+ </form>
26
+ </article>
27
+ <footer slot="modal-footer" class="modal-footer">
28
+ <button type="button" class="button_search button_spacing" @click="batchRoot('2')">批量升级</button>
29
+ <button type="button" class="button_search button_spacing" @click="batchRoot('1')">批量启用</button>
30
+ <button type="button" class="button_search button_spacing" @click="batchRoot('0')">批量停用</button>
31
+ <button type="button" class="button_clear button_spacing" @click='close'>退出</button>
32
+ </footer>
33
+ </modal>
9
34
  </div>
10
35
  </template>
11
36
  <script>
@@ -22,18 +47,74 @@
22
47
  return {
23
48
  isChange: false,
24
49
  row: null,
25
-
50
+ infoadd: true, // 判断是否显示 升级 等按钮(true/false)
51
+ batchPos: false,
26
52
  f_filialeids: ''
27
53
  }
28
54
  },
29
55
  methods: {
30
- selected (obj) {
31
- this.isChange = true
32
- this.row = obj.val
56
+ // 批量操作
57
+ async batchRoot(val){
58
+ let arrs = []
59
+ let alertMessage=''
60
+ let selPos = this.$refs.list.selPos
61
+ if (val==='0'){
62
+ alertMessage='停用'
63
+ for (const tmp of selPos) {
64
+ if (tmp.f_state==='正常') arrs.push(tmp)
65
+ }
66
+ } else if (val==='1'){
67
+ alertMessage='启用'
68
+ for (const tmp of selPos) {
69
+ if (tmp.f_state==='停用') arrs.push(tmp)
70
+ }
71
+ } else if(val==='2'){
72
+ alertMessage='升级'
73
+ for (const tmp of selPos) {
74
+ if (tmp.f_state==='正常') arrs.push(tmp)
75
+ }
76
+ } else {
77
+ this.showAlert('出现异常,请重新进操作')
78
+ return
79
+ }
80
+
81
+ await this.$resetpost('rs/logic/batchPos',{data: {tasks: arrs, taskState: val}}, {rejectMsg: null, resolveMsg: null})
82
+
83
+ // 需要提示
84
+ this.$showAlert(`已经开始批量${alertMessage},选择${selPos.length},其中${arrs.length}台可以正常${alertMessage},具体请留意设备情况,并刷新列表查看执行结果!`)
85
+ this.isChange = false
86
+ this.close()
87
+ },
88
+ close(){
89
+ this.batchPos = false
90
+ },
91
+ selected (obj, idx) {
92
+ console.log(obj)
93
+ if (!(obj instanceof MouseEvent)) {
94
+ if (this.$refs.list.selPos.length > 0){
95
+ this.$showMessage(`系统检测到您进行了多选,是否进行批量操作?`, ['confirm', 'cancel']).then((res) => {
96
+ if (res==='confirm'){
97
+ this.batchPos = true
98
+ } else {
99
+ this.isChange = true
100
+ this.infoadd = true
101
+ this.row = obj
102
+ }
103
+ })
104
+
105
+ }else {
106
+ this.isChange = true
107
+ this.infoadd = true
108
+ this.row = obj
109
+ }
110
+ } else {
111
+ this.$showAlert('如需新增,请点击增加按钮!', 'info', 1000)
112
+ }
33
113
  }
34
114
  },
35
115
  events: {
36
116
  'search' () {
117
+ this.infoadd=true
37
118
  this.isChange = false
38
119
  this.row = null
39
120
  this.$refs.list.$refs.paged.$refs.cri.search()
@@ -55,9 +136,11 @@
55
136
  'close' () {
56
137
  this.isChange = false
57
138
  this.row = null
58
- this.$refs.list.search()
139
+ // this.$refs.list.search()
59
140
  },
60
- 'add' () {
141
+ 'add' (val) {
142
+ this.f_filialeids = val
143
+ this.infoadd=false
61
144
  this.row = null
62
145
  this.isChange = true
63
146
  this.$refs.list.$refs.paged.$refs.grid.selectStore.selected = null
@@ -0,0 +1,320 @@
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="#">圈存机</a></li>
6
+ </ul>
7
+ <form novalidate class="form-horizontal">
8
+ <div class="row">
9
+ <div class="col-sm-4 form-group">
10
+ <label class="font_normal_body">所属人员</label>
11
+ <right-tree @re-res="getRes" :source="source"></right-tree>
12
+ </div>
13
+ <div class="col-sm-4 form-group" :class="[$v.f_terminal_number.required ? 'has-error' : '']">
14
+ <label class="font_normal_body">设备编号</label>
15
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_terminal_number"
16
+ placeholder="设备编号" v-el:f_terminal_number
17
+ v-validate:f_terminal_number='{required :true}'/>
18
+ </div>
19
+ <div class="col-sm-4 form-group" :class="[$v.f_terminal_name.required ? 'has-error' : '']">
20
+ <label class="font_normal_body">设备名称</label>
21
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_terminal_name"
22
+ placeholder="设备名称"
23
+ v-validate:f_terminal_name='{required: true}'/>
24
+ </div>
25
+ <div class="col-sm-4 form-group" :class="{'has-error': $v.f_equipment_type.required}">
26
+ <label class="font_normal_body">设备类型</label>
27
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_equipment_type"
28
+ placeholder="设备类型"
29
+ v-validate:f_equipment_type="{required: true}"/>
30
+ </div>
31
+ <div class="col-sm-4 form-group">
32
+ <label class="font_normal_body">MAC&nbsp;号&nbsp;</label>
33
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_mac_number" placeholder="MAC号">
34
+ </div>
35
+ <div class="col-sm-4 form-group">
36
+ <label class="font_normal_body">机器编号</label>
37
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_machine_number"
38
+ placeholder="机器编号">
39
+ </div>
40
+ <div class="col-sm-4 form-group" :class="{'has-error': $v.f_phone.required}">
41
+ <label class="font_normal_body">联系电话</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-4 form-group" :class="{'has-error': $v.f_address.required}">
47
+ <label class="font_normal_body">&nbsp;&nbsp;&nbsp;所在地</label>
48
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_address" placeholder="所在地"
49
+ v-validate:f_address="{required: true}">
50
+ </div>
51
+ <div class="col-sm-4 form-group" :class="{'has-error': $v.f_bank_name.required}">
52
+ <label class="font_normal_body">所属银行</label>
53
+ <input type="text" class="input_search" style="width: 60%" v-model="model.f_bank_name"
54
+ placeholder="所属银行"
55
+ v-validate:f_bank_name="{required: true}">
56
+ </div>
57
+ </div>
58
+ <div class="col-sm-12 form-group">
59
+ <label class="font_normal_body ">&nbsp;&nbsp;&nbsp;备注&nbsp;&nbsp;&nbsp;</label>
60
+ <textarea class="input_textarea" rows="3" style="width:80%;margin-top:5px"
61
+ v-model="model.f_comments"></textarea>
62
+ </div>
63
+ </form>
64
+ <div style="text-align:right;height:auto;">
65
+ <!-- <button class="button_search" @click="uploadFiles()" v-if="info">上传图片</button>-->
66
+ <button class="btn btn-info" @click="upgrade()" v-if="info && data.f_state==='正常'">更新</button>
67
+ <button class="btn btn-success" @click="getEditState()" v-if="model.f_state === '停用' && info">启用</button>
68
+ <button class="btn btn-danger" @click="getEditState()" v-if="model.f_state === '正常' && info">停用</button>
69
+ <button class="btn button_search" @click="confirm()" :disabled="!$v.valid">确认</button>
70
+ <button class="btn button_clear " @click="cancel()">取消</button>
71
+ </div>
72
+ <modal :show.sync="showfiles" width="80%" style="width:auto;" v-ref:modal middle backdrop="false">
73
+ <article slot="modal-body">
74
+ <upload :blodid="model.f_userinfo_id" :businessid="model.id" v-ref:upload fusetype="收费" isremark="true"
75
+ style="width:auto"></upload>
76
+ </article>
77
+ <footer slot="modal-footer" class="modal-footer">
78
+ </footer>
79
+ </modal>
80
+
81
+ <modal v-if="show" :show.sync="show" v-ref:modal backdrop="false">
82
+ <header slot="modal-header" class="modal-header">
83
+ <button type="button" class="close" @click="close"><span>&times;</span></button>
84
+ <h4 class="modal-title">圈存机更新</h4>
85
+ </header>
86
+ <article slot="modal-body" class="modal-body">
87
+ <form class="form-horizontal">
88
+ <div class="row">
89
+ <div>
90
+ <h4>是否更新?</h4>
91
+ </div>
92
+ </div>
93
+ </form>
94
+ </article>
95
+ <footer slot="modal-footer" class="modal-footer">
96
+ <button type="button" class="button_search button_spacing" @click='upgradeRoot()'>是</button>
97
+ <button type="button" class="button_clear button_spacing" @click='close'>否</button>
98
+ </footer>
99
+ </modal>
100
+ </validator>
101
+
102
+ </div>
103
+ </template>
104
+ <script>
105
+ import {PagedList} from 'vue-client'
106
+
107
+ export default {
108
+ data() {
109
+ return {
110
+ checkparam: false,
111
+ source: `tool.getFullTree(this.getRights().where(row.getType() != $zone$).where(row.getType() != $role$))`,
112
+ model: {
113
+ f_terminal_number: '',
114
+ f_terminal_name: '',
115
+ f_mac_number: '',
116
+ // f_username:'',
117
+ f_bank_name: '',
118
+ f_equipment_type: '圈存机',
119
+ f_state: '正常',
120
+ f_machine_number: '',
121
+ f_phone: '',
122
+ f_comments: '',
123
+ f_address: '',
124
+ f_filialeids: '',
125
+ f_orgid: ''
126
+ },
127
+ showfiles: false,
128
+ show: false,
129
+ infoadd: this.infoadd,
130
+ isSelPop: false
131
+ }
132
+ },
133
+ props: ['data', 'f_filialeids', 'info'],
134
+
135
+ watch: {
136
+ 'data'(val) {
137
+ if (val) {
138
+ this.edit(val)
139
+ } else {
140
+ this.initModel()
141
+ }
142
+ }
143
+ },
144
+ ready() {
145
+ console.log('mac信息:', this.data)
146
+ if (this.data) {
147
+ this.edit(this.data)
148
+ }
149
+ console.log('查看是否隐藏', this.info)
150
+ },
151
+
152
+ methods: {
153
+ recursiveSelOrg(val, flag) {
154
+ if (val.parent) {
155
+ if (val.parent.resourcetype === flag) {
156
+ return {id: val.parent.id, name: val.parent.name}
157
+ } else {
158
+ return this.recursiveSelOrg(val.parent, flag)
159
+ }
160
+ } else {
161
+ return {id: '', name: ''}
162
+ }
163
+ },
164
+ getRes(val) {
165
+ console.log('====================', val)
166
+ if (val.orgobj.length === 1 && val.orgobj[0].resourcetype === 'user') {
167
+
168
+ let org = this.recursiveSelOrg(val.orgobj[0], 'organization')
169
+ this.model.f_user_orgid = org.id
170
+ this.model.f_user_orgname = org.name
171
+ let dep = this.recursiveSelOrg(val.orgobj[0], 'department')
172
+ this.model.f_user_depid = dep.id
173
+ this.model.f_user_depname = dep.name
174
+
175
+ this.model.f_user_operatorid = val.orgobj[0].userid
176
+ this.model.f_user_operator = val.orgobj[0].name
177
+ this.isSelPop = true
178
+ } else {
179
+ // 不可提交
180
+ this.isSelPop = false
181
+ }
182
+ },
183
+ close() {
184
+ this.show = false
185
+ },
186
+ uploadFiles() {
187
+ this.showfiles = !this.showfiles
188
+ },
189
+ getEditState() {
190
+ if (this.model.f_state === '正常') {
191
+ this.$showMessage(`当前设备号: ${this.model.f_terminal_number} ,确认停用该设备?`, ['confirm', 'cancel']).then((res) => {
192
+ if (res === 'confirm') {
193
+ this.$showAlert(`已向设备号: ${this.model.f_terminal_number}发送停用指令,请稍后查看执行结果!`, 'success', 2500)
194
+ this.model.f_state = '停用'
195
+ try {
196
+ // 测试接口
197
+ // this.$resetpost('rs/logic/updatePosState', {data: {number: this.model.f_terminal_number, state: '停用'}}, {resolveMsg: null, rejectMsg: null}, 0)
198
+ // .then((res) => {})
199
+ this.$resetpost('pos/rs/logic/task', {
200
+ data: {
201
+ tasks: [{
202
+ sn: this.model.f_terminal_number,
203
+ taskState: "0"
204
+ }]
205
+ }
206
+ }, {rejectMsg: null, resolveMsg: null})
207
+ } catch (error) {
208
+ this.search()
209
+ }
210
+ }
211
+ })
212
+ } else if (this.model.f_state === '停用') {
213
+ this.$showMessage(`当前设备号: ${this.model.f_terminal_number} ,确认启用该设备?`, ['confirm', 'cancel']).then((res) => {
214
+ if (res === 'confirm') {
215
+ this.$showAlert(`已向设备号: ${this.model.f_terminal_number}发送启用指令,请稍后查看执行结果!`, 'success', 2500)
216
+ this.model.f_state = '正常'
217
+ try {
218
+ // 测试接口
219
+ // this.$resetpost('rs/logic/getEditPosState', {data: {number: this.model.f_terminal_number, state: '正常'}}, {resolveMsg: null, rejectMsg: null}, 0)
220
+ // .then((res) => {})
221
+ this.$resetpost('pos/rs/logic/task', {
222
+ data: {
223
+ tasks: [{
224
+ sn: this.model.f_terminal_number,
225
+ taskState: "1"
226
+ }]
227
+ }
228
+ }, {rejectMsg: null, resolveMsg: null})
229
+ } catch (error) {
230
+ this.search()
231
+ }
232
+ }
233
+ })
234
+ }
235
+ },
236
+ editBeizhu(val) {
237
+ this.editshow = true
238
+ this.posBase = val
239
+ },
240
+
241
+ //升级
242
+ upgrade() {
243
+ this.show = true
244
+ },
245
+ upgradeRoot() {
246
+ this.$resetpost('pos/rs/logic/task', {
247
+ data: {
248
+ tasks: [{
249
+ sn: this.model.f_terminal_number,
250
+ taskState: "2"
251
+ }]
252
+ }
253
+ }, {rejectMsg: null, resolveMsg: null})
254
+ this.$dispatch('refresh')
255
+ // this.$resetpost('rs/logic/t_equipment', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
256
+ // this.$dispatch('refresh')
257
+ // }).catch((error) => {
258
+ // this.$dispatch('refresh')
259
+ // })
260
+ },
261
+ search() {
262
+ this.$refs.paged.$refs.cri.search()
263
+ },
264
+ confirm() {
265
+ // 如果是修改的话,只修改页面上用户填写的信息
266
+ if (!this.info) {
267
+ this.model.f_online = '离线'
268
+ this.model.f_operator = this.$login.f.name
269
+ this.model.f_orgid = this.$login.f.orgid
270
+ this.model.f_filialeids = this.$login.f.orgid
271
+ this.model.f_operatorid = this.$login.f.id
272
+ this.model.f_orgname = this.$login.f.orgs
273
+ this.model.f_depid = this.$login.f.depids
274
+ this.model.f_depname = this.$login.f.deps
275
+ this.model.f_orgstr = this.$login.f.fullids
276
+ }
277
+ this.$resetpost('rs/entity/t_equipment', this.model, {
278
+ resolveMsg: '保存成功',
279
+ rejectMsg: '保存失败'
280
+ }).then((res) => {
281
+ this.$dispatch('refresh')
282
+ }).catch((error) => {
283
+ this.$dispatch('refresh')
284
+ })
285
+
286
+ },
287
+ edit(row) {
288
+ this.model.f_terminal_number = row.f_terminal_number
289
+ this.model.f_terminal_name = row.f_terminal_name
290
+ this.model.f_bank_name = row.f_bank_name
291
+ this.model.f_machine_number = row.f_machine_number
292
+ this.model.f_mac_number = row.f_mac_number
293
+ this.model.f_address = row.f_address
294
+ this.model.f_phone = row.f_phone
295
+ this.model.f_state = row.f_state
296
+ this.model.f_comments = row.f_comments
297
+ // this.model.f_username=row.f_username
298
+ this.model.id = row.id
299
+ this.model.f_filialeids = row.f_filialeids
300
+ this.model.f_orgid = row.f_orgid
301
+ },
302
+ initModel() {
303
+ delete this.model.id
304
+ this.model.f_terminal_number = ''
305
+ this.model.f_terminal_name = ''
306
+ this.model.f_bank_name = ''
307
+ this.model.f_machine_number = ''
308
+ this.model.f_state = '正常'
309
+ this.model.f_phone = ''
310
+ this.model.f_address = ''
311
+ this.model.f_filialeids = ''
312
+ this.model.f_orgid = ''
313
+ this.model.f_comments = ''
314
+ },
315
+ cancel() {
316
+ this.$dispatch('close')
317
+ }
318
+ }
319
+ }
320
+ </script>