|
|
|
|
@ -6,7 +6,7 @@ |
|
|
|
|
<template #menu="{ row, index }"> |
|
|
|
|
<el-button type="text" icon="el-icon-view" size="small" @click="rowView(row, index)">详情 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button type="text" icon="el-icon-map-location" :disabled="row.x == null" size="small" |
|
|
|
|
<el-button type="text" icon="el-icon-map-location" size="small" |
|
|
|
|
@click="rowMap(row, index)">地图定位 |
|
|
|
|
</el-button> |
|
|
|
|
</template> |
|
|
|
|
@ -51,22 +51,22 @@ export default { |
|
|
|
|
dialogClickModal: false, |
|
|
|
|
menuWidth: 180, |
|
|
|
|
column: [ |
|
|
|
|
{ |
|
|
|
|
label: "设备名称", |
|
|
|
|
prop: "name", |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "sn编号", |
|
|
|
|
prop: "sn", |
|
|
|
|
search: true, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "姓名", |
|
|
|
|
prop: "patientName", |
|
|
|
|
search: true, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "性别", |
|
|
|
|
prop: "sex", |
|
|
|
|
type: "select", |
|
|
|
|
dicData: [ |
|
|
|
|
{ value: "1", label: "男" }, { value: '0', label: "女" } |
|
|
|
|
], |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "科室", |
|
|
|
|
@ -74,48 +74,21 @@ export default { |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "状态", |
|
|
|
|
type: "status", |
|
|
|
|
type: "select", |
|
|
|
|
dicData: [ |
|
|
|
|
{ value: 0, label: "在线" }, { value: 1, label: "离线" } |
|
|
|
|
{ value: 'alarm', label: "报警" }, { value: 'offLine', label: "离线" }, { value: 'onLine', label: "在线" } |
|
|
|
|
], |
|
|
|
|
prop: "communicateStatus", |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "最后一次通信时间", |
|
|
|
|
labelWidth: 150, |
|
|
|
|
prop: "lastCommunicateTime", |
|
|
|
|
span: 24, |
|
|
|
|
formatter: (data, value) => { |
|
|
|
|
return dateFormat(new Date(data.lastCommunicateTime)) |
|
|
|
|
}, |
|
|
|
|
hide: true |
|
|
|
|
prop: "status", |
|
|
|
|
search: true, |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "最后一次配置时间", |
|
|
|
|
labelWidth: 150, |
|
|
|
|
prop: "lastConfigTime", |
|
|
|
|
span: 24, |
|
|
|
|
formatter: (data, value) => { |
|
|
|
|
return dateFormat(new Date(data.lastConfigTime)) |
|
|
|
|
}, |
|
|
|
|
hide: true |
|
|
|
|
label: "年龄", |
|
|
|
|
prop: "age", |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "入场时间", |
|
|
|
|
labelWidth: 150, |
|
|
|
|
prop: "admissionTime", |
|
|
|
|
label: "手机号", |
|
|
|
|
prop: "phone", |
|
|
|
|
span: 24, |
|
|
|
|
formatter: (data, value) => { |
|
|
|
|
return dateFormat(new Date(data.lastLocateTime)) |
|
|
|
|
}, |
|
|
|
|
hide: true |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
label: "出科室时间", |
|
|
|
|
prop: "outDepartmentTime", |
|
|
|
|
formatter: (data, value) => { |
|
|
|
|
return dateFormat(new Date(data.createTime)) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
] |
|
|
|
|
}, |
|
|
|
|
@ -152,7 +125,7 @@ export default { |
|
|
|
|
if (token == 'undefined' || !token) { |
|
|
|
|
bizLogin({ appKey: 'Arf7bd4f26', appSecret: 'kb207044c8' }).then(res => { |
|
|
|
|
window.sessionStorage.setItem('bizToken', res.data.data.token); |
|
|
|
|
terminalList(res.data.data.token, Object.assign(params, this.query, { page: page.currentPage, size: page.pageSize, buildingIds: this.buildingId, sn: row.sn })).then(res2 => { |
|
|
|
|
terminalList(res.data.data.token, { page: 1, size: 1, buildingIds: this.buildingId, sn: row.sn }).then(res2 => { |
|
|
|
|
if (res2.data.code == 401) { |
|
|
|
|
window.sessionStorage.removeItem('bizToken'); |
|
|
|
|
this.rowMap(row, index) |
|
|
|
|
@ -174,7 +147,7 @@ export default { |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
else { |
|
|
|
|
terminalList(token, Object.assign(params, this.query, { page: page.currentPage, size: page.pageSize, buildingIds: this.buildingId, sn: row.sn })).then(res2 => { |
|
|
|
|
terminalList(token, { page: 1, size: 1, buildingIds: this.buildingId, sn: row.sn }).then(res2 => { |
|
|
|
|
if (res2.data.code == 401) { |
|
|
|
|
window.sessionStorage.removeItem('bizToken'); |
|
|
|
|
this.rowMap(row, index); |
|
|
|
|
@ -236,8 +209,8 @@ export default { |
|
|
|
|
} |
|
|
|
|
else if (res2.data.code == 0) { |
|
|
|
|
const data = res2.data.data; |
|
|
|
|
this.page.total = data.totalElements; |
|
|
|
|
this.data = data.content; |
|
|
|
|
this.page.total = data.total; |
|
|
|
|
this.data = data.records; |
|
|
|
|
} |
|
|
|
|
}, err => { |
|
|
|
|
this.loading = false; |
|
|
|
|
@ -254,8 +227,8 @@ export default { |
|
|
|
|
} |
|
|
|
|
else if (res2.data.code == 0) { |
|
|
|
|
const data = res2.data.data; |
|
|
|
|
this.page.total = data.totalElements; |
|
|
|
|
this.data = data.content; |
|
|
|
|
this.page.total = data.total; |
|
|
|
|
this.data = data.records; |
|
|
|
|
} |
|
|
|
|
}, err => { |
|
|
|
|
this.loading = false; |
|
|
|
|
|