lirl преди 3 години
родител
ревизия
3d0d1e90e4
променени са 44 файла, в които са добавени 5815 реда и са изтрити 0 реда
  1. 104 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/controller/DzMaterialSfController.java
  2. 13 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/mapper/DzMaterialSfMapper.java
  3. 532 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/mapper/DzMaterialSfMapper.xml
  4. 299 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/model/DzMaterialSf.java
  5. 21 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/service/DzMaterialSFDBServer.java
  6. 24 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/service/IDzMaterialSfService.java
  7. 86 0
      src/main/java/com/steerinfo/ems/dzmaterialsf/service/impl/DzMaterialSfServiceImpl.java
  8. 115 0
      src/main/java/com/steerinfo/ems/emscalorificvalue/controller/EmsCalorificValueController.java
  9. 17 0
      src/main/java/com/steerinfo/ems/emscalorificvalue/mapper/EmsCalorificValueMapper.java
  10. 589 0
      src/main/java/com/steerinfo/ems/emscalorificvalue/mapper/EmsCalorificValueMapper.xml
  11. 317 0
      src/main/java/com/steerinfo/ems/emscalorificvalue/model/EmsCalorificValue.java
  12. 28 0
      src/main/java/com/steerinfo/ems/emscalorificvalue/service/IEmsCalorificValueService.java
  13. 50 0
      src/main/java/com/steerinfo/ems/emscalorificvalue/service/impl/EmsCalorificValueServiceImpl.java
  14. 110 0
      src/main/java/com/steerinfo/ems/emslog/controller/EmsLogController.java
  15. 10 0
      src/main/java/com/steerinfo/ems/emslog/mapper/EmsLogMapper.java
  16. 212 0
      src/main/java/com/steerinfo/ems/emslog/mapper/EmsLogMapper.xml
  17. 97 0
      src/main/java/com/steerinfo/ems/emslog/model/EmsLog.java
  18. 23 0
      src/main/java/com/steerinfo/ems/emslog/service/IEmsLogService.java
  19. 36 0
      src/main/java/com/steerinfo/ems/emslog/service/impl/EmsLogServiceImpl.java
  20. 107 0
      src/main/java/com/steerinfo/ems/emsscqklg/controller/EmsScqkLgController.java
  21. 11 0
      src/main/java/com/steerinfo/ems/emsscqklg/mapper/EmsScqkLgMapper.java
  22. 595 0
      src/main/java/com/steerinfo/ems/emsscqklg/mapper/EmsScqkLgMapper.xml
  23. 334 0
      src/main/java/com/steerinfo/ems/emsscqklg/model/EmsScqkLg.java
  24. 28 0
      src/main/java/com/steerinfo/ems/emsscqklg/service/EmsLgReportService.java
  25. 24 0
      src/main/java/com/steerinfo/ems/emsscqklg/service/IEmsScqkLgService.java
  26. 61 0
      src/main/java/com/steerinfo/ems/emsscqklg/service/impl/EmsScqkLgServiceImpl.java
  27. 131 0
      src/main/java/com/steerinfo/ems/foldthevalues/controller/FoldTheValuesController.java
  28. 20 0
      src/main/java/com/steerinfo/ems/foldthevalues/mapper/FoldTheValuesMapper.java
  29. 356 0
      src/main/java/com/steerinfo/ems/foldthevalues/mapper/FoldTheValuesMapper.xml
  30. 181 0
      src/main/java/com/steerinfo/ems/foldthevalues/model/FoldTheValues.java
  31. 32 0
      src/main/java/com/steerinfo/ems/foldthevalues/service/IFoldTheValuesService.java
  32. 114 0
      src/main/java/com/steerinfo/ems/foldthevalues/service/impl/FoldTheValuesServiceImpl.java
  33. 110 0
      src/main/java/com/steerinfo/ems/njformula/controller/NjFormulaController.java
  34. 13 0
      src/main/java/com/steerinfo/ems/njformula/mapper/NjFormulaMapper.java
  35. 192 0
      src/main/java/com/steerinfo/ems/njformula/mapper/NjFormulaMapper.xml
  36. 81 0
      src/main/java/com/steerinfo/ems/njformula/model/NjFormula.java
  37. 26 0
      src/main/java/com/steerinfo/ems/njformula/service/INjFormulaService.java
  38. 41 0
      src/main/java/com/steerinfo/ems/njformula/service/impl/NjFormulaServiceImpl.java
  39. 108 0
      src/main/java/com/steerinfo/ems/rttable/controller/RttableController.java
  40. 19 0
      src/main/java/com/steerinfo/ems/rttable/mapper/RttableMapper.java
  41. 284 0
      src/main/java/com/steerinfo/ems/rttable/mapper/RttableMapper.xml
  42. 128 0
      src/main/java/com/steerinfo/ems/rttable/model/Rttable.java
  43. 27 0
      src/main/java/com/steerinfo/ems/rttable/service/IRttableService.java
  44. 109 0
      src/main/java/com/steerinfo/ems/rttable/service/impl/RttableServiceImpl.java

+ 104 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/controller/DzMaterialSfController.java

@@ -0,0 +1,104 @@
+package com.steerinfo.ems.dzmaterialsf.controller;
+
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf;
+import com.steerinfo.ems.dzmaterialsf.service.IDzMaterialSfService;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.ArrayList;
+import java.math.BigDecimal;
+
+/**
+ * DzMaterialSf RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-16 08:57
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-16
+ * 作者:generator
+ * 参考:
+ * 描述:DzMaterialSf RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/dzmaterialsfs")
+public class DzMaterialSfController extends BaseRESTfulController {
+
+    @Autowired
+    IDzMaterialSfService dzMaterialSfService;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("dzmaterialsf:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<DzMaterialSf> list = dzMaterialSfService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("dzmaterialsf:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<DzMaterialSf> list = dzMaterialSfService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据DzMaterialSf对象创建")
+    @ApiImplicitParam(name = "dzMaterialSf", value = "详细实体dzMaterialSf", required = true, dataType = "DzMaterialSf")
+    //@RequiresPermissions("dzmaterialsf:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@ModelAttribute DzMaterialSf model){
+        DzMaterialSf dzMaterialSf = dzMaterialSfService.add(model);
+        return success(dzMaterialSf);
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(name = "model", value = "详细实体dzMaterialSf的id值", required = true, dataType = "DzMaterialSf")
+    //@RequiresPermissions("dzmaterialsf:view")
+    @GetMapping(value = "/getById")
+    public RESTfulResult get(@ModelAttribute DzMaterialSf model){
+        DzMaterialSf dzMaterialSf = dzMaterialSfService.getById(model);
+        return success(dzMaterialSf);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的dzMaterialSf信息来更新详细信息")
+    @ApiImplicitParam(name = "dzMaterialSf", value = "详细实体dzMaterialSf", required = true, dataType = "DzMaterialSf")
+    //@RequiresPermissions("dzmaterialsf:update")
+    @PutMapping(value = "/", produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update(@RequestBody DzMaterialSf model){
+        DzMaterialSf dzMaterialSf = dzMaterialSfService.modify(model);
+        return success(dzMaterialSf);
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(name = "models", value = "详细实体dzMaterialSf", required = true, dataType = "DzMaterialSf")
+    //@RequiresPermissions("dzmaterialsf:delete")
+    @DeleteMapping(value = "/")//DzMaterialSf
+    public RESTfulResult delete(@RequestBody List<DzMaterialSf> models){
+    	if(ListUtils.isNotEmpty(models)) {
+			  dzMaterialSfService.delete(models);
+    	}
+      return success();
+    }
+}

+ 13 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/mapper/DzMaterialSfMapper.java

@@ -0,0 +1,13 @@
+package com.steerinfo.ems.dzmaterialsf.mapper;
+
+import com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf;
+import com.steerinfo.framework.mapper.ICBaseMapper;
+import java.math.*;
+import java.util.List;
+
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface DzMaterialSfMapper extends ICBaseMapper<DzMaterialSf, String> {
+    List<DzMaterialSf> getDzMaterialSf(String gbsj);
+}

+ 532 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/mapper/DzMaterialSfMapper.xml

@@ -0,0 +1,532 @@
+<?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.ems.dzmaterialsf.mapper.DzMaterialSfMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf">
+    <id column="GBSJ" jdbcType="VARCHAR" property="gbsj" />
+    <id column="CINVCCODE" jdbcType="VARCHAR" property="cinvccode" />
+    <id column="CINVCODE" jdbcType="VARCHAR" property="cinvcode" />
+    <id column="CWHCODE" jdbcType="VARCHAR" property="cwhcode" />
+    <result column="CINVCNAME" jdbcType="VARCHAR" property="cinvcname" />
+    <result column="CINVNAME" jdbcType="VARCHAR" property="cinvname" />
+    <result column="CINVSTD" jdbcType="VARCHAR" property="cinvstd" />
+    <result column="CWHNAME" jdbcType="VARCHAR" property="cwhname" />
+    <result column="MZ" jdbcType="DECIMAL" property="mz" />
+    <result column="PZ" jdbcType="DECIMAL" property="pz" />
+    <result column="JZ" jdbcType="DECIMAL" property="jz" />
+    <result column="TAB" jdbcType="VARCHAR" property="tab" />
+    <result column="CREATEMAN" jdbcType="VARCHAR" property="createman" />
+    <result column="CREATETIME" jdbcType="VARCHAR" property="createtime" />
+    <result column="UPDATEMAN" jdbcType="VARCHAR" property="updateman" />
+    <result column="UPDATETIME" jdbcType="VARCHAR" property="updatetime" />
+    <result column="READTIME" jdbcType="VARCHAR" property="readtime" />
+  </resultMap>
+  <sql id="columns">
+    GBSJ, CINVCCODE, CINVCODE, CWHCODE, CINVCNAME, CINVNAME, CINVSTD, CWHNAME, MZ, PZ, 
+    JZ, TAB, CREATEMAN, CREATETIME, UPDATEMAN, UPDATETIME, READTIME
+  </sql>
+  <sql id="columns_alias">
+    t.GBSJ, t.CINVCCODE, t.CINVCODE, t.CWHCODE, t.CINVCNAME, t.CINVNAME, t.CINVSTD, t.CWHNAME, 
+    t.MZ, t.PZ, t.JZ, t.TAB, t.CREATEMAN, t.CREATETIME, t.UPDATEMAN, t.UPDATETIME, t.READTIME
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM DZ_MATERIAL_SF
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM DZ_MATERIAL_SF t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="gbsj != null and gbsj != ''">
+        and GBSJ = #{gbsj}
+      </if>
+      <if test="cinvccode != null and cinvccode != ''">
+        and CINVCCODE = #{cinvccode}
+      </if>
+      <if test="cinvcode != null and cinvcode != ''">
+        and CINVCODE = #{cinvcode}
+      </if>
+      <if test="cwhcode != null and cwhcode != ''">
+        and CWHCODE = #{cwhcode}
+      </if>
+      <if test="cinvcname != null and cinvcname != ''">
+        and CINVCNAME = #{cinvcname}
+      </if>
+      <if test="cinvname != null and cinvname != ''">
+        and CINVNAME = #{cinvname}
+      </if>
+      <if test="cinvstd != null and cinvstd != ''">
+        and CINVSTD = #{cinvstd}
+      </if>
+      <if test="cwhname != null and cwhname != ''">
+        and CWHNAME = #{cwhname}
+      </if>
+      <if test="mz != null">
+        and MZ = #{mz}
+      </if>
+      <if test="pz != null">
+        and PZ = #{pz}
+      </if>
+      <if test="jz != null">
+        and JZ = #{jz}
+      </if>
+      <if test="tab != null and tab != ''">
+        and TAB = #{tab}
+      </if>
+      <if test="createman != null and createman != ''">
+        and CREATEMAN = #{createman}
+      </if>
+      <if test="createtime != null and createtime != ''">
+        and CREATETIME = #{createtime}
+      </if>
+      <if test="updateman != null and updateman != ''">
+        and UPDATEMAN = #{updateman}
+      </if>
+      <if test="updatetime != null and updatetime != ''">
+        and UPDATETIME = #{updatetime}
+      </if>
+      <if test="readtime != null and readtime != ''">
+        and READTIME = #{readtime}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="gbsj != null and gbsj != ''">
+        and GBSJ LIKE '%${gbsj}%'
+      </if>
+      <if test="cinvccode != null and cinvccode != ''">
+        and CINVCCODE LIKE '%${cinvccode}%'
+      </if>
+      <if test="cinvcode != null and cinvcode != ''">
+        and CINVCODE LIKE '%${cinvcode}%'
+      </if>
+      <if test="cwhcode != null and cwhcode != ''">
+        and CWHCODE LIKE '%${cwhcode}%'
+      </if>
+      <if test="cinvcname != null and cinvcname != ''">
+        and CINVCNAME LIKE '%${cinvcname}%'
+      </if>
+      <if test="cinvname != null and cinvname != ''">
+        and CINVNAME LIKE '%${cinvname}%'
+      </if>
+      <if test="cinvstd != null and cinvstd != ''">
+        and CINVSTD LIKE '%${cinvstd}%'
+      </if>
+      <if test="cwhname != null and cwhname != ''">
+        and CWHNAME LIKE '%${cwhname}%'
+      </if>
+      <if test="mz != null">
+        and MZ = #{mz}
+      </if>
+      <if test="pz != null">
+        and PZ = #{pz}
+      </if>
+      <if test="jz != null">
+        and JZ = #{jz}
+      </if>
+      <if test="tab != null and tab != ''">
+        and TAB LIKE '%${tab}%'
+      </if>
+      <if test="createman != null and createman != ''">
+        and CREATEMAN LIKE '%${createman}%'
+      </if>
+      <if test="createtime != null and createtime != ''">
+        and CREATETIME LIKE '%${createtime}%'
+      </if>
+      <if test="updateman != null and updateman != ''">
+        and UPDATEMAN LIKE '%${updateman}%'
+      </if>
+      <if test="updatetime != null and updatetime != ''">
+        and UPDATETIME LIKE '%${updatetime}%'
+      </if>
+      <if test="readtime != null and readtime != ''">
+        and READTIME LIKE '%${readtime}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="map">
+    delete from DZ_MATERIAL_SF
+    where GBSJ = #{gbsj,jdbcType=VARCHAR}
+      and CINVCCODE = #{cinvccode,jdbcType=VARCHAR}
+      and CINVCODE = #{cinvcode,jdbcType=VARCHAR}
+      and CWHCODE = #{cwhcode,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from DZ_MATERIAL_SF
+    where 1!=1 
+      <if test="cinvccode != null and cinvccode != ''">
+        or CINVCCODE = #{cinvccode}
+      </if>
+      <if test="cinvcode != null and cinvcode != ''">
+        or CINVCODE = #{cinvcode}
+      </if>
+      <if test="cwhcode != null and cwhcode != ''">
+        or CWHCODE = #{cwhcode}
+      </if>
+      <if test="cinvcname != null and cinvcname != ''">
+        or CINVCNAME = #{cinvcname}
+      </if>
+      <if test="cinvname != null and cinvname != ''">
+        or CINVNAME = #{cinvname}
+      </if>
+      <if test="cinvstd != null and cinvstd != ''">
+        or CINVSTD = #{cinvstd}
+      </if>
+      <if test="cwhname != null and cwhname != ''">
+        or CWHNAME = #{cwhname}
+      </if>
+      <if test="mz != null">
+        or MZ = #{mz}
+      </if>
+      <if test="pz != null">
+        or PZ = #{pz}
+      </if>
+      <if test="jz != null">
+        or JZ = #{jz}
+      </if>
+      <if test="tab != null and tab != ''">
+        or TAB = #{tab}
+      </if>
+      <if test="createman != null and createman != ''">
+        or CREATEMAN = #{createman}
+      </if>
+      <if test="createtime != null and createtime != ''">
+        or CREATETIME = #{createtime}
+      </if>
+      <if test="updateman != null and updateman != ''">
+        or UPDATEMAN = #{updateman}
+      </if>
+      <if test="updatetime != null and updatetime != ''">
+        or UPDATETIME = #{updatetime}
+      </if>
+      <if test="readtime != null and readtime != ''">
+        or READTIME = #{readtime}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf">
+    insert into DZ_MATERIAL_SF (GBSJ, CINVCCODE, CINVCODE, 
+      CWHCODE, CINVCNAME, CINVNAME, 
+      CINVSTD, CWHNAME, MZ, 
+      PZ, JZ, TAB, CREATEMAN, 
+      CREATETIME, UPDATEMAN, UPDATETIME, 
+      READTIME)
+    values (#{gbsj,jdbcType=VARCHAR}, #{cinvccode,jdbcType=VARCHAR}, #{cinvcode,jdbcType=VARCHAR}, 
+      #{cwhcode,jdbcType=VARCHAR}, #{cinvcname,jdbcType=VARCHAR}, #{cinvname,jdbcType=VARCHAR}, 
+      #{cinvstd,jdbcType=VARCHAR}, #{cwhname,jdbcType=VARCHAR}, #{mz,jdbcType=DECIMAL}, 
+      #{pz,jdbcType=DECIMAL}, #{jz,jdbcType=DECIMAL}, #{tab,jdbcType=VARCHAR}, #{createman,jdbcType=VARCHAR}, 
+      #{createtime,jdbcType=VARCHAR}, #{updateman,jdbcType=VARCHAR}, #{updatetime,jdbcType=VARCHAR}, 
+      #{readtime,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf">
+    insert into DZ_MATERIAL_SF
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="gbsj != null">
+        GBSJ,
+      </if>
+      <if test="cinvccode != null">
+        CINVCCODE,
+      </if>
+      <if test="cinvcode != null">
+        CINVCODE,
+      </if>
+      <if test="cwhcode != null">
+        CWHCODE,
+      </if>
+      <if test="cinvcname != null">
+        CINVCNAME,
+      </if>
+      <if test="cinvname != null">
+        CINVNAME,
+      </if>
+      <if test="cinvstd != null">
+        CINVSTD,
+      </if>
+      <if test="cwhname != null">
+        CWHNAME,
+      </if>
+      <if test="mz != null">
+        MZ,
+      </if>
+      <if test="pz != null">
+        PZ,
+      </if>
+      <if test="jz != null">
+        JZ,
+      </if>
+      <if test="tab != null">
+        TAB,
+      </if>
+      <if test="createman != null">
+        CREATEMAN,
+      </if>
+      <if test="createtime != null">
+        CREATETIME,
+      </if>
+      <if test="updateman != null">
+        UPDATEMAN,
+      </if>
+      <if test="updatetime != null">
+        UPDATETIME,
+      </if>
+      <if test="readtime != null">
+        READTIME,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="gbsj != null">
+        #{gbsj,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvccode != null">
+        #{cinvccode,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvcode != null">
+        #{cinvcode,jdbcType=VARCHAR},
+      </if>
+      <if test="cwhcode != null">
+        #{cwhcode,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvcname != null">
+        #{cinvcname,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvname != null">
+        #{cinvname,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvstd != null">
+        #{cinvstd,jdbcType=VARCHAR},
+      </if>
+      <if test="cwhname != null">
+        #{cwhname,jdbcType=VARCHAR},
+      </if>
+      <if test="mz != null">
+        #{mz,jdbcType=DECIMAL},
+      </if>
+      <if test="pz != null">
+        #{pz,jdbcType=DECIMAL},
+      </if>
+      <if test="jz != null">
+        #{jz,jdbcType=DECIMAL},
+      </if>
+      <if test="tab != null">
+        #{tab,jdbcType=VARCHAR},
+      </if>
+      <if test="createman != null">
+        #{createman,jdbcType=VARCHAR},
+      </if>
+      <if test="createtime != null">
+        #{createtime,jdbcType=VARCHAR},
+      </if>
+      <if test="updateman != null">
+        #{updateman,jdbcType=VARCHAR},
+      </if>
+      <if test="updatetime != null">
+        #{updatetime,jdbcType=VARCHAR},
+      </if>
+      <if test="readtime != null">
+        #{readtime,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf">
+    update DZ_MATERIAL_SF
+    set CINVCNAME = #{cinvcname,jdbcType=VARCHAR},
+      CINVNAME = #{cinvname,jdbcType=VARCHAR},
+      CINVSTD = #{cinvstd,jdbcType=VARCHAR},
+      CWHNAME = #{cwhname,jdbcType=VARCHAR},
+      MZ = #{mz,jdbcType=DECIMAL},
+      PZ = #{pz,jdbcType=DECIMAL},
+      JZ = #{jz,jdbcType=DECIMAL},
+      TAB = #{tab,jdbcType=VARCHAR},
+      CREATEMAN = #{createman,jdbcType=VARCHAR},
+      CREATETIME = #{createtime,jdbcType=VARCHAR},
+      UPDATEMAN = #{updateman,jdbcType=VARCHAR},
+      UPDATETIME = #{updatetime,jdbcType=VARCHAR},
+      READTIME = #{readtime,jdbcType=VARCHAR}
+    where GBSJ = #{gbsj,jdbcType=VARCHAR}
+      and CINVCCODE = #{cinvccode,jdbcType=VARCHAR}
+      and CINVCODE = #{cinvcode,jdbcType=VARCHAR}
+      and CWHCODE = #{cwhcode,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf">
+    update DZ_MATERIAL_SF
+    <set>
+      <if test="cinvcname != null">
+        CINVCNAME = #{cinvcname,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvname != null">
+        CINVNAME = #{cinvname,jdbcType=VARCHAR},
+      </if>
+      <if test="cinvstd != null">
+        CINVSTD = #{cinvstd,jdbcType=VARCHAR},
+      </if>
+      <if test="cwhname != null">
+        CWHNAME = #{cwhname,jdbcType=VARCHAR},
+      </if>
+      <if test="mz != null">
+        MZ = #{mz,jdbcType=DECIMAL},
+      </if>
+      <if test="pz != null">
+        PZ = #{pz,jdbcType=DECIMAL},
+      </if>
+      <if test="jz != null">
+        JZ = #{jz,jdbcType=DECIMAL},
+      </if>
+      <if test="tab != null">
+        TAB = #{tab,jdbcType=VARCHAR},
+      </if>
+      <if test="createman != null">
+        CREATEMAN = #{createman,jdbcType=VARCHAR},
+      </if>
+      <if test="createtime != null">
+        CREATETIME = #{createtime,jdbcType=VARCHAR},
+      </if>
+      <if test="updateman != null">
+        UPDATEMAN = #{updateman,jdbcType=VARCHAR},
+      </if>
+      <if test="updatetime != null">
+        UPDATETIME = #{updatetime,jdbcType=VARCHAR},
+      </if>
+      <if test="readtime != null">
+        READTIME = #{readtime,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where GBSJ = #{gbsj,jdbcType=VARCHAR}
+      and CINVCCODE = #{cinvccode,jdbcType=VARCHAR}
+      and CINVCODE = #{cinvcode,jdbcType=VARCHAR}
+      and CWHCODE = #{cwhcode,jdbcType=VARCHAR}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="map" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where GBSJ = #{gbsj,jdbcType=VARCHAR}
+      and CINVCCODE = #{cinvccode,jdbcType=VARCHAR}
+      and CINVCODE = #{cinvcode,jdbcType=VARCHAR}
+      and CWHCODE = #{cwhcode,jdbcType=VARCHAR}
+      and TAB = #{tab,jdbcType=VARCHAR}
+  </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 DZ_MATERIAL_SF 
+      (GBSJ, 
+      CINVCCODE, CINVCODE, CWHCODE, 
+      CINVCNAME, CINVNAME, CINVSTD, 
+      CWHNAME, MZ, PZ, 
+      JZ, TAB, CREATEMAN, 
+      CREATETIME, UPDATEMAN, UPDATETIME, 
+      READTIME)
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.gbsj,jdbcType=VARCHAR}, 
+      #{item.cinvccode,jdbcType=VARCHAR}, #{item.cinvcode,jdbcType=VARCHAR}, #{item.cwhcode,jdbcType=VARCHAR}, 
+      #{item.cinvcname,jdbcType=VARCHAR}, #{item.cinvname,jdbcType=VARCHAR}, #{item.cinvstd,jdbcType=VARCHAR}, 
+      #{item.cwhname,jdbcType=VARCHAR}, #{item.mz,jdbcType=DECIMAL}, #{item.pz,jdbcType=DECIMAL}, 
+      #{item.jz,jdbcType=DECIMAL}, #{item.tab,jdbcType=VARCHAR}, #{item.createman,jdbcType=VARCHAR}, 
+      #{item.createtime,jdbcType=VARCHAR}, #{item.updateman,jdbcType=VARCHAR}, #{item.updatetime,jdbcType=VARCHAR}, 
+      #{item.readtime,jdbcType=VARCHAR} from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update DZ_MATERIAL_SF
+     set
+       GBSJ=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.gbsj,jdbcType=VARCHAR}
+       </foreach>
+       ,CINVCCODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cinvccode,jdbcType=VARCHAR}
+       </foreach>
+       ,CINVCODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cinvcode,jdbcType=VARCHAR}
+       </foreach>
+       ,CWHCODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cwhcode,jdbcType=VARCHAR}
+       </foreach>
+       ,CINVCNAME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cinvcname,jdbcType=VARCHAR}
+       </foreach>
+       ,CINVNAME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cinvname,jdbcType=VARCHAR}
+       </foreach>
+       ,CINVSTD=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cinvstd,jdbcType=VARCHAR}
+       </foreach>
+       ,CWHNAME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.cwhname,jdbcType=VARCHAR}
+       </foreach>
+       ,MZ=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.mz,jdbcType=DECIMAL}
+       </foreach>
+       ,PZ=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.pz,jdbcType=DECIMAL}
+       </foreach>
+       ,JZ=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.jz,jdbcType=DECIMAL}
+       </foreach>
+       ,TAB=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.tab,jdbcType=VARCHAR}
+       </foreach>
+       ,CREATEMAN=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.createman,jdbcType=VARCHAR}
+       </foreach>
+       ,CREATETIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.createtime,jdbcType=VARCHAR}
+       </foreach>
+       ,UPDATEMAN=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.updateman,jdbcType=VARCHAR}
+       </foreach>
+       ,UPDATETIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.updatetime,jdbcType=VARCHAR}
+       </foreach>
+       ,READTIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case GBSJ" close="end">
+          when #{item.gbsj,jdbcType=VARCHAR} then #{item.readtime,jdbcType=VARCHAR}
+       </foreach>
+    where (GBSJ,CINVCCODE,CINVCODE,CWHCODE) in
+    <foreach collection="list" item="item" open="(" close=")" separator=",">
+     (#{item.gbsj, jdbcType=VARCHAR},#{item.cinvccode, jdbcType=VARCHAR},#{item.cinvcode, jdbcType=VARCHAR},#{item.cwhcode, jdbcType=VARCHAR})
+    </foreach>
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from DZ_MATERIAL_SF
+    where (GBSJ,CINVCCODE,CINVCODE,CWHCODE) in
+    <foreach collection="list" item="item" open="(" close=")" separator=",">
+     ( #{item.gbsj, jdbcType=VARCHAR}, #{item.cinvccode, jdbcType=VARCHAR}, #{item.cinvcode, jdbcType=VARCHAR}, #{item.cwhcode, jdbcType=VARCHAR})
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+  <select id="getDzMaterialSf" resultMap="BaseResultMap" parameterType="java.lang.String" >
+    select * from (
+    SELECT CONVERT(varchar(100), gbsj, 23) as gbsj, cInvCCode, cInvCName, cInvCode, cInvName,
+    cInvStd, cWhCode, cWhName, sum(mz) as mz, sum(pz) as pz, sum(jz) as jz, 'sh' as tab
+    FROM v_nyjk_sh where gbsj >= #{gbsj,jdbcType=VARCHAR} and
+    cInvCName in('合金材料','国内矿粉','过滤材料','进口矿粉','原煤','外购精煤','国内球团','高炉干渣','进口块矿','石料')
+    group by cInvCCode, cInvCName, cInvCode, cInvName, cInvStd, cWhCode, cWhName, CONVERT(varchar(100), gbsj, 23)
+    ) as sh union all (
+    SELECT CONVERT(varchar(100), gbsj, 23) as gbsj, cInvCCode, cInvCName, cInvCode, cInvName,
+    cInvStd, cWhCode, cWhName, sum(mz) as mz, sum(pz) as pz, sum(jz) as jz, 'fh' as tab
+    FROM v_nyjk_fh where gbsj >= #{gbsj,jdbcType=VARCHAR} and
+    cInvCName in('合金材料','国内矿粉','过滤材料','进口矿粉','原煤','外购精煤','国内球团','高炉干渣','进口块矿','石料')
+    group by cInvCCode, cInvCName, cInvCode, cInvName, cInvStd, cWhCode, cWhName, CONVERT(varchar(100), [gbsj], 23))
+  </select>
+</mapper>

+ 299 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/model/DzMaterialSf.java

@@ -0,0 +1,299 @@
+package com.steerinfo.ems.dzmaterialsf.model;
+
+import com.steerinfo.framework.model.ICBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.math.BigDecimal;
+import java.util.HashMap;
+import java.util.Map;
+
+@ApiModel(value="大宗物料数据表")
+public class DzMaterialSf implements ICBasePO<DzMaterialSf> {
+    /**
+     * 日期(GBSJ,VARCHAR,20)
+     */
+    @ApiModelProperty(value="日期",required=true)
+    private String gbsj;
+
+    /**
+     * 物料类型id(CINVCCODE,VARCHAR,20)
+     */
+    @ApiModelProperty(value="物料类型id",required=true)
+    private String cinvccode;
+
+    /**
+     * 物料ID(CINVCODE,VARCHAR,20)
+     */
+    @ApiModelProperty(value="物料ID",required=true)
+    private String cinvcode;
+
+    /**
+     * 物料仓库ID(CWHCODE,VARCHAR,20)
+     */
+    @ApiModelProperty(value="物料仓库ID",required=true)
+    private String cwhcode;
+
+    /**
+     * 物料类型名称(CINVCNAME,VARCHAR,20)
+     */
+    @ApiModelProperty(value="物料类型名称",required=false)
+    private String cinvcname;
+
+    /**
+     * 物料名称(CINVNAME,VARCHAR,50)
+     */
+    @ApiModelProperty(value="物料名称",required=false)
+    private String cinvname;
+
+    /**
+     * 物料规格(备注)(CINVSTD,VARCHAR,100)
+     */
+    @ApiModelProperty(value="物料规格(备注)",required=false)
+    private String cinvstd;
+
+    /**
+     * 物料仓库名称(CWHNAME,VARCHAR,100)
+     */
+    @ApiModelProperty(value="物料仓库名称",required=false)
+    private String cwhname;
+
+    /**
+     * 毛重(MZ,DECIMAL,20)
+     */
+    @ApiModelProperty(value="毛重",required=false)
+    private BigDecimal mz;
+
+    /**
+     * 皮重(PZ,DECIMAL,20)
+     */
+    @ApiModelProperty(value="皮重",required=false)
+    private BigDecimal pz;
+
+    /**
+     * 净重(JZ,DECIMAL,20)
+     */
+    @ApiModelProperty(value="净重",required=false)
+    private BigDecimal jz;
+
+    /**
+     * 表标识(TAB,VARCHAR,10)
+     */
+    @ApiModelProperty(value="表标识",required=false)
+    private String tab;
+
+    /**
+     * 创建人(CREATEMAN,VARCHAR,50)
+     */
+    @ApiModelProperty(value="创建人",required=false)
+    private String createman;
+
+    /**
+     * 创建时间(CREATETIME,VARCHAR,50)
+     */
+    @ApiModelProperty(value="创建时间",required=false)
+    private String createtime;
+
+    /**
+     * 修改人(UPDATEMAN,VARCHAR,50)
+     */
+    @ApiModelProperty(value="修改人",required=false)
+    private String updateman;
+
+    /**
+     * 修改时间(UPDATETIME,VARCHAR,50)
+     */
+    @ApiModelProperty(value="修改时间",required=false)
+    private String updatetime;
+
+    /**
+     * 读取时间(READTIME,VARCHAR,50)
+     */
+    @ApiModelProperty(value="读取时间",required=false)
+    private String readtime;
+
+    private static final long serialVersionUID = 1L;
+
+    @Override
+    public Map<String, Object> getId() {
+        Map<String, Object> params = new HashMap<>();
+        params.put("gbsj",this.gbsj);
+        params.put("cinvccode",this.cinvccode);
+        params.put("cinvcode",this.cinvcode);
+        params.put("cwhcode",this.cwhcode);
+        params.put("tab",this.tab);
+        return params;
+    }
+
+    @Override
+    public void setId(DzMaterialSf dzMaterialSf) {
+        this.gbsj = dzMaterialSf.getGbsj();
+        this.cinvccode = dzMaterialSf.getCinvccode();
+        this.cinvcode = dzMaterialSf.getCinvcode();
+        this.cwhcode = dzMaterialSf.getCwhcode();
+        this.tab = dzMaterialSf.getTab();
+    }
+
+    public String getGbsj() {
+        return gbsj;
+    }
+
+    public void setGbsj(String gbsj) {
+        this.gbsj = gbsj == null ? null : gbsj.trim();
+    }
+
+    public String getCinvccode() {
+        return cinvccode;
+    }
+
+    public void setCinvccode(String cinvccode) {
+        this.cinvccode = cinvccode == null ? null : cinvccode.trim();
+    }
+
+    public String getCinvcode() {
+        return cinvcode;
+    }
+
+    public void setCinvcode(String cinvcode) {
+        this.cinvcode = cinvcode == null ? null : cinvcode.trim();
+    }
+
+    public String getCwhcode() {
+        return cwhcode;
+    }
+
+    public void setCwhcode(String cwhcode) {
+        this.cwhcode = cwhcode == null ? null : cwhcode.trim();
+    }
+
+    public String getCinvcname() {
+        return cinvcname;
+    }
+
+    public void setCinvcname(String cinvcname) {
+        this.cinvcname = cinvcname == null ? null : cinvcname.trim();
+    }
+
+    public String getCinvname() {
+        return cinvname;
+    }
+
+    public void setCinvname(String cinvname) {
+        this.cinvname = cinvname == null ? null : cinvname.trim();
+    }
+
+    public String getCinvstd() {
+        return cinvstd;
+    }
+
+    public void setCinvstd(String cinvstd) {
+        this.cinvstd = cinvstd == null ? null : cinvstd.trim();
+    }
+
+    public String getCwhname() {
+        return cwhname;
+    }
+
+    public void setCwhname(String cwhname) {
+        this.cwhname = cwhname == null ? null : cwhname.trim();
+    }
+
+    public BigDecimal getMz() {
+        return mz;
+    }
+
+    public void setMz(BigDecimal mz) {
+        this.mz = mz;
+    }
+
+    public BigDecimal getPz() {
+        return pz;
+    }
+
+    public void setPz(BigDecimal pz) {
+        this.pz = pz;
+    }
+
+    public BigDecimal getJz() {
+        return jz;
+    }
+
+    public void setJz(BigDecimal jz) {
+        this.jz = jz;
+    }
+
+    public String getTab() {
+        return tab;
+    }
+
+    public void setTab(String tab) {
+        this.tab = tab == null ? null : tab.trim();
+    }
+
+    public String getCreateman() {
+        return createman;
+    }
+
+    public void setCreateman(String createman) {
+        this.createman = createman == null ? null : createman.trim();
+    }
+
+    public String getCreatetime() {
+        return createtime;
+    }
+
+    public void setCreatetime(String createtime) {
+        this.createtime = createtime == null ? null : createtime.trim();
+    }
+
+    public String getUpdateman() {
+        return updateman;
+    }
+
+    public void setUpdateman(String updateman) {
+        this.updateman = updateman == null ? null : updateman.trim();
+    }
+
+    public String getUpdatetime() {
+        return updatetime;
+    }
+
+    public void setUpdatetime(String updatetime) {
+        this.updatetime = updatetime == null ? null : updatetime.trim();
+    }
+
+    public String getReadtime() {
+        return readtime;
+    }
+
+    public void setReadtime(String readtime) {
+        this.readtime = readtime == null ? null : readtime.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", gbsj=").append(gbsj);
+        sb.append(", cinvccode=").append(cinvccode);
+        sb.append(", cinvcode=").append(cinvcode);
+        sb.append(", cwhcode=").append(cwhcode);
+        sb.append(", cinvcname=").append(cinvcname);
+        sb.append(", cinvname=").append(cinvname);
+        sb.append(", cinvstd=").append(cinvstd);
+        sb.append(", cwhname=").append(cwhname);
+        sb.append(", mz=").append(mz);
+        sb.append(", pz=").append(pz);
+        sb.append(", jz=").append(jz);
+        sb.append(", tab=").append(tab);
+        sb.append(", createman=").append(createman);
+        sb.append(", createtime=").append(createtime);
+        sb.append(", updateman=").append(updateman);
+        sb.append(", updatetime=").append(updatetime);
+        sb.append(", readtime=").append(readtime);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 21 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/service/DzMaterialSFDBServer.java

