system-clients 3.1.85 → 3.1.86-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.
- package/package.json +1 -1
- package/src/components/Main.vue +1 -1
- package/src/components/equipment/EquipmentManage.vue +68 -65
- package/src/components/equipment/PcAdd.vue +5 -5
- package/src/components/equipment/PcList.vue +5 -5
- package/src/components/equipment/PhoneAdd.vue +4 -4
- package/src/components/equipment/PhoneList.vue +4 -4
- package/src/components/equipment/PosAdd.vue +205 -43
- package/src/components/equipment/PosList.vue +153 -63
- package/src/components/equipment/PosManage.vue +92 -9
- package/src/components/equipment/QCAdd.vue +318 -0
- package/src/components/equipment/QCList.vue +230 -0
- package/src/components/equipment/QCManage.vue +150 -0
- package/src/components/server/Login.vue +642 -687
- package/src/components/server/ModifyPw.vue +4 -5
- package/src/components/server/ResSelect.vue +5 -1
- package/src/components/server/ResSelectGroup.vue +1 -1
- package/src/components/server/RightTree.vue +3 -4
- package/src/plugins/EncryptUtil.js +53 -0
- package/src/plugins/GetLoginInfoService.js +2 -0
- package/src/plugins/validation.js +1 -1
- package/src/system.js +7 -1
- package/.gradle/3.5/file-changes/last-build.bin +0 -0
- package/.gradle/3.5/taskHistory/taskHistory.lock +0 -0
- package/.gradle/5.5/fileChanges/last-build.bin +0 -0
- package/.gradle/5.5/fileHashes/fileHashes.lock +0 -0
- package/.gradle/5.5/gc.properties +0 -0
- package/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/.gradle/buildOutputCleanup/built.bin +0 -0
- package/.gradle/buildOutputCleanup/cache.properties +0 -2
- package/.gradle/buildOutputCleanup/cache.properties.lock +0 -1
- package/.gradle/vcs-1/gc.properties +0 -0
- package/src/styles/fonts/PINGFANG LIGHT.TTF +0 -0
- package/src/styles/fonts/PingFangSC-Regular.ttf +0 -0
- package/src/styles/fonts/glyphicons-halflings-regular.eot +0 -0
- package/src/styles/fonts/glyphicons-halflings-regular.svg +0 -288
- package/src/styles/fonts/glyphicons-halflings-regular.ttf +0 -0
- package/src/styles/fonts/glyphicons-halflings-regular.woff +0 -0
- package/src/styles/fonts/glyphicons-halflings-regular.woff2 +0 -0
- package/src/styles/fonts/pingfang-bold.ttf +0 -0
- package/src/styles/fonts/pingfang-medium.ttf +0 -0
- package/src/styles/fonts/pingfang-regular.ttf +0 -0
- package/src/styles/fonts/trendstrends.ttf +0 -0
- 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
- package/src/styles/less/.csscomb.json +0 -304
- package/src/styles/less/.csslintrc +0 -19
- package/src/styles/less/alerts.less +0 -73
- package/src/styles/less/aofeng/animate.min.css +0 -11
- package/src/styles/less/aofeng/expandcss.less +0 -569
- package/src/styles/less/aofeng/standard.less +0 -2121
- package/src/styles/less/aofeng/themeOne/BinaryTemplate.less +0 -686
- package/src/styles/less/aofeng/themeOne/loginStyle.less +0 -1586
- package/src/styles/less/aofeng/themeOne/systemStyle.less +0 -2650
- package/src/styles/less/aofeng/themeOne.less +0 -17
- package/src/styles/less/aofeng/themeTwo/newStyle1.less +0 -415
- package/src/styles/less/aofeng/themeTwo.less +0 -3
- package/src/styles/less/badges.less +0 -66
- package/src/styles/less/bootstrap.less +0 -66
- package/src/styles/less/breadcrumbs.less +0 -26
- package/src/styles/less/button-groups.less +0 -247
- package/src/styles/less/buttons.less +0 -172
- package/src/styles/less/carousel.less +0 -269
- package/src/styles/less/close.less +0 -34
- package/src/styles/less/code.less +0 -69
- package/src/styles/less/component-animations.less +0 -33
- package/src/styles/less/dropdowns.less +0 -216
- package/src/styles/less/fonts-list.less +0 -25
- package/src/styles/less/forms.less +0 -626
- package/src/styles/less/glyphicons.less +0 -305
- package/src/styles/less/grid.less +0 -84
- package/src/styles/less/input-groups.less +0 -167
- package/src/styles/less/jumbotron.less +0 -52
- package/src/styles/less/labels.less +0 -64
- package/src/styles/less/list-group.less +0 -141
- package/src/styles/less/manageStyle/manageChile.less +0 -180
- package/src/styles/less/manageStyle/manageStyle.less +0 -1102
- package/src/styles/less/manageStyle/safeStyle.less +0 -498
- package/src/styles/less/media.less +0 -66
- package/src/styles/less/mixins/alerts.less +0 -14
- package/src/styles/less/mixins/background-variant.less +0 -9
- package/src/styles/less/mixins/border-radius.less +0 -18
- package/src/styles/less/mixins/buttons.less +0 -69
- package/src/styles/less/mixins/center-block.less +0 -7
- package/src/styles/less/mixins/clearfix.less +0 -22
- package/src/styles/less/mixins/forms.less +0 -90
- package/src/styles/less/mixins/gradients.less +0 -59
- package/src/styles/less/mixins/grid-framework.less +0 -92
- package/src/styles/less/mixins/grid.less +0 -122
- package/src/styles/less/mixins/hide-text.less +0 -21
- package/src/styles/less/mixins/image.less +0 -33
- package/src/styles/less/mixins/labels.less +0 -12
- package/src/styles/less/mixins/list-group.less +0 -30
- package/src/styles/less/mixins/nav-divider.less +0 -10
- package/src/styles/less/mixins/nav-vertical-align.less +0 -9
- package/src/styles/less/mixins/opacity.less +0 -8
- package/src/styles/less/mixins/pagination.less +0 -24
- package/src/styles/less/mixins/panels.less +0 -24
- package/src/styles/less/mixins/progress-bar.less +0 -10
- package/src/styles/less/mixins/reset-filter.less +0 -8
- package/src/styles/less/mixins/reset-text.less +0 -18
- package/src/styles/less/mixins/resize.less +0 -6
- package/src/styles/less/mixins/responsive-visibility.less +0 -15
- package/src/styles/less/mixins/size.less +0 -10
- package/src/styles/less/mixins/tab-focus.less +0 -9
- package/src/styles/less/mixins/table-row.less +0 -44
- package/src/styles/less/mixins/text-emphasis.less +0 -9
- package/src/styles/less/mixins/text-overflow.less +0 -8
- package/src/styles/less/mixins/vendor-prefixes.less +0 -227
- package/src/styles/less/mixins.less +0 -40
- package/src/styles/less/modals.less +0 -151
- package/src/styles/less/navbar.less +0 -660
- package/src/styles/less/navs.less +0 -285
- package/src/styles/less/normalize.less +0 -424
- package/src/styles/less/pager.less +0 -76
- package/src/styles/less/pagination.less +0 -89
- package/src/styles/less/panels.less +0 -275
- package/src/styles/less/popovers.less +0 -131
- package/src/styles/less/print.less +0 -101
- package/src/styles/less/progress-bars.less +0 -87
- package/src/styles/less/responsive-embed.less +0 -35
- package/src/styles/less/responsive-utilities.less +0 -194
- package/src/styles/less/scaffolding.less +0 -161
- package/src/styles/less/stand.less +0 -207
- package/src/styles/less/tables.less +0 -262
- package/src/styles/less/theme.less +0 -291
- package/src/styles/less/thumbnails.less +0 -36
- package/src/styles/less/tooltip.less +0 -102
- package/src/styles/less/type.less +0 -303
- package/src/styles/less/utilities.less +0 -55
- package/src/styles/less/variables.less +0 -896
- package/src/styles/less/wells.less +0 -29
- package/static/logo.png +0 -0
@@ -0,0 +1,318 @@
|
|
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 号 </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}"/>
|
44
|
+
</div>
|
45
|
+
<div class="col-sm-4 form-group" :class="{'has-error': $v.f_address.required}">
|
46
|
+
<label class="font_normal_body"> 所在地</label>
|
47
|
+
<input type="text" class="input_search" style="width: 60%" v-model="model.f_address" placeholder="所在地"
|
48
|
+
v-validate:f_address="{required: true}">
|
49
|
+
</div>
|
50
|
+
<div class="col-sm-4 form-group">
|
51
|
+
<label class="font_normal_body">所属银行</label>
|
52
|
+
<input type="text" class="input_search" style="width: 60%" v-model="model.f_bank_name"
|
53
|
+
placeholder="所属银行">
|
54
|
+
</div>
|
55
|
+
</div>
|
56
|
+
<div class="col-sm-12 form-group">
|
57
|
+
<label class="font_normal_body "> 备注 </label>
|
58
|
+
<textarea class="input_textarea" rows="3" style="width:80%;margin-top:5px"
|
59
|
+
v-model="model.f_comments"></textarea>
|
60
|
+
</div>
|
61
|
+
</form>
|
62
|
+
<div style="text-align:right;height:auto;">
|
63
|
+
<!-- <button class="button_search" @click="uploadFiles()" v-if="info">上传图片</button>-->
|
64
|
+
<button class="btn btn-info" @click="upgrade()" v-if="info && data.f_state==='正常'">更新</button>
|
65
|
+
<button class="btn btn-success" @click="getEditState()" v-if="model.f_state === '停用' && info">启用</button>
|
66
|
+
<button class="btn btn-danger" @click="getEditState()" v-if="model.f_state === '正常' && info">停用</button>
|
67
|
+
<button class="btn button_search" @click="confirm()" :disabled="!$v.valid">确认</button>
|
68
|
+
<button class="btn button_clear " @click="cancel()">取消</button>
|
69
|
+
</div>
|
70
|
+
<modal :show.sync="showfiles" width="80%" style="width:auto;" v-ref:modal middle backdrop="false">
|
71
|
+
<article slot="modal-body">
|
72
|
+
<upload :blodid="model.f_userinfo_id" :businessid="model.id" v-ref:upload fusetype="收费" isremark="true"
|
73
|
+
style="width:auto"></upload>
|
74
|
+
</article>
|
75
|
+
<footer slot="modal-footer" class="modal-footer">
|
76
|
+
</footer>
|
77
|
+
</modal>
|
78
|
+
|
79
|
+
<modal v-if="show" :show.sync="show" v-ref:modal backdrop="false">
|
80
|
+
<header slot="modal-header" class="modal-header">
|
81
|
+
<button type="button" class="close" @click="close"><span>×</span></button>
|
82
|
+
<h4 class="modal-title">圈存机更新</h4>
|
83
|
+
</header>
|
84
|
+
<article slot="modal-body" class="modal-body">
|
85
|
+
<form class="form-horizontal">
|
86
|
+
<div class="row">
|
87
|
+
<div>
|
88
|
+
<h4>是否更新?</h4>
|
89
|
+
</div>
|
90
|
+
</div>
|
91
|
+
</form>
|
92
|
+
</article>
|
93
|
+
<footer slot="modal-footer" class="modal-footer">
|
94
|
+
<button type="button" class="button_search button_spacing" @click='upgradeRoot()'>是</button>
|
95
|
+
<button type="button" class="button_clear button_spacing" @click='close'>否</button>
|
96
|
+
</footer>
|
97
|
+
</modal>
|
98
|
+
</validator>
|
99
|
+
|
100
|
+
</div>
|
101
|
+
</template>
|
102
|
+
<script>
|
103
|
+
import {PagedList} from 'vue-client'
|
104
|
+
|
105
|
+
export default {
|
106
|
+
data() {
|
107
|
+
return {
|
108
|
+
checkparam: false,
|
109
|
+
source: `tool.getFullTree(this.getRights().where(row.getType() != $zone$).where(row.getType() != $role$))`,
|
110
|
+
model: {
|
111
|
+
f_terminal_number: '',
|
112
|
+
f_terminal_name: '',
|
113
|
+
f_mac_number: '',
|
114
|
+
// f_username:'',
|
115
|
+
f_bank_name: '',
|
116
|
+
f_equipment_type: '圈存机',
|
117
|
+
f_state: '正常',
|
118
|
+
f_machine_number: '',
|
119
|
+
f_phone: '',
|
120
|
+
f_comments: '',
|
121
|
+
f_address: '',
|
122
|
+
f_filialeids: '',
|
123
|
+
f_orgid: ''
|
124
|
+
},
|
125
|
+
showfiles: false,
|
126
|
+
show: false,
|
127
|
+
infoadd: this.infoadd,
|
128
|
+
isSelPop: false
|
129
|
+
}
|
130
|
+
},
|
131
|
+
props: ['data', 'f_filialeids', 'info'],
|
132
|
+
|
133
|
+
watch: {
|
134
|
+
'data'(val) {
|
135
|
+
if (val) {
|
136
|
+
this.edit(val)
|
137
|
+
} else {
|
138
|
+
this.initModel()
|
139
|
+
}
|
140
|
+
}
|
141
|
+
},
|
142
|
+
ready() {
|
143
|
+
console.log('mac信息:', this.data)
|
144
|
+
if (this.data) {
|
145
|
+
this.edit(this.data)
|
146
|
+
}
|
147
|
+
console.log('查看是否隐藏', this.info)
|
148
|
+
},
|
149
|
+
|
150
|
+
methods: {
|
151
|
+
recursiveSelOrg(val, flag) {
|
152
|
+
if (val.parent) {
|
153
|
+
if (val.parent.resourcetype === flag) {
|
154
|
+
return {id: val.parent.id, name: val.parent.name}
|
155
|
+
} else {
|
156
|
+
return this.recursiveSelOrg(val.parent, flag)
|
157
|
+
}
|
158
|
+
} else {
|
159
|
+
return {id: '', name: ''}
|
160
|
+
}
|
161
|
+
},
|
162
|
+
getRes(val) {
|
163
|
+
console.log('====================', val)
|
164
|
+
if (val.orgobj.length === 1 && val.orgobj[0].resourcetype === 'user') {
|
165
|
+
|
166
|
+
let org = this.recursiveSelOrg(val.orgobj[0], 'organization')
|
167
|
+
this.model.f_user_orgid = org.id
|
168
|
+
this.model.f_user_orgname = org.name
|
169
|
+
let dep = this.recursiveSelOrg(val.orgobj[0], 'department')
|
170
|
+
this.model.f_user_depid = dep.id
|
171
|
+
this.model.f_user_depname = dep.name
|
172
|
+
|
173
|
+
this.model.f_user_operatorid = val.orgobj[0].userid
|
174
|
+
this.model.f_user_operator = val.orgobj[0].name
|
175
|
+
this.isSelPop = true
|
176
|
+
} else {
|
177
|
+
// 不可提交
|
178
|
+
this.isSelPop = false
|
179
|
+
}
|
180
|
+
},
|
181
|
+
close() {
|
182
|
+
this.show = false
|
183
|
+
},
|
184
|
+
uploadFiles() {
|
185
|
+
this.showfiles = !this.showfiles
|
186
|
+
},
|
187
|
+
getEditState() {
|
188
|
+
if (this.model.f_state === '正常') {
|
189
|
+
this.$showMessage(`当前设备号: ${this.model.f_terminal_number} ,确认停用该设备?`, ['confirm', 'cancel']).then((res) => {
|
190
|
+
if (res === 'confirm') {
|
191
|
+
this.$showAlert(`已向设备号: ${this.model.f_terminal_number}发送停用指令,请稍后查看执行结果!`, 'success', 2500)
|
192
|
+
this.model.f_state = '停用'
|
193
|
+
try {
|
194
|
+
// 测试接口
|
195
|
+
// this.$resetpost('rs/logic/updatePosState', {data: {number: this.model.f_terminal_number, state: '停用'}}, {resolveMsg: null, rejectMsg: null}, 0)
|
196
|
+
// .then((res) => {})
|
197
|
+
this.$resetpost('pos/rs/logic/task', {
|
198
|
+
data: {
|
199
|
+
tasks: [{
|
200
|
+
sn: this.model.f_terminal_number,
|
201
|
+
taskState: "0"
|
202
|
+
}]
|
203
|
+
}
|
204
|
+
}, {rejectMsg: null, resolveMsg: null})
|
205
|
+
} catch (error) {
|
206
|
+
this.search()
|
207
|
+
}
|
208
|
+
}
|
209
|
+
})
|
210
|
+
} else if (this.model.f_state === '停用') {
|
211
|
+
this.$showMessage(`当前设备号: ${this.model.f_terminal_number} ,确认启用该设备?`, ['confirm', 'cancel']).then((res) => {
|
212
|
+
if (res === 'confirm') {
|
213
|
+
this.$showAlert(`已向设备号: ${this.model.f_terminal_number}发送启用指令,请稍后查看执行结果!`, 'success', 2500)
|
214
|
+
this.model.f_state = '正常'
|
215
|
+
try {
|
216
|
+
// 测试接口
|
217
|
+
// this.$resetpost('rs/logic/getEditPosState', {data: {number: this.model.f_terminal_number, state: '正常'}}, {resolveMsg: null, rejectMsg: null}, 0)
|
218
|
+
// .then((res) => {})
|
219
|
+
this.$resetpost('pos/rs/logic/task', {
|
220
|
+
data: {
|
221
|
+
tasks: [{
|
222
|
+
sn: this.model.f_terminal_number,
|
223
|
+
taskState: "1"
|
224
|
+
}]
|
225
|
+
}
|
226
|
+
}, {rejectMsg: null, resolveMsg: null})
|
227
|
+
} catch (error) {
|
228
|
+
this.search()
|
229
|
+
}
|
230
|
+
}
|
231
|
+
})
|
232
|
+
}
|
233
|
+
},
|
234
|
+
editBeizhu(val) {
|
235
|
+
this.editshow = true
|
236
|
+
this.posBase = val
|
237
|
+
},
|
238
|
+
|
239
|
+
//升级
|
240
|
+
upgrade() {
|
241
|
+
this.show = true
|
242
|
+
},
|
243
|
+
upgradeRoot() {
|
244
|
+
this.$resetpost('pos/rs/logic/task', {
|
245
|
+
data: {
|
246
|
+
tasks: [{
|
247
|
+
sn: this.model.f_terminal_number,
|
248
|
+
taskState: "2"
|
249
|
+
}]
|
250
|
+
}
|
251
|
+
}, {rejectMsg: null, resolveMsg: null})
|
252
|
+
this.$dispatch('refresh')
|
253
|
+
// this.$resetpost('rs/logic/t_equipment', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
|
254
|
+
// this.$dispatch('refresh')
|
255
|
+
// }).catch((error) => {
|
256
|
+
// this.$dispatch('refresh')
|
257
|
+
// })
|
258
|
+
},
|
259
|
+
search() {
|
260
|
+
this.$refs.paged.$refs.cri.search()
|
261
|
+
},
|
262
|
+
confirm() {
|
263
|
+
// 如果是修改的话,只修改页面上用户填写的信息
|
264
|
+
if (!this.info) {
|
265
|
+
this.model.f_online = '离线'
|
266
|
+
this.model.f_operator = this.$login.f.name
|
267
|
+
this.model.f_orgid = this.$login.f.orgid
|
268
|
+
this.model.f_filialeids = this.$login.f.orgid
|
269
|
+
this.model.f_operatorid = this.$login.f.id
|
270
|
+
this.model.f_orgname = this.$login.f.orgs
|
271
|
+
this.model.f_depid = this.$login.f.depids
|
272
|
+
this.model.f_depname = this.$login.f.deps
|
273
|
+
this.model.f_orgstr = this.$login.f.fullids
|
274
|
+
}
|
275
|
+
this.$resetpost('rs/entity/t_equipment', this.model, {
|
276
|
+
resolveMsg: '保存成功',
|
277
|
+
rejectMsg: '保存失败'
|
278
|
+
}).then((res) => {
|
279
|
+
this.$dispatch('refresh')
|
280
|
+
}).catch((error) => {
|
281
|
+
this.$dispatch('refresh')
|
282
|
+
})
|
283
|
+
|
284
|
+
},
|
285
|
+
edit(row) {
|
286
|
+
this.model.f_terminal_number = row.f_terminal_number
|
287
|
+
this.model.f_terminal_name = row.f_terminal_name
|
288
|
+
this.model.f_bank_name = row.f_bank_name
|
289
|
+
this.model.f_machine_number = row.f_machine_number
|
290
|
+
this.model.f_mac_number = row.f_mac_number
|
291
|
+
this.model.f_address = row.f_address
|
292
|
+
this.model.f_phone = row.f_phone
|
293
|
+
this.model.f_state = row.f_state
|
294
|
+
this.model.f_comments = row.f_comments
|
295
|
+
// this.model.f_username=row.f_username
|
296
|
+
this.model.id = row.id
|
297
|
+
this.model.f_filialeids = row.f_filialeids
|
298
|
+
this.model.f_orgid = row.f_orgid
|
299
|
+
},
|
300
|
+
initModel() {
|
301
|
+
delete this.model.id
|
302
|
+
this.model.f_terminal_number = ''
|
303
|
+
this.model.f_terminal_name = ''
|
304
|
+
this.model.f_bank_name = ''
|
305
|
+
this.model.f_machine_number = ''
|
306
|
+
this.model.f_state = '正常'
|
307
|
+
this.model.f_phone = ''
|
308
|
+
this.model.f_address = ''
|
309
|
+
this.model.f_filialeids = ''
|
310
|
+
this.model.f_orgid = ''
|
311
|
+
this.model.f_comments = ''
|
312
|
+
},
|
313
|
+
cancel() {
|
314
|
+
this.$dispatch('close')
|
315
|
+
}
|
316
|
+
}
|
317
|
+
}
|
318
|
+
</script>
|
@@ -0,0 +1,230 @@
|
|
1
|
+
<template>
|
2
|
+
<div class="flex">
|
3
|
+
<criteria-paged :model="model" v-ref:paged>
|
4
|
+
|
5
|
+
<criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
|
6
|
+
<div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
|
7
|
+
<div class="row">
|
8
|
+
<div class="col-sm-3 form-group">
|
9
|
+
<label class="font_normal_body">公 司</label>
|
10
|
+
<res-select restype='organization'
|
11
|
+
is-mul="false"
|
12
|
+
@res-select="$parent.$parent.getorg"
|
13
|
+
:initresid="$parent.$parent.curorgid">
|
14
|
+
</res-select>
|
15
|
+
</div>
|
16
|
+
<div class="col-sm-3 form-group">
|
17
|
+
<label class="font_normal_body">设备编号</label>
|
18
|
+
<input type="text" class="input_search" style="width:60%" v-model="model.f_terminal_number"
|
19
|
+
condition="f_terminal_number like '%{}%'" placeholder="设备编号">
|
20
|
+
</div>
|
21
|
+
<div class="span" style="float:right;">
|
22
|
+
<button type="button" class="button_search" @click="search()" v-el:cx>查询</button>
|
23
|
+
<button type="button" class="button_search" @click="$parent.$parent.add() " v-el:cx >新增</button>
|
24
|
+
<div style="float: right" class="button_spacing" :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
|
25
|
+
@click="$parent.$parent.hidden()"></div>
|
26
|
+
</div>
|
27
|
+
</div>
|
28
|
+
<div class="row" v-show="$parent.$parent.criteriaShow">
|
29
|
+
<div class="col-sm-3 form-group">
|
30
|
+
<label class="font_normal_body">所在地</label>
|
31
|
+
<input type="text" class="input_search" style="width:60%" v-model="model.f_address"
|
32
|
+
condition="f_address like '%{}%'" placeholder="所在地">
|
33
|
+
</div>
|
34
|
+
<div class="col-sm-3 form-group">
|
35
|
+
<label class="font_normal_body">设备名称</label>
|
36
|
+
<input type="text" class="input_search" style="width:60%" v-model="model.f_terminal_name"
|
37
|
+
condition="f_terminal_name like '%{}%'" placeholder="设备名称">
|
38
|
+
</div>
|
39
|
+
<div class="col-sm-3 form-group">
|
40
|
+
<label class="font_normal_body">机器编号</label>
|
41
|
+
<input type="text" class="input_search" style="width:60%" v-model="model.f_machine_number"
|
42
|
+
condition="f_machine_number like '%{}%'" placeholder="机器编号">
|
43
|
+
</div>
|
44
|
+
<div class="col-sm-3 form-group">
|
45
|
+
<label class="font_normal_body">联系电话</label>
|
46
|
+
<input type="text" class="input_search" style="width:60%" v-model="model.f_phone"
|
47
|
+
condition="f_phone like '%{}%'" placeholder="联系电话">
|
48
|
+
</div>
|
49
|
+
</div>
|
50
|
+
</div>
|
51
|
+
</criteria>
|
52
|
+
<data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid >
|
53
|
+
<template partial='head'>
|
54
|
+
<tr>
|
55
|
+
<th><input type="checkbox" name="ischeckbox_all_id" v-model="$parent.$parent.$parent.isSelAll" :value.sync="$parent.$parent.$parent.isSelAll" /></th>
|
56
|
+
<th style="text-align:center;white-space:nowrap;">序号</th>
|
57
|
+
<th style="text-align:center;white-space:nowrap;">设备编号</th>
|
58
|
+
<th style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">设备类型</th>
|
59
|
+
<th style="text-align:center;white-space:nowrap;">设备名称</th>
|
60
|
+
<th style="text-align:center;white-space:nowrap;">所属公司</th>
|
61
|
+
<th style="text-align:center;white-space:nowrap;">状态</th>
|
62
|
+
<th style="text-align:center;white-space:nowrap;">机器编号</th>
|
63
|
+
<th style="text-align:center;white-space:nowrap;">联系电话</th>
|
64
|
+
<th style="text-align:center;white-space:nowrap;">所在地</th>
|
65
|
+
<!-- <th style="text-align:center;white-space:nowrap;">电池电量</th>-->
|
66
|
+
<!-- <th style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">是否登录</th>-->
|
67
|
+
<!-- <th style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">更新时间</th>-->
|
68
|
+
<th style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">操作时间</th>
|
69
|
+
<!-- <th style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">软件版本</th>-->
|
70
|
+
<th style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">操作人</th>
|
71
|
+
<th style="text-align:center;white-space:nowrap;">失联状态</th>
|
72
|
+
<th style="text-align:center;white-space:nowrap;">操作</th>
|
73
|
+
</tr>
|
74
|
+
</template>
|
75
|
+
<template partial='body':model="model">
|
76
|
+
<tr>
|
77
|
+
<td><input type="checkbox" name="checkbox_id" v-model="$parent.$parent.$parent.selPos" :value.sync="row"></td>
|
78
|
+
<td style="text-align:center;white-space:nowrap;">{{$index+1}}</td>
|
79
|
+
<td style="text-align:center;white-space:nowrap;"><span title="点击查看历史" @click="$parent.$parent.$parent.abcd(row)"><a>{{row.f_terminal_number}}</a></span></td>
|
80
|
+
<td style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">{{row.f_equipment_type}}</td>
|
81
|
+
<td style="text-align:center;white-space:nowrap;">{{row.f_terminal_name}}</td>
|
82
|
+
<td style="text-align:center;white-space:nowrap;">{{row.f_user_orgname}}</td>
|
83
|
+
<td style="text-align:center;white-space:nowrap;">{{row.f_state}}</td>
|
84
|
+
<td style="text-align:center;white-space:nowrap;">{{row.f_machine_number}}</td>
|
85
|
+
<td style="text-align:center;white-space:nowrap;">{{row.f_phone}}</td>
|
86
|
+
<td style="text-align:center;white-space:nowrap;">{{row.f_address}}</td>
|
87
|
+
<!-- <td style="text-align:center;white-space:nowrap;">{{row.f_battery_level}}</td>-->
|
88
|
+
<!-- <td style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">{{row.f_is_login}}</td>-->
|
89
|
+
<!-- <td style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">{{row.f_hybrid_version}}</td>-->
|
90
|
+
<td style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">{{row.f_operate_date}}</td>
|
91
|
+
<!-- <td style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">{{row.f_appVer}}</td>-->
|
92
|
+
<td style="text-align:center;white-space:nowrap;" v-show="!$parent.$parent.$parent.isshowless">{{row.f_operator}}</td>
|
93
|
+
<td style="text-align:center;white-space:nowrap;" >{{row.f_online}}</td>
|
94
|
+
<td style="text-align:center;white-space:nowrap;" ><button class="btn btn-danger" @click="$parent.$parent.$parent.delQc(row)">删除</button></td>
|
95
|
+
</tr>
|
96
|
+
</template>
|
97
|
+
</data-grid>
|
98
|
+
</criteria-paged>
|
99
|
+
</div>
|
100
|
+
<modal v-show="infoshow" :show.sync="infoshow" v-ref:modal backdrop="false" width="800px" title="终端历史信息">
|
101
|
+
<article slot="modal-body" class="modal-body">
|
102
|
+
<criteria-paged :model="model2" v-ref:paged2>
|
103
|
+
<data-grid :model="model2" v-ref:grid2 partial='list'>
|
104
|
+
<template partial='head'>
|
105
|
+
<tr>
|
106
|
+
<th><nobr>序号</nobr></th>
|
107
|
+
<th><nobr>终端号</nobr></th>
|
108
|
+
<th><nobr>上次上报时间</nobr></th>
|
109
|
+
<th><nobr>本次上报时间</nobr></th>
|
110
|
+
<th><nobr><b>状态</b></nobr></th>
|
111
|
+
</tr>
|
112
|
+
</template>
|
113
|
+
<template partial='body'>
|
114
|
+
<td style="text-align: center;">{{$index + 1}}</td>
|
115
|
+
<td style="text-align: center;">{{row.f_terminal_number}}</td>
|
116
|
+
<td style="text-align: center;">{{row.f_update_date}}</td>
|
117
|
+
<td style="text-align: center;">{{row.f_update_date }}</td>
|
118
|
+
<td style="text-align: center;"><b>{{row.f_pos_state}}</b></td>
|
119
|
+
</template>
|
120
|
+
</data-grid>
|
121
|
+
</criteria-paged>
|
122
|
+
</article>
|
123
|
+
<footer slot="modal-footer" class="modal-footer">
|
124
|
+
<button type="button" class="btn btn-success" @click='infoclose'>关闭</button>
|
125
|
+
</footer>
|
126
|
+
</modal>
|
127
|
+
</template>
|
128
|
+
|
129
|
+
<script>
|
130
|
+
|
131
|
+
import {PagedList} from 'vue-client'
|
132
|
+
|
133
|
+
export default {
|
134
|
+
title: '终端控制',
|
135
|
+
components: {},
|
136
|
+
data () {
|
137
|
+
return {
|
138
|
+
source: `tool.getFullTree(this.getRights().where(row.getType() != $zone$).where(row.getType() != $role$))`,
|
139
|
+
model: new PagedList('rs/sql/equipmentQuery', 20),
|
140
|
+
model2: new PagedList('rs/sql/singleTable', 30, {tablename: '`t_poshistory`'}),
|
141
|
+
curorgid: [this.f_filialeid],
|
142
|
+
f_orgid: '',
|
143
|
+
f_filialeids: '',
|
144
|
+
criteriaShow: false,
|
145
|
+
infoadd: false,
|
146
|
+
selPos: [],
|
147
|
+
isSelAll: false, // 默认不全选
|
148
|
+
infoshow: false
|
149
|
+
}
|
150
|
+
},
|
151
|
+
props: ['f_filialeid','isshowless'],
|
152
|
+
ready () {
|
153
|
+
this.search()
|
154
|
+
},
|
155
|
+
watch:{
|
156
|
+
'isSelAll'(val){
|
157
|
+
if (val) {
|
158
|
+
// 对当前页面全选
|
159
|
+
this.selPos = []
|
160
|
+
for (const sel of this.model.rows) {
|
161
|
+
this.selPos.push(sel)
|
162
|
+
}
|
163
|
+
} else {
|
164
|
+
this.selPos = []
|
165
|
+
}
|
166
|
+
}
|
167
|
+
},
|
168
|
+
methods: {
|
169
|
+
delQc(row){
|
170
|
+
this.$showMessage('删除之后不可回复,确定要删除该圈存机吗?', ['confirm', 'cancel']).then(async (res) => {
|
171
|
+
if (res == 'confirm') {
|
172
|
+
console.log('要删除了', row)
|
173
|
+
row.f_state = '已删除'
|
174
|
+
this.$resetpost('rs/entity/t_equipment', row, {warnMsg: '确定要删除这条信息吗?', resolveMsg: '删除成功', rejectMsg: '删除失败'}).then((res) => {
|
175
|
+
this.$dispatch('refresh')
|
176
|
+
}).catch((error) => {
|
177
|
+
this.$dispatch('refresh')
|
178
|
+
})
|
179
|
+
}
|
180
|
+
})
|
181
|
+
},
|
182
|
+
getRes(val){
|
183
|
+
if (val.orgobj.length === 1 && val.orgobj[0].resourcetype === 'user'){
|
184
|
+
this.$refs.paged.$refs.cri.model.f_user_operatorid=val.orgobj[0].userid
|
185
|
+
this.$refs.paged.$refs.cri.model.f_user_operator=val.orgobj[0].name
|
186
|
+
} else {
|
187
|
+
this.$refs.paged.$refs.cri.model.f_user_operatorid=''
|
188
|
+
this.$refs.paged.$refs.cri.model.f_user_operator=''
|
189
|
+
}
|
190
|
+
},
|
191
|
+
infoclose(){
|
192
|
+
this.infoshow=false
|
193
|
+
},
|
194
|
+
abcd (row) {
|
195
|
+
console.log("chakan",row)
|
196
|
+
let condition = `f_terminal_number = '${row.f_terminal_number}' order by id desc`
|
197
|
+
// this.model2.search(condition)
|
198
|
+
this.infoshow = true
|
199
|
+
},
|
200
|
+
search () {
|
201
|
+
console.log("111111111111111111111111111111111111")
|
202
|
+
this.$refs.paged.$refs.cri.search()
|
203
|
+
},
|
204
|
+
|
205
|
+
selfSearch (args) {
|
206
|
+
// args.condition = `${args.condition} and f_equipment_type = '圈存机' and f_orgid = '${this.f_filialeid ? this.f_orgid: this.$login.f.orgid}'`
|
207
|
+
args.condition = `${args.condition} and f_equipment_type = '圈存机' and f_state !='已删除' and f_orgid = '${this.f_filialeid ? this.f_orgid: this.$login.f.orgid}'`
|
208
|
+
this.model.search(args.condition, this.model)
|
209
|
+
this.$dispatch('research')
|
210
|
+
},
|
211
|
+
|
212
|
+
add () {
|
213
|
+
this.infoadd=false
|
214
|
+
this.$dispatch('add', this.f_filialeid)
|
215
|
+
},
|
216
|
+
|
217
|
+
getorg (val) {
|
218
|
+
this.f_orgid = val[0]
|
219
|
+
this.f_filialeid = val[0]
|
220
|
+
// this.search()
|
221
|
+
},
|
222
|
+
hidden(){
|
223
|
+
this.criteriaShow = !this.criteriaShow
|
224
|
+
}
|
225
|
+
},
|
226
|
+
computed: {
|
227
|
+
|
228
|
+
}
|
229
|
+
}
|
230
|
+
</script>
|