4c4f7640
梁保满
路由表,路由前端文件
|
1
|
<template>
|
e3b0e3e7
梁保满
季度时间格式调整
|
2
|
<div ref="main" class="page-content">
|
bb778c90
阿宝
设备状态
|
3
4
5
6
|
<back-box>
<template slot="title">
<span>设备管理</span>
</template>
|
575eb544
梁保满
账号异常提示,放开长水学校管理员设...
|
7
|
<template slot="btns" v-if="role == 'ROLE_XUEXIAO' && type == 1">
|
3ba60a63
梁保满
发卡补卡,设备状态上传下载接口联调
|
8
|
<el-tooltip effect="dark" content="设备导入" placement="bottom">
|
bb778c90
阿宝
设备状态
|
9
10
11
12
13
14
|
<el-button
type="primary"
icon="el-icon-upload2"
size="mini"
plain
circle
|
db11048f
阿宝
设备状态,学校管理
|
15
|
@click="diaUp = true"
|
bb778c90
阿宝
设备状态
|
16
|
></el-button>
|
3ba60a63
梁保满
发卡补卡,设备状态上传下载接口联调
|
17
|
</el-tooltip>
|
87053bc8
梁保满
设备状态模版下载更新
|
18
|
<el-tooltip effect="dark" content="添加基站" placement="bottom">
|
bb778c90
阿宝
设备状态
|
19
20
21
22
23
24
|
<el-button
type="primary"
icon="el-icon-receiving"
size="mini"
plain
circle
|
e3b0e3e7
梁保满
季度时间格式调整
|
25
|
@click="addDev"
|
bb778c90
阿宝
设备状态
|
26
|
></el-button>
|
e3b0e3e7
梁保满
季度时间格式调整
|
27
|
</el-tooltip>
|
bb778c90
阿宝
设备状态
|
28
29
|
</template>
</back-box>
|
1365ef5e
梁保满
优化
|
30
|
<div>
|
db11048f
阿宝
设备状态,学校管理
|
31
32
33
34
35
36
37
38
|
<div class="tab-box">
<el-radio-group v-model="type">
<el-radio-button :label="1">基站管理</el-radio-button>
<el-radio-button :label="2">答题器管理</el-radio-button>
<el-radio-button :label="3">授课端管理</el-radio-button>
</el-radio-group>
</div>
<div class="content">
|
8ea67428
梁保满
飞书bug
|
39
|
<div v-show="type == 1">
|
225a00b6
梁保满
飞书问题解决
|
40
|
<div class="chart-box" v-if="count">
|
db11048f
阿宝
设备状态,学校管理
|
41
|
<div class="device-num">
|
225a00b6
梁保满
飞书问题解决
|
42
|
<p class="p1">{{ count }}</p>
|
db11048f
阿宝
设备状态,学校管理
|
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
<p class="p2">基站数量</p>
</div>
<div class="chart">
<pie-chart
id="pieChart"
:params="chartData"
@clickPieChart="clickPieChart"
></pie-chart>
</div>
</div>
<div class="table-box">
<div class="answer-header">
<div class="sel-box">
<el-cascader
|
225a00b6
梁保满
飞书问题解决
|
57
|
size="small"
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
58
|
class="sel sel2"
|
db11048f
阿宝
设备状态,学校管理
|
59
60
61
|
clearable
placeholder="选择班级"
v-model="query.classId"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
62
|
:options="gradeList"
|
db11048f
阿宝
设备状态,学校管理
|
63
|
:props="props"
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
64
|
collapse-tags
|
db11048f
阿宝
设备状态,学校管理
|
65
|
:show-all-levels="false"
|
db11048f
阿宝
设备状态,学校管理
|
66
67
68
|
></el-cascader>
<el-select
class="sel"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
69
|
v-model="query.onlineStatus"
|
db11048f
阿宝
设备状态,学校管理
|
70
|
placeholder="选择状态"
|
b21d90ef
梁保满
长水登录
|
71
|
@change="_QueryData(true)"
|
db11048f
阿宝
设备状态,学校管理
|
72
73
74
75
76
77
78
79
80
81
|
>
<el-option
v-for="item in statusList"
:key="item.value"
:label="item.label"
:value="item.value"
>
</el-option>
</el-select>
<el-input
|
db11048f
阿宝
设备状态,学校管理
|
82
|
placeholder="请输入设备编码"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
83
|
v-model="query.sn"
|
db11048f
阿宝
设备状态,学校管理
|
84
85
86
87
88
89
90
91
92
|
class="input-with-select"
@keyup.enter.native="_QueryData(true)"
>
<el-button
slot="append"
icon="el-icon-search"
@click="_QueryData(true)"
></el-button>
</el-input>
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
93
|
<el-button class="serach-box" round @click="_QueryData(true)"
|
b21d90ef
梁保满
长水登录
|
94
95
|
>筛选</el-button
>
|
db11048f
阿宝
设备状态,学校管理
|
96
97
98
99
|
</div>
</div>
<el-table :data="tableData" border style="width: 100%">
<el-table-column
|
6d7bd862
梁保满
飞书bug
|
100
|
prop="sn"
|
db11048f
阿宝
设备状态,学校管理
|
101
102
103
104
|
label="设备编码"
align="center"
></el-table-column>
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
105
|
prop="frequency"
|
db11048f
阿宝
设备状态,学校管理
|
106
107
108
109
|
label="频点"
align="center"
></el-table-column>
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
110
|
prop="pairingCode"
|
db11048f
阿宝
设备状态,学校管理
|
111
112
113
114
|
label="配对码"
align="center"
></el-table-column>
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
115
|
prop="roomName"
|
db11048f
阿宝
设备状态,学校管理
|
116
117
118
|
label="所在教室"
align="center"
></el-table-column>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
119
120
|
<el-table-column label="关联班级" align="center">
<template slot-scope="scoped">
|
e3b0e3e7
梁保满
季度时间格式调整
|
121
|
<p v-for="(item, index) in scoped.row.classList" :key="index">
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
122
123
124
125
|
{{ item.className }}
</p>
</template>
</el-table-column>
|
db11048f
阿宝
设备状态,学校管理
|
126
|
<el-table-column
|
6d7bd862
梁保满
飞书bug
|
127
|
prop="otaVersionName"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
128
|
label="固件版本号"
|
db11048f
阿宝
设备状态,学校管理
|
129
130
131
|
align="center"
></el-table-column>
<el-table-column
|
6d7bd862
梁保满
飞书bug
|
132
|
prop="onlineTime"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
133
|
label="最近上报"
|
db11048f
阿宝
设备状态,学校管理
|
134
135
|
align="center"
></el-table-column>
|
db11048f
阿宝
设备状态,学校管理
|
136
137
138
|
<el-table-column label="状态" align="center"
><template slot-scope="scope">
{{
|
6d7bd862
梁保满
飞书bug
|
139
|
scope.row.onlineStatus == 1
|
db11048f
阿宝
设备状态,学校管理
|
140
|
? "在线"
|
6d7bd862
梁保满
飞书bug
|
141
142
143
|
: scope.row.onlineStatus == 2
? "异常"
: "离线"
|
db11048f
阿宝
设备状态,学校管理
|
144
145
146
147
148
|
}}
</template></el-table-column
>
<el-table-column label="操作" align="center"
><template slot-scope="scoped">
|
225a00b6
梁保满
飞书问题解决
|
149
150
151
152
153
154
|
<el-tooltip
effect="dark"
v-if="role != 'ROLE_JITUAN'"
content="修改基站"
placement="top"
>
|
db11048f
阿宝
设备状态,学校管理
|
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
|
<el-button
type="primary"
circle
size="mini"
icon="fa fa-edit"
@click="edit(scoped.row)"
></el-button>
</el-tooltip>
<el-tooltip effect="dark" content="日志" placement="top">
<el-button
type="warning"
circle
size="mini"
icon="fa fa-eye"
@click="linkTo(scoped.row, 1)"
></el-button>
</el-tooltip> </template
></el-table-column>
</el-table>
</div>
</div>
|
8ea67428
梁保满
飞书bug
|
176
|
<div v-show="type == 2">
|
225a00b6
梁保满
飞书问题解决
|
177
|
<div class="chart-box" v-if="count">
|
db11048f
阿宝
设备状态,学校管理
|
178
|
<div class="device-num">
|
225a00b6
梁保满
飞书问题解决
|
179
|
<p class="p1">{{ count }}</p>
|
db11048f
阿宝
设备状态,学校管理
|
180
181
182
183
184
185
186
187
188
189
190
191
192
193
|
<p class="p2">答题器数量</p>
</div>
<div class="chart">
<scatter-chart
id="scatterChart"
:params="chartData2"
@clickScatterChart="clickScatterChart"
></scatter-chart>
</div>
</div>
<div class="table-box">
<div class="answer-header">
<div class="sel-box">
<el-cascader
|
225a00b6
梁保满
飞书问题解决
|
194
|
size="small"
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
195
|
class="sel sel2"
|
db11048f
阿宝
设备状态,学校管理
|
196
197
198
|
clearable
placeholder="选择班级"
v-model="query.classId"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
199
|
:options="gradeList"
|
db11048f
阿宝
设备状态,学校管理
|
200
|
:props="props"
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
201
|
collapse-tags
|
db11048f
阿宝
设备状态,学校管理
|
202
|
:show-all-levels="false"
|
db11048f
阿宝
设备状态,学校管理
|
203
204
205
|
></el-cascader>
<el-select
class="sel"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
206
|
v-model="query.type"
|
db11048f
阿宝
设备状态,学校管理
|
207
|
placeholder="选择状态"
|
b21d90ef
梁保满
长水登录
|
208
|
@change="_QueryData(true)"
|
db11048f
阿宝
设备状态,学校管理
|
209
210
|
>
<el-option
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
211
|
v-for="item in typeList"
|
db11048f
阿宝
设备状态,学校管理
|
212
213
214
215
216
217
218
|
:key="item.value"
:label="item.label"
:value="item.value"
>
</el-option>
</el-select>
<el-input
|
db11048f
阿宝
设备状态,学校管理
|
219
|
placeholder="请输入设备编码"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
220
|
v-model="query.sn"
|
db11048f
阿宝
设备状态,学校管理
|
221
222
223
224
225
226
227
228
229
|
class="input-with-select"
@keyup.enter.native="_QueryData(true)"
>
<el-button
slot="append"
icon="el-icon-search"
@click="_QueryData(true)"
></el-button>
</el-input>
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
230
|
<el-button class="serach-box" round @click="_QueryData(true)"
|
b21d90ef
梁保满
长水登录
|
231
|
>筛选</el-button
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
232
|
>
|
db11048f
阿宝
设备状态,学校管理
|
233
234
235
236
|
</div>
</div>
<el-table :data="tableData" border style="width: 100%">
<el-table-column
|
6d7bd862
梁保满
飞书bug
|
237
|
prop="sn"
|
db11048f
阿宝
设备状态,学校管理
|
238
239
240
|
label="设备编码"
align="center"
></el-table-column>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
241
242
243
|
<el-table-column label="学生信息" align="center"
><template slot-scope="scoped"
><p
|
6d7bd862
梁保满
飞书bug
|
244
245
|
v-for="(item, index) in scoped.row.studentList"
:key="index"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
246
247
248
249
250
|
>
{{ item.studentName }}
</p></template
></el-table-column
>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
251
252
|
<el-table-column prop="class" label="关联班级" align="center">
<template slot-scope="scoped">
|
6d7bd862
梁保满
飞书bug
|
253
|
<p v-for="(item, index) in scoped.row.classList" :key="index">
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
254
255
256
257
|
{{ item.className }}
</p>
</template></el-table-column
>
|
5fb1f184
梁保满
答题器管理:不显示 题器配对码,修...
|
258
|
<!-- <el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
259
|
prop="pairingCode"
|
db11048f
阿宝
设备状态,学校管理
|
260
261
|
label="配对码"
align="center"
|
5fb1f184
梁保满
答题器管理:不显示 题器配对码,修...
|
262
|
></el-table-column> -->
|
cffc1a98
梁保满
3-8BUG
|
263
|
<!-- <el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
264
|
prop="answerTimes"
|
db11048f
阿宝
设备状态,学校管理
|
265
266
|
label="答题次数"
align="center"
|
cffc1a98
梁保满
3-8BUG
|
267
|
></el-table-column> -->
|
db11048f
阿宝
设备状态,学校管理
|
268
|
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
269
|
prop="latestReportTime"
|
db11048f
阿宝
设备状态,学校管理
|
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
|
label="最后答题时间"
align="center"
></el-table-column>
<el-table-column label="操作" align="center"
><template slot-scope="scoped">
<el-tooltip effect="dark" content="日志" placement="top">
<el-button
type="warning"
circle
size="mini"
icon="fa fa-eye"
@click="linkTo(scoped.row, 2)"
></el-button>
</el-tooltip> </template
></el-table-column>
</el-table>
</div>
</div>
|
8ea67428
梁保满
飞书bug
|
288
|
<div v-show="type == 3">
|
db11048f
阿宝
设备状态,学校管理
|
289
290
291
292
|
<div class="table-box">
<div class="answer-header">
<div class="sel-box">
<el-cascader
|
225a00b6
梁保满
飞书问题解决
|
293
|
size="small"
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
294
|
class="sel sel2"
|
db11048f
阿宝
设备状态,学校管理
|
295
296
297
|
clearable
placeholder="选择班级"
v-model="query.classId"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
298
|
:options="gradeList"
|
db11048f
阿宝
设备状态,学校管理
|
299
|
:props="props"
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
300
|
collapse-tags
|
db11048f
阿宝
设备状态,学校管理
|
301
302
303
|
:show-all-levels="false"
@change="_QueryData(false)"
></el-cascader>
|
e5ff81a1
阿宝
集团管理员接口
|
304
305
306
|
<span class="sel"
>共选择{{ selectionTabIds.length }}个授课端</span
>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
307
|
<el-button plan round @click="autoUpDate(false)"
|
db11048f
阿宝
设备状态,学校管理
|
308
309
|
>开启自动更新</el-button
>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
310
|
<el-button plan round @click="stopUpdate(false)"
|
db11048f
阿宝
设备状态,学校管理
|
311
312
313
314
315
|
>停止自动更新</el-button
>
</div>
</div>
<el-table
|
0e46bc25
梁保满
优化
|
316
|
ref="multipleTable"
|
db11048f
阿宝
设备状态,学校管理
|
317
318
319
320
321
|
:data="tableData"
border
style="width: 100%"
@selection-change="handleSelectionChange"
>
|
6d7bd862
梁保满
飞书bug
|
322
|
<el-table-column type="selection" width="55"></el-table-column>
|
a0d49348
梁保满
授课端管理添加设备编码,随堂问、即...
|
323
324
325
326
327
|
<el-table-column
prop="sn"
label="设备编码"
align="center"
></el-table-column>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
328
329
|
<el-table-column prop="class" label="关联班级" align="center"
><template slot-scope="scoped">
|
6d7bd862
梁保满
飞书bug
|
330
|
<p v-for="(item, index) in scoped.row.classList" :key="index">
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
331
332
333
334
|
{{ item.className }}
</p>
</template></el-table-column
>
|
db11048f
阿宝
设备状态,学校管理
|
335
|
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
336
|
prop="lastUpdateTime"
|
db11048f
阿宝
设备状态,学校管理
|
337
338
339
340
|
label="最近更新"
align="center"
></el-table-column>
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
341
|
prop="osInfo"
|
db11048f
阿宝
设备状态,学校管理
|
342
343
344
345
|
label="软件系统"
align="center"
></el-table-column>
<el-table-column
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
346
|
prop="hardwareInfo"
|
db11048f
阿宝
设备状态,学校管理
|
347
348
349
350
|
label="硬件环境"
align="center"
></el-table-column>
<el-table-column
|
255e2506
梁保满
飞书bug及优化
|
351
|
prop="otaVersionName"
|
db11048f
阿宝
设备状态,学校管理
|
352
353
354
355
356
357
|
label="版本号"
align="center"
></el-table-column>
<el-table-column label="状态" align="center"
><template slot-scope="scope">
{{
|
6d7bd862
梁保满
飞书bug
|
358
|
scope.row.onlineStatus == 1
|
db11048f
阿宝
设备状态,学校管理
|
359
|
? "在线"
|
6d7bd862
梁保满
飞书bug
|
360
361
362
|
: scope.row.onlineStatus == 2
? "异常"
: "离线"
|
db11048f
阿宝
设备状态,学校管理
|
363
364
365
366
367
368
|
}}
</template></el-table-column
>
<el-table-column label="自动更新" align="center"
><template slot-scope="scoped">
<el-switch
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
369
|
v-model="scoped.row.upgradeFlag"
|
db11048f
阿宝
设备状态,学校管理
|
370
371
372
373
374
375
376
|
@change="changeUpdate($event, scoped.row, this)"
>
</el-switch> </template
></el-table-column>
</el-table>
</div>
</div>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
377
378
379
380
381
382
383
384
385
386
387
388
|
<div class="pagination-box">
<el-pagination
small=""
layout="total,prev, pager, next"
:hide-on-single-page="true"
:total="total"
@current-change="changePage"
:current-page="page"
:page-size="size"
>
</el-pagination>
</div>
|
ae0a304c
梁保满
学生管理-显示班级基站信息
|
389
390
391
392
393
394
395
396
397
398
|
<!-- <p class="down" v-if="tableData.length">
<el-button
type="primary"
plain
round
icon="fa fa-cloud-download"
@click="downExl"
>导出报表</el-button
>
</p> -->
|
db11048f
阿宝
设备状态,学校管理
|
399
400
401
|
</div>
</div>
<el-dialog title="设备导入" :visible.sync="diaUp" width="400">
|
87abc4f3
梁保满
基站上传接口地址修改
|
402
|
<up-load :url="url" @upSuccess="upSuccess" fileName="设备信息">
|
db11048f
阿宝
设备状态,学校管理
|
403
404
|
<p class="down-txt" slot="down">
通过Excel名单导入设备,需要提供设备编码,点击
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
405
|
<el-link type="danger" @click="downExcel">模板下载</el-link> 。
|
db11048f
阿宝
设备状态,学校管理
|
406
407
408
409
410
411
|
</p>
</up-load>
<div class="dialog-footer" slot="footer">
<el-button @click="diaUp = false">取 消</el-button>
</div>
</el-dialog>
|
0e46bc25
梁保满
优化
|
412
413
414
415
416
|
<el-dialog
:title="isAdd ? '添加基站' : '修改基站'"
:visible.sync="diaAnswerEqu"
width="400"
>
|
db11048f
阿宝
设备状态,学校管理
|
417
|
<el-form ref="forms" :model="form" :rules="formRules" label-width="140px">
|
1365ef5e
梁保满
优化
|
418
|
<el-form-item label="设备编码:" prop="sn">
|
6d7bd862
梁保满
飞书bug
|
419
|
<el-col :span="16"
|
db11048f
阿宝
设备状态,学校管理
|
420
421
422
|
><el-input
type="text"
placeholder="输入设备编码"
|
1365ef5e
梁保满
优化
|
423
|
v-model.trim="form.sn"
|
db11048f
阿宝
设备状态,学校管理
|
424
425
426
|
maxlength="30"
size="45"
show-word-limit
|
e3b0e3e7
梁保满
季度时间格式调整
|
427
|
:disabled="!isAdd"
|
db11048f
阿宝
设备状态,学校管理
|
428
429
430
431
|
>
</el-input
></el-col>
</el-form-item>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
432
|
<el-form-item label="频点:" prop="frequency">
|
6d7bd862
梁保满
飞书bug
|
433
|
<el-col :span="16"
|
db11048f
阿宝
设备状态,学校管理
|
434
435
436
|
><el-input
type="text"
placeholder="输入频点"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
437
|
v-model.trim="form.frequency"
|
db11048f
阿宝
设备状态,学校管理
|
438
439
440
441
442
443
444
|
maxlength="30"
size="45"
show-word-limit
>
</el-input
></el-col>
</el-form-item>
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
445
|
<el-form-item label="配对码:" prop="pairingCode">
|
6d7bd862
梁保满
飞书bug
|
446
|
<el-col :span="16"
|
db11048f
阿宝
设备状态,学校管理
|
447
448
449
|
><el-input
type="text"
placeholder="输入配对码"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
450
|
v-model.trim="form.pairingCode"
|
db11048f
阿宝
设备状态,学校管理
|
451
452
453
454
455
456
457
|
maxlength="30"
size="45"
show-word-limit
>
</el-input
></el-col>
</el-form-item>
|
6d7bd862
梁保满
飞书bug
|
458
459
|
<el-form-item label="选择班级:" prop="classIds">
<el-col :span="16">
|
db11048f
阿宝
设备状态,学校管理
|
460
|
<el-cascader
|
6d7bd862
梁保满
飞书bug
|
461
|
class="sel"
|
db11048f
阿宝
设备状态,学校管理
|
462
|
clearable
|
6d7bd862
梁保满
飞书bug
|
463
|
v-model="form.classIds"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
464
|
:options="gradeList"
|
db11048f
阿宝
设备状态,学校管理
|
465
466
467
468
469
|
:show-all-levels="false"
></el-cascader>
</el-col>
</el-form-item>
<el-form-item label="所在教室:">
|
6d7bd862
梁保满
飞书bug
|
470
|
<el-col :span="16"
|
db11048f
阿宝
设备状态,学校管理
|
471
472
473
|
><el-input
type="text"
placeholder="输入所在教室"
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
474
|
v-model.trim="form.roomName"
|
db11048f
阿宝
设备状态,学校管理
|
475
476
477
478
479
480
481
482
483
|
maxlength="30"
size="45"
show-word-limit
>
</el-input
></el-col>
</el-form-item>
</el-form>
<div class="dialog-footer" slot="footer">
|
236b1f0e
梁保满
周末-飞书bug
|
484
|
<el-button type="primary" @click="setAnswerEqu">确 定</el-button>
|
db11048f
阿宝
设备状态,学校管理
|
485
486
487
|
<el-button @click="diaAnswerEqu = false">取 消</el-button>
</div>
</el-dialog>
|
bb778c90
阿宝
设备状态
|
488
|
</div>
|
4c4f7640
梁保满
路由表,路由前端文件
|
489
490
491
|
</template>
<script>
|
db11048f
阿宝
设备状态,学校管理
|
492
493
494
|
import pieChart from "@/components/charts/pieChart";
import scatterChart from "@/components/charts/scatterChart";
import _ from "lodash";
|
191d5bfa
梁保满
学生管理、基站管理下载名称设置,上...
|
495
|
import { downloadFile, getBlob, formatGradeNameClass } from "@/utils";
|
255e2506
梁保满
飞书bug及优化
|
496
|
import api from "@/api/apis/apis";
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
497
|
import BusEvent from "@/utils/busEvent";
|
db11048f
阿宝
设备状态,学校管理
|
498
499
|
export default {
components: { pieChart, scatterChart },
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
500
501
502
503
|
watch: {
type: function (val) {
this.page = 1;
this.total = 0;
|
225a00b6
梁保满
飞书问题解决
|
504
|
this.count = 0;
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
505
506
507
508
509
510
511
512
513
514
515
516
|
this.query.classId = [];
this.query.onlineStatus = "";
this.query.sn = "";
this.query.type = "";
if (val == 1) {
this.stationReport();
} else if (val == 2) {
this.keyboardReport();
}
this._QueryData();
},
},
|
db11048f
阿宝
设备状态,学校管理
|
517
518
|
data() {
return {
|
ae0a304c
梁保满
学生管理-显示班级基站信息
|
519
|
exportLoading: false,
|
0e46bc25
梁保满
优化
|
520
|
isAdd: false, //添加还是修改基站
|
e5ff81a1
阿宝
集团管理员接口
|
521
|
role: "",
|
d32e461c
梁保满
备题组卷
|
522
|
code: "",
|
db11048f
阿宝
设备状态,学校管理
|
523
|
loading: false,
|
87abc4f3
梁保满
基站上传接口地址修改
|
524
|
url: "/api_html/school/manager/importStation",
|
db11048f
阿宝
设备状态,学校管理
|
525
526
|
diaUp: false,
diaAnswerEqu: false,
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
527
528
|
gradeList: [],
gradeListAll: [],
|
225a00b6
梁保满
飞书问题解决
|
529
|
schoolAll: [],
|
e3b0e3e7
梁保满
季度时间格式调整
|
530
|
school: {}, //校园账号所属学校信息
|
255e2506
梁保满
飞书bug及优化
|
531
532
533
|
props: {
multiple: true,
checkStrictly: true,
|
255e2506
梁保满
飞书bug及优化
|
534
|
},
|
db11048f
阿宝
设备状态,学校管理
|
535
536
537
|
type: 1,
query: {
classId: [],
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
538
539
540
|
onlineStatus: "",
sn: "",
type: "",
|
db11048f
阿宝
设备状态,学校管理
|
541
542
|
},
statusList: [
|
dbbfc6c5
梁保满
飞书优化及bug
|
543
|
{ label: "全部", value: "" },
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
544
|
{ label: "离线", value: 0 },
|
db11048f
阿宝
设备状态,学校管理
|
545
|
{ label: "在线", value: 1 },
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
546
547
548
549
550
551
552
553
554
555
|
{ label: "异常", value: 2 },
],
typeList: [
{ label: "全部", value: 0 },
{ label: "1日内", value: 1 },
{ label: "3日内", value: 2 },
{ label: "7日内", value: 3 },
{ label: "1月内", value: 4 },
{ label: "3月内", value: 5 },
{ label: "3月以上", value: 6 },
|
db11048f
阿宝
设备状态,学校管理
|
556
557
|
],
form: {
|
255e2506
梁保满
飞书bug及优化
|
558
|
deviceId: "",
|
1365ef5e
梁保满
优化
|
559
|
sn: "",
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
560
561
|
frequency: "",
pairingCode: "",
|
183bfae8
梁保满
设备修改班级选择调整
|
562
|
classIds: [],
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
563
|
roomName: "",
|
db11048f
阿宝
设备状态,学校管理
|
564
565
|
},
formRules: {
|
e3b0e3e7
梁保满
季度时间格式调整
|
566
|
sn: [{ required: true, message: "请输入设备编码", trigger: "blur" }],
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
567
568
569
570
|
frequency: [{ required: true, message: "请输入频点", trigger: "blur" }],
pairingCode: [
{ required: true, message: "请输入配对码", trigger: "blur" },
],
|
280e7dfe
梁保满
设备日志显示选项
|
571
|
classIds: [{ required: true, message: "请选择班级", trigger: "blur" }],
|
db11048f
阿宝
设备状态,学校管理
|
572
|
},
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
573
574
|
tableData: [],
total: 0,
|
225a00b6
梁保满
飞书问题解决
|
575
|
count: 0,
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
576
577
|
chartData: [],
chartData2: [],
|
db11048f
阿宝
设备状态,学校管理
|
578
|
selectionTabIds: [],
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
579
580
|
page: 1,
size: 20,
|
db11048f
阿宝
设备状态,学校管理
|
581
582
583
|
};
},
created() {
|
e3b0e3e7
梁保满
季度时间格式调整
|
584
|
this.code = localStorage.getItem("csCode") || "";
|
87053bc8
梁保满
设备状态模版下载更新
|
585
586
587
|
this.role =
this.$store.getters.info.showRole ||
this.$store.getters.info.permissions[0].role;
|
255e2506
梁保满
飞书bug及优化
|
588
|
if (this.role == "ROLE_JITUAN") {
|
e3b0e3e7
梁保满
季度时间格式调整
|
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
|
(this.props.lazy = true),
(this.props.lazyLoad = function (node, resolve) {
const { level } = node;
if (level == 2) {
console.log(node);
api
.tenantClassList({
schoolId: node.data.value,
})
.then((res) => {
let children = formatGradeNameClass(res.data?.list).sort(
(a, b) => {
return a.grade - b.grade;
}
);
console.log();
|
255e2506
梁保满
飞书bug及优化
|
605
|
|
e3b0e3e7
梁保满
季度时间格式调整
|
606
607
608
609
610
611
612
613
614
615
616
|
const nodes = [...children];
// 通过调用resolve将子节点数据返回,通知组件数据加载完成
resolve(nodes);
});
} else {
resolve(node);
}
});
}
if (this.role == "ROLE_XUEXIAO") {
this._QueryDataSchool();
|
255e2506
梁保满
飞书bug及优化
|
617
|
}
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
618
619
620
|
this.stationReport();
this._QueryGradeList();
this._QueryData();
|
11cb8ce0
梁保满
样式调整
|
621
|
if (this.role == "ROLE_JITUAN") {
|
225a00b6
梁保满
飞书问题解决
|
622
623
|
this.showSchool();
}
|
db11048f
阿宝
设备状态,学校管理
|
624
|
},
|
5be3bb70
梁保满
切换账号,缓存组件接口报错问题
|
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
|
activated() {
const that = this;
BusEvent.$on("keepAlive", async function () {
that.type = 1;
that.page = 1;
that.total = 0;
that.count = 0;
that.query.classId = [];
that.query.onlineStatus = "";
that.query.sn = "";
that.query.type = "";
that.stationReport();
that._QueryData();
});
},
|
db11048f
阿宝
设备状态,学校管理
|
640
|
methods: {
|
191d5bfa
梁保满
学生管理、基站管理下载名称设置,上...
|
641
|
upSuccess(res) {
|
e3b0e3e7
梁保满
季度时间格式调整
|
642
|
//导入成功
|
191d5bfa
梁保满
学生管理、基站管理下载名称设置,上...
|
643
644
645
|
this.$message.closeAll();
this.$message({
showClose: true,
|
fc9cbff6
梁保满
上传信息显示调整
|
646
|
message: `成功(${res.data.success})`,
|
191d5bfa
梁保满
学生管理、基站管理下载名称设置,上...
|
647
|
type: "success",
|
183bfae8
梁保满
设备修改班级选择调整
|
648
|
duration: 5000,
|
191d5bfa
梁保满
学生管理、基站管理下载名称设置,上...
|
649
|
});
|
e3b0e3e7
梁保满
季度时间格式调整
|
650
|
this.diaUp = false;
|
87abc4f3
梁保满
基站上传接口地址修改
|
651
|
this.page = 1;
|
255e2506
梁保满
飞书bug及优化
|
652
653
|
this._QueryData();
},
|
575eb544
梁保满
账号异常提示,放开长水学校管理员设...
|
654
655
|
edit(obj) {
//修改设备
|
0e46bc25
梁保满
优化
|
656
|
this.isAdd = false;
|
255e2506
梁保满
飞书bug及优化
|
657
658
|
for (let key in this.form) {
if (key == "classIds") {
|
5fb1f184
梁保满
答题器管理:不显示 题器配对码,修...
|
659
660
661
|
this.form[key] = obj.classList.length
? [obj.classList[0].gradeName, obj.classList[0].classId]
: [];
|
255e2506
梁保满
飞书bug及优化
|
662
663
|
} else {
this.form[key] = obj[key];
|
6d7bd862
梁保满
飞书bug
|
664
665
|
}
}
|
0e46bc25
梁保满
优化
|
666
|
delete this.form.schoolId;
|
e3b0e3e7
梁保满
季度时间格式调整
|
667
|
this.form.deviceId = obj.id;
|
255e2506
梁保满
飞书bug及优化
|
668
|
this.diaAnswerEqu = true;
|
6d7bd862
梁保满
飞书bug
|
669
|
},
|
db11048f
阿宝
设备状态,学校管理
|
670
671
672
673
674
675
676
677
678
679
|
linkTo(obj, type) {
this.$router.push({
path: "/deviceLog",
query: {
id: obj.id,
type: type,
},
});
},
clickPieChart(obj) {
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
680
681
682
|
this.query.onlineStatus =
obj.name == "在线" ? 1 : obj.name == "离线" ? 0 : 2;
this.query.sn = "";
|
c4eb9615
梁保满
日志页面调整
|
683
|
this.query.classId = [];
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
684
|
this.page = 1;
|
b21d90ef
梁保满
长水登录
|
685
|
this._QueryData(false);
|
db11048f
阿宝
设备状态,学校管理
|
686
687
|
},
clickScatterChart(obj) {
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
688
689
690
691
692
693
694
695
696
697
698
699
700
|
this.query.type =
obj.name == "1日内"
? 1
: obj.name == "3日内"
? 2
: obj.name == "7日内"
? 3
: obj.name == "1月内"
? 4
: obj.name == "3月内"
? 5
: 6;
this.query.sn = "";
|
c4eb9615
梁保满
日志页面调整
|
701
|
this.query.classId = [];
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
702
|
this.page = 1;
|
b21d90ef
梁保满
长水登录
|
703
|
this._QueryData(false);
|
db11048f
阿宝
设备状态,学校管理
|
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
|
},
handleSelectionChange(val) {
console.log(val);
this.selectionTabIds = val.map((item) => {
return item.id;
});
},
changeUpdate: _.debounce(function (event, obj) {
console.log(this);
if (event) {
this.autoUpDate(obj.id);
} else {
this.stopUpdate(obj.id);
}
}, 800),
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
719
720
|
changePage(page) {
this.page = page;
|
b21d90ef
梁保满
长水登录
|
721
|
this._QueryData(false);
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
722
|
},
|
e3b0e3e7
梁保满
季度时间格式调整
|
723
724
725
726
|
addDev() {
this.form.sn = "";
this.form.frequency = "";
this.form.pairingCode = "";
|
183bfae8
梁保满
设备修改班级选择调整
|
727
|
this.form.classIds = [];
|
e3b0e3e7
梁保满
季度时间格式调整
|
728
|
this.form.roomName = "";
|
0e46bc25
梁保满
优化
|
729
730
731
|
this.form.schoolId = this.school.id;
delete this.form.deviceId;
this.isAdd = true;
|
e3b0e3e7
梁保满
季度时间格式调整
|
732
733
|
this.diaAnswerEqu = true;
},
|
225a00b6
梁保满
飞书问题解决
|
734
|
async showSchool() {
|
296f7c47
梁保满
集团管理员接口调整
|
735
736
|
const { data, status, info } = await this.$request.schoolList();
if (status === 0) {
|
183bfae8
梁保满
设备修改班级选择调整
|
737
738
739
740
741
742
|
let gradeListAll = data.list?.map((item) => {
return {
value: item.id,
label: item.schoolName,
};
});
|
225a00b6
梁保满
飞书问题解决
|
743
744
745
746
|
this.schoolAll = [
{
value: 0,
label: "全部",
|
183bfae8
梁保满
设备修改班级选择调整
|
747
|
children: [...gradeListAll],
|
225a00b6
梁保满
飞书问题解决
|
748
749
750
|
},
];
this.gradeList = [...this.schoolAll, ...this.gradeList];
|
296f7c47
梁保满
集团管理员接口调整
|
751
752
753
754
|
} else {
this.$message.error(info);
}
},
|
db11048f
阿宝
设备状态,学校管理
|
755
756
757
758
759
760
761
|
async autoUpDate(id) {
if (!this.selectionTabIds.length && !id) {
this.$message.warning("请选择授课端~");
return;
}
if (this.loadingUpDate) return;
this.loadingUpDate = true;
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
762
|
let data = await this.$request.modifyUpgradeFlag({
|
dd5150c5
阿宝
数据同步
|
763
|
deviceIds: id ? [id] : this.selectionTabIds,
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
764
|
upgradeFlag: 1,
|
db11048f
阿宝
设备状态,学校管理
|
765
766
767
768
|
});
this.loadingUpDate = false;
if (data && !data.code) {
this._QueryData(false);
|
e5ff81a1
阿宝
集团管理员接口
|
769
|
this.selectionTabIds = [];
|
db11048f
阿宝
设备状态,学校管理
|
770
771
|
this.$message.success("开启自动更新成功");
} else {
|
236b1f0e
梁保满
周末-飞书bug
|
772
|
this.$message.error(data.info);
|
db11048f
阿宝
设备状态,学校管理
|
773
774
775
776
777
778
779
780
781
|
}
},
async stopUpdate(id) {
if (!this.selectionTabIds.length && !id) {
this.$message.warning("请选择授课端~");
return;
}
if (this.loadingUpDate) return;
this.loadingUpDate = true;
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
782
|
let data = await this.$request.modifyUpgradeFlag({
|
dd5150c5
阿宝
数据同步
|
783
|
deviceIds: id ? [id] : this.selectionTabIds,
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
784
|
upgradeFlag: 0,
|
db11048f
阿宝
设备状态,学校管理
|
785
786
787
|
});
this.loadingUpDate = false;
if (data && !data.code) {
|
e5ff81a1
阿宝
集团管理员接口
|
788
|
this.selectionTabIds = [];
|
db11048f
阿宝
设备状态,学校管理
|
789
790
791
|
this._QueryData(false);
this.$message.success("关闭自动更新成功");
} else {
|
236b1f0e
梁保满
周末-飞书bug
|
792
|
this.$message.error(data.info);
|
db11048f
阿宝
设备状态,学校管理
|
793
794
795
|
}
},
async downExcel() {
|
87053bc8
梁保满
设备状态模版下载更新
|
796
|
let data = await this.$request.stationTemplate({
|
db11048f
阿宝
设备状态,学校管理
|
797
798
|
id: this.id,
});
|
87053bc8
梁保满
设备状态模版下载更新
|
799
800
801
802
803
|
if (data) {
let blob = new Blob([data], {
type: "application/vnd.ms-excel;charset=utf-8",
});
downloadFile(`基站模版.xlsx`, blob);
|
db11048f
阿宝
设备状态,学校管理
|
804
|
} else {
|
87053bc8
梁保满
设备状态模版下载更新
|
805
|
this.$message.error("下载失败");
|
db11048f
阿宝
设备状态,学校管理
|
806
807
|
}
},
|
ae0a304c
梁保满
学生管理-显示班级基站信息
|
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
|
async downExl() {
//报表到处
if (this.exportLoading == true) return;
const exportPhaseExamReport =
this.type == 1
? this.$request.cTExportPhaseExamReport
: this.type == 1
? this.$request.exportPhaseExamReport
: this.$request.exportPhaseExamReport;
this.exportLoading = true;
const data = await exportPhaseExamReport({ ...this.query });
this.exportLoading = false;
if (data && !data.code) {
let blob = new Blob([data], {
type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
});
let txt =
this.type == 1
? "基站管理报表.xlsx"
: this.type == 2
? "答题器报表.xlsx"
: "授课端报表.xlsx";
downloadFile(txt, blob);
} else {
this.$message.error(data.info);
}
},
|
db11048f
阿宝
设备状态,学校管理
|
835
|
|
236b1f0e
梁保满
周末-飞书bug
|
836
837
|
// 修改基站
setAnswerEqu() {
|
6d7bd862
梁保满
飞书bug
|
838
839
840
841
|
this.$refs.forms.validate(async (valid) => {
if (valid) {
if (this.loadingAnswerEqu) return;
this.loadingAnswerEqu = true;
|
255e2506
梁保满
飞书bug及优化
|
842
|
let query = { ...this.form };
|
236b1f0e
梁保满
周末-飞书bug
|
843
|
|
5fb1f184
梁保满
答题器管理:不显示 题器配对码,修...
|
844
|
query.classIds = query.classIds.length ? [query.classIds[1]] : [];
|
0e46bc25
梁保满
优化
|
845
846
847
|
let deviceApi = this.isAdd
? this.$request.addStation
: this.$request.updateDevice;
|
e3b0e3e7
梁保满
季度时间格式调整
|
848
|
const { data, status, info } = await deviceApi({
|
255e2506
梁保满
飞书bug及优化
|
849
850
|
...query,
});
|
6d7bd862
梁保满
飞书bug
|
851
852
853
|
this.loadingAnswerEqu = false;
console.log(status);
if (status === 0) {
|
255e2506
梁保满
飞书bug及优化
|
854
|
this.diaAnswerEqu = false;
|
1365ef5e
梁保满
优化
|
855
|
this.$message.success(info);
|
6d7bd862
梁保满
飞书bug
|
856
|
this._QueryData();
|
0e46bc25
梁保满
优化
|
857
858
|
if (this.isAdd) {
this.stationReport();
|
e3b0e3e7
梁保满
季度时间格式调整
|
859
|
}
|
6d7bd862
梁保满
飞书bug
|
860
861
862
863
864
865
866
|
} else {
this.$message.error(info);
}
} else {
this.$message.warning("数据有误,请检查!");
}
});
|
db11048f
阿宝
设备状态,学校管理
|
867
|
},
|
e3b0e3e7
梁保满
季度时间格式调整
|
868
869
870
871
872
873
874
875
|
async _QueryDataSchool() {
const { data, status, info } = await this.$request.schoolDetail();
if (status === 0) {
this.school = { ...data };
} else {
this.$message.error(info);
}
},
|
db11048f
阿宝
设备状态,学校管理
|
876
|
// 查找班级
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
877
878
|
async _QueryGradeList() {
this.loading = true;
|
e5ff81a1
阿宝
集团管理员接口
|
879
880
881
882
883
|
const gradeList =
this.role != "ROLE_JITUAN"
? this.$request.gradeList
: this.$request.regionList;
const { data, status, info } = await gradeList();
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
884
885
|
if (status === 0) {
if (!!data.list) {
|
e5ff81a1
阿宝
集团管理员接口
|
886
887
888
889
|
if (this.role != "ROLE_JITUAN") {
this.gradeList =
data.list?.map((item) => {
let gradeList = {
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
890
|
value: item.gradeName,
|
e5ff81a1
阿宝
集团管理员接口
|
891
892
893
894
895
|
label: item.gradeName,
};
gradeList.children =
item.classList?.map((items) => {
return {
|
1365ef5e
梁保满
优化
|
896
|
value: Number(items.id),
|
e5ff81a1
阿宝
集团管理员接口
|
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
|
label: items.className,
};
}) || [];
return gradeList;
}) || [];
} else {
this.gradeList =
data.list?.map((item) => {
let gradeList = {
value: item.id,
label: item.regionName,
};
gradeList.children =
item.schoolList?.map((items) => {
return {
value: items.id,
label: items.schoolName,
};
}) || [];
return gradeList;
}) || [];
|
225a00b6
梁保满
飞书问题解决
|
918
|
this.gradeList = [...this.schoolAll, ...this.gradeList];
|
e5ff81a1
阿宝
集团管理员接口
|
919
|
}
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
920
921
922
923
924
925
926
|
}
} else {
this.$message.error(info);
}
},
// 基站统计数据
async stationReport() {
|
e5ff81a1
阿宝
集团管理员接口
|
927
928
929
930
931
|
const stationReport =
this.role != "ROLE_JITUAN"
? this.$request.stationReport
: this.$request.tenantStationReport;
const { data, status, info } = await stationReport();
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
932
933
934
935
936
|
if (status === 0) {
this.chartData =
data.list?.map((item) => {
return {
name:
|
e5ff81a1
阿宝
集团管理员接口
|
937
938
939
940
941
|
item.onlineStatus == "1"
? "在线"
: item.onlineStatus == 0
? "离线"
: "异常",
|
296f7c47
梁保满
集团管理员接口调整
|
942
943
|
value: item.total,
rate: item.rate,
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
944
945
|
};
}) || [];
|
225a00b6
梁保满
飞书问题解决
|
946
|
this.count = data.total || 0;
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
947
948
949
950
951
952
|
} else {
this.$message.error(info);
}
},
// 答题器统计数据
async keyboardReport() {
|
e5ff81a1
阿宝
集团管理员接口
|
953
954
955
956
957
|
const keyboardReport =
this.role != "ROLE_JITUAN"
? this.$request.keyboardReport
: this.$request.tenantKeyboardReport;
const { data, status, info } = await keyboardReport();
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
|
if (status === 0) {
this.chartData2 =
data.list?.map((item) => {
return {
name:
item.type == 1
? "1日内"
: item.type == 2
? "3日内"
: item.type == 3
? "7日内"
: item.type == 4
? "1月内"
: item.type == 5
? "3月内"
: "3月以上",
|
225a00b6
梁保满
飞书问题解决
|
974
975
|
count: item.total,
value: item.rate * 100,
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
976
977
|
};
}) || [];
|
225a00b6
梁保满
飞书问题解决
|
978
|
this.count = data.total || 0;
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
979
980
981
|
} else {
this.$message.error(info);
}
|
db11048f
阿宝
设备状态,学校管理
|
982
|
},
|
225a00b6
梁保满
飞书问题解决
|
983
984
985
|
setQuery() {
//整理传参
let query = {};
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
986
987
988
|
if (this.query.sn) {
query.sn = this.query.sn;
} else {
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
989
990
991
992
993
994
995
|
if (this.type == 1) {
this.query.onlineStatus !== ""
? (query.onlineStatus = this.query.onlineStatus)
: "";
} else if (this.type == 2) {
this.query.type !== "" ? (query.type = this.query.type) : "";
}
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
996
997
998
|
if (this.role == "ROLE_JITUAN") {
query.regionIds = [];
query.schoolIds = [];
|
255e2506
梁保满
飞书bug及优化
|
999
1000
|
query.gradeNames = [];
query.classIds = [];
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1001
1002
|
this.query.classId?.map((item) => {
if (item.length == 1) {
|
225a00b6
梁保满
飞书问题解决
|
1003
|
if (!query.regionIds.includes(item[0])) {
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1004
1005
|
query.regionIds.push(item[0]);
}
|
255e2506
梁保满
飞书bug及优化
|
1006
|
} else if (item.length == 2) {
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1007
1008
1009
|
if (!query.schoolIds.includes(item[1])) {
query.schoolIds.push(item[1]);
}
|
255e2506
梁保满
飞书bug及优化
|
1010
1011
1012
1013
|
query.regionIds.includes(item[0])
? query.regionIds.remove(item[0])
: "";
} else if (item.length == 3) {
|
1365ef5e
梁保满
优化
|
1014
1015
1016
|
if (!query.schoolIds.includes(item[1])) {
query.schoolIds.push(item[1]);
}
|
255e2506
梁保满
飞书bug及优化
|
1017
1018
|
if (!query.gradeNames.includes(item[2])) {
query.gradeNames.push(item[2]);
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1019
|
}
|
255e2506
梁保满
飞书bug及优化
|
1020
1021
1022
|
query.regionIds.includes(item[0])
? query.regionIds.remove(item[0])
: "";
|
255e2506
梁保满
飞书bug及优化
|
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
|
} else if (item.length == 4) {
if (!query.classIds.includes(item[3])) {
query.classIds.push(item[3]);
}
query.regionIds.includes(item[0])
? query.regionIds.remove(item[0])
: "";
query.schoolIds.includes(item[1])
? query.schoolIds.remove(item[1])
: "";
query.gradeNames.includes(item[2])
? query.gradeNames.remove(item[2])
: "";
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1036
1037
1038
1039
1040
1041
1042
|
}
});
} else {
query.gradeNames = [];
query.classIds = [];
this.query.classId?.map((item) => {
if (item.length == 1) {
|
225a00b6
梁保满
飞书问题解决
|
1043
|
if (!query.gradeNames.includes(item[0])) {
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
|
query.gradeNames.push(item[0]);
}
} else {
if (!query.classIds.includes(item[1])) {
query.classIds.push(item[1]);
}
if (query.gradeNames.includes(item[0])) {
query.gradeNames.remove(item[0]);
}
}
});
}
delete query.classId;
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
1057
|
}
|
225a00b6
梁保满
飞书问题解决
|
1058
|
return query;
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1059
1060
1061
1062
|
},
// 设备列表信息
async _QueryData(isRef) {
this.loading = true;
|
225a00b6
梁保满
飞书问题解决
|
1063
|
let query = this.setQuery();
|
1b9bae95
梁保满
级联选择器调整,日志接口调整
|
1064
1065
|
if (isRef) {
this.page = 1;
|
b21d90ef
梁保满
长水登录
|
1066
|
}
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
1067
|
this.loading = true;
|
e5ff81a1
阿宝
集团管理员接口
|
1068
1069
1070
1071
|
const deviceList =
this.role != "ROLE_JITUAN"
? this.$request.deviceList
: this.$request.tenantDeviceList;
|
6d7bd862
梁保满
飞书bug
|
1072
|
this.tableData = [];
|
e5ff81a1
阿宝
集团管理员接口
|
1073
|
const { data, status, info } = await deviceList({
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
1074
1075
1076
1077
1078
1079
|
...query,
deviceType: this.type,
page: this.page,
size: this.size,
});
this.loading = false;
|
e5ff81a1
阿宝
集团管理员接口
|
1080
|
if (status == 0) {
|
225a00b6
梁保满
飞书问题解决
|
1081
|
this.tableData =
|
255e2506
梁保满
飞书bug及优化
|
1082
1083
1084
1085
1086
1087
|
(data?.list &&
data?.list.map((item) => {
item.upgradeFlag = item.upgradeFlag == 1 ? true : false;
return item;
})) ||
[];
|
0e46bc25
梁保满
优化
|
1088
|
|
225a00b6
梁保满
飞书问题解决
|
1089
|
this.total = data.count;
|
e3b0e3e7
梁保满
季度时间格式调整
|
1090
1091
|
this.$nextTick(function () {
this.$refs.main.scrollTop = 0;
|
0e46bc25
梁保满
优化
|
1092
1093
1094
1095
1096
1097
|
if (this.query.classId.length) {
this.selectionTabIds = this.tableData.map((item) => {
this.$refs.multipleTable.toggleRowSelection(item);
return item.id;
});
}
|
e3b0e3e7
梁保满
季度时间格式调整
|
1098
|
});
|
23a6dc5f
阿宝
学校管理相关接口简单对接
|
1099
1100
1101
|
} else {
this.$message.error(info);
}
|
db11048f
阿宝
设备状态,学校管理
|
1102
1103
1104
|
},
},
};
|
4c4f7640
梁保满
路由表,路由前端文件
|
1105
1106
|
</script>
|
db11048f
阿宝
设备状态,学校管理
|
1107
1108
|
<style lang="scss" scoped>
.page-content {
|
1365ef5e
梁保满
优化
|
1109
1110
1111
|
padding: 0 20px;
height: 100%;
overflow-y: auto;
|
db11048f
阿宝
设备状态,学校管理
|
1112
1113
|
}
.tab-box {
|
e3b0e3e7
梁保满
季度时间格式调整
|
1114
|
padding: 20px 0 12px;
|
db11048f
阿宝
设备状态,学校管理
|
1115
|
}
|
ae0a304c
梁保满
学生管理-显示班级基站信息
|
1116
1117
1118
|
.down {
padding:0 0 16px 20px;
}
|
db11048f
阿宝
设备状态,学校管理
|
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
|
.content {
background: #f8f8f8;
border: 1px solid #e2e2e2;
border-radius: 10px;
overflow: hidden;
:deep(.fa-edit) {
width: 12px;
height: 12px;
&::before {
margin-left: 2px;
}
}
:deep(.fa-eye) {
width: 12px;
height: 12px;
&::before {
margin-left: 1px;
}
}
.chart-box {
display: flex;
overflow: hidden;
height: 240px;
border-bottom: 0.5px solid #e2e2e2;
.device-num {
width: 280px;
border-right: 0.5px solid #e2e2e2;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
.p1 {
font-size: 28px;
}
}
.chart {
flex: 1;
height: 100%;
}
}
.table-box {
padding: 20px;
.answer-header {
padding: 0;
margin-bottom: 12px;
}
}
}
|
4c4f7640
梁保满
路由表,路由前端文件
|
1167
|
</style>
|