@@ -0,0 +1,21 @@
+package com.steerinfo.ems.dzmaterialsf.service;
+
+import com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf;
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.stereotype.Component;
+import org.springframework.web.bind.annotation.GetMapping;
+
+import java.util.List;
+
+/**
+ * @author Shadow
+ * @create 2021-10-15 18:11
+ * @project xt-ems-api-new
+ */
+@FeignClient(value = "xt-ems-datasource")
+@Component
+public interface DzMaterialSFDBServer {
+
+    @GetMapping("v1/dematerialSfDb/getDzMaterialSf")
+    public List<DzMaterialSf> getDzMaterialSf();
+}

+ 24 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/service/IDzMaterialSfService.java

@@ -0,0 +1,24 @@
+package com.steerinfo.ems.dzmaterialsf.service;
+
+import com.steerinfo.framework.service.ICBaseService;
+import com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf;
+import java.util.Date;
+import java.math.BigDecimal;
+
+/**
+ * DzMaterialSf服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-16 08:57
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-16
+ * 作者:generator
+ * 参考:
+ * 描述:DzMaterialSf服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IDzMaterialSfService extends ICBaseService<DzMaterialSf, String>{
+
+    int dataGeneration();
+}

+ 86 - 0
src/main/java/com/steerinfo/ems/dzmaterialsf/service/impl/DzMaterialSfServiceImpl.java

@@ -0,0 +1,86 @@
+package com.steerinfo.ems.dzmaterialsf.service.impl;
+
+import com.steerinfo.ems.Utils.DateUtils;
+import com.steerinfo.ems.dzmaterialsf.mapper.DzMaterialSfMapper;
+import com.steerinfo.ems.dzmaterialsf.model.DzMaterialSf;
+import com.steerinfo.ems.dzmaterialsf.service.DzMaterialSFDBServer;
+import com.steerinfo.ems.dzmaterialsf.service.IDzMaterialSfService;
+import com.steerinfo.framework.mapper.ICBaseMapper;
+import com.steerinfo.framework.service.impl.CBaseServiceImpl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * DzMaterialSf服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-16 08:57
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-16
+ * 作者:generator
+ * 参考:
+ * 描述:DzMaterialSf服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "dzMaterialSfService")
+public class DzMaterialSfServiceImpl extends CBaseServiceImpl<DzMaterialSf, String> implements IDzMaterialSfService {
+
+    private static final Logger logger = LoggerFactory.getLogger(DzMaterialSfServiceImpl.class);
+
+    @Autowired
+    private DzMaterialSfMapper dzMaterialSfMapper;
+
+    @Autowired
+    private DzMaterialSFDBServer dzMaterialSFDBServer;
+
+    @Override
+    protected ICBaseMapper<DzMaterialSf, String> getMapper() {
+        return dzMaterialSfMapper;
+    }
+
+    @Override
+    public int dataGeneration() {
+        int addSize = 0;
+        int updateSize = 0;
+        try {
+            List<DzMaterialSf> dzMaterialSfList = dzMaterialSFDBServer.getDzMaterialSf();
+            //List<DzMaterialSf> models;
+            DzMaterialSf model;
+            HashMap<String, Object> hashMap = new HashMap<>();
+            for (DzMaterialSf dzMaterialSf : dzMaterialSfList){
+                dzMaterialSf.setReadtime(DateUtils.dateStr(new Date(),"yyyy-MM-dd HH:mm:ss"));
+                hashMap.put("gbsj",dzMaterialSf.getGbsj());
+                hashMap.put("cinvccode",dzMaterialSf.getCinvccode());
+                hashMap.put("cinvcode",dzMaterialSf.getCinvcode());
+                hashMap.put("cwhcode",dzMaterialSf.getCwhcode());
+                hashMap.put("tab",dzMaterialSf.getTab());
+                //model = dzMaterialSfMapper.selectByParameters(hashMap);
+                model = dzMaterialSfMapper.selectByPrimaryKey(dzMaterialSf);
+                if(model != null){
+                    dzMaterialSf.setUpdateman("系统");
+                    dzMaterialSf.setUpdatetime(DateUtils.dateStr(new Date(),"yyyy-MM-dd HH:mm:ss"));
+                    dzMaterialSfMapper.updateByPrimaryKey(dzMaterialSf);
+                    updateSize+=1;
+                    continue;
+                }else {
+                    dzMaterialSf.setCreateman("系统");
+                    dzMaterialSf.setCreatetime(DateUtils.dateStr(new Date(),"yyyy-MM-dd HH:mm:ss"));
+                    addSize+= dzMaterialSfMapper.insert(dzMaterialSf);
+                }
+            }
+        } catch (Exception e) {
+            e.printStackTrace();
+        } finally {
+            logger.info("本次总共新增大宗物料收发数据条数:" + addSize);
+            logger.info("本次总共更新大宗物料收发数据条数:" + updateSize);
+        }
+        return addSize+updateSize;
+    }
+}

+ 115 - 0
src/main/java/com/steerinfo/ems/emscalorificvalue/controller/EmsCalorificValueController.java

@@ -0,0 +1,115 @@
+package com.steerinfo.ems.emscalorificvalue.controller;
+
+import com.steerinfo.ems.emscalorificvalue.mapper.EmsCalorificValueMapper;
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue;
+import com.steerinfo.ems.emscalorificvalue.service.IEmsCalorificValueService;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.ArrayList;
+import java.math.BigDecimal;
+
+/**
+ * EmsCalorificValue RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 08:22
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:EmsCalorificValue RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/emscalorificvalues")
+public class EmsCalorificValueController extends BaseRESTfulController {
+
+    @Autowired
+    IEmsCalorificValueService emsCalorificValueService;
+    @Autowired
+    EmsCalorificValueMapper emsCalorificValueMapper;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("emscalorificvalue:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<EmsCalorificValue> list = emsCalorificValueService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("emscalorificvalue:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<EmsCalorificValue> list = emsCalorificValueService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据EmsCalorificValue对象创建")
+    @ApiImplicitParam(name = "emsCalorificValue", value = "详细实体emsCalorificValue", required = true, dataType = "EmsCalorificValue")
+    //@RequiresPermissions("emscalorificvalue:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@RequestBody EmsCalorificValue[] model){
+        for (EmsCalorificValue emsCalorificValue : model) {
+            emsCalorificValueMapper.insert(emsCalorificValue);
+        }
+         return success();
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("emscalorificvalue:view")
+    @GetMapping(value = "/{id}")
+    public RESTfulResult get(@PathVariable String id){
+        EmsCalorificValue emsCalorificValue = emsCalorificValueService.getById(id);
+        return success(emsCalorificValue);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的emsCalorificValue信息来更新详细信息")
+    @ApiImplicitParams({
+        @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String"),
+        @ApiImplicitParam(name = "emsCalorificValue", value = "详细实体emsCalorificValue", required = true, dataType = "EmsCalorificValue")
+    })
+    //@RequiresPermissions("emscalorificvalue:update")
+    @PutMapping(value = "/{id}", produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update(@PathVariable String id, @RequestBody EmsCalorificValue model){
+        model.setId(id);
+        EmsCalorificValue emsCalorificValue = emsCalorificValueService.modify(model);
+        return success(emsCalorificValue);
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("emscalorificvalue:delete")
+    @DeleteMapping(value = "/{id}")//String
+    public RESTfulResult delete(@PathVariable String id){
+    	List<String> list = Arrays.asList(id.split(","));
+    	if(ListUtils.isNotEmpty(list)) {
+	    	List<String> ids = ListUtils.convertList(list);
+			  emsCalorificValueService.delete(ids);
+    	}
+      return success();
+    }
+}

+ 17 - 0
src/main/java/com/steerinfo/ems/emscalorificvalue/mapper/EmsCalorificValueMapper.java

@@ -0,0 +1,17 @@
+package com.steerinfo.ems.emscalorificvalue.mapper;
+
+import com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import java.math.*;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface EmsCalorificValueMapper extends IBaseMapper<EmsCalorificValue, String> {
+    public List<EmsCalorificValue> getNewDate();
+    //获取每个能介的检验值
+    public String getValue(HashMap<String,Object> hashMap);
+}

+ 589 - 0
src/main/java/com/steerinfo/ems/emscalorificvalue/mapper/EmsCalorificValueMapper.xml

@@ -0,0 +1,589 @@
+<?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.ems.emscalorificvalue.mapper.EmsCalorificValueMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue">
+    <id column="WTBH" jdbcType="VARCHAR" property="wtbh" />
+    <result column="SAMPLETYPE" jdbcType="VARCHAR" property="sampletype" />
+    <result column="MATERIALNO" jdbcType="VARCHAR" property="materialno" />
+    <result column="MATERIALNAME" jdbcType="VARCHAR" property="materialname" />
+    <result column="MATERIALSOURCE" jdbcType="VARCHAR" property="materialsource" />
+    <result column="SAMPLETIME" jdbcType="TIMESTAMP" property="sampletime" />
+    <result column="SAMPLEPERSON" jdbcType="VARCHAR" property="sampleperson" />
+    <result column="SENDTIME" jdbcType="TIMESTAMP" property="sendtime" />
+    <result column="SENDER" jdbcType="VARCHAR" property="sender" />
+    <result column="JUDGERESULT" jdbcType="VARCHAR" property="judgeresult" />
+    <result column="JUDGETIME" jdbcType="TIMESTAMP" property="judgetime" />
+    <result column="MEMO" jdbcType="VARCHAR" property="memo" />
+    <result column="SAMPLENO" jdbcType="VARCHAR" property="sampleno" />
+    <result column="ITEMCODE" jdbcType="VARCHAR" property="itemcode" />
+    <result column="ITEM" jdbcType="VARCHAR" property="item" />
+    <result column="TESTRESULT" jdbcType="VARCHAR" property="testresult" />
+    <result column="ITEMJUDGERESULT" jdbcType="VARCHAR" property="itemjudgeresult" />
+    <result column="RECORDER" jdbcType="VARCHAR" property="recorder" />
+    <result column="INPUTTIME" jdbcType="TIMESTAMP" property="inputtime" />
+  </resultMap>
+  <sql id="columns">
+    WTBH, SAMPLETYPE, MATERIALNO, MATERIALNAME, MATERIALSOURCE, SAMPLETIME, SAMPLEPERSON, 
+    SENDTIME, SENDER, JUDGERESULT, JUDGETIME, MEMO, SAMPLENO, ITEMCODE, ITEM, TESTRESULT, 
+    ITEMJUDGERESULT, RECORDER, INPUTTIME
+  </sql>
+  <sql id="columns_alias">
+    t.WTBH, t.SAMPLETYPE, t.MATERIALNO, t.MATERIALNAME, t.MATERIALSOURCE, t.SAMPLETIME, 
+    t.SAMPLEPERSON, t.SENDTIME, t.SENDER, t.JUDGERESULT, t.JUDGETIME, t.MEMO, t.SAMPLENO, 
+    t.ITEMCODE, t.ITEM, t.TESTRESULT, t.ITEMJUDGERESULT, t.RECORDER, t.INPUTTIME
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM EMS_CALORIFIC_VALUE
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM EMS_CALORIFIC_VALUE t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="wtbh != null and wtbh != ''">
+        and WTBH = #{wtbh}
+      </if>
+      <if test="sampletype != null and sampletype != ''">
+        and SAMPLETYPE = #{sampletype}
+      </if>
+      <if test="materialno != null and materialno != ''">
+        and MATERIALNO = #{materialno}
+      </if>
+      <if test="materialname != null and materialname != ''">
+        and MATERIALNAME = #{materialname}
+      </if>
+      <if test="materialsource != null and materialsource != ''">
+        and MATERIALSOURCE = #{materialsource}
+      </if>
+      <if test="sampletime != null">
+        and TO_CHAR(SAMPLETIME,'yyyy-MM-dd') = #{sampletime}
+      </if>
+      <if test="sampleperson != null and sampleperson != ''">
+        and SAMPLEPERSON = #{sampleperson}
+      </if>
+      <if test="sendtime != null">
+        and TO_CHAR(SENDTIME,'yyyy-MM-dd') = #{sendtime}
+      </if>
+      <if test="sender != null and sender != ''">
+        and SENDER = #{sender}
+      </if>
+      <if test="judgeresult != null and judgeresult != ''">
+        and JUDGERESULT = #{judgeresult}
+      </if>
+      <if test="judgetime != null">
+        and TO_CHAR(JUDGETIME,'yyyy-MM-dd') = #{judgetime}
+      </if>
+      <if test="memo != null and memo != ''">
+        and MEMO = #{memo}
+      </if>
+      <if test="sampleno != null and sampleno != ''">
+        and SAMPLENO = #{sampleno}
+      </if>
+      <if test="itemcode != null and itemcode != ''">
+        and ITEMCODE = #{itemcode}
+      </if>
+      <if test="item != null and item != ''">
+        and ITEM = #{item}
+      </if>
+      <if test="testresult != null and testresult != ''">
+        and TESTRESULT = #{testresult}
+      </if>
+      <if test="itemjudgeresult != null and itemjudgeresult != ''">
+        and ITEMJUDGERESULT = #{itemjudgeresult}
+      </if>
+      <if test="recorder != null and recorder != ''">
+        and RECORDER = #{recorder}
+      </if>
+      <if test="inputtime != null">
+        and TO_CHAR(INPUTTIME,'yyyy-MM-dd') = #{inputtime}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="wtbh != null and wtbh != ''">
+        and WTBH LIKE '%${wtbh}%'
+      </if>
+      <if test="sampletype != null and sampletype != ''">
+        and SAMPLETYPE LIKE '%${sampletype}%'
+      </if>
+      <if test="materialno != null and materialno != ''">
+        and MATERIALNO LIKE '%${materialno}%'
+      </if>
+      <if test="materialname != null and materialname != ''">
+        and MATERIALNAME LIKE '%${materialname}%'
+      </if>
+      <if test="materialsource != null and materialsource != ''">
+        and MATERIALSOURCE LIKE '%${materialsource}%'
+      </if>
+      <if test="sampletime != null">
+        and TO_CHAR(SAMPLETIME,'yyyy-MM-dd') = #{sampletime}
+      </if>
+      <if test="sampleperson != null and sampleperson != ''">
+        and SAMPLEPERSON LIKE '%${sampleperson}%'
+      </if>
+      <if test="sendtime != null">
+        and TO_CHAR(SENDTIME,'yyyy-MM-dd') = #{sendtime}
+      </if>
+      <if test="sender != null and sender != ''">
+        and SENDER LIKE '%${sender}%'
+      </if>
+      <if test="judgeresult != null and judgeresult != ''">
+        and JUDGERESULT LIKE '%${judgeresult}%'
+      </if>
+      <if test="judgetime != null">
+        and TO_CHAR(JUDGETIME,'yyyy-MM-dd') = #{judgetime}
+      </if>
+      <if test="memo != null and memo != ''">
+        and MEMO LIKE '%${memo}%'
+      </if>
+      <if test="sampleno != null and sampleno != ''">
+        and SAMPLENO LIKE '%${sampleno}%'
+      </if>
+      <if test="itemcode != null and itemcode != ''">
+        and ITEMCODE LIKE '%${itemcode}%'
+      </if>
+      <if test="item != null and item != ''">
+        and ITEM LIKE '%${item}%'
+      </if>
+      <if test="testresult != null and testresult != ''">
+        and TESTRESULT LIKE '%${testresult}%'
+      </if>
+      <if test="itemjudgeresult != null and itemjudgeresult != ''">
+        and ITEMJUDGERESULT LIKE '%${itemjudgeresult}%'
+      </if>
+      <if test="recorder != null and recorder != ''">
+        and RECORDER LIKE '%${recorder}%'
+      </if>
+      <if test="inputtime != null">
+        and TO_CHAR(INPUTTIME,'yyyy-MM-dd') = #{inputtime}
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from EMS_CALORIFIC_VALUE
+    where WTBH = #{wtbh,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from EMS_CALORIFIC_VALUE
+    where 1!=1 
+      <if test="sampletype != null and sampletype != ''">
+        or SAMPLETYPE = #{sampletype}
+      </if>
+      <if test="materialno != null and materialno != ''">
+        or MATERIALNO = #{materialno}
+      </if>
+      <if test="materialname != null and materialname != ''">
+        or MATERIALNAME = #{materialname}
+      </if>
+      <if test="materialsource != null and materialsource != ''">
+        or MATERIALSOURCE = #{materialsource}
+      </if>
+      <if test="sampletime != null">
+        or TO_CHAR(SAMPLETIME,'yyyy-MM-dd') = '#{sampletime}'
+      </if>
+      <if test="sampleperson != null and sampleperson != ''">
+        or SAMPLEPERSON = #{sampleperson}
+      </if>
+      <if test="sendtime != null">
+        or TO_CHAR(SENDTIME,'yyyy-MM-dd') = '#{sendtime}'
+      </if>
+      <if test="sender != null and sender != ''">
+        or SENDER = #{sender}
+      </if>
+      <if test="judgeresult != null and judgeresult != ''">
+        or JUDGERESULT = #{judgeresult}
+      </if>
+      <if test="judgetime != null">
+        or TO_CHAR(JUDGETIME,'yyyy-MM-dd') = '#{judgetime}'
+      </if>
+      <if test="memo != null and memo != ''">
+        or MEMO = #{memo}
+      </if>
+      <if test="sampleno != null and sampleno != ''">
+        or SAMPLENO = #{sampleno}
+      </if>
+      <if test="itemcode != null and itemcode != ''">
+        or ITEMCODE = #{itemcode}
+      </if>
+      <if test="item != null and item != ''">
+        or ITEM = #{item}
+      </if>
+      <if test="testresult != null and testresult != ''">
+        or TESTRESULT = #{testresult}
+      </if>
+      <if test="itemjudgeresult != null and itemjudgeresult != ''">
+        or ITEMJUDGERESULT = #{itemjudgeresult}
+      </if>
+      <if test="recorder != null and recorder != ''">
+        or RECORDER = #{recorder}
+      </if>
+      <if test="inputtime != null">
+        or TO_CHAR(INPUTTIME,'yyyy-MM-dd') = '#{inputtime}'
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue">
+    insert into EMS_CALORIFIC_VALUE (WTBH, SAMPLETYPE, MATERIALNO, 
+      MATERIALNAME, MATERIALSOURCE, SAMPLETIME, 
+      SAMPLEPERSON, SENDTIME, SENDER, 
+      JUDGERESULT, JUDGETIME, MEMO, 
+      SAMPLENO, ITEMCODE, ITEM, 
+      TESTRESULT, ITEMJUDGERESULT, RECORDER, 
+      INPUTTIME)
+    values (#{wtbh,jdbcType=VARCHAR}, #{sampletype,jdbcType=VARCHAR}, #{materialno,jdbcType=VARCHAR}, 
+      #{materialname,jdbcType=VARCHAR}, #{materialsource,jdbcType=VARCHAR}, #{sampletime,jdbcType=TIMESTAMP}, 
+      #{sampleperson,jdbcType=VARCHAR}, #{sendtime,jdbcType=TIMESTAMP}, #{sender,jdbcType=VARCHAR}, 
+      #{judgeresult,jdbcType=VARCHAR}, #{judgetime,jdbcType=TIMESTAMP}, #{memo,jdbcType=VARCHAR}, 
+      #{sampleno,jdbcType=VARCHAR}, #{itemcode,jdbcType=VARCHAR}, #{item,jdbcType=VARCHAR}, 
+      #{testresult,jdbcType=VARCHAR}, #{itemjudgeresult,jdbcType=VARCHAR}, #{recorder,jdbcType=VARCHAR}, 
+      #{inputtime,jdbcType=TIMESTAMP})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue">
+    insert into EMS_CALORIFIC_VALUE
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="wtbh != null">
+        WTBH,
+      </if>
+      <if test="sampletype != null">
+        SAMPLETYPE,
+      </if>
+      <if test="materialno != null">
+        MATERIALNO,
+      </if>
+      <if test="materialname != null">
+        MATERIALNAME,
+      </if>
+      <if test="materialsource != null">
+        MATERIALSOURCE,
+      </if>
+      <if test="sampletime != null">
+        SAMPLETIME,
+      </if>
+      <if test="sampleperson != null">
+        SAMPLEPERSON,
+      </if>
+      <if test="sendtime != null">
+        SENDTIME,
+      </if>
+      <if test="sender != null">
+        SENDER,
+      </if>
+      <if test="judgeresult != null">
+        JUDGERESULT,
+      </if>
+      <if test="judgetime != null">
+        JUDGETIME,
+      </if>
+      <if test="memo != null">
+        MEMO,
+      </if>
+      <if test="sampleno != null">
+        SAMPLENO,
+      </if>
+      <if test="itemcode != null">
+        ITEMCODE,
+      </if>
+      <if test="item != null">
+        ITEM,
+      </if>
+      <if test="testresult != null">
+        TESTRESULT,
+      </if>
+      <if test="itemjudgeresult != null">
+        ITEMJUDGERESULT,
+      </if>
+      <if test="recorder != null">
+        RECORDER,
+      </if>
+      <if test="inputtime != null">
+        INPUTTIME,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="wtbh != null">
+        #{wtbh,jdbcType=VARCHAR},
+      </if>
+      <if test="sampletype != null">
+        #{sampletype,jdbcType=VARCHAR},
+      </if>
+      <if test="materialno != null">
+        #{materialno,jdbcType=VARCHAR},
+      </if>
+      <if test="materialname != null">
+        #{materialname,jdbcType=VARCHAR},
+      </if>
+      <if test="materialsource != null">
+        #{materialsource,jdbcType=VARCHAR},
+      </if>
+      <if test="sampletime != null">
+        #{sampletime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="sampleperson != null">
+        #{sampleperson,jdbcType=VARCHAR},
+      </if>
+      <if test="sendtime != null">
+        #{sendtime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="sender != null">
+        #{sender,jdbcType=VARCHAR},
+      </if>
+      <if test="judgeresult != null">
+        #{judgeresult,jdbcType=VARCHAR},
+      </if>
+      <if test="judgetime != null">
+        #{judgetime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="memo != null">
+        #{memo,jdbcType=VARCHAR},
+      </if>
+      <if test="sampleno != null">
+        #{sampleno,jdbcType=VARCHAR},
+      </if>
+      <if test="itemcode != null">
+        #{itemcode,jdbcType=VARCHAR},
+      </if>
+      <if test="item != null">
+        #{item,jdbcType=VARCHAR},
+      </if>
+      <if test="testresult != null">
+        #{testresult,jdbcType=VARCHAR},
+      </if>
+      <if test="itemjudgeresult != null">
+        #{itemjudgeresult,jdbcType=VARCHAR},
+      </if>
+      <if test="recorder != null">
+        #{recorder,jdbcType=VARCHAR},
+      </if>
+      <if test="inputtime != null">
+        #{inputtime,jdbcType=TIMESTAMP},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue">
+    update EMS_CALORIFIC_VALUE
+    set SAMPLETYPE = #{sampletype,jdbcType=VARCHAR},
+      MATERIALNO = #{materialno,jdbcType=VARCHAR},
+      MATERIALNAME = #{materialname,jdbcType=VARCHAR},
+      MATERIALSOURCE = #{materialsource,jdbcType=VARCHAR},
+      SAMPLETIME = #{sampletime,jdbcType=TIMESTAMP},
+      SAMPLEPERSON = #{sampleperson,jdbcType=VARCHAR},
+      SENDTIME = #{sendtime,jdbcType=TIMESTAMP},
+      SENDER = #{sender,jdbcType=VARCHAR},
+      JUDGERESULT = #{judgeresult,jdbcType=VARCHAR},
+      JUDGETIME = #{judgetime,jdbcType=TIMESTAMP},
+      MEMO = #{memo,jdbcType=VARCHAR},
+      SAMPLENO = #{sampleno,jdbcType=VARCHAR},
+      ITEMCODE = #{itemcode,jdbcType=VARCHAR},
+      ITEM = #{item,jdbcType=VARCHAR},
+      TESTRESULT = #{testresult,jdbcType=VARCHAR},
+      ITEMJUDGERESULT = #{itemjudgeresult,jdbcType=VARCHAR},
+      RECORDER = #{recorder,jdbcType=VARCHAR},
+      INPUTTIME = #{inputtime,jdbcType=TIMESTAMP}
+    where WTBH = #{wtbh,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue">
+    update EMS_CALORIFIC_VALUE
+    <set>
+      <if test="sampletype != null">
+        SAMPLETYPE = #{sampletype,jdbcType=VARCHAR},
+      </if>
+      <if test="materialno != null">
+        MATERIALNO = #{materialno,jdbcType=VARCHAR},
+      </if>
+      <if test="materialname != null">
+        MATERIALNAME = #{materialname,jdbcType=VARCHAR},
+      </if>
+      <if test="materialsource != null">
+        MATERIALSOURCE = #{materialsource,jdbcType=VARCHAR},
+      </if>
+      <if test="sampletime != null">
+        SAMPLETIME = #{sampletime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="sampleperson != null">
+        SAMPLEPERSON = #{sampleperson,jdbcType=VARCHAR},
+      </if>
+      <if test="sendtime != null">
+        SENDTIME = #{sendtime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="sender != null">
+        SENDER = #{sender,jdbcType=VARCHAR},
+      </if>
+      <if test="judgeresult != null">
+        JUDGERESULT = #{judgeresult,jdbcType=VARCHAR},
+      </if>
+      <if test="judgetime != null">
+        JUDGETIME = #{judgetime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="memo != null">
+        MEMO = #{memo,jdbcType=VARCHAR},
+      </if>
+      <if test="sampleno != null">
+        SAMPLENO = #{sampleno,jdbcType=VARCHAR},
+      </if>
+      <if test="itemcode != null">
+        ITEMCODE = #{itemcode,jdbcType=VARCHAR},
+      </if>
+      <if test="item != null">
+        ITEM = #{item,jdbcType=VARCHAR},
+      </if>
+      <if test="testresult != null">
+        TESTRESULT = #{testresult,jdbcType=VARCHAR},
+      </if>
+      <if test="itemjudgeresult != null">
+        ITEMJUDGERESULT = #{itemjudgeresult,jdbcType=VARCHAR},
+      </if>
+      <if test="recorder != null">
+        RECORDER = #{recorder,jdbcType=VARCHAR},
+      </if>
+      <if test="inputtime != null">
+        INPUTTIME = #{inputtime,jdbcType=TIMESTAMP},
+      </if>
+    </set>
+    where WTBH = #{wtbh,jdbcType=VARCHAR}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where WTBH = #{wtbh,jdbcType=VARCHAR}
+  </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 EMS_CALORIFIC_VALUE 
+      (WTBH, 
+      SAMPLETYPE, MATERIALNO, MATERIALNAME, 
+      MATERIALSOURCE, SAMPLETIME, 
+      SAMPLEPERSON, SENDTIME, SENDER, 
+      JUDGERESULT, JUDGETIME, MEMO, 
+      SAMPLENO, ITEMCODE, ITEM, 
+      TESTRESULT, ITEMJUDGERESULT, 
+      RECORDER, INPUTTIME)
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.wtbh,jdbcType=VARCHAR}, 
+      #{item.sampletype,jdbcType=VARCHAR}, #{item.materialno,jdbcType=VARCHAR}, #{item.materialname,jdbcType=VARCHAR}, 
+      #{item.materialsource,jdbcType=VARCHAR}, #{item.sampletime,jdbcType=TIMESTAMP}, 
+      #{item.sampleperson,jdbcType=VARCHAR}, #{item.sendtime,jdbcType=TIMESTAMP}, #{item.sender,jdbcType=VARCHAR}, 
+      #{item.judgeresult,jdbcType=VARCHAR}, #{item.judgetime,jdbcType=TIMESTAMP}, #{item.memo,jdbcType=VARCHAR}, 
+      #{item.sampleno,jdbcType=VARCHAR}, #{item.itemcode,jdbcType=VARCHAR}, #{item.item,jdbcType=VARCHAR}, 
+      #{item.testresult,jdbcType=VARCHAR}, #{item.itemjudgeresult,jdbcType=VARCHAR}, 
+      #{item.recorder,jdbcType=VARCHAR}, #{item.inputtime,jdbcType=TIMESTAMP} from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update EMS_CALORIFIC_VALUE
+     set
+       WTBH=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.wtbh,jdbcType=VARCHAR}
+       </foreach>
+       ,SAMPLETYPE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.sampletype,jdbcType=VARCHAR}
+       </foreach>
+       ,MATERIALNO=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.materialno,jdbcType=VARCHAR}
+       </foreach>
+       ,MATERIALNAME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.materialname,jdbcType=VARCHAR}
+       </foreach>
+       ,MATERIALSOURCE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.materialsource,jdbcType=VARCHAR}
+       </foreach>
+       ,SAMPLETIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.sampletime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,SAMPLEPERSON=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.sampleperson,jdbcType=VARCHAR}
+       </foreach>
+       ,SENDTIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.sendtime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,SENDER=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.sender,jdbcType=VARCHAR}
+       </foreach>
+       ,JUDGERESULT=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.judgeresult,jdbcType=VARCHAR}
+       </foreach>
+       ,JUDGETIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.judgetime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,MEMO=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.memo,jdbcType=VARCHAR}
+       </foreach>
+       ,SAMPLENO=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.sampleno,jdbcType=VARCHAR}
+       </foreach>
+       ,ITEMCODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.itemcode,jdbcType=VARCHAR}
+       </foreach>
+       ,ITEM=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.item,jdbcType=VARCHAR}
+       </foreach>
+       ,TESTRESULT=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.testresult,jdbcType=VARCHAR}
+       </foreach>
+       ,ITEMJUDGERESULT=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.itemjudgeresult,jdbcType=VARCHAR}
+       </foreach>
+       ,RECORDER=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.recorder,jdbcType=VARCHAR}
+       </foreach>
+       ,INPUTTIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case WTBH" close="end">
+          when #{item.wtbh,jdbcType=VARCHAR} then #{item.inputtime,jdbcType=TIMESTAMP}
+       </foreach>
+     where WTBH in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.wtbh,jdbcType=VARCHAR}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from EMS_CALORIFIC_VALUE
+    where WTBH in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+  <!--获取最新的数据-->
+  <select id="getNewDate"  resultMap="BaseResultMap">
+    select distinct t.wtbh, t.materialno, t.materialname, t.materialsource,substr(t.sampleno,0,8) as sampleno
+    from ems_calorific_value t
+    where
+    t.wtbh not in (select id from Fold_the_values )
+  </select>
+  <select id="getValue" parameterType="java.util.HashMap" resultType="java.lang.String">
+    select t.TESTRESULT from ems_calorific_value t
+    <where>
+      <if test="wtbh != null and wtbh != '' ">
+       and  t.wtbh = #{wtbh}
+      </if>
+      <if test="item != null and item != '' ">
+       and t.item = #{item}
+      </if>
+    </where>
+  </select>
+</mapper>

+ 317 - 0
src/main/java/com/steerinfo/ems/emscalorificvalue/model/EmsCalorificValue.java

@@ -0,0 +1,317 @@
+package com.steerinfo.ems.emscalorificvalue.model;
+
+import com.steerinfo.framework.model.IBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.util.Date;
+
+@ApiModel(value="null")
+public class EmsCalorificValue implements IBasePO<String> {
+    /**
+     * 检验编号(WTBH,VARCHAR,100)
+     */
+    @ApiModelProperty(value="检验编号",required=true)
+    private String wtbh;
+
+    /**
+     * 取样类型(SAMPLETYPE,VARCHAR,10)
+     */
+    @ApiModelProperty(value="取样类型",required=false)
+    private String sampletype;
+
+    /**
+     * 物料编码(MATERIALNO,VARCHAR,100)
+     */
+    @ApiModelProperty(value="物料编码",required=false)
+    private String materialno;
+
+    /**
+     * 物料名称(MATERIALNAME,VARCHAR,40)
+     */
+    @ApiModelProperty(value="物料名称",required=false)
+    private String materialname;
+
+    /**
+     * 物料来源(MATERIALSOURCE,VARCHAR,100)
+     */
+    @ApiModelProperty(value="物料来源",required=false)
+    private String materialsource;
+
+    /**
+     * 取样时间(SAMPLETIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="取样时间",required=false)
+    private Date sampletime;
+
+    /**
+     * 取样人(SAMPLEPERSON,VARCHAR,40)
+     */
+    @ApiModelProperty(value="取样人",required=false)
+    private String sampleperson;
+
+    /**
+     * 送样时间(SENDTIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="送样时间",required=false)
+    private Date sendtime;
+
+    /**
+     * 送样人 (SENDER,VARCHAR,40)
+     */
+    @ApiModelProperty(value="送样人 ",required=false)
+    private String sender;
+
+    /**
+     * 判定结果(JUDGERESULT,VARCHAR,20)
+     */
+    @ApiModelProperty(value="判定结果",required=false)
+    private String judgeresult;
+
+    /**
+     * 判定时间(JUDGETIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="判定时间",required=false)
+    private Date judgetime;
+
+    /**
+     * 备注(MEMO,VARCHAR,100)
+     */
+    @ApiModelProperty(value="备注",required=false)
+    private String memo;
+
+    /**
+     * 样品编号(SAMPLENO,VARCHAR,100)
+     */
+    @ApiModelProperty(value="样品编号",required=false)
+    private String sampleno;
+
+    /**
+     * 检验项目编号(ITEMCODE,VARCHAR,100)
+     */
+    @ApiModelProperty(value="检验项目编号",required=false)
+    private String itemcode;
+
+    /**
+     * 检验项目(ITEM,VARCHAR,50)
+     */
+    @ApiModelProperty(value="检验项目",required=false)
+    private String item;
+
+    /**
+     * 检验结果(TESTRESULT,VARCHAR,50)
+     */
+    @ApiModelProperty(value="检验结果",required=false)
+    private String testresult;
+
+    /**
+     * 结果判定 (ITEMJUDGERESULT,VARCHAR,50)
+     */
+    @ApiModelProperty(value="结果判定 ",required=false)
+    private String itemjudgeresult;
+
+    /**
+     * 检验人 (RECORDER,VARCHAR,40)
+     */
+    @ApiModelProperty(value="检验人 ",required=false)
+    private String recorder;
+
+    /**
+     * 检验时间(INPUTTIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="检验时间",required=false)
+    private Date inputtime;
+
+    private static final long serialVersionUID = 1L;
+
+    @Override
+    public String getId() {
+        return this.wtbh;
+    }
+
+    @Override
+    public void setId(String wtbh) {
+        this.wtbh = wtbh == null ? null : wtbh.trim();
+    }
+
+    public String getWtbh() {
+        return wtbh;
+    }
+
+    public void setWtbh(String wtbh) {
+        this.wtbh = wtbh == null ? null : wtbh.trim();
+    }
+
+    public String getSampletype() {
+        return sampletype;
+    }
+
+    public void setSampletype(String sampletype) {
+        this.sampletype = sampletype == null ? null : sampletype.trim();
+    }
+
+    public String getMaterialno() {
+        return materialno;
+    }
+
+    public void setMaterialno(String materialno) {
+        this.materialno = materialno == null ? null : materialno.trim();
+    }
+
+    public String getMaterialname() {
+        return materialname;
+    }
+
+    public void setMaterialname(String materialname) {
+        this.materialname = materialname == null ? null : materialname.trim();
+    }
+
+    public String getMaterialsource() {
+        return materialsource;
+    }
+
+    public void setMaterialsource(String materialsource) {
+        this.materialsource = materialsource == null ? null : materialsource.trim();
+    }
+
+    public Date getSampletime() {
+        return sampletime;
+    }
+
+    public void setSampletime(Date sampletime) {
+        this.sampletime = sampletime;
+    }
+
+    public String getSampleperson() {
+        return sampleperson;
+    }
+
+    public void setSampleperson(String sampleperson) {
+        this.sampleperson = sampleperson == null ? null : sampleperson.trim();
+    }
+
+    public Date getSendtime() {
+        return sendtime;
+    }
+
+    public void setSendtime(Date sendtime) {
+        this.sendtime = sendtime;
+    }
+
+    public String getSender() {
+        return sender;
+    }
+
+    public void setSender(String sender) {
+        this.sender = sender == null ? null : sender.trim();
+    }
+
+    public String getJudgeresult() {
+        return judgeresult;
+    }
+
+    public void setJudgeresult(String judgeresult) {
+        this.judgeresult = judgeresult == null ? null : judgeresult.trim();
+    }
+
+    public Date getJudgetime() {
+        return judgetime;
+    }
+
+    public void setJudgetime(Date judgetime) {
+        this.judgetime = judgetime;
+    }
+
+    public String getMemo() {
+        return memo;
+    }
+
+    public void setMemo(String memo) {
+        this.memo = memo == null ? null : memo.trim();
+    }
+
+    public String getSampleno() {
+        return sampleno;
+    }
+
+    public void setSampleno(String sampleno) {
+        this.sampleno = sampleno == null ? null : sampleno.trim();
+    }
+
+    public String getItemcode() {
+        return itemcode;
+    }
+
+    public void setItemcode(String itemcode) {
+        this.itemcode = itemcode == null ? null : itemcode.trim();
+    }
+
+    public String getItem() {
+        return item;
+    }
+
+    public void setItem(String item) {
+        this.item = item == null ? null : item.trim();
+    }
+
+    public String getTestresult() {
+        return testresult;
+    }
+
+    public void setTestresult(String testresult) {
+        this.testresult = testresult == null ? null : testresult.trim();
+    }
+
+    public String getItemjudgeresult() {
+        return itemjudgeresult;
+    }
+
+    public void setItemjudgeresult(String itemjudgeresult) {
+        this.itemjudgeresult = itemjudgeresult == null ? null : itemjudgeresult.trim();
+    }
+
+    public String getRecorder() {
+        return recorder;
+    }
+
+    public void setRecorder(String recorder) {
+        this.recorder = recorder == null ? null : recorder.trim();
+    }
+
+    public Date getInputtime() {
+        return inputtime;
+    }
+
+    public void setInputtime(Date inputtime) {
+        this.inputtime = inputtime;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", wtbh=").append(wtbh);
+        sb.append(", sampletype=").append(sampletype);
+        sb.append(", materialno=").append(materialno);
+        sb.append(", materialname=").append(materialname);
+        sb.append(", materialsource=").append(materialsource);
+        sb.append(", sampletime=").append(sampletime);
+        sb.append(", sampleperson=").append(sampleperson);
+        sb.append(", sendtime=").append(sendtime);
+        sb.append(", sender=").append(sender);
+        sb.append(", judgeresult=").append(judgeresult);
+        sb.append(", judgetime=").append(judgetime);
+        sb.append(", memo=").append(memo);
+        sb.append(", sampleno=").append(sampleno);
+        sb.append(", itemcode=").append(itemcode);
+        sb.append(", item=").append(item);
+        sb.append(", testresult=").append(testresult);
+        sb.append(", itemjudgeresult=").append(itemjudgeresult);
+        sb.append(", recorder=").append(recorder);
+        sb.append(", inputtime=").append(inputtime);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 28 - 0
src/main/java/com/steerinfo/ems/emscalorificvalue/service/IEmsCalorificValueService.java

@@ -0,0 +1,28 @@
+package com.steerinfo.ems.emscalorificvalue.service;
+
+import com.steerinfo.framework.service.IBaseService;
+import com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue;
+import java.util.Date;
+import java.math.BigDecimal;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * EmsCalorificValue服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 08:22
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:EmsCalorificValue服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IEmsCalorificValueService extends IBaseService<EmsCalorificValue, String>{
+    public List<EmsCalorificValue> getNewDate();
+    //获取每个能介的检验值
+    public String getValue(HashMap<String,Object> hashMap);
+}

+ 50 - 0
src/main/java/com/steerinfo/ems/emscalorificvalue/service/impl/EmsCalorificValueServiceImpl.java

@@ -0,0 +1,50 @@
+package com.steerinfo.ems.emscalorificvalue.service.impl;
+
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue;
+import com.steerinfo.ems.emscalorificvalue.mapper.EmsCalorificValueMapper;
+import com.steerinfo.ems.emscalorificvalue.service.IEmsCalorificValueService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import java.util.Date;
+import java.math.BigDecimal;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * EmsCalorificValue服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 08:22
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:EmsCalorificValue服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "emsCalorificValueService")
+public class EmsCalorificValueServiceImpl extends BaseServiceImpl<EmsCalorificValue, String> implements IEmsCalorificValueService {
+
+    @Autowired
+    private EmsCalorificValueMapper emsCalorificValueMapper;
+
+    @Override
+    protected IBaseMapper<EmsCalorificValue, String> getMapper() {
+        return emsCalorificValueMapper;
+    }
+
+
+    @Override
+    public List<EmsCalorificValue> getNewDate() {
+        return emsCalorificValueMapper.getNewDate();
+    }
+
+    @Override
+    public String getValue(HashMap<String, Object> hashMap) {
+        return emsCalorificValueMapper.getValue(hashMap);
+    }
+
+}

+ 110 - 0
src/main/java/com/steerinfo/ems/emslog/controller/EmsLogController.java

@@ -0,0 +1,110 @@
+package com.steerinfo.ems.emslog.controller;
+
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import com.steerinfo.ems.emslog.model.EmsLog;
+import com.steerinfo.ems.emslog.service.IEmsLogService;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.ArrayList;
+import java.math.BigDecimal;
+
+/**
+ * EmsLog RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-18 04:03
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-18
+ * 作者:generator
+ * 参考:
+ * 描述:EmsLog RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/emslogs")
+public class EmsLogController extends BaseRESTfulController {
+
+    @Autowired
+    IEmsLogService emsLogService;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("emslog:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<EmsLog> list = emsLogService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("emslog:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<EmsLog> list = emsLogService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据EmsLog对象创建")
+    @ApiImplicitParam(name = "emsLog", value = "详细实体emsLog", required = true, dataType = "EmsLog")
+    //@RequiresPermissions("emslog:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@ModelAttribute EmsLog model){
+        EmsLog emsLog = emsLogService.add(model);
+        return success(emsLog);
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("emslog:view")
+    @GetMapping(value = "/{id}")
+    public RESTfulResult get(@PathVariable String id){
+        EmsLog emsLog = emsLogService.getById(id);
+        return success(emsLog);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的emsLog信息来更新详细信息")
+    @ApiImplicitParams({
+        @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String"),
+        @ApiImplicitParam(name = "emsLog", value = "详细实体emsLog", required = true, dataType = "EmsLog")
+    })
+    //@RequiresPermissions("emslog:update")
+    @PutMapping(value = "/{id}", produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update(@PathVariable String id, @RequestBody EmsLog model){
+        model.setId(id);
+        EmsLog emsLog = emsLogService.modify(model);
+        return success(emsLog);
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("emslog:delete")
+    @DeleteMapping(value = "/{id}")//String
+    public RESTfulResult delete(@PathVariable String id){
+    	List<String> list = Arrays.asList(id.split(","));
+    	if(ListUtils.isNotEmpty(list)) {
+	    	List<String> ids = ListUtils.convertList(list);
+			  emsLogService.delete(ids);
+    	}
+      return success();
+    }
+}

+ 10 - 0
src/main/java/com/steerinfo/ems/emslog/mapper/EmsLogMapper.java

@@ -0,0 +1,10 @@
+package com.steerinfo.ems.emslog.mapper;
+
+import com.steerinfo.ems.emslog.model.EmsLog;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import java.math.*;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface EmsLogMapper extends IBaseMapper<EmsLog, String> {
+}

+ 212 - 0
src/main/java/com/steerinfo/ems/emslog/mapper/EmsLogMapper.xml

@@ -0,0 +1,212 @@
+<?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.ems.emslog.mapper.EmsLogMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.emslog.model.EmsLog">
+    <id column="ID" jdbcType="VARCHAR" property="id" />
+    <result column="UPDATETABLE" jdbcType="VARCHAR" property="updatetable" />
+    <result column="CODE" jdbcType="VARCHAR" property="code" />
+    <result column="OPERATORTIME" jdbcType="TIMESTAMP" property="operatortime" />
+    <result column="OPERATOR" jdbcType="VARCHAR" property="operator" />
+  </resultMap>
+  <sql id="columns">
+    ID, UPDATETABLE, CODE, OPERATORTIME, OPERATOR
+  </sql>
+  <sql id="columns_alias">
+    t.ID, t.UPDATETABLE, t.CODE, t.OPERATORTIME, t.OPERATOR
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM EMS_LOG
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM EMS_LOG t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="id != null and id != ''">
+        and ID = #{id}
+      </if>
+      <if test="updatetable != null and updatetable != ''">
+        and UPDATETABLE = #{updatetable}
+      </if>
+      <if test="code != null and code != ''">
+        and CODE = #{code}
+      </if>
+      <if test="operatortime != null">
+        and TO_CHAR(OPERATORTIME,'yyyy-MM-dd') = #{operatortime}
+      </if>
+      <if test="operator != null and operator != ''">
+        and OPERATOR = #{operator}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="id != null and id != ''">
+        and ID LIKE '%${id}%'
+      </if>
+      <if test="updatetable != null and updatetable != ''">
+        and UPDATETABLE LIKE '%${updatetable}%'
+      </if>
+      <if test="code != null and code != ''">
+        and CODE LIKE '%${code}%'
+      </if>
+      <if test="operatortime != null">
+        and TO_CHAR(OPERATORTIME,'yyyy-MM-dd') = #{operatortime}
+      </if>
+      <if test="operator != null and operator != ''">
+        and OPERATOR LIKE '%${operator}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from EMS_LOG
+    where ID = #{id,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from EMS_LOG
+    where 1!=1 
+      <if test="updatetable != null and updatetable != ''">
+        or UPDATETABLE = #{updatetable}
+      </if>
+      <if test="code != null and code != ''">
+        or CODE = #{code}
+      </if>
+      <if test="operatortime != null">
+        or TO_CHAR(OPERATORTIME,'yyyy-MM-dd') = '#{operatortime}'
+      </if>
+      <if test="operator != null and operator != ''">
+        or OPERATOR = #{operator}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.emslog.model.EmsLog">
+    insert into EMS_LOG (ID, UPDATETABLE, CODE, 
+      OPERATORTIME, OPERATOR)
+    values (#{id,jdbcType=VARCHAR}, #{updatetable,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, 
+      #{operatortime,jdbcType=TIMESTAMP}, #{operator,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.emslog.model.EmsLog">
+    insert into EMS_LOG
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        ID,
+      </if>
+      <if test="updatetable != null">
+        UPDATETABLE,
+      </if>
+      <if test="code != null">
+        CODE,
+      </if>
+      <if test="operatortime != null">
+        OPERATORTIME,
+      </if>
+      <if test="operator != null">
+        OPERATOR,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=VARCHAR},
+      </if>
+      <if test="updatetable != null">
+        #{updatetable,jdbcType=VARCHAR},
+      </if>
+      <if test="code != null">
+        #{code,jdbcType=VARCHAR},
+      </if>
+      <if test="operatortime != null">
+        #{operatortime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="operator != null">
+        #{operator,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.emslog.model.EmsLog">
+    update EMS_LOG
+    set UPDATETABLE = #{updatetable,jdbcType=VARCHAR},
+      CODE = #{code,jdbcType=VARCHAR},
+      OPERATORTIME = #{operatortime,jdbcType=TIMESTAMP},
+      OPERATOR = #{operator,jdbcType=VARCHAR}
+    where ID = #{id,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.emslog.model.EmsLog">
+    update EMS_LOG
+    <set>
+      <if test="updatetable != null">
+        UPDATETABLE = #{updatetable,jdbcType=VARCHAR},
+      </if>
+      <if test="code != null">
+        CODE = #{code,jdbcType=VARCHAR},
+      </if>
+      <if test="operatortime != null">
+        OPERATORTIME = #{operatortime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="operator != null">
+        OPERATOR = #{operator,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where ID = #{id,jdbcType=VARCHAR}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where ID = #{id,jdbcType=VARCHAR}
+  </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 EMS_LOG 
+      (ID, 
+      UPDATETABLE, CODE, OPERATORTIME, 
+      OPERATOR)
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.id,jdbcType=VARCHAR}, 
+      #{item.updatetable,jdbcType=VARCHAR}, #{item.code,jdbcType=VARCHAR}, #{item.operatortime,jdbcType=TIMESTAMP}, 
+      #{item.operator,jdbcType=VARCHAR} from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update EMS_LOG
+     set
+       ID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.id,jdbcType=VARCHAR}
+       </foreach>
+       ,UPDATETABLE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.updatetable,jdbcType=VARCHAR}
+       </foreach>
+       ,CODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.code,jdbcType=VARCHAR}
+       </foreach>
+       ,OPERATORTIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.operatortime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,OPERATOR=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.operator,jdbcType=VARCHAR}
+       </foreach>
+     where ID in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.id,jdbcType=VARCHAR}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from EMS_LOG
+    where ID in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+  
+</mapper>

+ 97 - 0
src/main/java/com/steerinfo/ems/emslog/model/EmsLog.java

@@ -0,0 +1,97 @@
+package com.steerinfo.ems.emslog.model;
+
+import com.steerinfo.framework.model.IBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.util.Date;
+
+@ApiModel(value="系统操作日志表")
+public class EmsLog implements IBasePO<String> {
+    /**
+     * 主键(ID,VARCHAR,100)
+     */
+    @ApiModelProperty(value="主键ID",required=true)
+    private String id;
+
+    /**
+     * 修改的表名(UPDATETABLE,VARCHAR,50)
+     */
+    @ApiModelProperty(value="修改的表名",required=false)
+    private String updatetable;
+
+    /**
+     * 修改内容(CODE,VARCHAR,1000)
+     */
+    @ApiModelProperty(value="修改内容",required=false)
+    private String code;
+
+    /**
+     * 操作人(OPERATORTIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="操作人",required=false)
+    private Date operatortime;
+
+    /**
+     * 操作时间(OPERATOR,VARCHAR,50)
+     */
+    @ApiModelProperty(value="操作时间",required=false)
+    private String operator;
+
+    private static final long serialVersionUID = 1L;
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id == null ? null : id.trim();
+    }
+
+    public String getUpdatetable() {
+        return updatetable;
+    }
+
+    public void setUpdatetable(String updatetable) {
+        this.updatetable = updatetable == null ? null : updatetable.trim();
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public void setCode(String code) {
+        this.code = code == null ? null : code.trim();
+    }
+
+    public Date getOperatortime() {
+        return operatortime;
+    }
+
+    public void setOperatortime(Date operatortime) {
+        this.operatortime = operatortime;
+    }
+
+    public String getOperator() {
+        return operator;
+    }
+
+    public void setOperator(String operator) {
+        this.operator = operator == null ? null : operator.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", id=").append(id);
+        sb.append(", updatetable=").append(updatetable);
+        sb.append(", code=").append(code);
+        sb.append(", operatortime=").append(operatortime);
+        sb.append(", operator=").append(operator);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 23 - 0
src/main/java/com/steerinfo/ems/emslog/service/IEmsLogService.java

@@ -0,0 +1,23 @@
+package com.steerinfo.ems.emslog.service;
+
+import com.steerinfo.framework.service.IBaseService;
+import com.steerinfo.ems.emslog.model.EmsLog;
+import java.util.Date;
+import java.math.BigDecimal;
+
+/**
+ * EmsLog服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-18 04:03
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-18
+ * 作者:generator
+ * 参考:
+ * 描述:EmsLog服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IEmsLogService extends IBaseService<EmsLog, String>{
+
+}

+ 36 - 0
src/main/java/com/steerinfo/ems/emslog/service/impl/EmsLogServiceImpl.java

@@ -0,0 +1,36 @@
+package com.steerinfo.ems.emslog.service.impl;
+
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import com.steerinfo.ems.emslog.model.EmsLog;
+import com.steerinfo.ems.emslog.mapper.EmsLogMapper;
+import com.steerinfo.ems.emslog.service.IEmsLogService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import java.util.Date;
+import java.math.BigDecimal;
+
+/**
+ * EmsLog服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-18 04:03
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-18
+ * 作者:generator
+ * 参考:
+ * 描述:EmsLog服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "emsLogService")
+public class EmsLogServiceImpl extends BaseServiceImpl<EmsLog, String> implements IEmsLogService {
+
+    @Autowired
+    private EmsLogMapper emsLogMapper;
+
+    @Override
+    protected IBaseMapper<EmsLog, String> getMapper() {
+        return emsLogMapper;
+    }
+}

+ 107 - 0
src/main/java/com/steerinfo/ems/emsscqklg/controller/EmsScqkLgController.java

@@ -0,0 +1,107 @@
+package com.steerinfo.ems.emsscqklg.controller;
+
+import com.steerinfo.ems.emsscqklg.model.EmsScqkLg;
+import com.steerinfo.ems.emsscqklg.service.IEmsScqkLgService;
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Arrays;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * EmsScqkLg RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-19 10:43
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-19
+ * 作者:generator
+ * 参考:
+ * 描述:EmsScqkLg RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/emsscqklgs")
+public class EmsScqkLgController extends BaseRESTfulController {
+
+    @Autowired
+    IEmsScqkLgService emsScqkLgService;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("emsscqklg:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<EmsScqkLg> list = emsScqkLgService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("emsscqklg:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<EmsScqkLg> list = emsScqkLgService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据EmsScqkLg对象创建")
+    @ApiImplicitParam(name = "emsScqkLg", value = "详细实体emsScqkLg", required = true, dataType = "EmsScqkLg")
+    //@RequiresPermissions("emsscqklg:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@ModelAttribute EmsScqkLg model){
+        EmsScqkLg emsScqkLg = emsScqkLgService.add(model);
+        return success(emsScqkLg);
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "Date")
+    //@RequiresPermissions("emsscqklg:view")
+    @GetMapping(value = "/{id}")
+    public RESTfulResult get(@PathVariable Date id){
+        EmsScqkLg emsScqkLg = emsScqkLgService.getById(id);
+        return success(emsScqkLg);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的emsScqkLg信息来更新详细信息")
+    @ApiImplicitParams({
+        @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "Date"),
+        @ApiImplicitParam(name = "emsScqkLg", value = "详细实体emsScqkLg", required = true, dataType = "EmsScqkLg")
+    })
+    //@RequiresPermissions("emsscqklg:update")
+    @PutMapping(value = "/{id}", produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update(@PathVariable Date id, @RequestBody EmsScqkLg model){
+        model.setId(id);
+        EmsScqkLg emsScqkLg = emsScqkLgService.modify(model);
+        return success(emsScqkLg);
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "Date")
+    //@RequiresPermissions("emsscqklg:delete")
+    @DeleteMapping(value = "/{id}")//Date
+    public RESTfulResult delete(@PathVariable String id){
+    	List<String> list = Arrays.asList(id.split(","));
+    	if(ListUtils.isNotEmpty(list)) {
+	    	List<Date> ids = ListUtils.convertList(list);
+			  emsScqkLgService.delete(ids);
+    	}
+      return success();
+    }
+}

+ 11 - 0
src/main/java/com/steerinfo/ems/emsscqklg/mapper/EmsScqkLgMapper.java

@@ -0,0 +1,11 @@
+package com.steerinfo.ems.emsscqklg.mapper;
+
+import com.steerinfo.ems.emsscqklg.model.EmsScqkLg;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.Date;
+
+@Mapper
+public interface EmsScqkLgMapper extends IBaseMapper<EmsScqkLg, Date> {
+}

+ 595 - 0
src/main/java/com/steerinfo/ems/emsscqklg/mapper/EmsScqkLgMapper.xml

@@ -0,0 +1,595 @@
+<?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.ems.emsscqklg.mapper.EmsScqkLgMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.emsscqklg.model.EmsScqkLg">
+    <id column="DATES" jdbcType="TIMESTAMP" property="dates" />
+    <result column="RCL" jdbcType="DECIMAL" property="rcl" />
+    <result column="JTSL" jdbcType="DECIMAL" property="jtsl" />
+    <result column="SJYL" jdbcType="DECIMAL" property="sjyl" />
+    <result column="KCL" jdbcType="DECIMAL" property="kcl" />
+    <result column="WJZL" jdbcType="DECIMAL" property="wjzl" />
+    <result column="SCLS" jdbcType="DECIMAL" property="scls" />
+    <result column="LL_1" jdbcType="DECIMAL" property="ll1" />
+    <result column="LL_2" jdbcType="DECIMAL" property="ll2" />
+    <result column="FGZL_NBHST" jdbcType="DECIMAL" property="fgzlNbhst" />
+    <result column="FGZL_WG" jdbcType="DECIMAL" property="fgzlWg" />
+    <result column="LLDLYL" jdbcType="DECIMAL" property="lldlyl" />
+    <result column="WGFG_JFGK" jdbcType="DECIMAL" property="wgfgJfgk" />
+    <result column="WGFG_QXC" jdbcType="DECIMAL" property="wgfgQxc" />
+    <result column="XCF" jdbcType="DECIMAL" property="xcf" />
+    <result column="MEMO" jdbcType="VARCHAR" property="memo" />
+    <result column="CZR" jdbcType="VARCHAR" property="czr" />
+    <result column="CZSJ" jdbcType="TIMESTAMP" property="czsj" />
+    <result column="WXGPCL" jdbcType="DECIMAL" property="wxgpcl" />
+    <result column="LLB" jdbcType="DECIMAL" property="llb" />
+  </resultMap>
+  <sql id="columns">
+    DATES, RCL, JTSL, SJYL, KCL, WJZL, SCLS, LL_1, LL_2, FGZL_NBHST, FGZL_WG, LLDLYL, 
+    WGFG_JFGK, WGFG_QXC, XCF, MEMO, CZR, CZSJ, WXGPCL, LLB
+  </sql>
+  <sql id="columns_alias">
+    t.DATES, t.RCL, t.JTSL, t.SJYL, t.KCL, t.WJZL, t.SCLS, t.LL_1, t.LL_2, t.FGZL_NBHST, 
+    t.FGZL_WG, t.LLDLYL, t.WGFG_JFGK, t.WGFG_QXC, t.XCF, t.MEMO, t.CZR, t.CZSJ, t.WXGPCL, 
+    t.LLB
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM EMS_SCQK_LG
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM EMS_SCQK_LG t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="dates != null">
+        and TO_CHAR(DATES,'yyyy-MM-dd') = #{dates}
+      </if>
+      <if test="rcl != null">
+        and RCL = #{rcl}
+      </if>
+      <if test="jtsl != null">
+        and JTSL = #{jtsl}
+      </if>
+      <if test="sjyl != null">
+        and SJYL = #{sjyl}
+      </if>
+      <if test="kcl != null">
+        and KCL = #{kcl}
+      </if>
+      <if test="wjzl != null">
+        and WJZL = #{wjzl}
+      </if>
+      <if test="scls != null">
+        and SCLS = #{scls}
+      </if>
+      <if test="ll1 != null">
+        and LL_1 = #{ll1}
+      </if>
+      <if test="ll2 != null">
+        and LL_2 = #{ll2}
+      </if>
+      <if test="fgzlNbhst != null">
+        and FGZL_NBHST = #{fgzlNbhst}
+      </if>
+      <if test="fgzlWg != null">
+        and FGZL_WG = #{fgzlWg}
+      </if>
+      <if test="lldlyl != null">
+        and LLDLYL = #{lldlyl}
+      </if>
+      <if test="wgfgJfgk != null">
+        and WGFG_JFGK = #{wgfgJfgk}
+      </if>
+      <if test="wgfgQxc != null">
+        and WGFG_QXC = #{wgfgQxc}
+      </if>
+      <if test="xcf != null">
+        and XCF = #{xcf}
+      </if>
+      <if test="memo != null and memo != ''">
+        and MEMO = #{memo}
+      </if>
+      <if test="czr != null and czr != ''">
+        and CZR = #{czr}
+      </if>
+      <if test="czsj != null">
+        and TO_CHAR(CZSJ,'yyyy-MM-dd') = #{czsj}
+      </if>
+      <if test="wxgpcl != null">
+        and WXGPCL = #{wxgpcl}
+      </if>
+      <if test="llb != null">
+        and LLB = #{llb}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="dates != null">
+        and TO_CHAR(DATES,'yyyy-MM-dd') = #{dates}
+      </if>
+      <if test="rcl != null">
+        and RCL = #{rcl}
+      </if>
+      <if test="jtsl != null">
+        and JTSL = #{jtsl}
+      </if>
+      <if test="sjyl != null">
+        and SJYL = #{sjyl}
+      </if>
+      <if test="kcl != null">
+        and KCL = #{kcl}
+      </if>
+      <if test="wjzl != null">
+        and WJZL = #{wjzl}
+      </if>
+      <if test="scls != null">
+        and SCLS = #{scls}
+      </if>
+      <if test="ll1 != null">
+        and LL_1 = #{ll1}
+      </if>
+      <if test="ll2 != null">
+        and LL_2 = #{ll2}
+      </if>
+      <if test="fgzlNbhst != null">
+        and FGZL_NBHST = #{fgzlNbhst}
+      </if>
+      <if test="fgzlWg != null">
+        and FGZL_WG = #{fgzlWg}
+      </if>
+      <if test="lldlyl != null">
+        and LLDLYL = #{lldlyl}
+      </if>
+      <if test="wgfgJfgk != null">
+        and WGFG_JFGK = #{wgfgJfgk}
+      </if>
+      <if test="wgfgQxc != null">
+        and WGFG_QXC = #{wgfgQxc}
+      </if>
+      <if test="xcf != null">
+        and XCF = #{xcf}
+      </if>
+      <if test="memo != null and memo != ''">
+        and MEMO LIKE '%${memo}%'
+      </if>
+      <if test="czr != null and czr != ''">
+        and CZR LIKE '%${czr}%'
+      </if>
+      <if test="czsj != null">
+        and TO_CHAR(CZSJ,'yyyy-MM-dd') = #{czsj}
+      </if>
+      <if test="wxgpcl != null">
+        and WXGPCL = #{wxgpcl}
+      </if>
+      <if test="llb != null">
+        and LLB = #{llb}
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.util.Date">
+    delete from EMS_SCQK_LG
+    where DATES = #{dates,jdbcType=TIMESTAMP}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from EMS_SCQK_LG
+    where 1!=1 
+      <if test="rcl != null">
+        or RCL = #{rcl}
+      </if>
+      <if test="jtsl != null">
+        or JTSL = #{jtsl}
+      </if>
+      <if test="sjyl != null">
+        or SJYL = #{sjyl}
+      </if>
+      <if test="kcl != null">
+        or KCL = #{kcl}
+      </if>
+      <if test="wjzl != null">
+        or WJZL = #{wjzl}
+      </if>
+      <if test="scls != null">
+        or SCLS = #{scls}
+      </if>
+      <if test="ll1 != null">
+        or LL_1 = #{ll1}
+      </if>
+      <if test="ll2 != null">
+        or LL_2 = #{ll2}
+      </if>
+      <if test="fgzlNbhst != null">
+        or FGZL_NBHST = #{fgzlNbhst}
+      </if>
+      <if test="fgzlWg != null">
+        or FGZL_WG = #{fgzlWg}
+      </if>
+      <if test="lldlyl != null">
+        or LLDLYL = #{lldlyl}
+      </if>
+      <if test="wgfgJfgk != null">
+        or WGFG_JFGK = #{wgfgJfgk}
+      </if>
+      <if test="wgfgQxc != null">
+        or WGFG_QXC = #{wgfgQxc}
+      </if>
+      <if test="xcf != null">
+        or XCF = #{xcf}
+      </if>
+      <if test="memo != null and memo != ''">
+        or MEMO = #{memo}
+      </if>
+      <if test="czr != null and czr != ''">
+        or CZR = #{czr}
+      </if>
+      <if test="czsj != null">
+        or TO_CHAR(CZSJ,'yyyy-MM-dd') = '#{czsj}'
+      </if>
+      <if test="wxgpcl != null">
+        or WXGPCL = #{wxgpcl}
+      </if>
+      <if test="llb != null">
+        or LLB = #{llb}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.emsscqklg.model.EmsScqkLg">
+    insert into EMS_SCQK_LG (DATES, RCL, JTSL, 
+      SJYL, KCL, WJZL, SCLS, 
+      LL_1, LL_2, FGZL_NBHST, 
+      FGZL_WG, LLDLYL, WGFG_JFGK, 
+      WGFG_QXC, XCF, MEMO, 
+      CZR, CZSJ, WXGPCL, 
+      LLB)
+    values (#{dates,jdbcType=TIMESTAMP}, #{rcl,jdbcType=DECIMAL}, #{jtsl,jdbcType=DECIMAL}, 
+      #{sjyl,jdbcType=DECIMAL}, #{kcl,jdbcType=DECIMAL}, #{wjzl,jdbcType=DECIMAL}, #{scls,jdbcType=DECIMAL}, 
+      #{ll1,jdbcType=DECIMAL}, #{ll2,jdbcType=DECIMAL}, #{fgzlNbhst,jdbcType=DECIMAL}, 
+      #{fgzlWg,jdbcType=DECIMAL}, #{lldlyl,jdbcType=DECIMAL}, #{wgfgJfgk,jdbcType=DECIMAL}, 
+      #{wgfgQxc,jdbcType=DECIMAL}, #{xcf,jdbcType=DECIMAL}, #{memo,jdbcType=VARCHAR}, 
+      #{czr,jdbcType=VARCHAR}, #{czsj,jdbcType=TIMESTAMP}, #{wxgpcl,jdbcType=DECIMAL}, 
+      #{llb,jdbcType=DECIMAL})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.emsscqklg.model.EmsScqkLg">
+    insert into EMS_SCQK_LG
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="dates != null">
+        DATES,
+      </if>
+      <if test="rcl != null">
+        RCL,
+      </if>
+      <if test="jtsl != null">
+        JTSL,
+      </if>
+      <if test="sjyl != null">
+        SJYL,
+      </if>
+      <if test="kcl != null">
+        KCL,
+      </if>
+      <if test="wjzl != null">
+        WJZL,
+      </if>
+      <if test="scls != null">
+        SCLS,
+      </if>
+      <if test="ll1 != null">
+        LL_1,
+      </if>
+      <if test="ll2 != null">
+        LL_2,
+      </if>
+      <if test="fgzlNbhst != null">
+        FGZL_NBHST,
+      </if>
+      <if test="fgzlWg != null">
+        FGZL_WG,
+      </if>
+      <if test="lldlyl != null">
+        LLDLYL,
+      </if>
+      <if test="wgfgJfgk != null">
+        WGFG_JFGK,
+      </if>
+      <if test="wgfgQxc != null">
+        WGFG_QXC,
+      </if>
+      <if test="xcf != null">
+        XCF,
+      </if>
+      <if test="memo != null">
+        MEMO,
+      </if>
+      <if test="czr != null">
+        CZR,
+      </if>
+      <if test="czsj != null">
+        CZSJ,
+      </if>
+      <if test="wxgpcl != null">
+        WXGPCL,
+      </if>
+      <if test="llb != null">
+        LLB,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="dates != null">
+        #{dates,jdbcType=TIMESTAMP},
+      </if>
+      <if test="rcl != null">
+        #{rcl,jdbcType=DECIMAL},
+      </if>
+      <if test="jtsl != null">
+        #{jtsl,jdbcType=DECIMAL},
+      </if>
+      <if test="sjyl != null">
+        #{sjyl,jdbcType=DECIMAL},
+      </if>
+      <if test="kcl != null">
+        #{kcl,jdbcType=DECIMAL},
+      </if>
+      <if test="wjzl != null">
+        #{wjzl,jdbcType=DECIMAL},
+      </if>
+      <if test="scls != null">
+        #{scls,jdbcType=DECIMAL},
+      </if>
+      <if test="ll1 != null">
+        #{ll1,jdbcType=DECIMAL},
+      </if>
+      <if test="ll2 != null">
+        #{ll2,jdbcType=DECIMAL},
+      </if>
+      <if test="fgzlNbhst != null">
+        #{fgzlNbhst,jdbcType=DECIMAL},
+      </if>
+      <if test="fgzlWg != null">
+        #{fgzlWg,jdbcType=DECIMAL},
+      </if>
+      <if test="lldlyl != null">
+        #{lldlyl,jdbcType=DECIMAL},
+      </if>
+      <if test="wgfgJfgk != null">
+        #{wgfgJfgk,jdbcType=DECIMAL},
+      </if>
+      <if test="wgfgQxc != null">
+        #{wgfgQxc,jdbcType=DECIMAL},
+      </if>
+      <if test="xcf != null">
+        #{xcf,jdbcType=DECIMAL},
+      </if>
+      <if test="memo != null">
+        #{memo,jdbcType=VARCHAR},
+      </if>
+      <if test="czr != null">
+        #{czr,jdbcType=VARCHAR},
+      </if>
+      <if test="czsj != null">
+        #{czsj,jdbcType=TIMESTAMP},
+      </if>
+      <if test="wxgpcl != null">
+        #{wxgpcl,jdbcType=DECIMAL},
+      </if>
+      <if test="llb != null">
+        #{llb,jdbcType=DECIMAL},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.emsscqklg.model.EmsScqkLg">
+    update EMS_SCQK_LG
+    set RCL = #{rcl,jdbcType=DECIMAL},
+      JTSL = #{jtsl,jdbcType=DECIMAL},
+      SJYL = #{sjyl,jdbcType=DECIMAL},
+      KCL = #{kcl,jdbcType=DECIMAL},
+      WJZL = #{wjzl,jdbcType=DECIMAL},
+      SCLS = #{scls,jdbcType=DECIMAL},
+      LL_1 = #{ll1,jdbcType=DECIMAL},
+      LL_2 = #{ll2,jdbcType=DECIMAL},
+      FGZL_NBHST = #{fgzlNbhst,jdbcType=DECIMAL},
+      FGZL_WG = #{fgzlWg,jdbcType=DECIMAL},
+      LLDLYL = #{lldlyl,jdbcType=DECIMAL},
+      WGFG_JFGK = #{wgfgJfgk,jdbcType=DECIMAL},
+      WGFG_QXC = #{wgfgQxc,jdbcType=DECIMAL},
+      XCF = #{xcf,jdbcType=DECIMAL},
+      MEMO = #{memo,jdbcType=VARCHAR},
+      CZR = #{czr,jdbcType=VARCHAR},
+      CZSJ = #{czsj,jdbcType=TIMESTAMP},
+      WXGPCL = #{wxgpcl,jdbcType=DECIMAL},
+      LLB = #{llb,jdbcType=DECIMAL}
+    where DATES = #{dates,jdbcType=TIMESTAMP}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.emsscqklg.model.EmsScqkLg">
+    update EMS_SCQK_LG
+    <set>
+      <if test="rcl != null">
+        RCL = #{rcl,jdbcType=DECIMAL},
+      </if>
+      <if test="jtsl != null">
+        JTSL = #{jtsl,jdbcType=DECIMAL},
+      </if>
+      <if test="sjyl != null">
+        SJYL = #{sjyl,jdbcType=DECIMAL},
+      </if>
+      <if test="kcl != null">
+        KCL = #{kcl,jdbcType=DECIMAL},
+      </if>
+      <if test="wjzl != null">
+        WJZL = #{wjzl,jdbcType=DECIMAL},
+      </if>
+      <if test="scls != null">
+        SCLS = #{scls,jdbcType=DECIMAL},
+      </if>
+      <if test="ll1 != null">
+        LL_1 = #{ll1,jdbcType=DECIMAL},
+      </if>
+      <if test="ll2 != null">
+        LL_2 = #{ll2,jdbcType=DECIMAL},
+      </if>
+      <if test="fgzlNbhst != null">
+        FGZL_NBHST = #{fgzlNbhst,jdbcType=DECIMAL},
+      </if>
+      <if test="fgzlWg != null">
+        FGZL_WG = #{fgzlWg,jdbcType=DECIMAL},
+      </if>
+      <if test="lldlyl != null">
+        LLDLYL = #{lldlyl,jdbcType=DECIMAL},
+      </if>
+      <if test="wgfgJfgk != null">
+        WGFG_JFGK = #{wgfgJfgk,jdbcType=DECIMAL},
+      </if>
+      <if test="wgfgQxc != null">
+        WGFG_QXC = #{wgfgQxc,jdbcType=DECIMAL},
+      </if>
+      <if test="xcf != null">
+        XCF = #{xcf,jdbcType=DECIMAL},
+      </if>
+      <if test="memo != null">
+        MEMO = #{memo,jdbcType=VARCHAR},
+      </if>
+      <if test="czr != null">
+        CZR = #{czr,jdbcType=VARCHAR},
+      </if>
+      <if test="czsj != null">
+        CZSJ = #{czsj,jdbcType=TIMESTAMP},
+      </if>
+      <if test="wxgpcl != null">
+        WXGPCL = #{wxgpcl,jdbcType=DECIMAL},
+      </if>
+      <if test="llb != null">
+        LLB = #{llb,jdbcType=DECIMAL},
+      </if>
+    </set>
+    where DATES = #{dates,jdbcType=TIMESTAMP}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.util.Date" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where DATES = #{dates,jdbcType=TIMESTAMP}
+  </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 EMS_SCQK_LG 
+      (DATES, 
+      RCL, JTSL, SJYL, 
+      KCL, WJZL, SCLS, 
+      LL_1, LL_2, FGZL_NBHST, 
+      FGZL_WG, LLDLYL, WGFG_JFGK, 
+      WGFG_QXC, XCF, MEMO, 
+      CZR, CZSJ, WXGPCL, 
+      LLB)
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.dates,jdbcType=TIMESTAMP}, 
+      #{item.rcl,jdbcType=DECIMAL}, #{item.jtsl,jdbcType=DECIMAL}, #{item.sjyl,jdbcType=DECIMAL}, 
+      #{item.kcl,jdbcType=DECIMAL}, #{item.wjzl,jdbcType=DECIMAL}, #{item.scls,jdbcType=DECIMAL}, 
+      #{item.ll1,jdbcType=DECIMAL}, #{item.ll2,jdbcType=DECIMAL}, #{item.fgzlNbhst,jdbcType=DECIMAL}, 
+      #{item.fgzlWg,jdbcType=DECIMAL}, #{item.lldlyl,jdbcType=DECIMAL}, #{item.wgfgJfgk,jdbcType=DECIMAL}, 
+      #{item.wgfgQxc,jdbcType=DECIMAL}, #{item.xcf,jdbcType=DECIMAL}, #{item.memo,jdbcType=VARCHAR}, 
+      #{item.czr,jdbcType=VARCHAR}, #{item.czsj,jdbcType=TIMESTAMP}, #{item.wxgpcl,jdbcType=DECIMAL}, 
+      #{item.llb,jdbcType=DECIMAL} from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update EMS_SCQK_LG
+     set
+       DATES=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.dates,jdbcType=TIMESTAMP}
+       </foreach>
+       ,RCL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.rcl,jdbcType=DECIMAL}
+       </foreach>
+       ,JTSL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.jtsl,jdbcType=DECIMAL}
+       </foreach>
+       ,SJYL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.sjyl,jdbcType=DECIMAL}
+       </foreach>
+       ,KCL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.kcl,jdbcType=DECIMAL}
+       </foreach>
+       ,WJZL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.wjzl,jdbcType=DECIMAL}
+       </foreach>
+       ,SCLS=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.scls,jdbcType=DECIMAL}
+       </foreach>
+       ,LL_1=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.ll1,jdbcType=DECIMAL}
+       </foreach>
+       ,LL_2=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.ll2,jdbcType=DECIMAL}
+       </foreach>
+       ,FGZL_NBHST=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.fgzlNbhst,jdbcType=DECIMAL}
+       </foreach>
+       ,FGZL_WG=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.fgzlWg,jdbcType=DECIMAL}
+       </foreach>
+       ,LLDLYL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.lldlyl,jdbcType=DECIMAL}
+       </foreach>
+       ,WGFG_JFGK=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.wgfgJfgk,jdbcType=DECIMAL}
+       </foreach>
+       ,WGFG_QXC=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.wgfgQxc,jdbcType=DECIMAL}
+       </foreach>
+       ,XCF=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.xcf,jdbcType=DECIMAL}
+       </foreach>
+       ,MEMO=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.memo,jdbcType=VARCHAR}
+       </foreach>
+       ,CZR=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.czr,jdbcType=VARCHAR}
+       </foreach>
+       ,CZSJ=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.czsj,jdbcType=TIMESTAMP}
+       </foreach>
+       ,WXGPCL=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.wxgpcl,jdbcType=DECIMAL}
+       </foreach>
+       ,LLB=
+       <foreach collection="list" item="item" index="index" separator=" " open="case DATES" close="end">
+          when #{item.dates,jdbcType=TIMESTAMP} then #{item.llb,jdbcType=DECIMAL}
+       </foreach>
+     where DATES in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.dates,jdbcType=TIMESTAMP}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from EMS_SCQK_LG
+    where DATES in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+  
+</mapper>

+ 334 - 0
src/main/java/com/steerinfo/ems/emsscqklg/model/EmsScqkLg.java

@@ -0,0 +1,334 @@
+package com.steerinfo.ems.emsscqklg.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="生产情况-炼钢")
+public class EmsScqkLg implements IBasePO<Date> {
+    /**
+     * 生产日期(DATES,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="生产日期",required=true)
+    private Date dates;
+
+    /**
+     * 钢坯日产量(RCL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="钢坯日产量",required=false)
+    private BigDecimal rcl;
+
+    /**
+     * 进入炼钢铁水量(JTSL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="进入炼钢铁水量",required=false)
+    private BigDecimal jtsl;
+
+    /**
+     * 炼钢实际用量(SJYL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="炼钢实际用量",required=false)
+    private BigDecimal sjyl;
+
+    /**
+     * 库存量(铁水)(KCL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="库存量(铁水)",required=false)
+    private BigDecimal kcl;
+
+    /**
+     * 未浇钢水量(WJZL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="未浇钢水量",required=false)
+    private BigDecimal wjzl;
+
+    /**
+     * 生产炉数(SCLS,DECIMAL,0)
+     */
+    @ApiModelProperty(value="生产炉数",required=false)
+    private BigDecimal scls;
+
+    /**
+     * 1#炉龄(LL_1,DECIMAL,0)
+     */
+    @ApiModelProperty(value="1#炉龄",required=false)
+    private BigDecimal ll1;
+
+    /**
+     * 2#炉龄(LL_2,DECIMAL,0)
+     */
+    @ApiModelProperty(value="2#炉龄",required=false)
+    private BigDecimal ll2;
+
+    /**
+     * 废钢总量_内部含生铁(FGZL_NBHST,DECIMAL,0)
+     */
+    @ApiModelProperty(value="废钢总量_内部含生铁",required=false)
+    private BigDecimal fgzlNbhst;
+
+    /**
+     * 废钢总量_外购(FGZL_WG,DECIMAL,0)
+     */
+    @ApiModelProperty(value="废钢总量_外购",required=false)
+    private BigDecimal fgzlWg;
+
+    /**
+     * 冷料单炉用量(LLDLYL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="冷料单炉用量",required=false)
+    private BigDecimal lldlyl;
+
+    /**
+     * 外购废钢_进废钢坑(WGFG_JFGK,DECIMAL,0)
+     */
+    @ApiModelProperty(value="外购废钢_进废钢坑",required=false)
+    private BigDecimal wgfgJfgk;
+
+    /**
+     * 外购废钢_去席村废钢量(WGFG_QXC,DECIMAL,0)
+     */
+    @ApiModelProperty(value="外购废钢_去席村废钢量",required=false)
+    private BigDecimal wgfgQxc;
+
+    /**
+     * 席村返回废钢量(XCF,DECIMAL,0)
+     */
+    @ApiModelProperty(value="席村返回废钢量",required=false)
+    private BigDecimal xcf;
+
+    /**
+     * 记事(MEMO,VARCHAR,500)
+     */
+    @ApiModelProperty(value="记事",required=false)
+    private String memo;
+
+    /**
+     * 操作人(CZR,VARCHAR,10)
+     */
+    @ApiModelProperty(value="操作人",required=false)
+    private String czr;
+
+    /**
+     * 操作时间(CZSJ,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="操作时间",required=false)
+    private Date czsj;
+
+    /**
+     * 外销钢坯产量(WXGPCL,DECIMAL,0)
+     */
+    @ApiModelProperty(value="外销钢坯产量",required=false)
+    private BigDecimal wxgpcl;
+
+    /**
+     * 冷料比(LLB,DECIMAL,0)
+     */
+    @ApiModelProperty(value="冷料比",required=false)
+    private BigDecimal llb;
+
+    private static final long serialVersionUID = 1L;
+
+    @Override
+    public Date getId() {
+        return this.dates;
+    }
+
+    @Override
+    public void setId(Date dates) {
+        this.dates = dates;
+    }
+
+    public Date getDates() {
+        return dates;
+    }
+
+    public void setDates(Date dates) {
+        this.dates = dates;
+    }
+
+    public BigDecimal getRcl() {
+        return rcl;
+    }
+
+    public void setRcl(BigDecimal rcl) {
+        this.rcl = rcl;
+    }
+
+    public BigDecimal getJtsl() {
+        return jtsl;
+    }
+
+    public void setJtsl(BigDecimal jtsl) {
+        this.jtsl = jtsl;
+    }
+
+    public BigDecimal getSjyl() {
+        return sjyl;
+    }
+
+    public void setSjyl(BigDecimal sjyl) {
+        this.sjyl = sjyl;
+    }
+
+    public BigDecimal getKcl() {
+        return kcl;
+    }
+
+    public void setKcl(BigDecimal kcl) {
+        this.kcl = kcl;
+    }
+
+    public BigDecimal getWjzl() {
+        return wjzl;
+    }
+
+    public void setWjzl(BigDecimal wjzl) {
+        this.wjzl = wjzl;
+    }
+
+    public BigDecimal getScls() {
+        return scls;
+    }
+
+    public void setScls(BigDecimal scls) {
+        this.scls = scls;
+    }
+
+    public BigDecimal getLl1() {
+        return ll1;
+    }
+
+    public void setLl1(BigDecimal ll1) {
+        this.ll1 = ll1;
+    }
+
+    public BigDecimal getLl2() {
+        return ll2;
+    }
+
+    public void setLl2(BigDecimal ll2) {
+        this.ll2 = ll2;
+    }
+
+    public BigDecimal getFgzlNbhst() {
+        return fgzlNbhst;
+    }
+
+    public void setFgzlNbhst(BigDecimal fgzlNbhst) {
+        this.fgzlNbhst = fgzlNbhst;
+    }
+
+    public BigDecimal getFgzlWg() {
+        return fgzlWg;
+    }
+
+    public void setFgzlWg(BigDecimal fgzlWg) {
+        this.fgzlWg = fgzlWg;
+    }
+
+    public BigDecimal getLldlyl() {
+        return lldlyl;
+    }
+
+    public void setLldlyl(BigDecimal lldlyl) {
+        this.lldlyl = lldlyl;
+    }
+
+    public BigDecimal getWgfgJfgk() {
+        return wgfgJfgk;
+    }
+
+    public void setWgfgJfgk(BigDecimal wgfgJfgk) {
+        this.wgfgJfgk = wgfgJfgk;
+    }
+
+    public BigDecimal getWgfgQxc() {
+        return wgfgQxc;
+    }
+
+    public void setWgfgQxc(BigDecimal wgfgQxc) {
+        this.wgfgQxc = wgfgQxc;
+    }
+
+    public BigDecimal getXcf() {
+        return xcf;
+    }
+
+    public void setXcf(BigDecimal xcf) {
+        this.xcf = xcf;
+    }
+
+    public String getMemo() {
+        return memo;
+    }
+
+    public void setMemo(String memo) {
+        this.memo = memo == null ? null : memo.trim();
+    }
+
+    public String getCzr() {
+        return czr;
+    }
+
+    public void setCzr(String czr) {
+        this.czr = czr == null ? null : czr.trim();
+    }
+
+    public Date getCzsj() {
+        return czsj;
+    }
+
+    public void setCzsj(Date czsj) {
+        this.czsj = czsj;
+    }
+
+    public BigDecimal getWxgpcl() {
+        return wxgpcl;
+    }
+
+    public void setWxgpcl(BigDecimal wxgpcl) {
+        this.wxgpcl = wxgpcl;
+    }
+
+    public BigDecimal getLlb() {
+        return llb;
+    }
+
+    public void setLlb(BigDecimal llb) {
+        this.llb = llb;
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", dates=").append(dates);
+        sb.append(", rcl=").append(rcl);
+        sb.append(", jtsl=").append(jtsl);
+        sb.append(", sjyl=").append(sjyl);
+        sb.append(", kcl=").append(kcl);
+        sb.append(", wjzl=").append(wjzl);
+        sb.append(", scls=").append(scls);
+        sb.append(", ll1=").append(ll1);
+        sb.append(", ll2=").append(ll2);
+        sb.append(", fgzlNbhst=").append(fgzlNbhst);
+        sb.append(", fgzlWg=").append(fgzlWg);
+        sb.append(", lldlyl=").append(lldlyl);
+        sb.append(", wgfgJfgk=").append(wgfgJfgk);
+        sb.append(", wgfgQxc=").append(wgfgQxc);
+        sb.append(", xcf=").append(xcf);
+        sb.append(", memo=").append(memo);
+        sb.append(", czr=").append(czr);
+        sb.append(", czsj=").append(czsj);
+        sb.append(", wxgpcl=").append(wxgpcl);
+        sb.append(", llb=").append(llb);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 28 - 0
src/main/java/com/steerinfo/ems/emsscqklg/service/EmsLgReportService.java

@@ -0,0 +1,28 @@
+package com.steerinfo.ems.emsscqklg.service;
+
+import com.steerinfo.ems.emsscqklg.model.EmsScqkLg;
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.stereotype.Component;
+import org.springframework.web.bind.annotation.GetMapping;
+
+import java.util.List;
+
+/**
+ * EmsScqkLg服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-19 10:43
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-19
+ * 作者:generator
+ * 参考:
+ * 描述:EmsScqkLg服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@FeignClient(value = "xt-ems-datasource")
+@Component
+public interface EmsLgReportService {
+    @GetMapping("v1/lgreport/queryReportByTime")
+    public List<EmsScqkLg> queryReportByTime();
+}

+ 24 - 0
src/main/java/com/steerinfo/ems/emsscqklg/service/IEmsScqkLgService.java

@@ -0,0 +1,24 @@
+package com.steerinfo.ems.emsscqklg.service;
+
+import com.steerinfo.ems.emsscqklg.model.EmsScqkLg;
+import com.steerinfo.framework.service.IBaseService;
+
+import java.util.Date;
+
+/**
+ * EmsScqkLg服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-19 10:43
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-19
+ * 作者:generator
+ * 参考:
+ * 描述:EmsScqkLg服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+
+public interface IEmsScqkLgService extends IBaseService<EmsScqkLg, Date>{
+    int dateGenerate();
+}

+ 61 - 0
src/main/java/com/steerinfo/ems/emsscqklg/service/impl/EmsScqkLgServiceImpl.java

@@ -0,0 +1,61 @@
+package com.steerinfo.ems.emsscqklg.service.impl;
+
+import com.steerinfo.ems.emsscqklg.mapper.EmsScqkLgMapper;
+import com.steerinfo.ems.emsscqklg.model.EmsScqkLg;
+import com.steerinfo.ems.emsscqklg.service.EmsLgReportService;
+import com.steerinfo.ems.emsscqklg.service.IEmsScqkLgService;
+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.util.Date;
+import java.util.List;
+
+/**
+ * EmsScqkLg服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-19 10:43
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-19
+ * 作者:generator
+ * 参考:
+ * 描述:EmsScqkLg服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "emsScqkLgService")
+public class EmsScqkLgServiceImpl extends BaseServiceImpl<EmsScqkLg, Date> implements IEmsScqkLgService {
+
+    @Autowired
+    private EmsScqkLgMapper emsScqkLgMapper;
+
+    @Autowired
+    private EmsLgReportService emsLgReportService;
+
+    @Override
+    protected IBaseMapper<EmsScqkLg, Date> getMapper() {
+        return emsScqkLgMapper;
+    }
+
+
+    @Override
+    public int dateGenerate() {
+       List<EmsScqkLg> emsScqkLgs =  emsLgReportService.queryReportByTime();
+       EmsScqkLg model;
+       Integer number=0;
+       for(EmsScqkLg emsScqkLg :emsScqkLgs)
+       {
+           emsScqkLg.setCzr("炼钢MES");
+           emsScqkLg.setCzsj(new Date());
+           model = emsScqkLgMapper.selectByPrimaryKey(emsScqkLg.getId());
+           if(model == null){
+              number += emsScqkLgMapper.insert(emsScqkLg);
+              continue;
+           }
+           number += emsScqkLgMapper.updateByPrimaryKeySelective(emsScqkLg);
+       }
+        return number;
+    }
+}

+ 131 - 0
src/main/java/com/steerinfo/ems/foldthevalues/controller/FoldTheValuesController.java

@@ -0,0 +1,131 @@
+package com.steerinfo.ems.foldthevalues.controller;
+
+import com.steerinfo.ems.foldthevalues.mapper.FoldTheValuesMapper;
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import com.steerinfo.ems.foldthevalues.model.FoldTheValues;
+import com.steerinfo.ems.foldthevalues.service.IFoldTheValuesService;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiModelProperty;
+import io.swagger.annotations.ApiOperation;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import javax.script.ScriptException;
+import java.util.*;
+import java.math.BigDecimal;
+
+/**
+ * FoldTheValues RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 02:33
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:FoldTheValues RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/foldthevaluess")
+public class FoldTheValuesController extends BaseRESTfulController {
+
+    @Autowired
+    IFoldTheValuesService foldTheValuesService;
+    @Autowired
+    FoldTheValuesMapper foldTheValuesMapper;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("foldthevalues:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<FoldTheValues> list = foldTheValuesService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("foldthevalues:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<FoldTheValues> list = foldTheValuesService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据FoldTheValues对象创建")
+    @ApiImplicitParam(name = "foldTheValues", value = "详细实体foldTheValues", required = true, dataType = "FoldTheValues")
+    //@RequiresPermissions("foldthevalues:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@ModelAttribute FoldTheValues model){
+        FoldTheValues foldTheValues = foldTheValuesService.add(model);
+        return success(foldTheValues);
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("foldthevalues:view")
+    @GetMapping(value = "/{id}")
+    public RESTfulResult get(@PathVariable String id){
+        FoldTheValues foldTheValues = foldTheValuesService.getById(id);
+        return success(foldTheValues);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的foldTheValues信息来更新详细信息")
+    @ApiImplicitParams({
+        @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String"),
+        @ApiImplicitParam(name = "foldTheValues", value = "详细实体foldTheValues", required = true, dataType = "FoldTheValues")
+    })
+    //@RequiresPermissions("foldthevalues:update")
+    @PutMapping(produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update( @RequestBody FoldTheValues[] models){
+        for (FoldTheValues model : models) {
+            foldTheValuesMapper.updateByPrimaryKey(model);
+        }
+        return success();
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("foldthevalues:delete")
+    @DeleteMapping(value = "/{id}")//String
+    public RESTfulResult delete(@PathVariable String id){
+    	List<String> list = Arrays.asList(id.split(","));
+    	if(ListUtils.isNotEmpty(list)) {
+	    	List<String> ids = ListUtils.convertList(list);
+			  foldTheValuesService.delete(ids);
+    	}
+      return success();
+    }
+
+    @GetMapping("/aaa")
+    public RESTfulResult getdate() throws ScriptException {
+        foldTheValuesService.getDate();
+        return  success();
+    }
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+            @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("foldthevalues:view")
+    @GetMapping(value = "/getDateForPage")
+    public RESTfulResult getDateForPage (@RequestParam HashMap<String, Object> parmas,Integer pageNum, Integer pageSize) {
+        PageList<Map<String, Object>> forPage = foldTheValuesService.getDateForPage(parmas, pageNum, pageSize);
+        return success(forPage);
+    }
+
+}

+ 20 - 0
src/main/java/com/steerinfo/ems/foldthevalues/mapper/FoldTheValuesMapper.java

@@ -0,0 +1,20 @@
+package com.steerinfo.ems.foldthevalues.mapper;
+
+import com.steerinfo.ems.foldthevalues.model.FoldTheValues;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import java.math.*;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface FoldTheValuesMapper extends IBaseMapper<FoldTheValues, String> {
+    /**
+     * 获取页面数据
+     * @param parmas
+     * @return
+     */
+    List<Map<String, Object>> getDateForPage(HashMap<String,Object> parmas);
+}

