parent
8373805007
commit
28a6bbf954
@ -0,0 +1,104 @@
|
|||||||
|
package com.ruoyi.tcZz.controller;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.tcZz.domain.TcWljg;
|
||||||
|
import com.ruoyi.tcZz.service.ITcWljgService;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 网络监测Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2023-10-12
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/tcZz/networkSecurity/cybersecurity")
|
||||||
|
public class TcWljgController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private ITcWljgService tcWljgService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询网络监测列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('tcZz/networkSecurity:cybersecurity:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<TcWljg> list = tcWljgService.selectTcWljgList(tcWljg);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出网络监测列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('tcZz/networkSecurity:cybersecurity:export')")
|
||||||
|
@Log(title = "网络监测", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response, TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
List<TcWljg> list = tcWljgService.selectTcWljgList(tcWljg);
|
||||||
|
ExcelUtil<TcWljg> util = new ExcelUtil<TcWljg>(TcWljg.class);
|
||||||
|
util.exportExcel(response, list, "网络监测数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取网络监测详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('tcZz/networkSecurity:cybersecurity:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return success(tcWljgService.selectTcWljgById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增网络监测
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('tcZz/networkSecurity:cybersecurity:add')")
|
||||||
|
@Log(title = "网络监测", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
return toAjax(tcWljgService.insertTcWljg(tcWljg));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改网络监测
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('tcZz/networkSecurity:cybersecurity:edit')")
|
||||||
|
@Log(title = "网络监测", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
return toAjax(tcWljgService.updateTcWljg(tcWljg));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除网络监测
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('tcZz/networkSecurity:cybersecurity:remove')")
|
||||||
|
@Log(title = "网络监测", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable Long[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(tcWljgService.deleteTcWljgByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,220 @@
|
|||||||
|
package com.ruoyi.tcZz.domain;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 网络监测对象 tc_wljg
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2023-10-12
|
||||||
|
*/
|
||||||
|
public class TcWljg extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** $column.columnComment */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 区域id */
|
||||||
|
@Excel(name = "区域id")
|
||||||
|
private String areaId;
|
||||||
|
|
||||||
|
/** 1.启用 2.禁用 */
|
||||||
|
@Excel(name = "1.启用 2.禁用")
|
||||||
|
private Long isStatus;
|
||||||
|
|
||||||
|
/** 攻击发起时间 */
|
||||||
|
private Date startTime;
|
||||||
|
|
||||||
|
/** 攻击源IP */
|
||||||
|
@Excel(name = "攻击源IP")
|
||||||
|
private String attackyIp;
|
||||||
|
|
||||||
|
/** 攻击类型 */
|
||||||
|
@Excel(name = "攻击类型")
|
||||||
|
private String attackType;
|
||||||
|
|
||||||
|
/** 攻击源IP区域 */
|
||||||
|
private String attackIpArea;
|
||||||
|
|
||||||
|
/** 受攻击目标类型 */
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/** 受攻击IP */
|
||||||
|
@Excel(name = "受攻击IP")
|
||||||
|
private String sAttackIp;
|
||||||
|
|
||||||
|
/** 受攻击IP区域 */
|
||||||
|
private String sAttackIpArea;
|
||||||
|
|
||||||
|
/** 网站安全等级 */
|
||||||
|
@Excel(name = "网站安全等级")
|
||||||
|
private String netLevel;
|
||||||
|
|
||||||
|
/** 所属单位 */
|
||||||
|
private String affUnit;
|
||||||
|
|
||||||
|
/** 联系电话 */
|
||||||
|
private String linkTel;
|
||||||
|
|
||||||
|
/** 联系人 */
|
||||||
|
@Excel(name = "联系人")
|
||||||
|
private String linkMan;
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setAreaId(String areaId)
|
||||||
|
{
|
||||||
|
this.areaId = areaId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAreaId()
|
||||||
|
{
|
||||||
|
return areaId;
|
||||||
|
}
|
||||||
|
public void setIsStatus(Long isStatus)
|
||||||
|
{
|
||||||
|
this.isStatus = isStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getIsStatus()
|
||||||
|
{
|
||||||
|
return isStatus;
|
||||||
|
}
|
||||||
|
public void setStartTime(Date startTime)
|
||||||
|
{
|
||||||
|
this.startTime = startTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getStartTime()
|
||||||
|
{
|
||||||
|
return startTime;
|
||||||
|
}
|
||||||
|
public void setAttackyIp(String attackyIp)
|
||||||
|
{
|
||||||
|
this.attackyIp = attackyIp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAttackyIp()
|
||||||
|
{
|
||||||
|
return attackyIp;
|
||||||
|
}
|
||||||
|
public void setAttackType(String attackType)
|
||||||
|
{
|
||||||
|
this.attackType = attackType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAttackType()
|
||||||
|
{
|
||||||
|
return attackType;
|
||||||
|
}
|
||||||
|
public void setAttackIpArea(String attackIpArea)
|
||||||
|
{
|
||||||
|
this.attackIpArea = attackIpArea;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAttackIpArea()
|
||||||
|
{
|
||||||
|
return attackIpArea;
|
||||||
|
}
|
||||||
|
public void setType(String type)
|
||||||
|
{
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getType()
|
||||||
|
{
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
public void setsAttackIp(String sAttackIp)
|
||||||
|
{
|
||||||
|
this.sAttackIp = sAttackIp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getsAttackIp()
|
||||||
|
{
|
||||||
|
return sAttackIp;
|
||||||
|
}
|
||||||
|
public void setsAttackIpArea(String sAttackIpArea)
|
||||||
|
{
|
||||||
|
this.sAttackIpArea = sAttackIpArea;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getsAttackIpArea()
|
||||||
|
{
|
||||||
|
return sAttackIpArea;
|
||||||
|
}
|
||||||
|
public void setNetLevel(String netLevel)
|
||||||
|
{
|
||||||
|
this.netLevel = netLevel;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNetLevel()
|
||||||
|
{
|
||||||
|
return netLevel;
|
||||||
|
}
|
||||||
|
public void setAffUnit(String affUnit)
|
||||||
|
{
|
||||||
|
this.affUnit = affUnit;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAffUnit()
|
||||||
|
{
|
||||||
|
return affUnit;
|
||||||
|
}
|
||||||
|
public void setLinkTel(String linkTel)
|
||||||
|
{
|
||||||
|
this.linkTel = linkTel;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLinkTel()
|
||||||
|
{
|
||||||
|
return linkTel;
|
||||||
|
}
|
||||||
|
public void setLinkMan(String linkMan)
|
||||||
|
{
|
||||||
|
this.linkMan = linkMan;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLinkMan()
|
||||||
|
{
|
||||||
|
return linkMan;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("areaId", getAreaId())
|
||||||
|
.append("isStatus", getIsStatus())
|
||||||
|
.append("startTime", getStartTime())
|
||||||
|
.append("attackyIp", getAttackyIp())
|
||||||
|
.append("attackType", getAttackType())
|
||||||
|
.append("attackIpArea", getAttackIpArea())
|
||||||
|
.append("type", getType())
|
||||||
|
.append("sAttackIp", getsAttackIp())
|
||||||
|
.append("sAttackIpArea", getsAttackIpArea())
|
||||||
|
.append("netLevel", getNetLevel())
|
||||||
|
.append("affUnit", getAffUnit())
|
||||||
|
.append("linkTel", getLinkTel())
|
||||||
|
.append("linkMan", getLinkMan())
|
||||||
|
.append("createBy", getCreateBy())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateBy", getUpdateBy())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.append("remark", getRemark())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,61 @@
|
|||||||
|
package com.ruoyi.tcZz.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.tcZz.domain.TcWljg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 网络监测Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2023-10-12
|
||||||
|
*/
|
||||||
|
public interface TcWljgMapper
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询网络监测
|
||||||
|
*
|
||||||
|
* @param id 网络监测主键
|
||||||
|
* @return 网络监测
|
||||||
|
*/
|
||||||
|
public TcWljg selectTcWljgById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询网络监测列表
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 网络监测集合
|
||||||
|
*/
|
||||||
|
public List<TcWljg> selectTcWljgList(TcWljg tcWljg);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增网络监测
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertTcWljg(TcWljg tcWljg);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改网络监测
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateTcWljg(TcWljg tcWljg);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除网络监测
|
||||||
|
*
|
||||||
|
* @param id 网络监测主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteTcWljgById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除网络监测
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteTcWljgByIds(Long[] ids);
|
||||||
|
}
|
@ -0,0 +1,61 @@
|
|||||||
|
package com.ruoyi.tcZz.service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.tcZz.domain.TcWljg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 网络监测Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2023-10-12
|
||||||
|
*/
|
||||||
|
public interface ITcWljgService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询网络监测
|
||||||
|
*
|
||||||
|
* @param id 网络监测主键
|
||||||
|
* @return 网络监测
|
||||||
|
*/
|
||||||
|
public TcWljg selectTcWljgById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询网络监测列表
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 网络监测集合
|
||||||
|
*/
|
||||||
|
public List<TcWljg> selectTcWljgList(TcWljg tcWljg);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增网络监测
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertTcWljg(TcWljg tcWljg);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改网络监测
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateTcWljg(TcWljg tcWljg);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除网络监测
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的网络监测主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteTcWljgByIds(Long[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除网络监测信息
|
||||||
|
*
|
||||||
|
* @param id 网络监测主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteTcWljgById(Long id);
|
||||||
|
}
|
@ -0,0 +1,96 @@
|
|||||||
|
package com.ruoyi.tcZz.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.ruoyi.tcZz.mapper.TcWljgMapper;
|
||||||
|
import com.ruoyi.tcZz.domain.TcWljg;
|
||||||
|
import com.ruoyi.tcZz.service.ITcWljgService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 网络监测Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2023-10-12
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class TcWljgServiceImpl implements ITcWljgService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private TcWljgMapper tcWljgMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询网络监测
|
||||||
|
*
|
||||||
|
* @param id 网络监测主键
|
||||||
|
* @return 网络监测
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public TcWljg selectTcWljgById(Long id)
|
||||||
|
{
|
||||||
|
return tcWljgMapper.selectTcWljgById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询网络监测列表
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 网络监测
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<TcWljg> selectTcWljgList(TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
return tcWljgMapper.selectTcWljgList(tcWljg);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增网络监测
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertTcWljg(TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
tcWljg.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return tcWljgMapper.insertTcWljg(tcWljg);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改网络监测
|
||||||
|
*
|
||||||
|
* @param tcWljg 网络监测
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateTcWljg(TcWljg tcWljg)
|
||||||
|
{
|
||||||
|
tcWljg.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return tcWljgMapper.updateTcWljg(tcWljg);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除网络监测
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的网络监测主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteTcWljgByIds(Long[] ids)
|
||||||
|
{
|
||||||
|
return tcWljgMapper.deleteTcWljgByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除网络监测信息
|
||||||
|
*
|
||||||
|
* @param id 网络监测主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteTcWljgById(Long id)
|
||||||
|
{
|
||||||
|
return tcWljgMapper.deleteTcWljgById(id);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,104 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.ruoyi.tcZz.mapper.TcSjlyMapper">
|
||||||
|
|
||||||
|
<resultMap type="TcSjly" id="TcSjlyResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="areaId" column="area_id" />
|
||||||
|
<result property="type" column="type" />
|
||||||
|
<result property="isStatus" column="isStatus" />
|
||||||
|
<result property="zcName" column="zc_name" />
|
||||||
|
<result property="affUnit" column="aff_unit" />
|
||||||
|
<result property="sysyemIp" column="sysyem_ip" />
|
||||||
|
<result property="os" column="os" />
|
||||||
|
<result property="versions" column="versions" />
|
||||||
|
<result property="createBy" column="create_by" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateBy" column="update_by" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectTcSjlyVo">
|
||||||
|
select id, area_id, type, isStatus, zc_name, aff_unit, sysyem_ip, os, versions, create_by, create_time, update_by, update_time, remark from tc_sjly
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectTcSjlyList" parameterType="TcSjly" resultMap="TcSjlyResult">
|
||||||
|
<include refid="selectTcSjlyVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="areaId != null and areaId != ''"> and area_id = #{areaId}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectTcSjlyById" parameterType="Long" resultMap="TcSjlyResult">
|
||||||
|
<include refid="selectTcSjlyVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertTcSjly" parameterType="TcSjly" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into tc_sjly
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="areaId != null">area_id,</if>
|
||||||
|
<if test="type != null">type,</if>
|
||||||
|
<if test="isStatus != null">isStatus,</if>
|
||||||
|
<if test="zcName != null">zc_name,</if>
|
||||||
|
<if test="affUnit != null">aff_unit,</if>
|
||||||
|
<if test="sysyemIp != null">sysyem_ip,</if>
|
||||||
|
<if test="os != null">os,</if>
|
||||||
|
<if test="versions != null">versions,</if>
|
||||||
|
<if test="createBy != null">create_by,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateBy != null">update_by,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="areaId != null">#{areaId},</if>
|
||||||
|
<if test="type != null">#{type},</if>
|
||||||
|
<if test="isStatus != null">#{isStatus},</if>
|
||||||
|
<if test="zcName != null">#{zcName},</if>
|
||||||
|
<if test="affUnit != null">#{affUnit},</if>
|
||||||
|
<if test="sysyemIp != null">#{sysyemIp},</if>
|
||||||
|
<if test="os != null">#{os},</if>
|
||||||
|
<if test="versions != null">#{versions},</if>
|
||||||
|
<if test="createBy != null">#{createBy},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateBy != null">#{updateBy},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateTcSjly" parameterType="TcSjly">
|
||||||
|
update tc_sjly
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="areaId != null">area_id = #{areaId},</if>
|
||||||
|
<if test="type != null">type = #{type},</if>
|
||||||
|
<if test="isStatus != null">isStatus = #{isStatus},</if>
|
||||||
|
<if test="zcName != null">zc_name = #{zcName},</if>
|
||||||
|
<if test="affUnit != null">aff_unit = #{affUnit},</if>
|
||||||
|
<if test="sysyemIp != null">sysyem_ip = #{sysyemIp},</if>
|
||||||
|
<if test="os != null">os = #{os},</if>
|
||||||
|
<if test="versions != null">versions = #{versions},</if>
|
||||||
|
<if test="createBy != null">create_by = #{createBy},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteTcSjlyById" parameterType="Long">
|
||||||
|
delete from tc_sjly where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteTcSjlyByIds" parameterType="String">
|
||||||
|
delete from tc_sjly where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
@ -0,0 +1,125 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.ruoyi.tcZz.mapper.TcWljgMapper">
|
||||||
|
|
||||||
|
<resultMap type="TcWljg" id="TcWljgResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="areaId" column="area_id" />
|
||||||
|
<result property="isStatus" column="isStatus" />
|
||||||
|
<result property="startTime" column="start_time" />
|
||||||
|
<result property="attackyIp" column="attacky_ip" />
|
||||||
|
<result property="attackType" column="attack_type" />
|
||||||
|
<result property="attackIpArea" column="attack_ip_area" />
|
||||||
|
<result property="type" column="type" />
|
||||||
|
<result property="sAttackIp" column="s_attack_ip" />
|
||||||
|
<result property="sAttackIpArea" column="s_attack_ip_area" />
|
||||||
|
<result property="netLevel" column="net_level" />
|
||||||
|
<result property="affUnit" column="aff_unit" />
|
||||||
|
<result property="linkTel" column="link_tel" />
|
||||||
|
<result property="linkMan" column="link_man" />
|
||||||
|
<result property="createBy" column="create_by" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateBy" column="update_by" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectTcWljgVo">
|
||||||
|
select id, area_id, isStatus, start_time, attacky_ip, attack_type, attack_ip_area, type, s_attack_ip, s_attack_ip_area, net_level, aff_unit, link_tel, link_man, create_by, create_time, update_by, update_time, remark from tc_wljg
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectTcWljgList" parameterType="TcWljg" resultMap="TcWljgResult">
|
||||||
|
<include refid="selectTcWljgVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="areaId != null and areaId != ''"> and area_id = #{areaId}</if>
|
||||||
|
<if test="isStatus != null "> and isStatus = #{isStatus}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectTcWljgById" parameterType="Long" resultMap="TcWljgResult">
|
||||||
|
<include refid="selectTcWljgVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertTcWljg" parameterType="TcWljg" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into tc_wljg
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="areaId != null">area_id,</if>
|
||||||
|
<if test="isStatus != null">isStatus,</if>
|
||||||
|
<if test="startTime != null">start_time,</if>
|
||||||
|
<if test="attackyIp != null">attacky_ip,</if>
|
||||||
|
<if test="attackType != null">attack_type,</if>
|
||||||
|
<if test="attackIpArea != null">attack_ip_area,</if>
|
||||||
|
<if test="type != null">type,</if>
|
||||||
|
<if test="sAttackIp != null">s_attack_ip,</if>
|
||||||
|
<if test="sAttackIpArea != null">s_attack_ip_area,</if>
|
||||||
|
<if test="netLevel != null">net_level,</if>
|
||||||
|
<if test="affUnit != null">aff_unit,</if>
|
||||||
|
<if test="linkTel != null">link_tel,</if>
|
||||||
|
<if test="linkMan != null">link_man,</if>
|
||||||
|
<if test="createBy != null">create_by,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateBy != null">update_by,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="areaId != null">#{areaId},</if>
|
||||||
|
<if test="isStatus != null">#{isStatus},</if>
|
||||||
|
<if test="startTime != null">#{startTime},</if>
|
||||||
|
<if test="attackyIp != null">#{attackyIp},</if>
|
||||||
|
<if test="attackType != null">#{attackType},</if>
|
||||||
|
<if test="attackIpArea != null">#{attackIpArea},</if>
|
||||||
|
<if test="type != null">#{type},</if>
|
||||||
|
<if test="sAttackIp != null">#{sAttackIp},</if>
|
||||||
|
<if test="sAttackIpArea != null">#{sAttackIpArea},</if>
|
||||||
|
<if test="netLevel != null">#{netLevel},</if>
|
||||||
|
<if test="affUnit != null">#{affUnit},</if>
|
||||||
|
<if test="linkTel != null">#{linkTel},</if>
|
||||||
|
<if test="linkMan != null">#{linkMan},</if>
|
||||||
|
<if test="createBy != null">#{createBy},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateBy != null">#{updateBy},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateTcWljg" parameterType="TcWljg">
|
||||||
|
update tc_wljg
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="areaId != null">area_id = #{areaId},</if>
|
||||||
|
<if test="isStatus != null">isStatus = #{isStatus},</if>
|
||||||
|
<if test="startTime != null">start_time = #{startTime},</if>
|
||||||
|
<if test="attackyIp != null">attacky_ip = #{attackyIp},</if>
|
||||||
|
<if test="attackType != null">attack_type = #{attackType},</if>
|
||||||
|
<if test="attackIpArea != null">attack_ip_area = #{attackIpArea},</if>
|
||||||
|
<if test="type != null">type = #{type},</if>
|
||||||
|
<if test="sAttackIp != null">s_attack_ip = #{sAttackIp},</if>
|
||||||
|
<if test="sAttackIpArea != null">s_attack_ip_area = #{sAttackIpArea},</if>
|
||||||
|
<if test="netLevel != null">net_level = #{netLevel},</if>
|
||||||
|
<if test="affUnit != null">aff_unit = #{affUnit},</if>
|
||||||
|
<if test="linkTel != null">link_tel = #{linkTel},</if>
|
||||||
|
<if test="linkMan != null">link_man = #{linkMan},</if>
|
||||||
|
<if test="createBy != null">create_by = #{createBy},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteTcWljgById" parameterType="Long">
|
||||||
|
delete from tc_wljg where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteTcWljgByIds" parameterType="String">
|
||||||
|
delete from tc_wljg where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
Loading…
Reference in new issue