add - 尖峰平谷信息

master
wenjy 3 years ago
parent 039e21f168
commit cc8078f318

@ -0,0 +1,137 @@
package com.ruoyi.web.controller.ems;
import java.util.Date;
import java.util.List;
import com.ruoyi.common.utils.ShiroUtils;
import com.ruoyi.web.controller.tool.UUIDTool;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.system.domain.BaseJfpgInfo;
import com.ruoyi.system.service.IBaseJfpgInfoService;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.common.core.page.TableDataInfo;
/**
* Controller
*
* @author WenJY
* @date 2021-11-30
*/
@Controller
@RequestMapping("/ems/JfpgInfo")
public class BaseJfpgInfoController extends BaseController
{
private String prefix = "ems/JfpgInfo";
@Autowired
private IBaseJfpgInfoService baseJfpgInfoService;
@RequiresPermissions("ems:JfpgInfo:view")
@GetMapping()
public String JfpgInfo()
{
return prefix + "/JfpgInfo";
}
/**
*
*/
@RequiresPermissions("ems:JfpgInfo:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(BaseJfpgInfo baseJfpgInfo)
{
startPage();
List<BaseJfpgInfo> list = baseJfpgInfoService.selectBaseJfpgInfoList(baseJfpgInfo);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("ems:JfpgInfo:export")
@Log(title = "尖峰平谷信息", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(BaseJfpgInfo baseJfpgInfo)
{
List<BaseJfpgInfo> list = baseJfpgInfoService.selectBaseJfpgInfoList(baseJfpgInfo);
ExcelUtil<BaseJfpgInfo> util = new ExcelUtil<BaseJfpgInfo>(BaseJfpgInfo.class);
return util.exportExcel(list, "尖峰平谷信息数据");
}
/**
*
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("ems:JfpgInfo:add")
@Log(title = "尖峰平谷信息", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(BaseJfpgInfo baseJfpgInfo)
{
baseJfpgInfo.setUuid(UUIDTool.generate());
baseJfpgInfo.setCreatedBy(ShiroUtils.getLoginName());
baseJfpgInfo.setCreatedTime(new Date());
return toAjax(baseJfpgInfoService.insertBaseJfpgInfo(baseJfpgInfo));
}
/**
*
*/
@GetMapping("/edit/{uuid}")
public String edit(@PathVariable("uuid") String uuid, ModelMap mmap)
{
BaseJfpgInfo baseJfpgInfo = baseJfpgInfoService.selectBaseJfpgInfoByUuid(uuid);
mmap.put("baseJfpgInfo", baseJfpgInfo);
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("ems:JfpgInfo:edit")
@Log(title = "尖峰平谷信息", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(BaseJfpgInfo baseJfpgInfo)
{
baseJfpgInfo.setUpdatedBy(ShiroUtils.getLoginName());
baseJfpgInfo.setUpdatedTime(new Date());
return toAjax(baseJfpgInfoService.updateBaseJfpgInfo(baseJfpgInfo));
}
/**
*
*/
@RequiresPermissions("ems:JfpgInfo:remove")
@Log(title = "尖峰平谷信息", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(baseJfpgInfoService.deleteBaseJfpgInfoByUuids(ids));
}
}

@ -0,0 +1,141 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('尖峰平谷信息列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>时段名称:</label>
<input type="text" name="timeframeName"/>
</li>
<li>
<label>是否启用:</label>
<select name="deleteFlag" th:with="type=${@dict.getType('delete_flag')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li class="select-time">
<label>创建时间:</label>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginCreatedTime]"/>
<span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endCreatedTime]"/>
</li>
<li class="select-time">
<label>更新时间:</label>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginUpdatedTime]"/>
<span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endUpdatedTime]"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="ems:JfpgInfo:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="ems:JfpgInfo:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="ems:JfpgInfo:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="ems:JfpgInfo:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('ems:JfpgInfo:edit')}]];
var removeFlag = [[${@permission.hasPermi('ems:JfpgInfo:remove')}]];
var deleteFlagDatas = [[${@dict.getType('delete_flag')}]];
var prefix = ctx + "ems/JfpgInfo";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "尖峰平谷信息",
columns: [{
checkbox: true
},
{
field: 'uuid',
title: 'UUID',
visible: false
},
{
field: 'timeframeName',
title: '时段名称'
},
{
field: 'timeframeBegin',
title: '时段开始'
},
{
field: 'timeframeEnd',
title: '时段结束'
},
{
field: 'timeframePrice',
title: '时段单价'
},
{
field: 'deleteFlag',
title: '是否启用',
formatter: function(value, row, index) {
return $.table.selectDictLabel(deleteFlagDatas, value);
}
},
{
field: 'createdBy',
title: '创建人'
},
{
field: 'createdTime',
title: '创建时间'
},
{
field: 'updatedBy',
title: '更新人'
},
{
field: 'updatedTime',
title: '更新时间'
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.uuid + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.uuid + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

@ -0,0 +1,101 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增尖峰平谷信息')" />
<th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-JfpgInfo-add">
<div class="form-group">
<label class="col-sm-3 control-label">时段名称:</label>
<div class="col-sm-8">
<input name="timeframeName" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">时段开始:</label>
<div class="col-sm-8">
<input name="timeframeBegin" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">时段结束:</label>
<div class="col-sm-8">
<input name="timeframeEnd" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">时段单价:</label>
<div class="col-sm-8">
<input name="timeframePrice" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">是否启用:</label>
<div class="col-sm-8">
<select name="deleteFlag" class="form-control m-b" th:with="type=${@dict.getType('delete_flag')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<!--<div class="form-group">
<label class="col-sm-3 control-label">创建人:</label>
<div class="col-sm-8">
<input name="createdBy" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">创建时间:</label>
<div class="col-sm-8">
<div class="input-group date">
<input name="createdTime" class="form-control" placeholder="yyyy-MM-dd" type="text">
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">更新人:</label>
<div class="col-sm-8">
<input name="updatedBy" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">更新时间:</label>
<div class="col-sm-8">
<div class="input-group date">
<input name="updatedTime" class="form-control" placeholder="yyyy-MM-dd" type="text">
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
</div>
</div>
</div>-->
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "ems/JfpgInfo"
$("#form-JfpgInfo-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-JfpgInfo-add').serialize());
}
}
$("input[name='createdTime']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
$("input[name='updatedTime']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
</script>
</body>
</html>

@ -0,0 +1,102 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改尖峰平谷信息')" />
<th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-JfpgInfo-edit" th:object="${baseJfpgInfo}">
<input name="uuid" th:field="*{uuid}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">时段名称:</label>
<div class="col-sm-8">
<input name="timeframeName" th:field="*{timeframeName}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">时段开始:</label>
<div class="col-sm-8">
<input name="timeframeBegin" th:field="*{timeframeBegin}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">时段结束:</label>
<div class="col-sm-8">
<input name="timeframeEnd" th:field="*{timeframeEnd}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">时段单价:</label>
<div class="col-sm-8">
<input name="timeframePrice" th:field="*{timeframePrice}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">是否启用:</label>
<div class="col-sm-8">
<select name="deleteFlag" class="form-control m-b" th:with="type=${@dict.getType('delete_flag')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{deleteFlag}"></option>
</select>
</div>
</div>
<!--<div class="form-group">
<label class="col-sm-3 control-label">创建人:</label>
<div class="col-sm-8">
<input name="createdBy" th:field="*{createdBy}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">创建时间:</label>
<div class="col-sm-8">
<div class="input-group date">
<input name="createdTime" th:value="${#dates.format(baseJfpgInfo.createdTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">更新人:</label>
<div class="col-sm-8">
<input name="updatedBy" th:field="*{updatedBy}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">更新时间:</label>
<div class="col-sm-8">
<div class="input-group date">
<input name="updatedTime" th:value="${#dates.format(baseJfpgInfo.updatedTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
</div>
</div>
</div>-->
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "ems/JfpgInfo";
$("#form-JfpgInfo-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-JfpgInfo-edit').serialize());
}
}
$("input[name='createdTime']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
$("input[name='updatedTime']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
</script>
</body>
</html>

@ -0,0 +1,61 @@
package com.ruoyi.system.mapper;
import java.util.List;
import com.ruoyi.system.domain.BaseJfpgInfo;
/**
* Mapper
*
* @author WenJY
* @date 2021-11-30
*/
public interface BaseJfpgInfoMapper
{
/**
*
*
* @param uuid
* @return
*/
public BaseJfpgInfo selectBaseJfpgInfoByUuid(String uuid);
/**
*
*
* @param baseJfpgInfo
* @return
*/
public List<BaseJfpgInfo> selectBaseJfpgInfoList(BaseJfpgInfo baseJfpgInfo);
/**
*
*
* @param baseJfpgInfo
* @return
*/
public int insertBaseJfpgInfo(BaseJfpgInfo baseJfpgInfo);
/**
*
*
* @param baseJfpgInfo
* @return
*/
public int updateBaseJfpgInfo(BaseJfpgInfo baseJfpgInfo);
/**
*
*
* @param uuid
* @return
*/
public int deleteBaseJfpgInfoByUuid(String uuid);
/**
*
*
* @param uuids
* @return
*/
public int deleteBaseJfpgInfoByUuids(String[] uuids);
}

@ -0,0 +1,61 @@
package com.ruoyi.system.service;
import java.util.List;
import com.ruoyi.system.domain.BaseJfpgInfo;
/**
* Service
*
* @author WenJY
* @date 2021-11-30
*/
public interface IBaseJfpgInfoService
{
/**
*
*
* @param uuid
* @return
*/
public BaseJfpgInfo selectBaseJfpgInfoByUuid(String uuid);
/**
*
*
* @param baseJfpgInfo
* @return
*/
public List<BaseJfpgInfo> selectBaseJfpgInfoList(BaseJfpgInfo baseJfpgInfo);
/**
*
*
* @param baseJfpgInfo
* @return
*/
public int insertBaseJfpgInfo(BaseJfpgInfo baseJfpgInfo);
/**
*
*
* @param baseJfpgInfo
* @return
*/
public int updateBaseJfpgInfo(BaseJfpgInfo baseJfpgInfo);
/**
*
*
* @param uuids
* @return
*/
public int deleteBaseJfpgInfoByUuids(String uuids);
/**
*
*
* @param uuid
* @return
*/
public int deleteBaseJfpgInfoByUuid(String uuid);
}

@ -0,0 +1,94 @@
package com.ruoyi.system.service.impl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.BaseJfpgInfoMapper;
import com.ruoyi.system.domain.BaseJfpgInfo;
import com.ruoyi.system.service.IBaseJfpgInfoService;
import com.ruoyi.common.core.text.Convert;
/**
* Service
*
* @author WenJY
* @date 2021-11-30
*/
@Service
public class BaseJfpgInfoServiceImpl implements IBaseJfpgInfoService
{
@Autowired
private BaseJfpgInfoMapper baseJfpgInfoMapper;
/**
*
*
* @param uuid
* @return
*/
@Override
public BaseJfpgInfo selectBaseJfpgInfoByUuid(String uuid)
{
return baseJfpgInfoMapper.selectBaseJfpgInfoByUuid(uuid);
}
/**
*
*
* @param baseJfpgInfo
* @return
*/
@Override
public List<BaseJfpgInfo> selectBaseJfpgInfoList(BaseJfpgInfo baseJfpgInfo)
{
return baseJfpgInfoMapper.selectBaseJfpgInfoList(baseJfpgInfo);
}
/**
*
*
* @param baseJfpgInfo
* @return
*/
@Override
public int insertBaseJfpgInfo(BaseJfpgInfo baseJfpgInfo)
{
return baseJfpgInfoMapper.insertBaseJfpgInfo(baseJfpgInfo);
}
/**
*
*
* @param baseJfpgInfo
* @return
*/
@Override
public int updateBaseJfpgInfo(BaseJfpgInfo baseJfpgInfo)
{
return baseJfpgInfoMapper.updateBaseJfpgInfo(baseJfpgInfo);
}
/**
*
*
* @param uuids
* @return
*/
@Override
public int deleteBaseJfpgInfoByUuids(String uuids)
{
return baseJfpgInfoMapper.deleteBaseJfpgInfoByUuids(Convert.toStrArray(uuids));
}
/**
*
*
* @param uuid
* @return
*/
@Override
public int deleteBaseJfpgInfoByUuid(String uuid)
{
return baseJfpgInfoMapper.deleteBaseJfpgInfoByUuid(uuid);
}
}

@ -0,0 +1,96 @@
<?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.system.mapper.BaseJfpgInfoMapper">
<resultMap type="BaseJfpgInfo" id="BaseJfpgInfoResult">
<result property="uuid" column="uuid" />
<result property="timeframeName" column="timeframe_name" />
<result property="timeframeBegin" column="timeframe_begin" />
<result property="timeframeEnd" column="timeframe_end" />
<result property="timeframePrice" column="timeframe_price" />
<result property="deleteFlag" column="delete_flag" />
<result property="createdBy" column="created_by" />
<result property="createdTime" column="created_time" />
<result property="updatedBy" column="updated_by" />
<result property="updatedTime" column="updated_time" />
</resultMap>
<sql id="selectBaseJfpgInfoVo">
select uuid, timeframe_name, timeframe_begin, timeframe_end, timeframe_price, delete_flag, created_by, created_time, updated_by, updated_time from base_jfpg_info
</sql>
<select id="selectBaseJfpgInfoList" parameterType="BaseJfpgInfo" resultMap="BaseJfpgInfoResult">
<include refid="selectBaseJfpgInfoVo"/>
<where>
<if test="timeframeName != null and timeframeName != ''"> and timeframe_name like concat(concat('%', #{timeframeName}), '%')</if>
<if test="deleteFlag != null "> and delete_flag = #{deleteFlag}</if>
<if test="params.beginCreatedTime != null and params.beginCreatedTime != '' and params.endCreatedTime != null and params.endCreatedTime != ''"> and created_time between #{params.beginCreatedTime} and #{params.endCreatedTime}</if>
<if test="params.beginUpdatedTime != null and params.beginUpdatedTime != '' and params.endUpdatedTime != null and params.endUpdatedTime != ''"> and updated_time between #{params.beginUpdatedTime} and #{params.endUpdatedTime}</if>
</where>
</select>
<select id="selectBaseJfpgInfoByUuid" parameterType="String" resultMap="BaseJfpgInfoResult">
<include refid="selectBaseJfpgInfoVo"/>
where uuid = #{uuid}
</select>
<insert id="insertBaseJfpgInfo" parameterType="BaseJfpgInfo">
<!-- <selectKey keyProperty="uuid" resultType="long" order="BEFORE">-->
<!-- SELECT seq_base_jfpg_info.NEXTVAL as uuid FROM DUAL-->
<!-- </selectKey>-->
insert into base_jfpg_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="uuid != null">uuid,</if>
<if test="timeframeName != null">timeframe_name,</if>
<if test="timeframeBegin != null">timeframe_begin,</if>
<if test="timeframeEnd != null">timeframe_end,</if>
<if test="timeframePrice != null">timeframe_price,</if>
<if test="deleteFlag != null">delete_flag,</if>
<if test="createdBy != null">created_by,</if>
<if test="createdTime != null">created_time,</if>
<if test="updatedBy != null">updated_by,</if>
<if test="updatedTime != null">updated_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="uuid != null">#{uuid},</if>
<if test="timeframeName != null">#{timeframeName},</if>
<if test="timeframeBegin != null">#{timeframeBegin},</if>
<if test="timeframeEnd != null">#{timeframeEnd},</if>
<if test="timeframePrice != null">#{timeframePrice},</if>
<if test="deleteFlag != null">#{deleteFlag},</if>
<if test="createdBy != null">#{createdBy},</if>
<if test="createdTime != null">#{createdTime},</if>
<if test="updatedBy != null">#{updatedBy},</if>
<if test="updatedTime != null">#{updatedTime},</if>
</trim>
</insert>
<update id="updateBaseJfpgInfo" parameterType="BaseJfpgInfo">
update base_jfpg_info
<trim prefix="SET" suffixOverrides=",">
<if test="timeframeName != null">timeframe_name = #{timeframeName},</if>
<if test="timeframeBegin != null">timeframe_begin = #{timeframeBegin},</if>
<if test="timeframeEnd != null">timeframe_end = #{timeframeEnd},</if>
<if test="timeframePrice != null">timeframe_price = #{timeframePrice},</if>
<if test="deleteFlag != null">delete_flag = #{deleteFlag},</if>
<if test="createdBy != null">created_by = #{createdBy},</if>
<if test="createdTime != null">created_time = #{createdTime},</if>
<if test="updatedBy != null">updated_by = #{updatedBy},</if>
<if test="updatedTime != null">updated_time = #{updatedTime},</if>
</trim>
where uuid = #{uuid}
</update>
<delete id="deleteBaseJfpgInfoByUuid" parameterType="String">
delete from base_jfpg_info where uuid = #{uuid}
</delete>
<delete id="deleteBaseJfpgInfoByUuids" parameterType="String">
delete from base_jfpg_info where uuid in
<foreach item="uuid" collection="array" open="(" separator="," close=")">
#{uuid}
</foreach>
</delete>
</mapper>
Loading…
Cancel
Save