+ 356 - 0
src/main/java/com/steerinfo/ems/foldthevalues/mapper/FoldTheValuesMapper.xml

@@ -0,0 +1,356 @@
+<?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.ems.foldthevalues.mapper.FoldTheValuesMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.foldthevalues.model.FoldTheValues">
+    <id column="ID" jdbcType="VARCHAR" property="id" />
+    <result column="MATERIALSOURCE" jdbcType="VARCHAR" property="materialsource" />
+    <result column="CLOCK" jdbcType="VARCHAR" property="clock" />
+    <result column="CODE" jdbcType="VARCHAR" property="code" />
+    <result column="DESCRIPTION" jdbcType="VARCHAR" property="description" />
+    <result column="ISAVAILABLE" jdbcType="VARCHAR" property="isavailable" />
+    <result column="REVISOR" jdbcType="VARCHAR" property="revisor" />
+    <result column="REVISETIME" jdbcType="VARCHAR" property="revisetime" />
+    <result column="UNITID" jdbcType="VARCHAR" property="unitid" />
+    <result column="BZ" jdbcType="VARCHAR" property="bz" />
+    <result column="MATERIALNO" jdbcType="VARCHAR" property="materialno"/>
+  </resultMap>
+  <sql id="columns">
+    ID, MATERIALSOURCE, CLOCK, CODE, DESCRIPTION, ISAVAILABLE, REVISOR, REVISETIME,
+    UNITID, BZ,MATERIALNO
+  </sql>
+  <sql id="columns_alias">
+    t.ID, t.MATERIALSOURCE, t.CLOCK, t.CODE, t.DESCRIPTION, t.ISAVAILABLE, t.REVISOR,
+    t.REVISETIME, t.UNITID, t.BZ,t.MATERIALNO
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM FOLD_THE_VALUES
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM FOLD_THE_VALUES t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="id != null and id != ''">
+        and ID = #{id}
+      </if>
+      <if test="materialsource != null and materialsource != ''">
+        and MATERIALSOURCE = #{materialsource}
+      </if>
+      <if test="clock != null and clock != ''">
+        and CLOCK = #{clock}
+      </if>
+      <if test="code != null and code != ''">
+        and CODE = #{code}
+      </if>
+      <if test="description != null and description != ''">
+        and DESCRIPTION = #{description}
+      </if>
+      <if test="isavailable != null and isavailable != ''">
+        and ISAVAILABLE = #{isavailable}
+      </if>
+      <if test="revisor != null and revisor != ''">
+        and REVISOR = #{revisor}
+      </if>
+      <if test="revisetime != null and revisetime != ''">
+        and REVISETIME = #{revisetime}
+      </if>
+      <if test="unitid != null and unitid != ''">
+        and UNITID = #{unitid}
+      </if>
+      <if test="bz != null and bz != ''">
+        and BZ = #{bz}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="id != null and id != ''">
+        and ID LIKE '%${id}%'
+      </if>
+      <if test="materialsource != null and materialsource != ''">
+        and MATERIALSOURCE LIKE '%${materialsource}%'
+      </if>
+      <if test="clock != null and clock != ''">
+        and CLOCK LIKE '%${clock}%'
+      </if>
+      <if test="code != null and code != ''">
+        and CODE LIKE '%${code}%'
+      </if>
+      <if test="description != null and description != ''">
+        and DESCRIPTION LIKE '%${description}%'
+      </if>
+      <if test="isavailable != null and isavailable != ''">
+        and ISAVAILABLE LIKE '%${isavailable}%'
+      </if>
+      <if test="revisor != null and revisor != ''">
+        and REVISOR LIKE '%${revisor}%'
+      </if>
+      <if test="revisetime != null and revisetime != ''">
+        and REVISETIME LIKE '%${revisetime}%'
+      </if>
+      <if test="unitid != null and unitid != ''">
+        and UNITID LIKE '%${unitid}%'
+      </if>
+      <if test="bz != null and bz != ''">
+        and BZ LIKE '%${bz}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from FOLD_THE_VALUES
+    where ID = #{id,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from FOLD_THE_VALUES
+    where 1!=1 
+      <if test="materialsource != null and materialsource != ''">
+        or MATERIALSOURCE = #{materialsource}
+      </if>
+      <if test="clock != null and clock != ''">
+        or CLOCK = #{clock}
+      </if>
+      <if test="code != null and code != ''">
+        or CODE = #{code}
+      </if>
+      <if test="description != null and description != ''">
+        or DESCRIPTION = #{description}
+      </if>
+      <if test="isavailable != null and isavailable != ''">
+        or ISAVAILABLE = #{isavailable}
+      </if>
+      <if test="revisor != null and revisor != ''">
+        or REVISOR = #{revisor}
+      </if>
+      <if test="revisetime != null and revisetime != ''">
+        or REVISETIME = #{revisetime}
+      </if>
+      <if test="unitid != null and unitid != ''">
+        or UNITID = #{unitid}
+      </if>
+      <if test="bz != null and bz != ''">
+        or BZ = #{bz}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.foldthevalues.model.FoldTheValues">
+    insert into FOLD_THE_VALUES (ID, MATERIALSOURCE, CLOCK,
+      CODE, DESCRIPTION, ISAVAILABLE, 
+      REVISOR, REVISETIME,MATERIALNO,
+      UNITID, BZ)
+    values (#{id,jdbcType=VARCHAR}, #{materialsource,jdbcType=VARCHAR}, #{clock,jdbcType=VARCHAR}, 
+      #{code,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR}, #{isavailable,jdbcType=VARCHAR}, 
+      #{revisor,jdbcType=VARCHAR}, #{revisetime,jdbcType=VARCHAR},#{materialno,jdbcType=VARCHAR},
+      #{unitid,jdbcType=VARCHAR}, #{bz,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.foldthevalues.model.FoldTheValues">
+    insert into FOLD_THE_VALUES
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        ID,
+      </if>
+      <if test="materialsource != null">
+        MATERIALSOURCE,
+      </if>
+      <if test="clock != null">
+        CLOCK,
+      </if>
+      <if test="code != null">
+        CODE,
+      </if>
+      <if test="description != null">
+        DESCRIPTION,
+      </if>
+      <if test="isavailable != null">
+        ISAVAILABLE,
+      </if>
+      <if test="revisor != null">
+        REVISOR,
+      </if>
+      <if test="revisetime != null">
+        REVISETIME,
+      </if>
+      <if test="unitid != null">
+        UNITID,
+      </if>
+      <if test="bz != null">
+        BZ,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=VARCHAR},
+      </if>
+      <if test="materialsource != null">
+        #{materialsource,jdbcType=VARCHAR},
+      </if>
+      <if test="clock != null">
+        #{clock,jdbcType=VARCHAR},
+      </if>
+      <if test="code != null">
+        #{code,jdbcType=VARCHAR},
+      </if>
+      <if test="description != null">
+        #{description,jdbcType=VARCHAR},
+      </if>
+      <if test="isavailable != null">
+        #{isavailable,jdbcType=VARCHAR},
+      </if>
+      <if test="revisor != null">
+        #{revisor,jdbcType=VARCHAR},
+      </if>
+      <if test="revisetime != null">
+        #{revisetime,jdbcType=VARCHAR},
+      </if>
+      <if test="unitid != null">
+        #{unitid,jdbcType=VARCHAR},
+      </if>
+      <if test="bz != null">
+        #{bz,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.foldthevalues.model.FoldTheValues">
+    update FOLD_THE_VALUES
+    set
+      CLOCK = #{clock,jdbcType=VARCHAR},
+      CODE = #{code,jdbcType=VARCHAR},
+      DESCRIPTION = #{description,jdbcType=VARCHAR},
+      ISAVAILABLE = #{isavailable,jdbcType=VARCHAR},
+      REVISOR = #{revisor,jdbcType=VARCHAR},
+      REVISETIME = #{revisetime,jdbcType=VARCHAR},
+      UNITID = #{unitid,jdbcType=VARCHAR},
+      BZ = #{bz,jdbcType=VARCHAR}
+    where ID = #{id,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.foldthevalues.model.FoldTheValues">
+    update FOLD_THE_VALUES
+    <set>
+      <if test="materialsource != null">
+        MATERIALSOURCE = #{materialsource,jdbcType=VARCHAR},
+      </if>
+      <if test="clock != null">
+        CLOCK = #{clock,jdbcType=VARCHAR},
+      </if>
+      <if test="code != null">
+        CODE = #{code,jdbcType=VARCHAR},
+      </if>
+      <if test="description != null">
+        DESCRIPTION = #{description,jdbcType=VARCHAR},
+      </if>
+      <if test="isavailable != null">
+        ISAVAILABLE = #{isavailable,jdbcType=VARCHAR},
+      </if>
+      <if test="revisor != null">
+        REVISOR = #{revisor,jdbcType=VARCHAR},
+      </if>
+      <if test="revisetime != null">
+        REVISETIME = #{revisetime,jdbcType=VARCHAR},
+      </if>
+      <if test="unitid != null">
+        UNITID = #{unitid,jdbcType=VARCHAR},
+      </if>
+      <if test="bz != null">
+        BZ = #{bz,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where ID = #{id,jdbcType=VARCHAR}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where ID = #{id,jdbcType=VARCHAR}
+  </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 FOLD_THE_VALUES 
+      (ID, 
+      MATERIALSOURCE, CLOCK, CODE, 
+      DESCRIPTION, ISAVAILABLE, REVISOR, 
+      REVISETIME, UNITID,
+      BZ)
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.id,jdbcType=VARCHAR}, 
+      #{item.materialsource,jdbcType=VARCHAR}, #{item.clock,jdbcType=VARCHAR}, #{item.code,jdbcType=VARCHAR}, 
+      #{item.description,jdbcType=VARCHAR}, #{item.isavailable,jdbcType=VARCHAR}, #{item.revisor,jdbcType=VARCHAR}, 
+      #{item.revisetime,jdbcType=VARCHAR}, #{item.unitid,jdbcType=VARCHAR},
+      #{item.bz,jdbcType=VARCHAR} from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update FOLD_THE_VALUES
+     set
+       ID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.id,jdbcType=VARCHAR}
+       </foreach>
+       ,MATERIALSOURCE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.materialsource,jdbcType=VARCHAR}
+       </foreach>
+       ,CLOCK=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.clock,jdbcType=VARCHAR}
+       </foreach>
+       ,CODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.code,jdbcType=VARCHAR}
+       </foreach>
+       ,DESCRIPTION=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.description,jdbcType=VARCHAR}
+       </foreach>
+       ,ISAVAILABLE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.isavailable,jdbcType=VARCHAR}
+       </foreach>
+       ,REVISOR=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.revisor,jdbcType=VARCHAR}
+       </foreach>
+       ,REVISETIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.revisetime,jdbcType=VARCHAR}
+       </foreach>
+       ,UNITID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.unitid,jdbcType=VARCHAR}
+       </foreach>
+       ,BZ=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.bz,jdbcType=VARCHAR}
+       </foreach>
+     where ID in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.id,jdbcType=VARCHAR}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from FOLD_THE_VALUES
+    where ID in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+  <select id="getDateForPage" parameterType="java.util.HashMap" resultType="Map">
+    select t.*, t1.id as energyid, t1.name as energyname
+      from Fold_the_values t
+      left join t_rm_energy t1
+      on t.materialno = t1.bdesc1
+      <where>
+        <if test="clock != null and clock != '' ">
+          and t.clock = #{clock}
+        </if>
+        <if test="energyid != null and energyid != '' ">
+          and t1.energyid = #{energyid}
+        </if>
+      </where>
+  </select>
+</mapper>

