15928045575 %!s(int64=2) %!d(string=hai) anos
pai
achega
1bba373ec3

+ 4 - 0
slope-modules/slope-detection/src/main/java/com/sckw/slope/detection/model/param/DeviceModelQuery.java

@@ -18,4 +18,8 @@ public class DeviceModelQuery {
     private int page;
 
     private int pageSize;
+
+    private Integer Status;
+
+    private Integer attribute;
 }

+ 5 - 0
slope-modules/slope-detection/src/main/java/com/sckw/slope/detection/model/param/DeviceQuery.java

@@ -44,6 +44,11 @@ public class DeviceQuery {
      */
     private String deviceModel;
 
+    /**
+     * 设备类别
+     */
+    private String attribute;
+
     private int page;
 
     private int pageSize;

+ 5 - 0
slope-modules/slope-detection/src/main/java/com/sckw/slope/detection/model/vo/DeviceVo.java

@@ -147,5 +147,10 @@ public class DeviceVo implements Serializable {
      */
     private String projectName;
 
+    /**
+     * 产品类型
+     */
+    private Long deviceType;
+
     private static final long serialVersionUID = 1L;
 }

+ 1 - 1
slope-modules/slope-detection/src/main/java/com/sckw/slope/detection/service/DeviceService.java

@@ -99,7 +99,7 @@ public class DeviceService {
     }
 
     /**
-     * 项目管理分页查询
+     * 设备管理分页查询
      *
      * @param deviceQuery 请求分页
      * @param response    http流

+ 4 - 0
slope-modules/slope-detection/src/main/resources/mapper/mysql/KwsDeviceMapper.xml

@@ -40,6 +40,7 @@
              manufacturer,
              device_type,
              m.name   as m_name,
+             m.device_type,
              d.remark,
              d.update_by,
              d.update_time,
@@ -59,6 +60,9 @@
           <if test="deviceQuery.id != null and deviceQuery.id != ''">
               and id = #{deviceQuery.id,jdbcType=BIGINT}
           </if>
+          <if test="deviceQuery.attribute != null and deviceQuery.attribute != ''">
+              and attribute = #{deviceQuery.attribute,jdbcType=TINYINT}
+          </if>
       </where>
   </select>
   <insert id="insert" parameterType="com.sckw.slope.detection.model.dos.mysql.KwsDevice">

+ 3 - 0
slope-modules/slope-detection/src/main/resources/mapper/mysql/KwsDeviceModelMapper.xml

@@ -46,6 +46,9 @@
         <if test="deviceModelQuery.name != null and deviceModelQuery.name != ''">
             and name like concat('%', #{deviceModelQuery.name}, '%')
         </if>
+        <if test="deviceModelQuery.status != null and deviceModelQuery.status != ''">
+            and status = #{deviceModelQuery.Status,jdbcType=TINYINT}
+        </if>
     </select>
     <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
         <!--@mbg.generated-->