소스 검색

app模块

txf 3 년 전
부모
커밋
44410302c0

+ 1 - 0
src/main/java/com/steerinfo/dil/controller/AMScontroller.java

@@ -807,6 +807,7 @@ public class AMScontroller{
         return amsFeign.updateOpenDispatchSaleOrder(mapVal);
     }
 
+
     //焦炭、水渣日计划
     //新增
     @PostMapping("/addTruckRailDayPlan")

+ 34 - 0
src/main/java/com/steerinfo/dil/controller/DilVersionController.java

@@ -0,0 +1,34 @@
+package com.steerinfo.dil.controller;
+
+import com.steerinfo.dil.service.impl.DilVersionServiceImpl;
+import io.swagger.annotations.ApiModelProperty;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+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.RestController;
+
+/**
+ * @ author    :TXF
+ * @ time      :2021/12/14 22:42
+ */
+@RestController
+@RequestMapping("/appVersion")
+public class DilVersionController {
+
+    @Autowired
+    DilVersionServiceImpl dilVersionService;
+
+    @ApiOperation(value = "查询版本号")
+    @PostMapping("/checkVersion/{version}")
+    public int deleteTruckRailDayPlan(@PathVariable("version") String version) {
+        return dilVersionService.compareAppVersion(version);
+    }
+
+    @ApiOperation(value = "新增版本号")
+    @PostMapping("/addAppVersion/{version}")
+    public String addAppVersion(@PathVariable("version") String version) {
+        return dilVersionService.addAppVersion(version);
+    }
+}

+ 11 - 0
src/main/java/com/steerinfo/dil/controller/TMSController.java

@@ -1861,4 +1861,15 @@ public class TMSController extends BaseRESTfulController {
     public Map<String, Object> batchSendMeasureCommission(@RequestBody(required = false) Map<String, Object> map) {
         return tmsTrainFeign.batchSendMeasureCommission(map);
     }
+
+    @ApiOperation(value="查询辅料燃料统计报表")
+    @PostMapping("/getRLFLReport")
+    public Map<String, Object> getRLFLReport(@RequestBody(required=false) Map<String,Object> mapValue,
+                                               Integer apiId,
+                                               Integer pageNum,
+                                               Integer pageSize,
+                                               Integer orderType
+    ){
+        return tmsTruckFeign.getRLFLReport(mapValue==null?new HashMap<>():mapValue, apiId, pageNum, pageSize, orderType);
+    }
 }

+ 7 - 0
src/main/java/com/steerinfo/dil/feign/TmsTruckFeign.java

@@ -339,6 +339,13 @@ public interface TmsTruckFeign {
     @PostMapping("api/v1/truckTms/selfMachine/getDeliveryOrder")
     Map<String, Object> getDeliveryOrder(@RequestParam String orderNumber);
 
+    @PostMapping("api/v1/truckTms/statisticalReport/getRLFLReport")
+    Map<String, Object> getRLFLReport(@RequestBody(required=false) Map<String,Object> mapValue,
+                                      @RequestParam("apiId") Integer apiId,
+                                      @RequestParam("pageNum") Integer pageNum,
+                                      @RequestParam("pageSize") Integer pageSize,
+                                      @RequestParam("orderType") Integer orderType
+    );
 }
 
 

+ 22 - 0
src/main/java/com/steerinfo/dil/mapper/DilVersionMapper.java

@@ -0,0 +1,22 @@
+package com.steerinfo.dil.mapper;
+
+import com.steerinfo.dil.model.DilVersion;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Select;
+
+import java.math.BigDecimal;
+
+@Mapper
+public interface DilVersionMapper extends IBaseMapper<DilVersion, BigDecimal> {
+
+    //查询最大主键
+    @Select("select max(DV.VERSION_ID) + 1 from DIL_VERSION")
+    BigDecimal selectMaxId();
+
+    //查询最新的版本号
+    String compareVersion();
+
+    //查询版本号是否已存在
+    Integer getVersionId(String version);
+}