+ 181 - 0
src/main/java/com/steerinfo/ems/foldthevalues/model/FoldTheValues.java

@@ -0,0 +1,181 @@
+package com.steerinfo.ems.foldthevalues.model;
+
+import com.steerinfo.framework.model.IBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+@ApiModel(value="折标系数值表")
+public class FoldTheValues implements IBasePO<String> {
+    /**
+     * ID(ID,VARCHAR,100)
+     */
+    @ApiModelProperty(value="ID",required=true)
+    private String id;
+
+    @ApiModelProperty(value="物料来源",required=false)
+    private String materialsource;
+
+    /**
+     * 版本(CLOCK,VARCHAR,30)
+     */
+    @ApiModelProperty(value="版本",required=false)
+    private String clock;
+
+    /**
+     * 折标值(CODE,VARCHAR,60)
+     */
+    @ApiModelProperty(value="折标值",required=false)
+    private String code;
+
+    /**
+     * 描述(DESCRIPTION,VARCHAR,500)
+     */
+    @ApiModelProperty(value="描述",required=false)
+    private String description;
+
+    /**
+     * 是否可用(ISAVAILABLE,VARCHAR,10)
+     */
+    @ApiModelProperty(value="是否可用",required=false)
+    private String isavailable;
+
+    /**
+     * 修改者(REVISOR,VARCHAR,30)
+     */
+    @ApiModelProperty(value="修改者",required=false)
+    private String revisor;
+
+    /**
+     * 修改时间(REVISETIME,VARCHAR,30)
+     */
+    @ApiModelProperty(value="修改时间",required=false)
+    private String revisetime;
+
+    /**
+     * 单位(UNITID,VARCHAR,20)
+     */
+    @ApiModelProperty(value="单位",required=false)
+    private String unitid;
+    /**
+     * 物料编码
+     */
+     @ApiModelProperty(value="物料编码",required=false)
+     private String materialno;
+
+    public String getMaterialno() {
+        return materialno;
+    }
+
+    public void setMaterialno(String materialno) {
+        this.materialno = materialno;
+    }
+
+    /**
+     * 备注(BZ,VARCHAR,255)
+     */
+    @ApiModelProperty(value="备注",required=false)
+    private String bz;
+
+    private static final long serialVersionUID = 1L;
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id == null ? null : id.trim();
+    }
+
+    public String getMaterialsource() {
+        return materialsource;
+    }
+
+    public void setMaterialsource(String materialsource) {
+        this.materialsource = materialsource == null ? null : materialsource.trim();
+    }
+
+    public String getClock() {
+        return clock;
+    }
+
+    public void setClock(String clock) {
+        this.clock = clock == null ? null : clock.trim();
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public void setCode(String code) {
+        this.code = code == null ? null : code.trim();
+    }
+
+    public String getDescription() {
+        return description;
+    }
+
+    public void setDescription(String description) {
+        this.description = description == null ? null : description.trim();
+    }
+
+    public String getIsavailable() {
+        return isavailable;
+    }
+
+    public void setIsavailable(String isavailable) {
+        this.isavailable = isavailable == null ? null : isavailable.trim();
+    }
+
+    public String getRevisor() {
+        return revisor;
+    }
+
+    public void setRevisor(String revisor) {
+        this.revisor = revisor == null ? null : revisor.trim();
+    }
+
+    public String getRevisetime() {
+        return revisetime;
+    }
+
+    public void setRevisetime(String revisetime) {
+        this.revisetime = revisetime == null ? null : revisetime.trim();
+    }
+
+    public String getUnitid() {
+        return unitid;
+    }
+
+    public void setUnitid(String unitid) {
+        this.unitid = unitid == null ? null : unitid.trim();
+    }
+
+    public String getBz() {
+        return bz;
+    }
+
+    public void setBz(String bz) {
+        this.bz = bz == null ? null : bz.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", id=").append(id);
+        sb.append(", materialsource=").append(materialsource);
+        sb.append(", clock=").append(clock);
+        sb.append(", code=").append(code);
+        sb.append(", description=").append(description);
+        sb.append(", isavailable=").append(isavailable);
+        sb.append(", revisor=").append(revisor);
+        sb.append(", revisetime=").append(revisetime);
+        sb.append(", unitid=").append(unitid);
+        sb.append(", bz=").append(bz);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 32 - 0
src/main/java/com/steerinfo/ems/foldthevalues/service/IFoldTheValuesService.java

@@ -0,0 +1,32 @@
+package com.steerinfo.ems.foldthevalues.service;
+
+import com.steerinfo.framework.service.IBaseService;
+import com.steerinfo.ems.foldthevalues.model.FoldTheValues;
+import com.steerinfo.framework.service.pagehelper.PageList;
+
+import javax.script.ScriptException;
+import java.util.Date;
+import java.math.BigDecimal;
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * FoldTheValues服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 02:33
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:FoldTheValues服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IFoldTheValuesService extends IBaseService<FoldTheValues, String>{
+    public void getDate()throws ScriptException;
+
+    public PageList<Map<String, Object>> getDateForPage(HashMap<String, Object> parmas, Integer pageNum,
+                                                   Integer pageSize);
+
+}

+ 114 - 0
src/main/java/com/steerinfo/ems/foldthevalues/service/impl/FoldTheValuesServiceImpl.java

@@ -0,0 +1,114 @@
+package com.steerinfo.ems.foldthevalues.service.impl;
+
+import com.steerinfo.ems.Utils.DateUtils;
+import com.steerinfo.ems.emscalorificvalue.mapper.EmsCalorificValueMapper;
+import com.steerinfo.ems.emscalorificvalue.model.EmsCalorificValue;
+import com.steerinfo.ems.njformula.mapper.NjFormulaMapper;
+import com.steerinfo.ems.njformula.model.NjFormula;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import com.steerinfo.ems.foldthevalues.model.FoldTheValues;
+import com.steerinfo.ems.foldthevalues.mapper.FoldTheValuesMapper;
+import com.steerinfo.ems.foldthevalues.service.IFoldTheValuesService;
+import com.steerinfo.framework.service.pagehelper.PageHelper;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import javax.script.ScriptEngine;
+import javax.script.ScriptEngineManager;
+import javax.script.ScriptException;
+import java.text.DecimalFormat;
+import java.util.Date;
+import java.math.BigDecimal;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * FoldTheValues服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 02:33
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:FoldTheValues服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "foldTheValuesService")
+public class FoldTheValuesServiceImpl extends BaseServiceImpl<FoldTheValues, String> implements IFoldTheValuesService {
+    @Autowired
+    private FoldTheValuesMapper foldTheValuesMapper;
+    @Autowired
+    private EmsCalorificValueMapper emsCalorificValueMapper;
+    @Autowired
+    private NjFormulaMapper njFormulaMapper;
+
+
+    @Override
+    protected IBaseMapper<FoldTheValues, String> getMapper() {
+        return foldTheValuesMapper;
+    }
+
+    public void getDate() throws ScriptException {
+        List<EmsCalorificValue> newDate = emsCalorificValueMapper.getNewDate();
+        FoldTheValues foldTheValues = new FoldTheValues();
+        for (EmsCalorificValue emsCalorificValue : newDate) {
+            foldTheValues.setMaterialsource(emsCalorificValue.getMaterialsource());
+            foldTheValues.setClock(emsCalorificValue.getSampleno());
+            foldTheValues.setCode(this.getzbz(emsCalorificValue) == null ? "0.00" : this.getzbz(emsCalorificValue));
+            foldTheValues.setMaterialno(emsCalorificValue.getMaterialno());
+            foldTheValues.setIsavailable("0");
+            foldTheValues.setUnitid("033");
+            foldTheValues.setId(emsCalorificValue.getWtbh());
+            foldTheValuesMapper.insert(foldTheValues);
+        }
+    }
+
+    @Override
+    public PageList<Map<String, Object>> getDateForPage(HashMap<String, Object> parmas, Integer pageNum, Integer pageSize) {
+        PageHelper.startPage(pageNum,pageSize);
+        List<Map<String, Object>> dateLc = foldTheValuesMapper.getDateForPage(parmas);
+        PageList<Map<String, Object>> pageInfo = new PageList<Map<String, Object>>(dateLc);
+        return pageInfo;
+    }
+
+    //获取折标值
+    public String getzbz(EmsCalorificValue emsCalorificValue) throws ScriptException {
+        ScriptEngine jse = new ScriptEngineManager().getEngineByName("JavaScript");
+        //首先获取公式
+        NjFormula njFormula = njFormulaMapper.getByMateralNo(emsCalorificValue.getMaterialno());
+        String formula = njFormula.getCode();
+        if (null == formula ){
+            return  null;
+        }
+        HashMap map =  new HashMap();
+        map.put("wtbh",emsCalorificValue.getWtbh());
+        if(formula.contains("CO") == true){
+            map.put("item","CO");
+            String value = emsCalorificValueMapper.getValue(map) == null ? "0.00" : emsCalorificValueMapper.getValue(map);
+            formula = formula.replace("CO", value);
+        }
+        if (formula.contains("H2") == true){
+            map.put("item","H2");
+            String value = emsCalorificValueMapper.getValue(map) == null ? "0.00" : emsCalorificValueMapper.getValue(map);
+            formula = formula.replace("H2", value);
+        }
+        if (formula.contains("CH4") == true){
+            map.put("item","CH4");
+            String value = emsCalorificValueMapper.getValue(map) == null ? "0.00" : emsCalorificValueMapper.getValue(map);
+            formula = formula.replace("CH4", value);
+        }
+        if (formula.contains("N2") == true){
+            map.put("item","N2");
+            String value = emsCalorificValueMapper.getValue(map) == null ? "0.00" :emsCalorificValueMapper.getValue(map);
+            formula = formula.replace("N2", value);
+        }
+        DecimalFormat df   = new DecimalFormat("0.00");
+        return  df.format(jse.eval(formula)).toString();
+    }
+
+}

