|
@@ -25,7 +25,7 @@
|
|
|
<template #default="{ row }">{{ row.clientID }}</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="IP" prop="updateTime" show-overflow-tooltip>
|
|
|
- <template #default="{ row }">{{ getIp(row.deviceInfo || '{}') }}</template>
|
|
|
+ <template #default="{ row }">{{ row.clientIp }}</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="设备信息" min-width="150" prop="deviceInfo" show-overflow-tooltip>
|
|
|
<template #header>
|
|
@@ -124,11 +124,16 @@ const getIp = (jsonString: string) => {
|
|
|
|
|
|
const getDeviceName = (jsonString: string) => {
|
|
|
if(!jsonString) return '';
|
|
|
- const nameMatch = jsonString.match(/"name"\s*:\s*"([^"]+)"/);
|
|
|
+ const nameMatch = jsonString.match(/"model"\s*:\s*"([^"]+)"/);
|
|
|
+ console.log(nameMatch);
|
|
|
+
|
|
|
const systemNameMatch = jsonString.match(/"systemName"\s*:\s*"([^"]+)"/);
|
|
|
+ const version = jsonString.match(/"version"\s*:\s*"([^"]+)"/);
|
|
|
const name = nameMatch ? nameMatch[1] : 'unKnown';
|
|
|
const systemName = systemNameMatch ? systemNameMatch[1] : 'unKnown';
|
|
|
- return `设备名称:${name}; 系统名称:${systemName}`
|
|
|
+ const versionName = version ? version[1] : '';
|
|
|
+
|
|
|
+ return `设备名称:${name}; 系统版本:${systemName} ${versionName}`
|
|
|
}
|
|
|
|
|
|
const timeRange = computed({
|