Browse Source

路径名修改

develop
ljlong_2630 11 months ago
parent
commit
242f1cc2c0
  1. 12
      lzbi-module/src/main/java/com/lzbi/targetFolder/domain/DcBaseAssetTargetDao.java
  2. 143
      lzbi-module/src/main/resources/mapper/targetFolder/DcBaseAssetTargetMapper.xml
  3. 108
      lzbi-module/src/main/resources/mapper/targetFolder/DcBaseTargetModelMapper.xml

12
lzbi-module/src/main/java/com/lzbi/targetFolder/domain/DcBaseAssetTargetDao.java

@ -68,16 +68,10 @@ public class DcBaseAssetTargetDao extends BaseModuleEntity
@Excel(name = "排序")
private String sort;
/** 创建人 */
private String createdBy;
/** 统计单元编码 */
@Excel(name = "统计单元编码")
private String assetCode;
/** 创建时间 */
private Date createdTime;
/** 更新人 */
private String updatedBy;
/** 更新时间 */
private Date updatedTime;
}

143
lzbi-module/src/main/resources/mapper/targetFolder/DcBaseAssetTargetMapper.xml

@ -0,0 +1,143 @@
<?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.lzbi.targetFolder.mapper.DcBaseAssetTargetMapper">
<resultMap type="com.lzbi.targetFolder.domain.DcBaseAssetTargetDao" id="DcBaseAssetTargetResult">
<result property="id" column="id" />
<result property="assetId" column="asset_id" />
<result property="targetModelCode" column="target_model_code" />
<result property="targetName" column="target_name" />
<result property="targetCode" column="target_code" />
<result property="targetField" column="target_field" />
<result property="limitUp" column="limit_up" />
<result property="limitDown" column="limit_down" />
<result property="valueBase" column="value_base" />
<result property="flagAvg" column="flag_avg" />
<result property="flagSum" column="flag_sum" />
<result property="flagCompute" column="flag_compute" />
<result property="sort" column="sort" />
<result property="tenantId" column="tenant_id" />
<result property="revision" column="revision" />
<result property="createdBy" column="created_by" />
<result property="createdTime" column="created_time" />
<result property="updatedBy" column="updated_by" />
<result property="updatedTime" column="updated_time" />
<result property="deleteBy" column="delete_by" />
<result property="deleteTime" column="delete_time" />
</resultMap>
<sql id="selectDcBaseAssetTargetVo">
select id, asset_id, target_model_code, target_name, target_code, target_field, limit_up, limit_down, value_base, flag_avg, flag_sum, flag_compute, sort, tenant_id, revision, created_by, created_time, updated_by, updated_time, delete_by, delete_time from dc_base_asset_target
</sql>
<select id="selectDcBaseAssetTargetDaoList" parameterType="DcBaseAssetTargetDao" resultMap="DcBaseAssetTargetResult">
<include refid="selectDcBaseAssetTargetVo"/>
<where>
<if test="assetId != null "> and asset_id = #{assetId}</if>
<if test="targetModelCode != null and targetModelCode != ''"> and target_model_code = #{targetModelCode}</if>
<if test="targetName != null and targetName != ''"> and target_name like concat('%', #{targetName}, '%')</if>
<if test="targetCode != null and targetCode != ''"> and target_code = #{targetCode}</if>
<if test="targetField != null and targetField != ''"> and target_field = #{targetField}</if>
<if test="limitUp != null "> and limit_up = #{limitUp}</if>
<if test="limitDown != null "> and limit_down = #{limitDown}</if>
<if test="valueBase != null "> and value_base = #{valueBase}</if>
<if test="flagAvg != null and flagAvg != ''"> and flag_avg = #{flagAvg}</if>
<if test="flagSum != null and flagSum != ''"> and flag_sum = #{flagSum}</if>
<if test="flagCompute != null and flagCompute != ''"> and flag_compute = #{flagCompute}</if>
<if test="sort != null and sort != ''"> and sort = #{sort}</if>
</where>
</select>
<select id="selectDcBaseAssetTargetDaoById" parameterType="Long" resultMap="DcBaseAssetTargetResult">
<include refid="selectDcBaseAssetTargetVo"/>
where id = #{id}
</select>
<insert id="insertDcBaseAssetTargetDao" parameterType="DcBaseAssetTargetDao" useGeneratedKeys="true" keyProperty="id">
insert into dc_base_asset_target
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="assetId != null">asset_id,</if>
<if test="targetModelCode != null">target_model_code,</if>
<if test="targetName != null">target_name,</if>
<if test="targetCode != null">target_code,</if>
<if test="targetField != null">target_field,</if>
<if test="limitUp != null">limit_up,</if>
<if test="limitDown != null">limit_down,</if>
<if test="valueBase != null">value_base,</if>
<if test="flagAvg != null">flag_avg,</if>
<if test="flagSum != null">flag_sum,</if>
<if test="flagCompute != null">flag_compute,</if>
<if test="sort != null">sort,</if>
<if test="tenantId != null">tenant_id,</if>
<if test="revision != null">revision,</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>
<if test="deleteBy != null">delete_by,</if>
<if test="deleteTime != null">delete_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="assetId != null">#{assetId},</if>
<if test="targetModelCode != null">#{targetModelCode},</if>
<if test="targetName != null">#{targetName},</if>
<if test="targetCode != null">#{targetCode},</if>
<if test="targetField != null">#{targetField},</if>
<if test="limitUp != null">#{limitUp},</if>
<if test="limitDown != null">#{limitDown},</if>
<if test="valueBase != null">#{valueBase},</if>
<if test="flagAvg != null">#{flagAvg},</if>
<if test="flagSum != null">#{flagSum},</if>
<if test="flagCompute != null">#{flagCompute},</if>
<if test="sort != null">#{sort},</if>
<if test="tenantId != null">#{tenantId},</if>
<if test="revision != null">#{revision},</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>
<if test="deleteBy != null">#{deleteBy},</if>
<if test="deleteTime != null">#{deleteTime},</if>
</trim>
</insert>
<update id="updateDcBaseAssetTargetDao" parameterType="DcBaseAssetTargetDao">
update dc_base_asset_target
<trim prefix="SET" suffixOverrides=",">
<if test="assetId != null">asset_id = #{assetId},</if>
<if test="targetModelCode != null">target_model_code = #{targetModelCode},</if>
<if test="targetName != null">target_name = #{targetName},</if>
<if test="targetCode != null">target_code = #{targetCode},</if>
<if test="targetField != null">target_field = #{targetField},</if>
<if test="limitUp != null">limit_up = #{limitUp},</if>
<if test="limitDown != null">limit_down = #{limitDown},</if>
<if test="valueBase != null">value_base = #{valueBase},</if>
<if test="flagAvg != null">flag_avg = #{flagAvg},</if>
<if test="flagSum != null">flag_sum = #{flagSum},</if>
<if test="flagCompute != null">flag_compute = #{flagCompute},</if>
<if test="sort != null">sort = #{sort},</if>
<if test="tenantId != null">tenant_id = #{tenantId},</if>
<if test="revision != null">revision = #{revision},</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>
<if test="deleteBy != null">delete_by = #{deleteBy},</if>
<if test="deleteTime != null">delete_time = #{deleteTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteDcBaseAssetTargetDaoById" parameterType="Long">
delete from dc_base_asset_target where id = #{id}
</delete>
<delete id="deleteDcBaseAssetTargetDaoByIds" parameterType="String">
delete from dc_base_asset_target where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>

108
lzbi-module/src/main/resources/mapper/targetFolder/DcBaseTargetModelMapper.xml

@ -0,0 +1,108 @@
<?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.lzbi.targetFolder.mapper.DcBaseTargetModelMapper">
<resultMap type="com.lzbi.targetFolder.domain.DcBaseTargetModelDao" id="DcBaseTargetModelResult">
<result property="id" column="id" />
<result property="targetModelCode" column="target_model_code" />
<result property="targetModelName" column="target_model_name" />
<result property="targetModelType" column="target_model_type" />
<result property="targetModelField" column="target_model_field" />
<result property="targetModelLevel" column="target_model_level" />
<result property="tenantId" column="tenant_id" />
<result property="revision" column="revision" />
<result property="createdBy" column="created_by" />
<result property="createdTime" column="created_time" />
<result property="updatedBy" column="updated_by" />
<result property="updatedTime" column="updated_time" />
<result property="deleteBy" column="delete_by" />
<result property="deleteTime" column="delete_time" />
</resultMap>
<sql id="selectDcBaseTargetModelVo">
select id, target_model_code, target_model_name, target_model_type, target_model_field, target_model_level, tenant_id, revision, created_by, created_time, updated_by, updated_time, delete_by, delete_time from dc_base_target_model
</sql>
<select id="selectDcBaseTargetModelDaoList" parameterType="DcBaseTargetModelDao" resultMap="DcBaseTargetModelResult">
<include refid="selectDcBaseTargetModelVo"/>
<where>
<if test="targetModelCode != null and targetModelCode != ''"> and target_model_code = #{targetModelCode}</if>
<if test="targetModelName != null and targetModelName != ''"> and target_model_name like concat('%', #{targetModelName}, '%')</if>
<if test="targetModelType != null and targetModelType != ''"> and target_model_type = #{targetModelType}</if>
<if test="targetModelField != null and targetModelField != ''"> and target_model_field = #{targetModelField}</if>
<if test="targetModelLevel != null "> and target_model_level = #{targetModelLevel}</if>
</where>
</select>
<select id="selectDcBaseTargetModelDaoById" parameterType="Long" resultMap="DcBaseTargetModelResult">
<include refid="selectDcBaseTargetModelVo"/>
where id = #{id}
</select>
<insert id="insertDcBaseTargetModelDao" parameterType="DcBaseTargetModelDao" useGeneratedKeys="true" keyProperty="id">
insert into dc_base_target_model
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="targetModelCode != null">target_model_code,</if>
<if test="targetModelName != null">target_model_name,</if>
<if test="targetModelType != null">target_model_type,</if>
<if test="targetModelField != null">target_model_field,</if>
<if test="targetModelLevel != null">target_model_level,</if>
<if test="tenantId != null">tenant_id,</if>
<if test="revision != null">revision,</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>
<if test="deleteBy != null">delete_by,</if>
<if test="deleteTime != null">delete_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="targetModelCode != null">#{targetModelCode},</if>
<if test="targetModelName != null">#{targetModelName},</if>
<if test="targetModelType != null">#{targetModelType},</if>
<if test="targetModelField != null">#{targetModelField},</if>
<if test="targetModelLevel != null">#{targetModelLevel},</if>
<if test="tenantId != null">#{tenantId},</if>
<if test="revision != null">#{revision},</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>
<if test="deleteBy != null">#{deleteBy},</if>
<if test="deleteTime != null">#{deleteTime},</if>
</trim>
</insert>
<update id="updateDcBaseTargetModelDao" parameterType="DcBaseTargetModelDao">
update dc_base_target_model
<trim prefix="SET" suffixOverrides=",">
<if test="targetModelCode != null">target_model_code = #{targetModelCode},</if>
<if test="targetModelName != null">target_model_name = #{targetModelName},</if>
<if test="targetModelType != null">target_model_type = #{targetModelType},</if>
<if test="targetModelField != null">target_model_field = #{targetModelField},</if>
<if test="targetModelLevel != null">target_model_level = #{targetModelLevel},</if>
<if test="tenantId != null">tenant_id = #{tenantId},</if>
<if test="revision != null">revision = #{revision},</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>
<if test="deleteBy != null">delete_by = #{deleteBy},</if>
<if test="deleteTime != null">delete_time = #{deleteTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteDcBaseTargetModelDaoById" parameterType="Long">
delete from dc_base_target_model where id = #{id}
</delete>
<delete id="deleteDcBaseTargetModelDaoByIds" parameterType="String">
delete from dc_base_target_model where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
Loading…
Cancel
Save