Browse Source

style:1、界面显示优化,页面比例超过100%时,显示完整设备名称2、心跳记录支持根据设备名称模糊查询

lihao16 3 months ago
parent
commit
6e7c86b0d2

+ 2 - 0
smsb-modules/smsb-device/src/main/java/com/inspur/device/domain/bo/SmsbDeviceHeartRecordBo.java

@@ -49,6 +49,8 @@ public class SmsbDeviceHeartRecordBo {
     @TableField(fill = FieldFill.INSERT)
     private Date createTime;
 
+    private String deviceName;
+
     /**
      * 请求参数
      */

+ 3 - 0
smsb-modules/smsb-device/src/main/resources/mapper/device/SmsbDeviceHeartRecordMapper.xml

@@ -19,6 +19,9 @@
         <if test="bo.clientIp != null and bo.clientIp != ''">
             AND sdh.client_ip like concat('%',#{bo.clientIp},'%')
         </if>
+        <if test="bo.deviceName != null and bo.deviceName != ''">
+            AND sd.name like concat('%',#{bo.deviceName},'%')
+        </if>
         <if test="bo.heartType != null">
             AND sdh.heart_type = #{bo.heartType}
         </if>

+ 1 - 1
smsb-plus-ui/src/views/smsb/deviceAuth/index.vue

@@ -29,7 +29,7 @@
     <el-card shadow="never">
       <div class="table-content">
         <el-table v-loading="loading" :data="deviceAuthList" @selection-change="handleSelectionChange">
-          <el-table-column label="主键ID" align="left" prop="id" v-if="true" width="180" :show-overflow-tooltip="true" />
+          <el-table-column label="" align="left" prop="" width="10" />
           <el-table-column label="加密字符" align="left" prop="encryptCode" width="250" :show-overflow-tooltip="true" />
           <el-table-column label="解密字符" align="left" prop="decryptCode" width="250" :show-overflow-tooltip="true" />
           <el-table-column label="鉴权key" align="left" prop="authKey" width="150" :show-overflow-tooltip="true" />

+ 6 - 5
smsb-plus-ui/src/views/smsb/deviceLogin/index.vue

@@ -50,18 +50,19 @@
           <!--
                 <el-table-column type="selection" width="55" align="center" />
         -->
-          <el-table-column label="ID" align="left" prop="id" v-if="true" width="180" :show-overflow-tooltip="true" />
+<!--          <el-table-column label="ID" align="left" prop="id" v-if="true" width="180" :show-overflow-tooltip="true" />-->
+          <el-table-column label="" align="left" prop="" width="10" />
           <el-table-column label="请求标识" align="left" prop="reqIdentifier" width="220" :show-overflow-tooltip="true" />
           <el-table-column label="请求IP" align="left" prop="reqIp" width="130" :show-overflow-tooltip="true" />
-          <el-table-column label="登录结果" align="center" prop="loginResult" width="120">
+          <el-table-column label="登录结果" align="center" prop="loginResult" width="100">
             <template #default="scope">
               <dict-tag :options="smsb_device_login_result" :value="scope.row.loginResult" />
             </template>
           </el-table-column>
           <el-table-column label="登录时间" align="left" prop="createTime" width="160" />
-          <el-table-column label="设备名称" align="left" prop="deviceName" :show-overflow-tooltip="true" />
-          <el-table-column label="设备标识" align="left" prop="identifier" width="220" :show-overflow-tooltip="true" />
-          <el-table-column label="设备SN" align="left" prop="serialNumber" width="180" :show-overflow-tooltip="true" />
+          <el-table-column label="设备名称" align="left" prop="deviceName" :show-overflow-tooltip="true" width="320" />
+          <el-table-column label="设备标识" align="left" prop="identifier" :show-overflow-tooltip="true" />
+          <el-table-column label="设备SN" align="left" prop="serialNumber" :show-overflow-tooltip="true" />
           <el-table-column label="设备MAC" align="left" prop="mac" width="150" />
           <el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width" width="80">
             <template #default="scope">

+ 6 - 3
smsb-plus-ui/src/views/smsb/httpHeart/index.vue

@@ -11,6 +11,9 @@
             <el-form-item label="设备IP" prop="clientIp">
               <el-input v-model="queryParams.clientIp" placeholder="请输入设备IP" clearable @keyup.enter="handleQuery" />
             </el-form-item>
+            <el-form-item label="设备名称" prop="deviceName">
+              <el-input v-model="queryParams.deviceName" placeholder="请输入设备名称" clearable @keyup.enter="handleQuery" />
+            </el-form-item>
             <el-form-item>
               <el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
               <el-button icon="Refresh" @click="resetQuery">重置</el-button>
@@ -48,9 +51,9 @@
           <!--        <el-table-column label="心跳类型 1-http 2-Netty" align="center" prop="heartType" />-->
           <el-table-column label="心跳间隔" align="center" prop="timeInterval" width="100" />
           <el-table-column label="心跳时间" align="left" prop="createTime" width="180" />
-          <el-table-column label="设备名称" align="left" prop="deviceName" :show-overflow-tooltip="true" />
-          <el-table-column label="设备SN" align="left" prop="serialNumber" width="220" :show-overflow-tooltip="true" />
-          <el-table-column label="设备MAC" align="left" prop="mac" width="180" />
+          <el-table-column label="设备名称" align="left" prop="deviceName" width="300" :show-overflow-tooltip="true" />
+          <el-table-column label="设备SN" align="left" prop="serialNumber" :show-overflow-tooltip="true" />
+          <el-table-column label="设备MAC" align="left" prop="mac" :show-overflow-tooltip="true" />
           <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="100">
             <template #default="scope">
               <!--            <el-tooltip content="修改" placement="top">

+ 6 - 3
smsb-plus-ui/src/views/smsb/nettyHeart/index.vue

@@ -11,6 +11,9 @@
 <!--            <el-form-item label="设备IP" prop="clientIp">
               <el-input v-model="queryParams.clientIp" placeholder="请输入设备IP" clearable @keyup.enter="handleQuery" />
             </el-form-item>-->
+            <el-form-item label="设备名称" prop="deviceName">
+              <el-input v-model="queryParams.deviceName" placeholder="请输入设备名称" clearable @keyup.enter="handleQuery" />
+            </el-form-item>
             <el-form-item>
               <el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
               <el-button icon="Refresh" @click="resetQuery">重置</el-button>
@@ -50,9 +53,9 @@
           <!--        <el-table-column label="心跳类型 1-http 2-Netty" align="center" prop="heartType" />-->
           <el-table-column label="心跳间隔" align="center" prop="timeInterval" width="100" />
           <el-table-column label="心跳时间" align="left" prop="createTime" width="200" />
-          <el-table-column label="设备名称" align="left" prop="deviceName" :show-overflow-tooltip="true" />
-          <el-table-column label="设备SN" align="left" prop="serialNumber" width="250" :show-overflow-tooltip="true" />
-          <el-table-column label="设备MAC" align="left" prop="mac" width="220" />
+          <el-table-column label="设备名称" align="left" prop="deviceName" width="350" :show-overflow-tooltip="true" />
+          <el-table-column label="设备SN" align="left" prop="serialNumber"   :show-overflow-tooltip="true" />
+          <el-table-column label="设备MAC" align="left" prop="mac" :show-overflow-tooltip="true" />
           <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="100">
             <template #default="scope">
               <!--            <el-tooltip content="修改" placement="top">