selectAllPro(@Param("type") String type);
+
+ /**
+ * 通过ID获取数据终端
+ * @param id ID
+ * @return DataTerminal
+ */
+ DataTerminal getById(Long id);
+
+ /**
+ * 查询已开通的数据终端
+ * @param type 数据终端类型
+ * @return DataTerminal
+ */
+ DataTerminal getTerminalOpen(@Param("type") String type);
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/DeviceDistributionMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceDistributionMapper.java
new file mode 100644
index 0000000..b785e8f
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceDistributionMapper.java
@@ -0,0 +1,37 @@
+package com.imitate.web.persistence.mapper;
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.params.DistributionListParam;
+import com.imitate.web.persistence.beans.DeviceDistribution;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * 设备配发/调拨单 Mapper 接口
+ *
+ *
+ * @author jshixiong
+ * @since 2022-08-02
+ */
+@Mapper
+@Repository
+public interface DeviceDistributionMapper extends BaseMapper {
+
+ /**
+ * 条件查询
+ * @param param DistributionListParam
+ * @return List
+ */
+ List selectAllPro(@Param("param") DistributionListParam param);
+
+ /**
+ * 通过id获取详情
+ * @param id ID
+ * @return DeviceDistribution
+ */
+ DeviceDistribution getById(Long id);
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/DeviceMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceMapper.java
new file mode 100644
index 0000000..637706b
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceMapper.java
@@ -0,0 +1,58 @@
+package com.imitate.web.persistence.mapper;
+
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.persistence.beans.Device;
+import com.imitate.web.params.DeviceListParam;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * 模拟设备表 Mapper 接口
+ *
+ *
+ * @author jshixiong
+ * @since 2022-07-14
+ */
+@Mapper
+@Repository
+public interface DeviceMapper extends BaseMapper {
+
+ /**
+ * 查所有设备详情列表
+ * @param param 查询条件
+ * @return List
+ */
+ List selectAllPro(@Param("param") DeviceListParam param);
+
+ /**
+ * 根据类型查设备列表
+ * @return List
+ */
+ List selectDeviceByType();
+
+ /**
+ * id获取设备
+ * @param id ID
+ * @return Device
+ */
+ Device getById(Long id);
+
+ /**
+ * 查询有多少使用该ID厂商的设备
+ * @param producerId 厂商ID
+ * @return Integer
+ */
+ Integer selectCountById(Long producerId);
+
+ /**
+ * 还原设备配发状态
+ * @param distributionId 配发单ID
+ * @return int
+ */
+ int updateDistributionId (Long distributionId);
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/DeviceTypeMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceTypeMapper.java
new file mode 100644
index 0000000..348c7b4
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceTypeMapper.java
@@ -0,0 +1,37 @@
+package com.imitate.web.persistence.mapper;
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.params.DeviceTypeParam;
+import com.imitate.web.persistence.beans.DeviceType;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * 设备类型表 Mapper 接口
+ *
+ *
+ * @author jshixiong
+ * @since 2022-07-25
+ */
+@Mapper
+@Repository
+public interface DeviceTypeMapper extends BaseMapper {
+
+ /**
+ * 根据ID获取类型详情
+ * @param id ID
+ * @return DeviceType
+ */
+ DeviceType getById(Long id);
+
+ /**
+ * 条件查询列表
+ * @param param DeviceTypeParam
+ * @return List
+ */
+ List selectByKey(@Param("param") DeviceTypeParam param);
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/DeviceTypeProducerMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceTypeProducerMapper.java
new file mode 100644
index 0000000..505e762
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/DeviceTypeProducerMapper.java
@@ -0,0 +1,26 @@
+package com.imitate.web.persistence.mapper;
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.persistence.beans.DeviceTypeProducer;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+/**
+ *
+ * Mapper 接口
+ *
+ *
+ * @author jshixiong
+ * @since 2022-07-25
+ */
+@Mapper
+@Repository
+public interface DeviceTypeProducerMapper extends BaseMapper {
+
+ /**
+ * 根据typeId删除所有相关 类型-厂商表
+ * @param id ID
+ * @return int
+ */
+ int deleteByTypeId(Long id);
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/ProducerMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/ProducerMapper.java
new file mode 100644
index 0000000..13b1ac7
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/ProducerMapper.java
@@ -0,0 +1,21 @@
+package com.imitate.web.persistence.mapper;
+
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.persistence.beans.Producer;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+/**
+ *
+ * 生产厂商表 Mapper 接口
+ *
+ *
+ * @author jshixiong
+ * @since 2022-07-14
+ */
+@Mapper
+@Repository
+public interface ProducerMapper extends BaseMapper {
+
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/ResourceMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/ResourceMapper.java
new file mode 100644
index 0000000..0bfd5a9
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/ResourceMapper.java
@@ -0,0 +1,17 @@
+package com.imitate.web.persistence.mapper;
+
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.persistence.beans.Resource;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface ResourceMapper extends BaseMapper {
+
+ Resource selectRecentResource();
+
+
+ void truncateTable();
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/SecretKeyMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/SecretKeyMapper.java
new file mode 100644
index 0000000..ff8eeff
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/SecretKeyMapper.java
@@ -0,0 +1,63 @@
+package com.imitate.web.persistence.mapper;
+
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.persistence.beans.SecretKey;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+/**
+ *
+ * 密钥存储表 Mapper 接口
+ *
+ *
+ * @author jshixiong
+ * @since 2022-07-14
+ */
+@Mapper
+@Repository
+public interface SecretKeyMapper extends BaseMapper {
+
+ /**
+ * 通过长度和类型查询
+ * @param secretKey
+ * @return SecretKey
+ */
+ SecretKey selectByLengthAndType(SecretKey secretKey);
+
+ /**
+ * 通过长度和类型修改
+ * @param secretKey
+ * @return int
+ */
+ int updateByLengthAndType(SecretKey secretKey);
+
+ /**
+ * 通过算法和类型修改
+ * @param secretKey
+ * @return int
+ */
+ int updateByAlgorithmAndType(SecretKey secretKey);
+
+ /**
+ * 通过类型查各长度密钥的数量
+ * @param type
+ * @return List
+ */
+ List selectStatisticsByType(String type);
+
+ /**
+ * 通过长度和类型推送
+ * @param secretKey
+ * @return int
+ */
+ int pushByLengthAndType(SecretKey secretKey);
+
+ /**
+ * 删除所有表数据!
+ * @return int
+ */
+ int deleteAll();
+}
diff --git a/web/src/main/java/com/imitate/web/persistence/mapper/SysLogMapper.java b/web/src/main/java/com/imitate/web/persistence/mapper/SysLogMapper.java
new file mode 100644
index 0000000..645acad
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/persistence/mapper/SysLogMapper.java
@@ -0,0 +1,20 @@
+package com.imitate.web.persistence.mapper;
+
+import com.imitate.common.util.BaseMapper;
+import com.imitate.web.persistence.beans.SysLog;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+
+@Mapper
+@Repository
+public interface SysLogMapper extends BaseMapper {
+ /**
+ * 根据操作名查日志
+ * @param operation 操作
+ * @return List
+ */
+ List selectAllByOperation(@Param("operation") String operation);
+}
diff --git a/web/src/main/java/com/imitate/web/vo/DeviceByTypeVO.java b/web/src/main/java/com/imitate/web/vo/DeviceByTypeVO.java
new file mode 100644
index 0000000..ac95908
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/DeviceByTypeVO.java
@@ -0,0 +1,16 @@
+package com.imitate.web.vo;
+
+import com.imitate.web.persistence.beans.Device;
+import lombok.Data;
+
+import java.util.List;
+
+/**
+ * @author jshixiong
+ */
+@Data
+public class DeviceByTypeVO {
+ private Long type;
+
+ private List deviceList;
+}
diff --git a/web/src/main/java/com/imitate/web/vo/DeviceManagerInitVO.java b/web/src/main/java/com/imitate/web/vo/DeviceManagerInitVO.java
new file mode 100644
index 0000000..040ec71
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/DeviceManagerInitVO.java
@@ -0,0 +1,36 @@
+package com.imitate.web.vo;
+
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import lombok.Data;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * 设施管理终端初始化资源类
+ * @author jshixiong
+ */
+@Data
+@ExcelIgnoreUnannotated
+public class DeviceManagerInitVO {
+
+ @ExcelProperty(value = "预制秘钥加密—秘钥长度")
+ private String keyLength;
+
+ @ExcelProperty(value = "产生公私钥对—算法类型")
+ private String algorithm;
+
+ private List keyLengthList;
+
+ private List algorithmList;
+
+ public DeviceManagerInitVO() {}
+
+ public DeviceManagerInitVO(boolean isList) {
+ if (isList){
+ this.keyLengthList = new ArrayList<>();
+ this.algorithmList = new ArrayList<>();
+ }
+ }
+}
diff --git a/web/src/main/java/com/imitate/web/vo/DeviceResourceInitVO.java b/web/src/main/java/com/imitate/web/vo/DeviceResourceInitVO.java
new file mode 100644
index 0000000..e13bd38
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/DeviceResourceInitVO.java
@@ -0,0 +1,30 @@
+package com.imitate.web.vo;
+
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import lombok.Data;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * 设备初装初始化资源类
+ * @author jshixiong
+ */
+@Data
+@ExcelIgnoreUnannotated
+public class DeviceResourceInitVO {
+
+ @ExcelProperty(value = "资源状态")
+ private String resourceStatus;
+
+ private List resourceStatusList;
+
+ public DeviceResourceInitVO() {}
+
+ public DeviceResourceInitVO(boolean isList) {
+ if (isList){
+ this.resourceStatusList = new ArrayList<>();
+ }
+ }
+}
diff --git a/web/src/main/java/com/imitate/web/vo/DeviceSoftwareInitVO.java b/web/src/main/java/com/imitate/web/vo/DeviceSoftwareInitVO.java
new file mode 100644
index 0000000..2aeee0b
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/DeviceSoftwareInitVO.java
@@ -0,0 +1,48 @@
+package com.imitate.web.vo;
+
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import lombok.Data;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * 设施管理软件初始化资源类
+ * @author jshixiong
+ */
+@Data
+@ExcelIgnoreUnannotated
+public class DeviceSoftwareInitVO {
+
+ @ExcelProperty(value = "开通设施管理设备证书系统—选择单位")
+ private String firstUnit;
+
+ @ExcelProperty(value = "总部级—选择保障单位")
+ private String supportUnit;
+
+ @ExcelProperty(value = "总部级—选择管理节点")
+ private String managerNode;
+
+ @ExcelProperty(value = "数据库配置—数据库类型")
+ private String dbType;
+
+ private List firstUnitList;
+
+ private List supportUnitList;
+
+ private List managerNodeList;
+
+ private List dbTypeList;
+
+ public DeviceSoftwareInitVO() {}
+
+ public DeviceSoftwareInitVO(boolean isList) {
+ if (isList){
+ this.firstUnitList = new ArrayList<>();
+ this.supportUnitList = new ArrayList<>();
+ this.managerNodeList = new ArrayList<>();
+ this.dbTypeList = new ArrayList<>();
+ }
+ }
+}
diff --git a/web/src/main/java/com/imitate/web/vo/DeviceTypeVO.java b/web/src/main/java/com/imitate/web/vo/DeviceTypeVO.java
new file mode 100644
index 0000000..52f2e5e
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/DeviceTypeVO.java
@@ -0,0 +1,28 @@
+package com.imitate.web.vo;
+
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import lombok.Data;
+
+/**
+ * @author jshixiong
+ */
+@Data
+@ExcelIgnoreUnannotated
+public class DeviceTypeVO {
+
+ @ExcelProperty(value = "装备名称")
+ private String name;
+
+ @ExcelProperty(value = "装备代号")
+ private String typeNumber;
+
+ @ExcelProperty(value = "工作模式")
+ private String pattern;
+
+ @ExcelProperty(value = "装备密级")
+ private String secretLevel;
+
+ @ExcelProperty(value = "管理层级")
+ private String managementLevel;
+}
diff --git a/web/src/main/java/com/imitate/web/vo/DeviceVO.java b/web/src/main/java/com/imitate/web/vo/DeviceVO.java
new file mode 100644
index 0000000..da311bd
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/DeviceVO.java
@@ -0,0 +1,38 @@
+package com.imitate.web.vo;
+
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * @author jshixiong
+ */
+@Data
+@ExcelIgnoreUnannotated
+public class DeviceVO {
+ private Long id;
+
+ @ExcelProperty(value = "设备ID")
+ private String deviceId;
+
+ @ExcelProperty(value = "设备名称")
+ private String name;
+
+ @ExcelProperty(value = "设备型号")
+ private String typeName;
+
+ private Long type;
+
+ private Long producerId;
+
+ @ExcelProperty(value = "生产厂商")
+ private String producerName;
+
+ private String producerSimpleName;
+
+ @JsonFormat(pattern = "yyyy-MM-dd HH:mm",timezone = "GMT+8")
+ private LocalDateTime addTime;
+}
diff --git a/web/src/main/java/com/imitate/web/vo/LocalManagerInitVO.java b/web/src/main/java/com/imitate/web/vo/LocalManagerInitVO.java
new file mode 100644
index 0000000..72ef89e
--- /dev/null
+++ b/web/src/main/java/com/imitate/web/vo/LocalManagerInitVO.java
@@ -0,0 +1,47 @@
+package com.imitate.web.vo;
+
+import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
+import com.alibaba.excel.annotation.ExcelProperty;
+import lombok.Data;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * 本地管理终端初始化资源类
+ * @author jshixiong
+ */
+@Data
+@ExcelIgnoreUnannotated
+public class LocalManagerInitVO {
+ @ExcelProperty(value = "配发管理—状态")
+ private String distributionStatus;
+
+ @ExcelProperty(value = "配发管理—新建调拨单—发往节点")
+ private String distributionNode;
+
+ @ExcelProperty(value = "密码长度")
+ private String keyLength;
+
+ @ExcelProperty(value = "推送节点")
+ private String keyNode;
+
+ private List distributionStatusList;
+
+ private List distributionNodeList;
+
+ private List keyLengthList;
+
+ private List keyNodeList;
+
+ public LocalManagerInitVO() {}
+
+ public LocalManagerInitVO(boolean isList) {
+ if (isList){
+ this.distributionStatusList = new ArrayList<>();
+ this.distributionNodeList = new ArrayList<>();
+ this.keyLengthList = new ArrayList<>();
+ this.keyNodeList = new ArrayList<>();
+ }
+ }
+}
diff --git a/web/src/main/resources/application.properties b/web/src/main/resources/application.properties
new file mode 100644
index 0000000..829ba82
--- /dev/null
+++ b/web/src/main/resources/application.properties
@@ -0,0 +1,62 @@
+server.port=8088
+server.servlet.context-path=/xgd
+server.max-http-header-size=8192
+server.compression.enabled=true
+server.compression.min-response-size=1024
+server.compression.mime-types=text/plain,text/css,text/xml,text/javascript,application/json,application/javascript,application/xml,application/xml+rss,application/x-javascript,application/x-httpd-php,image/jpeg,image/gif,image/png
+server.tomcat.uri-encoding=UTF-8
+
+
+
+spring.config.import=classpath:common.properties
+
+
+
+# mysql
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+spring.datasource.url=jdbc:mysql://testeducoder-public.mysql.polardb.rds.aliyuncs.com:3306/imitsys?useUnicode=true&characterEncoding=utf8&autoReconnect=true&failOverReadOnly=false
+spring.datasource.username=testeducoder
+spring.datasource.password=TEST@123
+spring.datasource.type=com.alibaba.druid.pool.DruidDataSource
+spring.datasource.initialSize=200
+spring.datasource.maxActive=400
+spring.datasource.minIdle=200
+spring.datasource.validationQuery=select 1
+spring.datasource.testOnBorrow=false
+spring.datasource.testOnReturn=false
+spring.datasource.testWhileIdle=true
+mybatis.type-aliases-package=com.imitate.web.persistence.beans
+mybatis.mapperLocations=classpath*:mybatis/*.xml
+mybatis.configuration.map-underscore-to-camel-case=true
+
+#xgd init
+imitate.init.path=/data/workspace/platform/eva/datacenter
+#imitate.init.path=C:\\xgd
+imitate.init.xml=xgdImitateInit.xml
+imitate.init.xlsx=xgdImitateInit.xlsx
+
+#mapper
+mapper.mappers=com.imitate.common.util.BaseMapper
+mapper.not-empty=false
+mapper.identity=MYSQL
+
+
+# pagehelper
+pagehelper.helper-dialect=mysql
+pagehelper.reasonable=true
+pagehelper.support-methods-arguments=true
+pagehelper.params=count=countSql
+
+
+#showSql
+logging.level.com.imitate.web.persistence.mapper=debug
+
+
+# redis
+spring.redis.host=127.0.0.1
+spring.redis.port=6379
+spring.redis.password=
+
+
+
+
diff --git a/web/src/main/resources/mybatis/CerificateMapper.xml b/web/src/main/resources/mybatis/CerificateMapper.xml
new file mode 100644
index 0000000..22f9d1d
--- /dev/null
+++ b/web/src/main/resources/mybatis/CerificateMapper.xml
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id,status,company,db_type,db_drive,db_ip,db_port,db_name,db_passwd,db_is_conn,target_ip,
+target_userdn,target_passwd,cert_url,cert_num,import_cert_file1,import_cert_file2,create_time,update_time
+
+
+
+
+
+
+
+
diff --git a/web/src/main/resources/mybatis/DataTerminalMapper.xml b/web/src/main/resources/mybatis/DataTerminalMapper.xml
new file mode 100644
index 0000000..b4c18fc
--- /dev/null
+++ b/web/src/main/resources/mybatis/DataTerminalMapper.xml
@@ -0,0 +1,65 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, name, type, number, producer_id, manager_num, physics_num, status, create_time, update_time
+
+
+
+
+
+
+
+
diff --git a/web/src/main/resources/mybatis/DeviceDistributionMapper.xml b/web/src/main/resources/mybatis/DeviceDistributionMapper.xml
new file mode 100644
index 0000000..eb84b8d
--- /dev/null
+++ b/web/src/main/resources/mybatis/DeviceDistributionMapper.xml
@@ -0,0 +1,85 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, type, status, number, basis, user_name, phone, send_node, begin_time, end_time, create_time, update_time
+
+
+
+
+
+
diff --git a/web/src/main/resources/mybatis/DeviceMapper.xml b/web/src/main/resources/mybatis/DeviceMapper.xml
new file mode 100644
index 0000000..22b203d
--- /dev/null
+++ b/web/src/main/resources/mybatis/DeviceMapper.xml
@@ -0,0 +1,138 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, device_id, name, type, producer_id,status, add_time
+
+
+
+
+
+
+
+
+
+
+
+ UPDATE
+ device
+ SET
+ distribution_id = 0
+ WHERE
+ distribution_id = #{distributionId}
+
+
diff --git a/web/src/main/resources/mybatis/DeviceTypeMapper.xml b/web/src/main/resources/mybatis/DeviceTypeMapper.xml
new file mode 100644
index 0000000..6f27c0d
--- /dev/null
+++ b/web/src/main/resources/mybatis/DeviceTypeMapper.xml
@@ -0,0 +1,51 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, name, type_number, pattern, secret_level, management_level, create_time, update_time
+
+
+
+
+
+
diff --git a/web/src/main/resources/mybatis/DeviceTypeProducerMapper.xml b/web/src/main/resources/mybatis/DeviceTypeProducerMapper.xml
new file mode 100644
index 0000000..1e6d970
--- /dev/null
+++ b/web/src/main/resources/mybatis/DeviceTypeProducerMapper.xml
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+ id, type_id, producer_id, create_time, update_time
+
+
+
+ DELETE
+ FROM
+ device_type_producer
+ WHERE
+ type_id = #{id}
+
+
diff --git a/web/src/main/resources/mybatis/ProducerMapper.xml b/web/src/main/resources/mybatis/ProducerMapper.xml
new file mode 100644
index 0000000..cdac4dd
--- /dev/null
+++ b/web/src/main/resources/mybatis/ProducerMapper.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
diff --git a/web/src/main/resources/mybatis/ResourceMapper.xml b/web/src/main/resources/mybatis/ResourceMapper.xml
new file mode 100644
index 0000000..8366a26
--- /dev/null
+++ b/web/src/main/resources/mybatis/ResourceMapper.xml
@@ -0,0 +1,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, status, db_user, db_passwd, db_server_ip, `type` ,data_name,node_name,device_no,support_unit,manager_node,
+file1,file2,file3,file4,create_time,update_time
+
+
+
+
+
+
+
+
diff --git a/web/src/main/resources/mybatis/SecretKeyMapper.xml b/web/src/main/resources/mybatis/SecretKeyMapper.xml
new file mode 100644
index 0000000..755f795
--- /dev/null
+++ b/web/src/main/resources/mybatis/SecretKeyMapper.xml
@@ -0,0 +1,88 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, type, length, count,algorithm
+
+
+
+
+
+ UPDATE
+ secret_key a
+ SET
+ a.count = a.count + #{count}
+ WHERE
+ a.type = #{type}
+ AND a.length = #{length}
+
+
+
+ UPDATE
+ secret_key a
+ SET
+ a.count = a.count + #{count}
+ WHERE
+ a.type = #{type}
+ AND a.algorithm = #{algorithm}
+
+
+
+
+
+ UPDATE
+ secret_key a
+ SET
+ a.count = a.count - #{count}
+ WHERE
+ a.type = #{type}
+
+ AND a.algorithm = #{algorithm}
+
+
+ AND a.length = #{length}
+
+ AND a.count >= #{count}
+
+
+
+ DELETE FROM secret_key
+
+
diff --git a/web/src/main/resources/mybatis/SysLogMapper.xml b/web/src/main/resources/mybatis/SysLogMapper.xml
new file mode 100644
index 0000000..cc6c550
--- /dev/null
+++ b/web/src/main/resources/mybatis/SysLogMapper.xml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ id, operation, method, params, time, ip, module_name, method_path, class_path, http_type, result, create_time, update_time
+
+
+
+
+
diff --git a/web/web.iml b/web/web.iml
new file mode 100644
index 0000000..6f25881
--- /dev/null
+++ b/web/web.iml
@@ -0,0 +1,179 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file