+ 110 - 0
src/main/java/com/steerinfo/ems/njformula/controller/NjFormulaController.java

@@ -0,0 +1,110 @@
+package com.steerinfo.ems.njformula.controller;
+
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import com.steerinfo.ems.njformula.model.NjFormula;
+import com.steerinfo.ems.njformula.service.INjFormulaService;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.ArrayList;
+import java.math.BigDecimal;
+
+/**
+ * NjFormula RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 02:53
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:NjFormula RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/njformulas")
+public class NjFormulaController extends BaseRESTfulController {
+
+    @Autowired
+    INjFormulaService njFormulaService;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("njformula:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<NjFormula> list = njFormulaService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("njformula:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<NjFormula> list = njFormulaService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据NjFormula对象创建")
+    @ApiImplicitParam(name = "njFormula", value = "详细实体njFormula", required = true, dataType = "NjFormula")
+    //@RequiresPermissions("njformula:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@ModelAttribute NjFormula model){
+        NjFormula njFormula = njFormulaService.add(model);
+        return success(njFormula);
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("njformula:view")
+    @GetMapping(value = "/{id}")
+    public RESTfulResult get(@PathVariable String id){
+        NjFormula njFormula = njFormulaService.getById(id);
+        return success(njFormula);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的njFormula信息来更新详细信息")
+    @ApiImplicitParams({
+        @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String"),
+        @ApiImplicitParam(name = "njFormula", value = "详细实体njFormula", required = true, dataType = "NjFormula")
+    })
+    //@RequiresPermissions("njformula:update")
+    @PutMapping(value = "/{id}", produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update(@PathVariable String id, @RequestBody NjFormula model){
+        model.setId(id);
+        NjFormula njFormula = njFormulaService.modify(model);
+        return success(njFormula);
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
+    //@RequiresPermissions("njformula:delete")
+    @DeleteMapping(value = "/{id}")//String
+    public RESTfulResult delete(@PathVariable String id){
+    	List<String> list = Arrays.asList(id.split(","));
+    	if(ListUtils.isNotEmpty(list)) {
+	    	List<String> ids = ListUtils.convertList(list);
+			  njFormulaService.delete(ids);
+    	}
+      return success();
+    }
+}

+ 13 - 0
src/main/java/com/steerinfo/ems/njformula/mapper/NjFormulaMapper.java

@@ -0,0 +1,13 @@
+package com.steerinfo.ems.njformula.mapper;
+
+import com.steerinfo.ems.njformula.model.NjFormula;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import java.math.*;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+@Mapper
+public interface NjFormulaMapper extends IBaseMapper<NjFormula, String> {
+    //根据物料编码获取公式
+    public NjFormula getByMateralNo(@Param("MateralNo") String MateralNo);
+}

+ 192 - 0
src/main/java/com/steerinfo/ems/njformula/mapper/NjFormulaMapper.xml

@@ -0,0 +1,192 @@
+<?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.ems.njformula.mapper.NjFormulaMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.njformula.model.NjFormula">
+    <id column="ID" jdbcType="VARCHAR" property="id" />
+    <result column="MATERIALNO" jdbcType="VARCHAR" property="materialno" />
+    <result column="CODE" jdbcType="VARCHAR" property="code" />
+    <result column="MEMO" jdbcType="VARCHAR" property="memo" />
+  </resultMap>
+  <sql id="columns">
+    ID, MATERIALNO, CODE, MEMO
+  </sql>
+  <sql id="columns_alias">
+    t.ID, t.MATERIALNO, t.CODE, t.MEMO
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM NJ_FORMULA
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM NJ_FORMULA t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="id != null and id != ''">
+        and ID = #{id}
+      </if>
+      <if test="materialno != null and materialno != ''">
+        and MATERIALNO = #{materialno}
+      </if>
+      <if test="code != null and code != ''">
+        and CODE = #{code}
+      </if>
+      <if test="memo != null and memo != ''">
+        and MEMO = #{memo}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="id != null and id != ''">
+        and ID LIKE '%${id}%'
+      </if>
+      <if test="materialno != null and materialno != ''">
+        and MATERIALNO LIKE '%${materialno}%'
+      </if>
+      <if test="code != null and code != ''">
+        and CODE LIKE '%${code}%'
+      </if>
+      <if test="memo != null and memo != ''">
+        and MEMO LIKE '%${memo}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from NJ_FORMULA
+    where ID = #{id,jdbcType=VARCHAR}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from NJ_FORMULA
+    where 1!=1 
+      <if test="materialno != null and materialno != ''">
+        or MATERIALNO = #{materialno}
+      </if>
+      <if test="code != null and code != ''">
+        or CODE = #{code}
+      </if>
+      <if test="memo != null and memo != ''">
+        or MEMO = #{memo}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.njformula.model.NjFormula">
+    insert into NJ_FORMULA (ID, MATERIALNO, CODE, 
+      MEMO)
+    values (#{id,jdbcType=VARCHAR}, #{materialno,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, 
+      #{memo,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.njformula.model.NjFormula">
+    insert into NJ_FORMULA
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        ID,
+      </if>
+      <if test="materialno != null">
+        MATERIALNO,
+      </if>
+      <if test="code != null">
+        CODE,
+      </if>
+      <if test="memo != null">
+        MEMO,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=VARCHAR},
+      </if>
+      <if test="materialno != null">
+        #{materialno,jdbcType=VARCHAR},
+      </if>
+      <if test="code != null">
+        #{code,jdbcType=VARCHAR},
+      </if>
+      <if test="memo != null">
+        #{memo,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.njformula.model.NjFormula">
+    update NJ_FORMULA
+    set MATERIALNO = #{materialno,jdbcType=VARCHAR},
+      CODE = #{code,jdbcType=VARCHAR},
+      MEMO = #{memo,jdbcType=VARCHAR}
+    where ID = #{id,jdbcType=VARCHAR}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.njformula.model.NjFormula">
+    update NJ_FORMULA
+    <set>
+      <if test="materialno != null">
+        MATERIALNO = #{materialno,jdbcType=VARCHAR},
+      </if>
+      <if test="code != null">
+        CODE = #{code,jdbcType=VARCHAR},
+      </if>
+      <if test="memo != null">
+        MEMO = #{memo,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where ID = #{id,jdbcType=VARCHAR}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where ID = #{id,jdbcType=VARCHAR}
+  </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 NJ_FORMULA 
+      (ID, 
+      MATERIALNO, CODE, MEMO
+      )
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.id,jdbcType=VARCHAR}, 
+      #{item.materialno,jdbcType=VARCHAR}, #{item.code,jdbcType=VARCHAR}, #{item.memo,jdbcType=VARCHAR}
+       from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update NJ_FORMULA
+     set
+       ID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.id,jdbcType=VARCHAR}
+       </foreach>
+       ,MATERIALNO=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.materialno,jdbcType=VARCHAR}
+       </foreach>
+       ,CODE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.code,jdbcType=VARCHAR}
+       </foreach>
+       ,MEMO=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=VARCHAR} then #{item.memo,jdbcType=VARCHAR}
+       </foreach>
+     where ID in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.id,jdbcType=VARCHAR}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from NJ_FORMULA
+    where ID in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+<!--  根据物料编码获取公式-->
+  <select id="getByMateralNo" parameterType="java.lang.String" resultMap="BaseResultMap">
+    select t.code from NJ_FORMULA t where
+    t.MATERIALNO =#{MateralNo}
+  </select>
+</mapper>

+ 81 - 0
src/main/java/com/steerinfo/ems/njformula/model/NjFormula.java

@@ -0,0 +1,81 @@
+package com.steerinfo.ems.njformula.model;
+
+import com.steerinfo.framework.model.IBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+@ApiModel(value="null")
+public class NjFormula implements IBasePO<String> {
+    /**
+     * ID(ID,VARCHAR,100)
+     */
+    @ApiModelProperty(value="ID",required=true)
+    private String id;
+
+    /**
+     * 物料编码(MATERIALNO,VARCHAR,50)
+     */
+    @ApiModelProperty(value="物料编码",required=false)
+    private String materialno;
+
+    /**
+     * 公式内容(CODE,VARCHAR,1000)
+     */
+    @ApiModelProperty(value="公式内容",required=false)
+    private String code;
+
+    /**
+     * 备注(MEMO,VARCHAR,100)
+     */
+    @ApiModelProperty(value="备注",required=false)
+    private String memo;
+
+    private static final long serialVersionUID = 1L;
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id == null ? null : id.trim();
+    }
+
+    public String getMaterialno() {
+        return materialno;
+    }
+
+    public void setMaterialno(String materialno) {
+        this.materialno = materialno == null ? null : materialno.trim();
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public void setCode(String code) {
+        this.code = code == null ? null : code.trim();
+    }
+
+    public String getMemo() {
+        return memo;
+    }
+
+    public void setMemo(String memo) {
+        this.memo = memo == null ? null : memo.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", id=").append(id);
+        sb.append(", materialno=").append(materialno);
+        sb.append(", code=").append(code);
+        sb.append(", memo=").append(memo);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 26 - 0
src/main/java/com/steerinfo/ems/njformula/service/INjFormulaService.java

@@ -0,0 +1,26 @@
+package com.steerinfo.ems.njformula.service;
+
+import com.steerinfo.framework.service.IBaseService;
+import com.steerinfo.ems.njformula.model.NjFormula;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.Date;
+import java.math.BigDecimal;
+
+/**
+ * NjFormula服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 02:53
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:NjFormula服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface INjFormulaService extends IBaseService<NjFormula, String>{
+    //根据物料编码获取公式
+    public NjFormula getByMateralNo(@Param("MateralNo") String MateralNo);
+}

+ 41 - 0
src/main/java/com/steerinfo/ems/njformula/service/impl/NjFormulaServiceImpl.java

@@ -0,0 +1,41 @@
+package com.steerinfo.ems.njformula.service.impl;
+
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import com.steerinfo.ems.njformula.model.NjFormula;
+import com.steerinfo.ems.njformula.mapper.NjFormulaMapper;
+import com.steerinfo.ems.njformula.service.INjFormulaService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import java.util.Date;
+import java.math.BigDecimal;
+
+/**
+ * NjFormula服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-14 02:53
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-14
+ * 作者:generator
+ * 参考:
+ * 描述:NjFormula服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "njFormulaService")
+public class NjFormulaServiceImpl extends BaseServiceImpl<NjFormula, String> implements INjFormulaService {
+
+    @Autowired
+    private NjFormulaMapper njFormulaMapper;
+
+    @Override
+    protected IBaseMapper<NjFormula, String> getMapper() {
+        return njFormulaMapper;
+    }
+
+    @Override
+    public NjFormula getByMateralNo(String MateralNo) {
+        return njFormulaMapper.getByMateralNo(MateralNo);
+    }
+}

+ 108 - 0
src/main/java/com/steerinfo/ems/rttable/controller/RttableController.java

@@ -0,0 +1,108 @@
+package com.steerinfo.ems.rttable.controller;
+
+import com.steerinfo.ems.rttable.model.Rttable;
+import com.steerinfo.ems.rttable.service.IRttableService;
+import com.steerinfo.framework.controller.BaseRESTfulController;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.utils.collection.ListUtils;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.math.BigDecimal;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * Rttable RESTful接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-15 03:37
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-15
+ * 作者:generator
+ * 参考:
+ * 描述:Rttable RESTful接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@RestController
+@RequestMapping("/${api.version}/rttables")
+public class RttableController extends BaseRESTfulController {
+
+    @Autowired
+    IRttableService rttableService;
+
+    @ApiOperation(value="获取列表", notes="分页查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("rttable:view")
+    @GetMapping(value = "/")
+    public RESTfulResult list(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<Rttable> list = rttableService.queryForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
+    @ApiOperation(value="获取列表", notes="分页模糊查询")
+    @ApiImplicitParams({
+        @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+        @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("rttable:view")
+    @GetMapping(value = "/like/")
+    public RESTfulResult listLike(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<Rttable> list = rttableService.queryLikeForPage(parmas, pageNum, pageSize);
+        return success(list);
+    }
+    
+    @ApiOperation(value="创建", notes="根据Rttable对象创建")
+    @ApiImplicitParam(name = "rttable", value = "详细实体rttable", required = true, dataType = "Rttable")
+    //@RequiresPermissions("rttable:create")
+    @PostMapping(value = "/")
+    public RESTfulResult add(@ModelAttribute Rttable model){
+        Rttable rttable = rttableService.add(model);
+        return success(rttable);
+    }
+
+    @ApiOperation(value="获取详细信息", notes="根据url的id来获取详细信息")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "BigDecimal")
+    //@RequiresPermissions("rttable:view")
+    @GetMapping(value = "/{id}")
+    public RESTfulResult get(@PathVariable BigDecimal id){
+        Rttable rttable = rttableService.getById(id);
+        return success(rttable);
+    }
+
+    @ApiOperation(value="更新详细信息", notes="根据url的id来指定更新对象,并根据传过来的rttable信息来更新详细信息")
+    @ApiImplicitParams({
+        @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "BigDecimal"),
+        @ApiImplicitParam(name = "rttable", value = "详细实体rttable", required = true, dataType = "Rttable")
+    })
+    //@RequiresPermissions("rttable:update")
+    @PutMapping(value = "/{id}", produces  = "application/json;charset=UTF-8")
+    public RESTfulResult update(@PathVariable BigDecimal id, @RequestBody Rttable model){
+        model.setId(id);
+        Rttable rttable = rttableService.modify(model);
+        return success(rttable);
+    }
+
+    @ApiOperation(value="删除", notes="根据url的id来指定删除对象")
+    @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "BigDecimal")
+    //@RequiresPermissions("rttable:delete")
+    @DeleteMapping(value = "/{id}")//BigDecimal
+    public RESTfulResult delete(@PathVariable String id){
+    	List<String> list = Arrays.asList(id.split(","));
+    	if(ListUtils.isNotEmpty(list)) {
+	    	List<BigDecimal> ids = ListUtils.convertList(list);
+			  rttableService.delete(ids);
+    	}
+      return success();
+    }
+
+}

+ 19 - 0
src/main/java/com/steerinfo/ems/rttable/mapper/RttableMapper.java

@@ -0,0 +1,19 @@
+package com.steerinfo.ems.rttable.mapper;
+
+import com.steerinfo.ems.rttable.model.Rttable;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.math.BigDecimal;
+import java.util.HashMap;
+
+@Mapper
+public interface RttableMapper extends IBaseMapper<Rttable, BigDecimal> {
+
+    int insertPowerTenMinutes(HashMap<String, Object> HashMap);
+
+    int updatePowerTenMinutes(HashMap<String, Object> HashMap);
+
+    int updatePowerMinutes(HashMap<String, Object> HashMap);
+
+}

+ 284 - 0
src/main/java/com/steerinfo/ems/rttable/mapper/RttableMapper.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.ems.rttable.mapper.RttableMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.ems.rttable.model.Rttable">
+    <id column="ID" jdbcType="DECIMAL" property="id" />
+    <result column="ALTID" jdbcType="VARCHAR" property="altid" />
+    <result column="RTVALUE" jdbcType="DECIMAL" property="rtvalue" />
+    <result column="ALARMSTATUS" jdbcType="DECIMAL" property="alarmstatus" />
+    <result column="COMMSTATUS" jdbcType="DECIMAL" property="commstatus" />
+    <result column="UPDATETIME" jdbcType="TIMESTAMP" property="updatetime" />
+    <result column="NOTE" jdbcType="VARCHAR" property="note" />
+  </resultMap>
+  <sql id="columns">
+    ID, ALTID, RTVALUE, ALARMSTATUS, COMMSTATUS, UPDATETIME, NOTE
+  </sql>
+  <sql id="columns_alias">
+    t.ID, t.ALTID, t.RTVALUE, t.ALARMSTATUS, t.COMMSTATUS, t.UPDATETIME, t.NOTE
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns"/> FROM RTTABLE
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias"/> FROM RTTABLE t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="id != null">
+        and ID = #{id}
+      </if>
+      <if test="altid != null and altid != ''">
+        and ALTID = #{altid}
+      </if>
+      <if test="rtvalue != null">
+        and RTVALUE = #{rtvalue}
+      </if>
+      <if test="alarmstatus != null">
+        and ALARMSTATUS = #{alarmstatus}
+      </if>
+      <if test="commstatus != null">
+        and COMMSTATUS = #{commstatus}
+      </if>
+      <if test="updatetime != null">
+        and TO_CHAR(UPDATETIME,'yyyy-MM-dd') = #{updatetime}
+      </if>
+      <if test="note != null and note != ''">
+        and NOTE = #{note}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="id != null">
+        and ID = #{id}
+      </if>
+      <if test="altid != null and altid != ''">
+        and ALTID LIKE '%${altid}%'
+      </if>
+      <if test="rtvalue != null">
+        and RTVALUE = #{rtvalue}
+      </if>
+      <if test="alarmstatus != null">
+        and ALARMSTATUS = #{alarmstatus}
+      </if>
+      <if test="commstatus != null">
+        and COMMSTATUS = #{commstatus}
+      </if>
+      <if test="updatetime != null">
+        and TO_CHAR(UPDATETIME,'yyyy-MM-dd') = #{updatetime}
+      </if>
+      <if test="note != null and note != ''">
+        and NOTE LIKE '%${note}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
+    delete from RTTABLE
+    where ID = #{id,jdbcType=DECIMAL}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from RTTABLE
+    where 1!=1 
+      <if test="altid != null and altid != ''">
+        or ALTID = #{altid}
+      </if>
+      <if test="rtvalue != null">
+        or RTVALUE = #{rtvalue}
+      </if>
+      <if test="alarmstatus != null">
+        or ALARMSTATUS = #{alarmstatus}
+      </if>
+      <if test="commstatus != null">
+        or COMMSTATUS = #{commstatus}
+      </if>
+      <if test="updatetime != null">
+        or TO_CHAR(UPDATETIME,'yyyy-MM-dd') = '#{updatetime}'
+      </if>
+      <if test="note != null and note != ''">
+        or NOTE = #{note}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.ems.rttable.model.Rttable">
+    insert into RTTABLE (ID, ALTID, RTVALUE, 
+      ALARMSTATUS, COMMSTATUS, UPDATETIME, 
+      NOTE)
+    values (#{id,jdbcType=DECIMAL}, #{altid,jdbcType=VARCHAR}, #{rtvalue,jdbcType=DECIMAL}, 
+      #{alarmstatus,jdbcType=DECIMAL}, #{commstatus,jdbcType=DECIMAL}, #{updatetime,jdbcType=TIMESTAMP}, 
+      #{note,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.ems.rttable.model.Rttable">
+    insert into RTTABLE
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        ID,
+      </if>
+      <if test="altid != null">
+        ALTID,
+      </if>
+      <if test="rtvalue != null">
+        RTVALUE,
+      </if>
+      <if test="alarmstatus != null">
+        ALARMSTATUS,
+      </if>
+      <if test="commstatus != null">
+        COMMSTATUS,
+      </if>
+      <if test="updatetime != null">
+        UPDATETIME,
+      </if>
+      <if test="note != null">
+        NOTE,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=DECIMAL},
+      </if>
+      <if test="altid != null">
+        #{altid,jdbcType=VARCHAR},
+      </if>
+      <if test="rtvalue != null">
+        #{rtvalue,jdbcType=DECIMAL},
+      </if>
+      <if test="alarmstatus != null">
+        #{alarmstatus,jdbcType=DECIMAL},
+      </if>
+      <if test="commstatus != null">
+        #{commstatus,jdbcType=DECIMAL},
+      </if>
+      <if test="updatetime != null">
+        #{updatetime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="note != null">
+        #{note,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.ems.rttable.model.Rttable">
+    update RTTABLE
+    set ALTID = #{altid,jdbcType=VARCHAR},
+      RTVALUE = #{rtvalue,jdbcType=DECIMAL},
+      ALARMSTATUS = #{alarmstatus,jdbcType=DECIMAL},
+      COMMSTATUS = #{commstatus,jdbcType=DECIMAL},
+      UPDATETIME = #{updatetime,jdbcType=TIMESTAMP},
+      NOTE = #{note,jdbcType=VARCHAR}
+    where ID = #{id,jdbcType=DECIMAL}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.ems.rttable.model.Rttable">
+    update RTTABLE
+    <set>
+      <if test="altid != null">
+        ALTID = #{altid,jdbcType=VARCHAR},
+      </if>
+      <if test="rtvalue != null">
+        RTVALUE = #{rtvalue,jdbcType=DECIMAL},
+      </if>
+      <if test="alarmstatus != null">
+        ALARMSTATUS = #{alarmstatus,jdbcType=DECIMAL},
+      </if>
+      <if test="commstatus != null">
+        COMMSTATUS = #{commstatus,jdbcType=DECIMAL},
+      </if>
+      <if test="updatetime != null">
+        UPDATETIME = #{updatetime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="note != null">
+        NOTE = #{note,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where ID = #{id,jdbcType=DECIMAL}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
+    <include refid="select"/>
+    where ID = #{id,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 RTTABLE 
+      (ID, 
+      ALTID, RTVALUE, ALARMSTATUS, 
+      COMMSTATUS, UPDATETIME, NOTE
+      )
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.id,jdbcType=DECIMAL}, 
+      #{item.altid,jdbcType=VARCHAR}, #{item.rtvalue,jdbcType=DECIMAL}, #{item.alarmstatus,jdbcType=DECIMAL}, 
+      #{item.commstatus,jdbcType=DECIMAL}, #{item.updatetime,jdbcType=TIMESTAMP}, #{item.note,jdbcType=VARCHAR}
+       from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update RTTABLE
+     set
+       ID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.id,jdbcType=DECIMAL}
+       </foreach>
+       ,ALTID=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.altid,jdbcType=VARCHAR}
+       </foreach>
+       ,RTVALUE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.rtvalue,jdbcType=DECIMAL}
+       </foreach>
+       ,ALARMSTATUS=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.alarmstatus,jdbcType=DECIMAL}
+       </foreach>
+       ,COMMSTATUS=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.commstatus,jdbcType=DECIMAL}
+       </foreach>
+       ,UPDATETIME=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.updatetime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,NOTE=
+       <foreach collection="list" item="item" index="index" separator=" " open="case ID" close="end">
+          when #{item.id,jdbcType=DECIMAL} then #{item.note,jdbcType=VARCHAR}
+       </foreach>
+     where ID in 
+     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+    #{item.id,jdbcType=DECIMAL}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from RTTABLE
+    where ID in 
+    <foreach collection="list" item="id" open="(" close=")" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+  <insert id="insertPowerTenMinutes" parameterType="java.util.HashMap">
+    INSERT INTO EMS_POWER_TIMING(TMSTMP) VALUES
+    (to_date (#{clock1,jdbcType=TIME}, 'YYYY-MM-DD HH24:MI:SS' )
+    )
+  </insert>
+  <update id="updatePowerTenMinutes" parameterType="java.util.HashMap">
+    update EMS_POWER_TIMING
+    <set>
+      ${sql}
+    </set>
+    where TMSTMP =to_date (#{clock1,jdbcType=TIME}, 'YYYY-MM-DD HH24:MI:SS' )
+  </update>
+  <update id="updatePowerMinutes" parameterType="java.util.HashMap">
+    update ${table}
+    <set>
+      <if test="clock != null and clock != ''">
+        TMSTMP = to_date (#{clock,jdbcType=TIME}, 'YYYY-MM-DD HH24:MI:SS' )
+      </if>
+      ${sql}
+    </set>
+  </update>
+</mapper>

+ 128 - 0
src/main/java/com/steerinfo/ems/rttable/model/Rttable.java

@@ -0,0 +1,128 @@
+package com.steerinfo.ems.rttable.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="null")
+public class Rttable implements IBasePO<BigDecimal> {
+    /**
+     * ID随机(ID,DECIMAL,38)
+     */
+    @ApiModelProperty(value="ID随机",required=true)
+    private BigDecimal id;
+
+    /**
+     * MOX数据库唯一ID号(EMS+分厂+工序+介质+仪表)(ALTID,VARCHAR,30)
+     */
+    @ApiModelProperty(value="MOX数据库唯一ID号(EMS+分厂+工序+介质+仪表)",required=true)
+    private String altid;
+
+    /**
+     * 数据(RTVALUE,DECIMAL,0)
+     */
+    @ApiModelProperty(value="数据",required=false)
+    private BigDecimal rtvalue;
+
+    /**
+     * 报警(ALARMSTATUS,DECIMAL,0)
+     */
+    @ApiModelProperty(value="报警",required=false)
+    private BigDecimal alarmstatus;
+
+    /**
+     * 通讯状态(COMMSTATUS,DECIMAL,0)
+     */
+    @ApiModelProperty(value="通讯状态",required=false)
+    private BigDecimal commstatus;
+
+    /**
+     * 更新时间(UPDATETIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="更新时间",required=false)
+    private Date updatetime;
+
+    /**
+     * EMS+分厂+工序+介质+仪表(NOTE,VARCHAR,200)
+     */
+    @ApiModelProperty(value="EMS+分厂+工序+介质+仪表",required=false)
+    private String note;
+
+    private static final long serialVersionUID = 1L;
+
+    public BigDecimal getId() {
+        return id;
+    }
+
+    public void setId(BigDecimal id) {
+        this.id = id;
+    }
+
+    public String getAltid() {
+        return altid;
+    }
+
+    public void setAltid(String altid) {
+        this.altid = altid == null ? null : altid.trim();
+    }
+
+    public BigDecimal getRtvalue() {
+        return rtvalue;
+    }
+
+    public void setRtvalue(String rtvalue) {
+        this.rtvalue = new BigDecimal(rtvalue);
+    }
+
+    public BigDecimal getAlarmstatus() {
+        return alarmstatus;
+    }
+
+    public void setAlarmstatus(String alarmstatus) {
+        this.alarmstatus = new BigDecimal(alarmstatus);
+    }
+
+    public BigDecimal getCommstatus() {
+        return commstatus;
+    }
+
+    public void setCommstatus(String commstatus) {
+        this.commstatus = new BigDecimal(commstatus);
+    }
+
+    public Date getUpdatetime() {
+        return updatetime;
+    }
+
+    public void setUpdatetime(Date updatetime) {
+        this.updatetime = updatetime;
+    }
+
+    public String getNote() {
+        return note;
+    }
+
+    public void setNote(String note) {
+        this.note = note == null ? null : note.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", id=").append(id);
+        sb.append(", altid=").append(altid);
+        sb.append(", rtvalue=").append(rtvalue);
+        sb.append(", alarmstatus=").append(alarmstatus);
+        sb.append(", commstatus=").append(commstatus);
+        sb.append(", updatetime=").append(updatetime);
+        sb.append(", note=").append(note);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 27 - 0
src/main/java/com/steerinfo/ems/rttable/service/IRttableService.java

@@ -0,0 +1,27 @@
+package com.steerinfo.ems.rttable.service;
+
+import com.steerinfo.ems.rttable.model.Rttable;
+import com.steerinfo.framework.service.IBaseService;
+
+import java.math.BigDecimal;
+
+/**
+ * Rttable服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-15 03:37
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-15
+ * 作者:generator
+ * 参考:
+ * 描述:Rttable服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IRttableService extends IBaseService<Rttable, BigDecimal>{
+
+    int dataGeneration();
+
+    int getPowerTenMinutes();
+
+}

+ 109 - 0
src/main/java/com/steerinfo/ems/rttable/service/impl/RttableServiceImpl.java

@@ -0,0 +1,109 @@
+package com.steerinfo.ems.rttable.service.impl;
+
+import com.steerinfo.ems.Utils.DateUtils;
+import com.steerinfo.ems.rttable.mapper.RttableMapper;
+import com.steerinfo.ems.rttable.model.Rttable;
+import com.steerinfo.ems.rttable.service.IRttableService;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.math.BigDecimal;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * Rttable服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-10-15 03:37
+ * 类描述
+ * 修订历史:
+ * 日期:2021-10-15
+ * 作者:generator
+ * 参考:
+ * 描述:Rttable服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "rttableService")
+public class RttableServiceImpl extends BaseServiceImpl<Rttable, BigDecimal> implements IRttableService {
+    private static final Logger logger = LoggerFactory.getLogger(RttableServiceImpl.class);
+    @Autowired
+    private RttableMapper rttableMapper;
+
+    @Override
+    protected IBaseMapper<Rttable, BigDecimal> getMapper() {
+        return rttableMapper;
+    }
+
+    @Override
+    public int dataGeneration() {
+
+        int addSize = 0;
+        int updateSize = 0;
+        try {
+            Rttable model;
+            // emsWaterRealtimeMapper.selectByPrimaryKey("1");//.getWaterListByArmMeter();
+            //List<EmsWaterRealtime> emsWaterRealtimeList = getWaterListByArmMeter();
+            String clock = DateUtils.dateStr(new Date(),"yyyy-MM-dd HH:mm:ss");
+            HashMap<String,Object> hashMap = new HashMap<String,Object>();
+            hashMap.put("clock",clock);
+            List<Rttable> rttableList = rttableMapper.selectByParameters(hashMap);
+            StringBuffer sub = new StringBuffer();
+            String table="EMS_POWER";
+            for (Rttable rttable : rttableList){
+                addSize ++ ;
+                //多个表生成数据就填加table;
+                String sql = ",TAG"+ addSize+ " = " + "'" + rttable.getRtvalue() + "'";
+                sub.append(sql);
+            }
+            hashMap.put("table",table);
+            hashMap.put("sql",sub.toString());
+            updateSize += rttableMapper.updatePowerMinutes(hashMap);
+        } catch (Exception e) {
+            e.printStackTrace();
+        } finally {
+            logger.info("本次总共新增动力数据条数:" + addSize);
+            logger.info("本次总共更新动力数据条数:" + updateSize);
+        }
+        return addSize+updateSize;
+    }
+
+
+    @Override
+    public int getPowerTenMinutes() {
+        int addSize = 0;
+        int updateSize = 0;
+        int i = 0;
+        try {
+            Rttable model;
+            // emsWaterRealtimeMapper.selectByPrimaryKey("1");//.getWaterListByArmMeter();
+            String clock1 = DateUtils.dateStr(new Date(),"yyyy-MM-dd HH:mm:ss");
+            HashMap<String,Object> hashMap = new HashMap<String,Object>();
+            hashMap.put("clock1",clock1);
+            addSize += rttableMapper.insertPowerTenMinutes(hashMap);
+            StringBuffer sub = new StringBuffer();
+            List<Rttable> rttableList = rttableMapper.selectByParameters(hashMap);
+            String table="EMS_POWER_TIMING";
+            for (Rttable rttable : rttableList){
+                i++;
+                String sql = "TAG"+ i+ " = " + "'" + rttable.getRtvalue() + "',";
+                sub.append(sql);
+            }
+            hashMap.put("table",table);
+            hashMap.put("sql",sub.toString());
+            updateSize += rttableMapper.updatePowerTenMinutes(hashMap);
+        } catch (Exception e) {
+            e.printStackTrace();
+        } finally {
+            logger.info("本次总共新增动力十分钟数据条数:" + addSize);
+            logger.info("本次总共更新动力十分钟数据条数:" + updateSize);
+        }
+
+        return addSize+updateSize;
+    }
+}