+ 138 - 0
src/main/java/com/steerinfo/dil/model/DilVersion.java

@@ -0,0 +1,138 @@
+package com.steerinfo.dil.model;
+
+import com.steerinfo.framework.model.IBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.math.BigDecimal;
+import java.util.Date;
+
+@ApiModel(value="app版本号")
+public class DilVersion implements IBasePO<BigDecimal> {
+    /**
+     * 主键ID(VERSION_ID,DECIMAL,38)
+     */
+    @ApiModelProperty(value="主键ID",required=true)
+    private BigDecimal versionId;
+
+    /**
+     * 版本号(VERSION_VALUE,VARCHAR,20)
+     */
+    @ApiModelProperty(value="版本号",required=false)
+    private String versionValue;
+
+    /**
+     * 记录创建人(INSERT_USERNAME,VARCHAR,20)
+     */
+    @ApiModelProperty(value="记录创建人",required=false)
+    private String insertUsername;
+
+    /**
+     * 记录创建时间(INSERT_TIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="记录创建时间",required=false)
+    private Date insertTime;
+
+    /**
+     * 记录修改人(UPDATE_USERNAME,VARCHAR,20)
+     */
+    @ApiModelProperty(value="记录修改人",required=false)
+    private String updateUsername;
+
+    /**
+     * 记录修改时间(UPDATE_TIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="记录修改时间",required=false)
+    private Date updateTime;
+
+    /**
+     * 记录创建或修改备注(INSERT_UPDATE_REMARK,VARCHAR,100)
+     */
+    @ApiModelProperty(value="记录创建或修改备注",required=false)
+    private String insertUpdateRemark;
+
+    private static final long serialVersionUID = 1L;
+
+    @Override
+    public BigDecimal getId() {
+        return this.versionId;
+    }
+
+    @Override
+    public void setId(BigDecimal versionId) {
+        this.versionId = versionId;
+    }
+
+    public BigDecimal getVersionId() {
+        return versionId;
+    }
+
+    public void setVersionId(BigDecimal versionId) {
+        this.versionId = versionId;
+    }
+
+    public String getVersionValue() {
+        return versionValue;
+    }
+
+    public void setVersionValue(String versionValue) {
+        this.versionValue = versionValue == null ? null : versionValue.trim();
+    }
+
+    public String getInsertUsername() {
+        return insertUsername;
+    }
+
+    public void setInsertUsername(String insertUsername) {
+        this.insertUsername = insertUsername == null ? null : insertUsername.trim();
+    }
+
+    public Date getInsertTime() {
+        return insertTime;
+    }
+
+    public void setInsertTime(Date insertTime) {
+        this.insertTime = insertTime;
+    }
+
+    public String getUpdateUsername() {
+        return updateUsername;
+    }
+
+    public void setUpdateUsername(String updateUsername) {
+        this.updateUsername = updateUsername == null ? null : updateUsername.trim();
+    }
+
+    public Date getUpdateTime() {
+        return updateTime;
+    }
+
+    public void setUpdateTime(Date updateTime) {
+        this.updateTime = updateTime;
+    }
+
+    public String getInsertUpdateRemark() {
+        return insertUpdateRemark;
+    }
+
+    public void setInsertUpdateRemark(String insertUpdateRemark) {
+        this.insertUpdateRemark = insertUpdateRemark == null ? null : insertUpdateRemark.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", versionId=").append(versionId);
+        sb.append(", versionValue=").append(versionValue);
+        sb.append(", insertUsername=").append(insertUsername);
+        sb.append(", insertTime=").append(insertTime);
+        sb.append(", updateUsername=").append(updateUsername);
+        sb.append(", updateTime=").append(updateTime);
+        sb.append(", insertUpdateRemark=").append(insertUpdateRemark);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 27 - 0
src/main/java/com/steerinfo/dil/service/IDilVersionService.java

@@ -0,0 +1,27 @@
+package com.steerinfo.dil.service;
+
+import com.steerinfo.dil.model.DilVersion;
+import com.steerinfo.framework.service.IBaseService;
+
+import java.math.BigDecimal;
+
+/**
+ * DilVersion服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-12-14 10:05
+ * 类描述
+ * 修订历史:
+ * 日期:2021-12-14
+ * 作者:generator
+ * 参考:
+ * 描述:DilVersion服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IDilVersionService{
+
+    int compareAppVersion(String version);
+
+    String addAppVersion(String version);
+
+}

+ 68 - 0
src/main/java/com/steerinfo/dil/service/impl/DilVersionServiceImpl.java

@@ -0,0 +1,68 @@
+package com.steerinfo.dil.service.impl;
+
+import com.steerinfo.dil.mapper.DilVersionMapper;
+import com.steerinfo.dil.model.DilVersion;
+import com.steerinfo.dil.service.IDilVersionService;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * DilVersion服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-12-14 10:05
+ * 类描述
+ * 修订历史:
+ * 日期:2021-12-14
+ * 作者:generator
+ * 参考:
+ * 描述:DilVersion服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "dilVersionService")
+public class DilVersionServiceImpl implements IDilVersionService {
+
+    @Autowired
+    private DilVersionMapper dilVersionMapper;
+
+
+    /**
+     * 传入版本号查询是否为最新版本
+     * @param version 版本号
+     * @return 0 不需要更新  1 需要更新
+     */
+    public int compareAppVersion(String version){
+        //查找当前最新版本号
+        String theLastVersion = dilVersionMapper.compareVersion();
+        //判断是否为最新版本号
+        if(theLastVersion.equals(version)){
+            return 0;
+        }
+        return 1;
+    }
+
+    /**
+     * 添加APP版本号
+     * @param version
+     * @return
+     */
+    public String addAppVersion(String version){
+        //判断该版本号是否已存在
+        Integer versionId = dilVersionMapper.getVersionId(version);
+        if(versionId != null){
+            return "版本号已存在";
+        }
+        DilVersion dilVersion = new DilVersion();
+        dilVersion.setVersionId(dilVersionMapper.selectMaxId());
+        dilVersion.setVersionValue(version);
+        dilVersion.setInsertTime(new Date());
+        dilVersion.setInsertUsername("admin");
+        dilVersionMapper.insertSelective(dilVersion);
+        return version + "添加成功";
+    }
+}

