远程代码上传
parent
cc0cb860ec
commit
6ea5eac763
|
|
@ -12,18 +12,18 @@
|
|||
<ul>
|
||||
<li class="select-time">
|
||||
<label>TIME: </label>
|
||||
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginTime]"/>
|
||||
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="createTime"/>
|
||||
<span>-</span>
|
||||
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endTime]"/>
|
||||
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="updateTime"/>
|
||||
</li>
|
||||
<li>
|
||||
雷达位置:<input type="text" name="jobName" placeholder="雷达位置"/>
|
||||
雷达位置:<input type="text" name="radarLocation" placeholder="雷达位置"/>
|
||||
</li>
|
||||
<li>
|
||||
铁包号/车架号:<input type="text" name="jobName" placeholder="铁包号/车架号"/>
|
||||
铁包号/车架号:<input type="text" name="ladleNumber" placeholder="铁包号/车架号"/>
|
||||
</li>
|
||||
<li>
|
||||
标识器:<input type="text" name="jobName" placeholder="标识器"/>
|
||||
标识器:<input type="text" name="tagId" placeholder="标识器"/>
|
||||
</li>
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||
|
|
@ -37,20 +37,20 @@
|
|||
</form>
|
||||
</div>
|
||||
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="monitor:job:add">
|
||||
<i class="fa fa-plus"></i> 新增
|
||||
</a>
|
||||
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="monitor:job:edit">
|
||||
<i class="fa fa-edit"></i> 修改
|
||||
</a>
|
||||
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="monitor:job:remove">
|
||||
<i class="fa fa-remove"></i> 删除
|
||||
</a>
|
||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="monitor:job:export">
|
||||
<i class="fa fa-download"></i> 导出
|
||||
</a>
|
||||
</div>
|
||||
<!-- <div class="btn-group-sm" id="toolbar" role="group">-->
|
||||
<!-- <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="monitor:job:add">-->
|
||||
<!-- <i class="fa fa-plus"></i> 新增-->
|
||||
<!-- </a>-->
|
||||
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="monitor:job:edit">-->
|
||||
<!-- <i class="fa fa-edit"></i> 修改-->
|
||||
<!-- </a>-->
|
||||
<!-- <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="monitor:job:remove">-->
|
||||
<!-- <i class="fa fa-remove"></i> 删除-->
|
||||
<!-- </a>-->
|
||||
<!-- <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="monitor:job:export">-->
|
||||
<!-- <i class="fa fa-download"></i> 导出-->
|
||||
<!-- </a>-->
|
||||
<!-- </div>-->
|
||||
|
||||
<div class="col-sm-12 select-table table-striped">
|
||||
<table id="bootstrap-table"></table>
|
||||
|
|
@ -81,12 +81,12 @@
|
|||
checkbox: true
|
||||
},
|
||||
{
|
||||
field: 'createTime',
|
||||
field: 'updateTime',
|
||||
title: 'TIME',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field: 'jobId',
|
||||
field: 'ladleNumber',
|
||||
title: '包号/架号'
|
||||
},
|
||||
{
|
||||
|
|
@ -125,21 +125,7 @@
|
|||
field: 'queryFre',
|
||||
title: '实时频率',
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
formatter: function(value, row, index) {
|
||||
var actions = [];
|
||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:;" onclick="$.operate.edit(\'' + row.jobId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:;" onclick="$.operate.remove(\'' + row.jobId + '\')"><i class="fa fa-remove"></i>删除</a> ');
|
||||
var more = [];
|
||||
more.push("<a class='btn btn-default btn-xs " + statusFlag + "' href='javascript:void(0)' onclick='run(" + row.jobId + ")'><i class='fa fa-play-circle-o'></i> 执行一次</a> ");
|
||||
more.push("<a class='btn btn-default btn-xs " + detailFlag + "' href='javascript:void(0)' onclick='$.operate.detail(" + row.jobId + ")'><i class='fa fa-search'></i>任务详细</a> ");
|
||||
more.push("<a class='btn btn-default btn-xs " + detailFlag + "' href='javascript:void(0)' onclick='jobLog(" + row.jobId + ")'><i class='fa fa-list'></i>调度日志</a>");
|
||||
actions.push('<a class="btn btn-info btn-xs" role="button" data-container="body" data-placement="left" data-toggle="popover" data-html="true" data-trigger="hover" data-content="' + more.join('') + '"><i class="fa fa-chevron-circle-right"></i>更多操作</a>');
|
||||
return actions.join('');
|
||||
}
|
||||
}]
|
||||
]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
|
|
|
|||
|
|
@ -59,7 +59,6 @@
|
|||
$('#scroll-up').toTop(opt);
|
||||
}
|
||||
queryUserList();
|
||||
queryDeptTree();
|
||||
});
|
||||
|
||||
function queryUserList() {
|
||||
|
|
@ -83,7 +82,7 @@
|
|||
title: '工位'
|
||||
},
|
||||
{
|
||||
field: 'alarmValue',
|
||||
field: 'alarmValue1',
|
||||
title: '报警值',
|
||||
sortable: true
|
||||
},
|
||||
|
|
|
|||
|
|
@ -54,6 +54,10 @@ public class PrimaryRadarData extends BaseEntity
|
|||
* 天线号
|
||||
*/
|
||||
private Integer number;
|
||||
|
||||
private String radarLocation;
|
||||
|
||||
private String ladleNumber;
|
||||
/** 删除标志(0代表存在 2代表删除) */
|
||||
private String delFlag;
|
||||
|
||||
|
|
@ -140,6 +144,22 @@ public class PrimaryRadarData extends BaseEntity
|
|||
this.number = number;
|
||||
}
|
||||
|
||||
public String getRadarLocation() {
|
||||
return radarLocation;
|
||||
}
|
||||
|
||||
public void setRadarLocation(String radarLocation) {
|
||||
this.radarLocation = radarLocation;
|
||||
}
|
||||
|
||||
public String getLadleNumber() {
|
||||
return ladleNumber;
|
||||
}
|
||||
|
||||
public void setLadleNumber(String ladleNumber) {
|
||||
this.ladleNumber = ladleNumber;
|
||||
}
|
||||
|
||||
public String getDelFlag() {
|
||||
return delFlag;
|
||||
}
|
||||
|
|
@ -161,6 +181,8 @@ public class PrimaryRadarData extends BaseEntity
|
|||
.append("baseLine",getBaseLine())
|
||||
.append("queryFre",getQueryFre())
|
||||
.append("number",getNumber())
|
||||
.append("radarLocation",getRadarLocation())
|
||||
.append("ladleNumber",getLadleNumber())
|
||||
.append("delFlag", getDelFlag())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import org.apache.commons.lang3.builder.ToStringBuilder;
|
|||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 常温标识器配置对象 sys_identifier
|
||||
* 报警配置对象 sys_police
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
|
|
@ -21,7 +21,10 @@ public class SysPolice extends BaseEntity
|
|||
|
||||
private String station;
|
||||
|
||||
private String alarmValue;
|
||||
private String alarmValue1;
|
||||
private String alarmValue2;
|
||||
private String alarmValue3;
|
||||
private String alarmValue4;
|
||||
private String presetValue;
|
||||
private String type;
|
||||
private String status;
|
||||
|
|
@ -48,12 +51,36 @@ public class SysPolice extends BaseEntity
|
|||
this.station = station;
|
||||
}
|
||||
|
||||
public String getAlarmValue() {
|
||||
return alarmValue;
|
||||
public String getAlarmValue1() {
|
||||
return alarmValue1;
|
||||
}
|
||||
|
||||
public void setAlarmValue(String alarmValue) {
|
||||
this.alarmValue = alarmValue;
|
||||
public void setAlarmValue1(String alarmValue1) {
|
||||
this.alarmValue1 = alarmValue1;
|
||||
}
|
||||
|
||||
public String getAlarmValue2() {
|
||||
return alarmValue2;
|
||||
}
|
||||
|
||||
public void setAlarmValue2(String alarmValue2) {
|
||||
this.alarmValue2 = alarmValue2;
|
||||
}
|
||||
|
||||
public String getAlarmValue3() {
|
||||
return alarmValue3;
|
||||
}
|
||||
|
||||
public void setAlarmValue3(String alarmValue3) {
|
||||
this.alarmValue3 = alarmValue3;
|
||||
}
|
||||
|
||||
public String getAlarmValue4() {
|
||||
return alarmValue4;
|
||||
}
|
||||
|
||||
public void setAlarmValue4(String alarmValue4) {
|
||||
this.alarmValue4 = alarmValue4;
|
||||
}
|
||||
|
||||
public String getPresetValue() {
|
||||
|
|
@ -93,7 +120,10 @@ public class SysPolice extends BaseEntity
|
|||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("station", getStation())
|
||||
.append("alarmValue", getAlarmValue())
|
||||
.append("alarmValue1", getAlarmValue1())
|
||||
.append("alarmValue2", getAlarmValue2())
|
||||
.append("alarmValue3", getAlarmValue3())
|
||||
.append("alarmValue4", getAlarmValue4())
|
||||
.append("presetValue", getPresetValue())
|
||||
.append("type", getType())
|
||||
.append("status", getStatus())
|
||||
|
|
|
|||
|
|
@ -13,8 +13,6 @@ import com.serotonin.modbus4j.ip.IpParameters;
|
|||
import com.serotonin.modbus4j.locator.BaseLocator;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import java.util.Timer;
|
||||
import java.util.TimerTask;
|
||||
import java.util.concurrent.locks.ReadWriteLock;
|
||||
import java.util.concurrent.locks.ReentrantReadWriteLock;
|
||||
|
||||
|
|
@ -108,4 +106,11 @@ public class ModbusUtils {
|
|||
return DataType.FOUR_BYTE_INT_SIGNED;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 翻着我们的照片
|
||||
* 想念若隐若现
|
||||
* 去年的冬天
|
||||
* 我们笑得很甜
|
||||
*/
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,11 +13,11 @@ import java.util.List;
|
|||
public interface PrimaryRadarDataMapper
|
||||
{
|
||||
|
||||
int insertNormalIdentifier(NormalIdentifier normalIdentifier);
|
||||
int insertPrimaryRadarData(PrimaryRadarData primaryRadarData);
|
||||
|
||||
NormalIdentifier selectNormalIdentifierById(Long id);
|
||||
PrimaryRadarData selectPrimaryRadarDataById(Long id);
|
||||
|
||||
int updateNormalIdentifier(NormalIdentifier normalIdentifier);
|
||||
int updatePrimaryRadarData(PrimaryRadarData primaryRadarData);
|
||||
|
||||
List<PrimaryRadarData> selectPrimaryRadarDataList(PrimaryRadarData primaryRadarData);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,9 +14,9 @@ public interface PrimaryRadarDataService
|
|||
{
|
||||
public List<PrimaryRadarData> selectPrimaryRadarDataList(PrimaryRadarData primaryRadarData);
|
||||
|
||||
int insertNormalIdentifier(NormalIdentifier normalIdentifier);
|
||||
int insertPrimaryRadarData(PrimaryRadarData primaryRadarData);
|
||||
|
||||
NormalIdentifier selectIdentifierById(Long id);
|
||||
PrimaryRadarData selectPrimaryRadarDataById(Long id);
|
||||
|
||||
int updateUser(NormalIdentifier normalIdentifier);
|
||||
int updateUser(PrimaryRadarData primaryRadarData);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,19 +42,19 @@ public class PrimaryRadarDataServiceImpl implements PrimaryRadarDataService
|
|||
}
|
||||
|
||||
@Override
|
||||
public int insertNormalIdentifier(NormalIdentifier normalIdentifier) {
|
||||
int rows = primaryRadarDataMapper.insertNormalIdentifier(normalIdentifier);
|
||||
public int insertPrimaryRadarData(PrimaryRadarData primaryRadarData) {
|
||||
int rows = primaryRadarDataMapper.insertPrimaryRadarData(primaryRadarData);
|
||||
return rows;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int updateUser(NormalIdentifier normalIdentifier) {
|
||||
return primaryRadarDataMapper.updateNormalIdentifier(normalIdentifier);
|
||||
public int updateUser(PrimaryRadarData primaryRadarData) {
|
||||
return primaryRadarDataMapper.updatePrimaryRadarData(primaryRadarData);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NormalIdentifier selectIdentifierById(Long id) {
|
||||
public PrimaryRadarData selectPrimaryRadarDataById(Long id) {
|
||||
|
||||
return primaryRadarDataMapper.selectNormalIdentifierById(id);
|
||||
return primaryRadarDataMapper.selectPrimaryRadarDataById(id);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,6 +15,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<result property="baseLine" column="base_line" />
|
||||
<result property="queryFre" column="query_fre" />
|
||||
<result property="number" column="number" />
|
||||
<result property="radarLocation" column="radar_location" />
|
||||
<result property="ladleNumber" column="ladle_number" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
|
|
@ -24,68 +26,57 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
</resultMap>
|
||||
|
||||
<select id="selectPrimaryRadarDataList" resultMap="PrimaryRadarDataResult">
|
||||
select p.id,p.tag_id,p.value1,p.value2,p.value3,p.value4,p.value5,p.base_line,p.query_fre,p.number,p.create_by,p.create_time,p.update_by,p.update_time,p.remark,p.del_flag from sys_primary_radar_data p
|
||||
select p.id,p.tag_id,p.value1,p.value2,p.value3,p.value4,p.value5,p.base_line,p.query_fre,p.number,p.radar_location,p.ladle_number,p.create_by,p.create_time,p.update_by,p.update_time,p.remark,p.del_flag from sys_primary_radar_data p
|
||||
where p.del_flag = '0'
|
||||
<!-- <if test="normalNumber != null and normalNumber != ''">-->
|
||||
<!-- AND n.normal_number like concat('%',#{normalNumber}, '%')-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="normalId != null and normalId != ''">-->
|
||||
<!-- AND n.normal_id like concat('%',#{normalId}, '%') or-->
|
||||
<!-- n.normal_two like concat('%',#{normalId}, '%') or-->
|
||||
<!-- n.normal_three like concat('%',#{normalId}, '%') or-->
|
||||
<!-- n.normal_four like concat('%',#{normalId}, '%')-->
|
||||
<!-- </if>-->
|
||||
<if test="radarLocation != null and radarLocation != ''">
|
||||
AND p.radar_location like concat('%',#{radarLocation}, '%')
|
||||
</if>
|
||||
<if test="ladleNumber != null and ladleNumber != ''">
|
||||
AND p.ladle_number like concat('%',#{ladleNumber}, '%')
|
||||
</if>
|
||||
<if test="tagId != null and tagId != ''">
|
||||
AND p.tag_id like concat('%',#{tagId},'%')
|
||||
</if>
|
||||
<if test="createTime != null and updateTime != null">
|
||||
AND DATE_FORMAT(p.update_time,'%Y-%m-%d') between DATE_FORMAT(#{createTime},'%Y-%m-%d') and DATE_FORMAT(#{updateTime},'%Y-%m-%d')
|
||||
</if>
|
||||
order by i.id asc
|
||||
</select>
|
||||
|
||||
<insert id="insertPrimaryRadarData">
|
||||
<!-- <insert id="insertPrimaryRadarData">-->
|
||||
|
||||
insert into sys_normalIdentifier(
|
||||
<if test="id != null and id != 0">id,</if>
|
||||
<if test="value1 != null and value1 != ''">value1,</if>
|
||||
<if test="value2 != null and value2 != ''">value2,</if>
|
||||
<if test="value3 != null and value3 != ''">value3,</if>
|
||||
<if test="value4 != null and value4 != ''">value4,</if>
|
||||
<if test="value5 != null and value5 != ''">value5,</if>
|
||||
<if test="baseLine != null and baseLine != ''">base_line,</if>
|
||||
<if test="queryFre != null and queryFre != ''">query_fre,</if>
|
||||
<if test="number != null and number != ''">number,</if>
|
||||
<if test="createBy != null and createBy != ''">create_by,</if>
|
||||
<if test="remark != null and remark != ''">remark,</if>
|
||||
create_time
|
||||
)values(
|
||||
<if test="id != null and id != 0">#{id},</if>
|
||||
<if test="value1 != null and value1 != ''">#{value1},</if>
|
||||
<if test="value2 != null and value2 != ''">#{value2},</if>
|
||||
<if test="value3 != null and value3 != ''">#{value3},</if>
|
||||
<if test="value4 != null and value4 != ''">#{value4},</if>
|
||||
<if test="value5 != null and value5 != ''">#{value5},</if>
|
||||
<if test="baseLine != null and baseLine != ''">#{baseLine},</if>
|
||||
<if test="queryFre != null and queryFre != ''">#{queryFre},</if>
|
||||
<if test="number != null and number != ''">#{number},</if>
|
||||
<if test="createBy!= null and createBy!= ''">#{createBy},</if>
|
||||
<if test="remark != null and remark != ''">#{remark},</if>
|
||||
sysdate()
|
||||
)
|
||||
</insert>
|
||||
|
||||
<select id="selectPrimaryRadarDataById" resultMap="PrimaryRadarDataResult">
|
||||
select n.id,n.normal_id,n.normal_two,n.normal_three,n.normal_four,n.normal_number,n.create_by,n.create_time,n.update_by,n.update_time,n.remark,n.del_flag from sys_normalIdentifier n where n.id = #{id}
|
||||
</select>
|
||||
|
||||
<update id="updatePrimaryRadarData">
|
||||
update sys_normalIdentifier
|
||||
<set>
|
||||
<if test="normalId != null and normalId != ''"> normal_id = #{normalId},</if>
|
||||
<if test="normalTwo != null and normalTwo != ''"> normal_two = #{normalTwo},</if>
|
||||
<if test="normalThree != null and normalThree != ''"> normal_three = #{normalThree},</if>
|
||||
<if test="normalFour != null and normalFour != ''"> normal_four = #{normalFour},</if>
|
||||
<if test="normalNumber != null and normalNumber != ''"> normal_number = #{normalNumber},</if>
|
||||
<if test="remark != null and remark != ''"> remark = #{remark},</if>
|
||||
update_time = sysdate()
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
<!-- insert into sys_normalIdentifier(-->
|
||||
<!-- <if test="id != null and id != 0">id,</if>-->
|
||||
<!-- <if test="value1 != null and value1 != ''">value1,</if>-->
|
||||
<!-- <if test="value2 != null and value2 != ''">value2,</if>-->
|
||||
<!-- <if test="value3 != null and value3 != ''">value3,</if>-->
|
||||
<!-- <if test="value4 != null and value4 != ''">value4,</if>-->
|
||||
<!-- <if test="value5 != null and value5 != ''">value5,</if>-->
|
||||
<!-- <if test="baseLine != null and baseLine != ''">base_line,</if>-->
|
||||
<!-- <if test="queryFre != null and queryFre != ''">query_fre,</if>-->
|
||||
<!-- <if test="number != null and number != ''">number,</if>-->
|
||||
<!-- <if test="radarLocation != null and radarLocation != ''">radar_location,</if>-->
|
||||
<!-- <if test="ladleNumber != null and ladleNumber != ''">ladle_number,</if>-->
|
||||
<!-- <if test="createBy != null and createBy != ''">create_by,</if>-->
|
||||
<!-- <if test="remark != null and remark != ''">remark,</if>-->
|
||||
<!-- create_time-->
|
||||
<!-- )values(-->
|
||||
<!-- <if test="id != null and id != 0">#{id},</if>-->
|
||||
<!-- <if test="value1 != null and value1 != ''">#{value1},</if>-->
|
||||
<!-- <if test="value2 != null and value2 != ''">#{value2},</if>-->
|
||||
<!-- <if test="value3 != null and value3 != ''">#{value3},</if>-->
|
||||
<!-- <if test="value4 != null and value4 != ''">#{value4},</if>-->
|
||||
<!-- <if test="value5 != null and value5 != ''">#{value5},</if>-->
|
||||
<!-- <if test="baseLine != null and baseLine != ''">#{baseLine},</if>-->
|
||||
<!-- <if test="queryFre != null and queryFre != ''">#{queryFre},</if>-->
|
||||
<!-- <if test="number != null and number != ''">#{number},</if>-->
|
||||
<!-- <if test="radarLocation != null and radarLocation != ''">#{radarLocation},</if>-->
|
||||
<!-- <if test="ladleNumber != null and ladleNumber != ''">#{ladleNumber},</if>-->
|
||||
<!-- <if test="createBy!= null and createBy!= ''">#{createBy},</if>-->
|
||||
<!-- <if test="remark != null and remark != ''">#{remark},</if>-->
|
||||
<!-- sysdate()-->
|
||||
<!-- )-->
|
||||
<!-- </insert>-->
|
||||
|
||||
|
||||
</mapper>
|
||||
|
|
@ -7,7 +7,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<resultMap type="com.ruoyi.common.core.domain.entity.SysPolice" id="SysPoliceResult">
|
||||
<id property="id" column="id" />
|
||||
<result property="station" column="station" />
|
||||
<result property="alarmValue" column="alarm_value" />
|
||||
<result property="alarmValue1" column="alarm_value1" />
|
||||
<result property="alarmValue2" column="alarm_value2" />
|
||||
<result property="alarmValue3" column="alarm_value3" />
|
||||
<result property="alarmValue4" column="alarm_value4" />
|
||||
<result property="presetValue" column="preset_value" />
|
||||
<result property="type" column="type" />
|
||||
<result property="status" column="status" />
|
||||
|
|
@ -20,7 +23,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
</resultMap>
|
||||
|
||||
<select id="selectSysPoliceList" resultMap="SysPoliceResult">
|
||||
select p.id,p.station,p.alarm_value , p.preset_value,p.type,p.create_by,p.create_time,p.update_by,p.update_time,p.remark,p.del_flag from sys_police p
|
||||
select p.id,p.station,p.alarm_value1 ,p.alarm_value2,p.alarm_value3,p.alarm_value4, p.preset_value,p.type,p.create_by,p.create_time,p.update_by,p.update_time,p.remark,p.del_flag from sys_police p
|
||||
where p.del_flag = '0'
|
||||
</select>
|
||||
|
||||
|
|
@ -29,7 +32,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
insert into sys_police(
|
||||
<if test="id != null and id != 0">id,</if>
|
||||
<if test="station != null and station != ''">station,</if>
|
||||
<if test="alarmValue != null and alarmValue != ''">alarm_value,</if>
|
||||
<if test="alarmValue1 != null and alarmValue1 != ''">alarm_value1,</if>
|
||||
<if test="alarmValue2 != null and alarmValue2 != ''">alarm_value2,</if>
|
||||
<if test="alarmValue3 != null and alarmValue3 != ''">alarm_value3,</if>
|
||||
<if test="alarmValue4 != null and alarmValue4 != ''">alarm_value4,</if>
|
||||
<if test="presetValue != null and presetValue != ''">preset_value,</if>
|
||||
<if test="type != null and type != ''">type,</if>
|
||||
<if test="createBy != null and createBy != ''">create_by,</if>
|
||||
|
|
@ -38,7 +44,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
)values(
|
||||
<if test="id != null and id != 0">#{id},</if>
|
||||
<if test="station != null and station != ''">#{station},</if>
|
||||
<if test="alarmValue != null and alarmValue != ''">#{alarmValue},</if>
|
||||
<if test="alarmValue1 != null and alarmValue1 != ''">#{alarmValue1},</if>
|
||||
<if test="alarmValue2 != null and alarmValue2 != ''">#{alarmValue2},</if>
|
||||
<if test="alarmValue3 != null and alarmValue3 != ''">#{alarmValue3},</if>
|
||||
<if test="alarmValue4 != null and alarmValue4 != ''">#{alarmValue4},</if>
|
||||
<if test="presetValue != null and presetValue != ''">#{presetValue},</if>
|
||||
<if test="type != null and type != ''">#{type},</if>
|
||||
<if test="createBy != null and createBy != ''">#{createBy},#,</if>
|
||||
|
|
@ -56,7 +65,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
update sys_police
|
||||
<set>
|
||||
<if test="station != null and station != ''"> station = #{station},</if>
|
||||
<if test="alarmValue != null and alarmValue != ''"> alarm_value = #{alarmValue},</if>
|
||||
<if test="alarmValue1 != null and alarmValue1 != ''"> alarm_value1 = #{alarmValue1},</if>
|
||||
<if test="alarmValue2 != null and alarmValue2 != ''"> alarm_value2 = #{alarmValue2},</if>
|
||||
<if test="alarmValue3 != null and alarmValue3 != ''"> alarm_value3 = #{alarmValue3},</if>
|
||||
<if test="alarmValue4 != null and alarmValue4 != ''"> alarm_value4 = #{alarmValue4},</if>
|
||||
<if test="presetValue != null and presetValue != ''"> preset_value = #{presetValue},</if>
|
||||
<if test="type != null and type != ''"> `type` = #{type},</if>
|
||||
<if test="remark != null and remark != ''"> remark = #{remark},</if>
|
||||
|
|
|
|||
Loading…
Reference in New Issue