+ 3 - 2
src/main/resources/bootstrap.yml

@@ -37,9 +37,9 @@ openfeign:
   QmsTruckFeign:
     url: ${QMSTRUCKFEIGN_URL:172.16.33.166:8047}
   TmsTrainFeign:
-    url: ${TMSTRAINFEIGN_URL:172.16.33.166:8086}
+    url: ${TMSTRAINFEIGN_URL:localhost:8086}
   TmsTruckFeign:
-    url: ${TMSTRUCKFEIGN_URL:172.16.33.166:8088}
+    url: ${TMSTRUCKFEIGN_URL:localhost:8088}
   TmsshipFeign:
     url: ${TMSSHIPFEIGN_URL:172.16.33.166:8090}
   WMSHFeign:
@@ -54,6 +54,7 @@ openfeign:
 genxml:
   pth: com/a
 cache:
+
   level: 2
 redis:
   host: 10.10.50.28

+ 284 - 0
src/main/resources/com/steerinfo/dil/mapper/DilVersionMapper.xml

@@ -0,0 +1,284 @@
+<?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.steerinfo.dil.mapper.DilVersionMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.dil.model.DilVersion">
+    <id column="VERSION_ID" jdbcType="DECIMAL" property="versionId" />
+    <result column="VERSION_VALUE" jdbcType="VARCHAR" property="versionValue" />
+    <result column="INSERT_USERNAME" jdbcType="VARCHAR" property="insertUsername" />
+    <result column="INSERT_TIME" jdbcType="TIMESTAMP" property="insertTime" />
+    <result column="UPDATE_USERNAME" jdbcType="VARCHAR" property="updateUsername" />
+    <result column="UPDATE_TIME" jdbcType="TIMESTAMP" property="updateTime" />
+    <result column="INSERT_UPDATE_REMARK" jdbcType="VARCHAR" property="insertUpdateRemark" />
+  </resultMap>
+  <sql id="columns">
+    VERSION_ID, VERSION_VALUE, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, 
+    INSERT_UPDATE_REMARK
+  </sql>
+  <sql id="columns_alias">
+    t.VERSION_ID, t.VERSION_VALUE, t.INSERT_USERNAME, t.INSERT_TIME, t.UPDATE_USERNAME, 
+    t.UPDATE_TIME, t.INSERT_UPDATE_REMARK
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM DIL_VERSION
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM DIL_VERSION t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="versionId != null">
+        and VERSION_ID = #{versionId}
+      </if>
+      <if test="versionValue != null and versionValue != ''">
+        and VERSION_VALUE = #{versionValue}
+      </if>
+      <if test="insertUsername != null and insertUsername != ''">
+        and INSERT_USERNAME = #{insertUsername}
+      </if>
+      <if test="insertTime != null">
+        and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime}
+      </if>
+      <if test="updateUsername != null and updateUsername != ''">
+        and UPDATE_USERNAME = #{updateUsername}
+      </if>
+      <if test="updateTime != null">
+        and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime}
+      </if>
+      <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
+        and INSERT_UPDATE_REMARK = #{insertUpdateRemark}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="versionId != null">
+        and VERSION_ID = #{versionId}
+      </if>
+      <if test="versionValue != null and versionValue != ''">
+        and VERSION_VALUE LIKE '%${versionValue}%'
+      </if>
+      <if test="insertUsername != null and insertUsername != ''">
+        and INSERT_USERNAME LIKE '%${insertUsername}%'
+      </if>
+      <if test="insertTime != null">
+        and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime}
+      </if>
+      <if test="updateUsername != null and updateUsername != ''">
+        and UPDATE_USERNAME LIKE '%${updateUsername}%'
+      </if>
+      <if test="updateTime != null">
+        and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime}
+      </if>
+      <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
+        and INSERT_UPDATE_REMARK LIKE '%${insertUpdateRemark}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
+    delete from DIL_VERSION
+    where VERSION_ID = #{versionId,jdbcType=DECIMAL}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from DIL_VERSION
+    where 1!=1 
+      <if test="versionValue != null and versionValue != ''">
+        or VERSION_VALUE = #{versionValue}
+      </if>
+      <if test="insertUsername != null and insertUsername != ''">
+        or INSERT_USERNAME = #{insertUsername}
+      </if>
+      <if test="insertTime != null">
+        or TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = '#{insertTime}'
+      </if>
+      <if test="updateUsername != null and updateUsername != ''">
+        or UPDATE_USERNAME = #{updateUsername}
+      </if>
+      <if test="updateTime != null">
+        or TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = '#{updateTime}'
+      </if>
+      <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
+        or INSERT_UPDATE_REMARK = #{insertUpdateRemark}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.dil.model.DilVersion">
+    insert into DIL_VERSION (VERSION_ID, VERSION_VALUE, INSERT_USERNAME, 
+      INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, 
+      INSERT_UPDATE_REMARK)
+    values (#{versionId,jdbcType=DECIMAL}, #{versionValue,jdbcType=VARCHAR}, #{insertUsername,jdbcType=VARCHAR}, 
+      #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, 
+      #{insertUpdateRemark,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.dil.model.DilVersion">
+    insert into DIL_VERSION
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="versionId != null">
+        VERSION_ID,
+      </if>
+      <if test="versionValue != null">
+        VERSION_VALUE,
+      </if>
+      <if test="insertUsername != null">
+        INSERT_USERNAME,
+      </if>
+      <if test="insertTime != null">
+        INSERT_TIME,
+      </if>
+      <if test="updateUsername != null">
+        UPDATE_USERNAME,
+      </if>
+      <if test="updateTime != null">
+        UPDATE_TIME,
+      </if>
+      <if test="insertUpdateRemark != null">
+        INSERT_UPDATE_REMARK,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="versionId != null">
+        #{versionId,jdbcType=DECIMAL},
+      </if>
+      <if test="versionValue != null">
+        #{versionValue,jdbcType=VARCHAR},
+      </if>
+      <if test="insertUsername != null">
+        #{insertUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="insertTime != null">
+        #{insertTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="updateUsername != null">
+        #{updateUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="updateTime != null">
+        #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="insertUpdateRemark != null">
+        #{insertUpdateRemark,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.DilVersion">
+    update DIL_VERSION
+    set VERSION_VALUE = #{versionValue,jdbcType=VARCHAR},
+      INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
+      INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP},
+      UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
+      UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
+      INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR}
+    where VERSION_ID = #{versionId,jdbcType=DECIMAL}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.DilVersion">
+    update DIL_VERSION
+    <set>
+      <if test="versionValue != null">
+        VERSION_VALUE = #{versionValue,jdbcType=VARCHAR},
+      </if>
+      <if test="insertUsername != null">
+        INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="insertTime != null">
+        INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="updateUsername != null">
+        UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="updateTime != null">
+        UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="insertUpdateRemark != null">
+        INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where VERSION_ID = #{versionId,jdbcType=DECIMAL}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where VERSION_ID = #{versionId,jdbcType=DECIMAL}
+  </select>
+  <select id="selectByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
+    <include refid="select"/>
+    <include refid="where"/>
+  </select>
+  <select id="selectLikeByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
+    <include refid="select"/>
+    <include refid="whereLike"/>
+  </select>
+  <insert id="batchInsert" parameterType="java.util.List">
+    insert into DIL_VERSION 
+      (VERSION_ID, 
+      VERSION_VALUE, INSERT_USERNAME, 
+      INSERT_TIME, UPDATE_USERNAME, 
+      UPDATE_TIME, INSERT_UPDATE_REMARK
+      )
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.versionId,jdbcType=DECIMAL}, 
+      #{item.versionValue,jdbcType=VARCHAR}, #{item.insertUsername,jdbcType=VARCHAR}, 
+      #{item.insertTime,jdbcType=TIMESTAMP}, #{item.updateUsername,jdbcType=VARCHAR}, 
+      #{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR}
+       from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update DIL_VERSION
+     set
+       VERSION_ID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.versionId,jdbcType=DECIMAL}
+       </foreach>
+       ,VERSION_VALUE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.versionValue,jdbcType=VARCHAR}
+       </foreach>
+       ,INSERT_USERNAME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
+       </foreach>
+       ,INSERT_TIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,UPDATE_USERNAME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
+       </foreach>
+       ,UPDATE_TIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,INSERT_UPDATE_REMARK=
+       <foreach collection="list" item="item" index="index" separator=" " open="case VERSION_ID" close="end">
+          when #{item.versionId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
+       </foreach>
+     where VERSION_ID in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.versionId,jdbcType=DECIMAL}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from DIL_VERSION
+    where VERSION_ID in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+
+  <select id="compareVersion" resultType="string">
+    select *
+    from (
+           select DV.VERSION_VALUE
+           from DIL_VERSION DV
+           order by DV.VERSION_ID desc
+         )
+    where ROWNUM = 1
+  </select>
+
+
+  <select id="getVersionId" parameterType="string" resultType="java.lang.Integer">
+    select DV.VERSION_ID from DIL_VERSION DV
+    where DV.VERSION_VALUE = #{versionValue}
+  </select>
+
+</mapper>