Ver Fonte

后端修改

dengyj há 4 anos atrás
pai
commit
63a56639b8
17 ficheiros alterados com 313 adições e 25 exclusões
  1. 3 0
      src/main/java/com/steerinfo/meterwork/meterworkcaractual/service/impl/MeterWorkCarActualServiceImpl.java
  2. 45 0
      src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/controller/MeterWorkCarActualFirstController.java
  3. 9 2
      src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/mapper/MeterWorkCarActualFirstMapper.xml
  4. 2 0
      src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/service/IMeterWorkCarActualFirstService.java
  5. 59 0
      src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/service/impl/MeterWorkCarActualFirstServiceImpl.java
  6. 75 22
      src/main/java/com/steerinfo/meterwork/meterworkmonitor/mapper/MeterWorkMonitorMapper.xml
  7. 31 0
      src/main/java/com/steerinfo/meterwork/meterworkmonitor/model/MeterWorkMonitor.java
  8. 13 1
      src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/controller/MeterWorkScheduledHelpController.java
  9. 5 0
      src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/mapper/MeterWorkScheduledHelpMapper.java
  10. 18 0
      src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/mapper/MeterWorkScheduledHelpMapper.xml
  11. 4 0
      src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/service/IMeterWorkScheduledHelpService.java
  12. 11 0
      src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/service/impl/MeterWorkScheduledHelpServiceImpl.java
  13. 17 0
      src/main/java/com/steerinfo/pretrack/pretrackscale/controller/PreTrackScaleController.java
  14. 2 0
      src/main/java/com/steerinfo/pretrack/pretrackscale/mapper/PreTrackScaleMapper.java
  15. 6 0
      src/main/java/com/steerinfo/pretrack/pretrackscale/mapper/PreTrackScaleMapper.xml
  16. 3 0
      src/main/java/com/steerinfo/pretrack/pretrackscale/service/IPreTrackScaleService.java
  17. 10 0
      src/main/java/com/steerinfo/pretrack/pretrackscale/service/impl/PreTrackScaleServiceImpl.java

+ 3 - 0
src/main/java/com/steerinfo/meterwork/meterworkcaractual/service/impl/MeterWorkCarActualServiceImpl.java

@@ -159,6 +159,9 @@ public class MeterWorkCarActualServiceImpl extends BaseServiceImpl<MeterWorkCarA
             if (!model.getValueFlag().equals("1")) {
                 throw new MarkerMetException(500, "只有未发布状态的数据才能进行发布数据操作");
             }
+            if (model.getIsPreScale().equals("0")) {
+                throw new MarkerMetException(500, "只有已匹配委托的数据才能进行发布数据操作");
+            }
             check(model);
             model.setValueFlag("2"); // 状态改为发布
             model.setUploadFlag("1");

+ 45 - 0
src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/controller/MeterWorkCarActualFirstController.java

@@ -2,9 +2,13 @@ package com.steerinfo.meterwork.meterworkcaractualfirst.controller;
 
 import com.alibaba.fastjson.JSONArray;
 import com.alibaba.fastjson.JSONObject;
+import com.steerinfo.baseinfo.meterbasematterinfo.model.MeterBaseMatterInfo;
+import com.steerinfo.baseinfo.meterbasespotinfo.mapper.MeterBaseSpotInfoMapper;
+import com.steerinfo.baseinfo.meterbasespotinfo.model.MeterBaseSpotInfo;
 import com.steerinfo.framework.controller.BaseRESTfulController;
 import com.steerinfo.framework.controller.RESTfulResult;
 import com.steerinfo.framework.service.pagehelper.PageList;
+import com.steerinfo.framework.user.UserPayload;
 import com.steerinfo.framework.utils.collection.ListUtils;
 import com.steerinfo.metermonitor.metermonitornote.model.MeterMonitorNote;
 import com.steerinfo.meterwork.dto.*;
@@ -54,6 +58,9 @@ public class MeterWorkCarActualFirstController extends BaseRESTfulController {
     @Resource
     MeterWorkCarActualFirstMapper meterWorkCarActualFirstMapper;
 
+    @Resource
+    MeterBaseSpotInfoMapper meterBaseSpotInfoMapper;
+
     @Autowired
     IMeterWorkCarActualFirstService meterWorkCarActualFirstService;
 
@@ -170,6 +177,28 @@ public class MeterWorkCarActualFirstController extends BaseRESTfulController {
             String no = meterWorkCarActualFirstMapper.getNewID(afl);
             model.setActualFirstNo(sdf.format(new Date()) + no);
             model.setValueFlag("1");
+            model.setCreateTime(new Date());
+            String userId = null;
+            String userName = null;
+            try{
+                UserPayload payload = UserPayload.getCurrUser();
+                userId = payload.getId();
+                userName = payload.getUserName();
+            }catch(Exception e) {
+                userId = "admin";
+                userName = "admins";
+            }
+            model.setCreateManNo(userId);
+            model.setCreateManName(userName);
+
+            HashMap<String, Object> obj = new HashMap<>();
+            obj.put("baseSpotNo", model.getBaseSpotNo());
+            List<MeterBaseSpotInfo> spotModel = meterBaseSpotInfoMapper.selectByParameters(obj);
+            if(spotModel.size() >= 1) {
+                model.setBaseSpotName(spotModel.get(0).getBaseSpotName());
+            }else {
+                throw new MarkerMetException(500, "计量点配置表未找到相应的计量点!!");
+            }
             MeterWorkCarActualFirst meterWorkCarActualFirst = meterWorkCarActualFirstService.add(model);
             return success(meterWorkCarActualFirst);
         } catch (Exception ex) {
@@ -178,6 +207,22 @@ public class MeterWorkCarActualFirstController extends BaseRESTfulController {
         }
     }
 
+    @ApiOperation(value = "一次数据补入", notes = "根据MeterWorkCarActualFirst对象创建")
+    @ApiImplicitParam(name = "meterWorkCarActualFirst", value = "详细实体meterWorkCarActualFirst", required = true, dataType = "MeterWorkCarActualFirst")
+    //@RequiresPermissions("meterworkcaractualfirst:create")
+    @PostMapping(value = "/firstDataSupplement")
+    public RESTfulResult firstDataSupplement(@RequestBody MeterWorkCarActualFirst model) {
+        RESTfulResult rm = new RESTfulResult();
+        rm.setFailed();
+        try {
+            rm = meterWorkCarActualFirstService.firstDataSupplement(model);
+        } catch (Exception ex) {
+            ex.printStackTrace();
+            rm.setMessage("操作异常,请确认!!!>>>>" + ex.getMessage());
+        }
+        return rm;
+    }
+
     @ApiOperation(value = "获取详细信息", notes = "根据url的id来获取详细信息")
     @ApiImplicitParam(paramType = "path", name = "id", value = "ID", required = true, dataType = "String")
     //@RequiresPermissions("meterworkcaractualfirst:view")

+ 9 - 2
src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/mapper/MeterWorkCarActualFirstMapper.xml

@@ -2843,8 +2843,13 @@
   <select id="likeByDesc" parameterType="java.util.HashMap" resultMap="BaseResultMap">
     <include refid="select"/>
     <include refid="whereLike"/>
+    <!--App特殊条件查询,查询不能为作废、已洁净数据-->
     <if test="flag != null and flag != ''">
-       and value_flag not in ('0', '2')
+       and value_flag in ('1', '3')
+       or (
+            value_flag = '2'
+            and (is_pre_scale = '0' or is_pre_scale is null)
+          )
     </if>
     order by create_time desc
   </select>
@@ -2852,8 +2857,10 @@
   <select id="ApplikeByDesc" parameterType="java.util.HashMap" resultMap="BaseResultMap">
     <include refid="select"/>
     <include refid="whereLike"/>
+    <!--已洁净且未匹配委托-->
     <if test="flag != null and flag != ''">
-      and value_flag != '0'
+      and value_flag = '2'
+      and (is_pre_scale = '0' or is_pre_scale is null)
     </if>
     order by create_time desc
   </select>

+ 2 - 0
src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/service/IMeterWorkCarActualFirstService.java

@@ -35,6 +35,8 @@ public interface IMeterWorkCarActualFirstService extends IBaseService<MeterWorkC
 
     int checkcarandupdate(MeterWorkCarActualFirst model);
 
+    RESTfulResult firstDataSupplement(MeterWorkCarActualFirst model);
+
     int audit(MeterWorkCarActualFirst model);
 
     int abolish(List<MeterWorkCarActualFirst> models);

+ 59 - 0
src/main/java/com/steerinfo/meterwork/meterworkcaractualfirst/service/impl/MeterWorkCarActualFirstServiceImpl.java

@@ -9,6 +9,8 @@ import com.steerinfo.baseinfo.meterbasehistaredetail.mapper.MeterBaseHisTareDeta
 import com.steerinfo.baseinfo.meterbasehistaredetail.model.MeterBaseHisTareDetail;
 import com.steerinfo.baseinfo.meterbasematterinfo.mapper.MeterBaseMatterInfoMapper;
 import com.steerinfo.baseinfo.meterbasematterinfo.model.MeterBaseMatterInfo;
+import com.steerinfo.baseinfo.meterbasespotinfo.mapper.MeterBaseSpotInfoMapper;
+import com.steerinfo.baseinfo.meterbasespotinfo.model.MeterBaseSpotInfo;
 import com.steerinfo.baseinfo.meterbasetermtaredata.mapper.MeterBaseTermTareDataMapper;
 import com.steerinfo.baseinfo.meterbasetermtaredata.model.MeterBaseTermTareData;
 import com.steerinfo.baseinfo.meterbaseunloadtime.mapper.MeterBaseUnloadTimeMapper;
@@ -96,6 +98,9 @@ public class MeterWorkCarActualFirstServiceImpl extends BaseServiceImpl<MeterWor
     @Resource
     private MeterWorkCraneActualMapper craneActualMapper;
 
+    @Resource
+    private MeterBaseSpotInfoMapper meterBaseSpotInfoMapper;
+
     @Resource
     private MeterWorkCarActualFirstMapper meterWorkCarActualFirstMapper;
 
@@ -246,6 +251,58 @@ public class MeterWorkCarActualFirstServiceImpl extends BaseServiceImpl<MeterWor
         }
     }
 
+    @Override
+    public RESTfulResult firstDataSupplement(MeterWorkCarActualFirst model) {
+        RESTfulResult rm = new RESTfulResult();
+        rm.setFailed();
+        try {
+            SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd");
+            String afl = sdf.format(new Date());
+            String no = meterWorkCarActualFirstMapper.getNewID(afl);
+            model.setActualFirstNo(sdf.format(new Date()) + no);
+            model.setValueFlag("1");
+            model.setCreateTime(new Date());
+            String userId = "";
+            String userName = "";
+            try{
+                UserPayload payload = UserPayload.getCurrUser();
+                userId = payload.getId();
+                userName = payload.getUserName();
+            }catch(Exception e) {
+                userId = "admin";
+                userName = "admins";
+            }
+            model.setCreateManNo(userId);
+            model.setCreateManName(userName);
+
+            HashMap<String, Object> obj = new HashMap<>();
+            obj.put("baseSpotNo", model.getBaseSpotNo());
+            List<MeterBaseSpotInfo> spotModel = meterBaseSpotInfoMapper.selectByParameters(obj);
+            if(spotModel.size() >= 1) {
+                model.setBaseSpotName(spotModel.get(0).getBaseSpotName());
+            }else {
+                rm.setMessage("计量点配置表未找到相应的计量点!!");
+                return rm;
+            }
+            model.setAddWeight(model.getAddWeight()==null ? new BigDecimal(0): model.getAddWeight());
+            BigDecimal meterWeight = model.getMeterWeight().multiply(new BigDecimal(1000));
+            model.setMeterWeight(meterWeight);
+            model.setCheckFlag("1");
+            model.setMeterMode("3");
+            model.setDataSource("4");
+            model.setIsPreScale("0");
+            meterWorkCarActualFirstMapper.insertSelective(model);
+            rm.setSucceed();
+            rm.setCode("200");
+            rm.setData(model);
+        }catch(Exception e) {
+            e.printStackTrace();
+            rm.setMessage("操作异常,请确认!!>>>>" + e.getMessage());
+        }
+        return rm;
+
+    }
+
     @Override
     @Transactional(rollbackFor = Exception.class)
     public int abolish(List<MeterWorkCarActualFirst> models) throws MarkerMetException {
@@ -3776,11 +3833,13 @@ public class MeterWorkCarActualFirstServiceImpl extends BaseServiceImpl<MeterWor
                     }
                 }
             }
+            //添加一条期限皮信息
             params.put("weightType", "2");
             List<MeterWorkCarActualFirst> firstList = meterWorkCarActualFirstMapper.likeByDesc(params);
             if(firstList.size() >= 1) {
                 rows.add(firstList.get(0));
             }
+
         /*Collections.sort(rows, new Comparator<MeterWorkCarActualFirst>() {
             @Override
             public int compare(MeterWorkCarActualFirst o1, MeterWorkCarActualFirst o2) {

+ 75 - 22
src/main/java/com/steerinfo/meterwork/meterworkmonitor/mapper/MeterWorkMonitorMapper.xml

@@ -59,6 +59,8 @@
     <result column="RFID_STATE" jdbcType="VARCHAR" property="rfidState" />
     <result column="VALID_AREA" jdbcType="VARCHAR" property="validArea" />
     <result column="WEIGHT_STATUS" jdbcType="VARCHAR" property="weightStatus" />
+    <result column="FERROALLOY_CONFIRM" jdbcType="VARCHAR" property="ferroalloyConfirm" />
+    <result column="FERROALLOY_RESULT" jdbcType="VARCHAR" property="ferroalloyResult" />
   </resultMap>
   <sql id="columns">
     POINT_NO, POINT_NAME, VALID_WGT, VALID_CARNO, VALID_TARE_TIME, VALID_TIME_INTERVAL, 
@@ -70,7 +72,7 @@
     IS_OPEN_SCANNING, VALID_IS_PRE, USER_IP, POWER_STATE, DVR_STATE, MOXA_STATE, PLC_STATE, 
     LEFT_INFRARED_RAY_STATE, RIGHT_INFRARED_RAY_STATE, AMPLIFIER_STATE, LAMP_STATE, SPOT_TYPE_NO, 
     RED_GREEN_LIGHT_STATE, FRONT_INFRARED_RAY_STATE, REAR_INFRARED_RAY_STATE, RFID_STATE, 
-    VALID_AREA, WEIGHT_STATUS
+    VALID_AREA, WEIGHT_STATUS, FERROALLOY_CONFIRM, FERROALLOY_RESULT
   </sql>
   <sql id="columns_alias">
     t.POINT_NO, t.POINT_NAME, t.VALID_WGT, t.VALID_CARNO, t.VALID_TARE_TIME, t.VALID_TIME_INTERVAL, 
@@ -83,7 +85,7 @@
     t.POWER_STATE, t.DVR_STATE, t.MOXA_STATE, t.PLC_STATE, t.LEFT_INFRARED_RAY_STATE, 
     t.RIGHT_INFRARED_RAY_STATE, t.AMPLIFIER_STATE, t.LAMP_STATE, t.SPOT_TYPE_NO, t.RED_GREEN_LIGHT_STATE, 
     t.FRONT_INFRARED_RAY_STATE, t.REAR_INFRARED_RAY_STATE, t.RFID_STATE, t.VALID_AREA, 
-    t.WEIGHT_STATUS
+    t.WEIGHT_STATUS, t.FERROALLOY_CONFIRM, t.FERROALLOY_RESULT
   </sql>
   <sql id="select">
     SELECT <include refid="columns" /> FROM METER_WORK_MONITOR
@@ -264,6 +266,12 @@
       <if test="weightStatus != null and weightStatus != ''">
         and WEIGHT_STATUS = #{weightStatus}
       </if>
+      <if test="ferroalloyConfirm != null and ferroalloyConfirm != ''">
+        and FERROALLOY_CONFIRM = #{ferroalloyConfirm}
+      </if>
+      <if test="ferroalloyResult != null and ferroalloyResult != ''">
+        and FERROALLOY_RESULT = #{ferroalloyResult}
+      </if>
     </where>
   </sql>
   <sql id="whereLike">
@@ -439,6 +447,12 @@
       <if test="weightStatus != null and weightStatus != ''">
         and WEIGHT_STATUS LIKE '%${weightStatus}%'
       </if>
+      <if test="ferroalloyConfirm != null and ferroalloyConfirm != ''">
+        and FERROALLOY_CONFIRM LIKE '%${ferroalloyConfirm}%'
+      </if>
+      <if test="ferroalloyResult != null and ferroalloyResult != ''">
+        and FERROALLOY_RESULT LIKE '%${ferroalloyResult}%'
+      </if>
     </where>
   </sql>
   <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
@@ -616,6 +630,12 @@
       <if test="weightStatus != null and weightStatus != ''">
         or WEIGHT_STATUS = #{weightStatus}
       </if>
+      <if test="ferroalloyConfirm != null and ferroalloyConfirm != ''">
+        or FERROALLOY_CONFIRM = #{ferroalloyConfirm}
+      </if>
+      <if test="ferroalloyResult != null and ferroalloyResult != ''">
+        or FERROALLOY_RESULT = #{ferroalloyResult}
+      </if>
   </delete>
   <insert id="insert" parameterType="com.steerinfo.meterwork.meterworkmonitor.model.MeterWorkMonitor">
     insert into METER_WORK_MONITOR (POINT_NO, POINT_NAME, VALID_WGT, 
@@ -637,7 +657,8 @@
       AMPLIFIER_STATE, LAMP_STATE, SPOT_TYPE_NO, 
       RED_GREEN_LIGHT_STATE, FRONT_INFRARED_RAY_STATE, 
       REAR_INFRARED_RAY_STATE, RFID_STATE, VALID_AREA, 
-      WEIGHT_STATUS)
+      WEIGHT_STATUS, FERROALLOY_CONFIRM, FERROALLOY_RESULT
+      )
     values (#{pointNo,jdbcType=VARCHAR}, #{pointName,jdbcType=VARCHAR}, #{validWgt,jdbcType=VARCHAR}, 
       #{validCarno,jdbcType=VARCHAR}, #{validTareTime,jdbcType=VARCHAR}, #{validTimeInterval,jdbcType=VARCHAR}, 
       #{validParkStatus,jdbcType=VARCHAR}, #{validExceedWgt,jdbcType=VARCHAR}, #{validPredictionDiff,jdbcType=VARCHAR}, 
@@ -657,7 +678,8 @@
       #{amplifierState,jdbcType=VARCHAR}, #{lampState,jdbcType=VARCHAR}, #{spotTypeNo,jdbcType=VARCHAR}, 
       #{redGreenLightState,jdbcType=VARCHAR}, #{frontInfraredRayState,jdbcType=VARCHAR}, 
       #{rearInfraredRayState,jdbcType=VARCHAR}, #{rfidState,jdbcType=VARCHAR}, #{validArea,jdbcType=VARCHAR}, 
-      #{weightStatus,jdbcType=VARCHAR})
+      #{weightStatus,jdbcType=VARCHAR}, #{ferroalloyConfirm,jdbcType=VARCHAR}, #{ferroalloyResult,jdbcType=VARCHAR}
+      )
   </insert>
   <insert id="insertSelective" parameterType="com.steerinfo.meterwork.meterworkmonitor.model.MeterWorkMonitor">
     insert into METER_WORK_MONITOR
@@ -833,6 +855,12 @@
       <if test="weightStatus != null">
         WEIGHT_STATUS,
       </if>
+      <if test="ferroalloyConfirm != null">
+        FERROALLOY_CONFIRM,
+      </if>
+      <if test="ferroalloyResult != null">
+        FERROALLOY_RESULT,
+      </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides=",">
       <if test="pointNo != null">
@@ -1006,6 +1034,12 @@
       <if test="weightStatus != null">
         #{weightStatus,jdbcType=VARCHAR},
       </if>
+      <if test="ferroalloyConfirm != null">
+        #{ferroalloyConfirm,jdbcType=VARCHAR},
+      </if>
+      <if test="ferroalloyResult != null">
+        #{ferroalloyResult,jdbcType=VARCHAR},
+      </if>
     </trim>
   </insert>
   <update id="updateByPrimaryKey" parameterType="com.steerinfo.meterwork.meterworkmonitor.model.MeterWorkMonitor">
@@ -1065,7 +1099,9 @@
       REAR_INFRARED_RAY_STATE = #{rearInfraredRayState,jdbcType=VARCHAR},
       RFID_STATE = #{rfidState,jdbcType=VARCHAR},
       VALID_AREA = #{validArea,jdbcType=VARCHAR},
-      WEIGHT_STATUS = #{weightStatus,jdbcType=VARCHAR}
+      WEIGHT_STATUS = #{weightStatus,jdbcType=VARCHAR},
+      FERROALLOY_CONFIRM = #{ferroalloyConfirm,jdbcType=VARCHAR},
+      FERROALLOY_RESULT = #{ferroalloyResult,jdbcType=VARCHAR}
     where POINT_NO = #{pointNo,jdbcType=VARCHAR}
   </update>
   <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.meterwork.meterworkmonitor.model.MeterWorkMonitor">
@@ -1239,6 +1275,12 @@
       <if test="weightStatus != null">
         WEIGHT_STATUS = #{weightStatus,jdbcType=VARCHAR},
       </if>
+      <if test="ferroalloyConfirm != null">
+        FERROALLOY_CONFIRM = #{ferroalloyConfirm,jdbcType=VARCHAR},
+      </if>
+      <if test="ferroalloyResult != null">
+        FERROALLOY_RESULT = #{ferroalloyResult,jdbcType=VARCHAR},
+      </if>
     </set>
     where POINT_NO = #{pointNo,jdbcType=VARCHAR}
   </update>
@@ -1277,7 +1319,8 @@
       RIGHT_INFRARED_RAY_STATE, AMPLIFIER_STATE, 
       LAMP_STATE, SPOT_TYPE_NO, RED_GREEN_LIGHT_STATE, 
       FRONT_INFRARED_RAY_STATE, REAR_INFRARED_RAY_STATE, 
-      RFID_STATE, VALID_AREA, WEIGHT_STATUS
+      RFID_STATE, VALID_AREA, WEIGHT_STATUS, 
+      FERROALLOY_CONFIRM, FERROALLOY_RESULT
       )
     ( <foreach collection="list" item="item" separator="union all"> 
    select  
@@ -1302,7 +1345,8 @@
       #{item.rightInfraredRayState,jdbcType=VARCHAR}, #{item.amplifierState,jdbcType=VARCHAR}, 
       #{item.lampState,jdbcType=VARCHAR}, #{item.spotTypeNo,jdbcType=VARCHAR}, #{item.redGreenLightState,jdbcType=VARCHAR}, 
       #{item.frontInfraredRayState,jdbcType=VARCHAR}, #{item.rearInfraredRayState,jdbcType=VARCHAR}, 
-      #{item.rfidState,jdbcType=VARCHAR}, #{item.validArea,jdbcType=VARCHAR}, #{item.weightStatus,jdbcType=VARCHAR}
+      #{item.rfidState,jdbcType=VARCHAR}, #{item.validArea,jdbcType=VARCHAR}, #{item.weightStatus,jdbcType=VARCHAR}, 
+      #{item.ferroalloyConfirm,jdbcType=VARCHAR}, #{item.ferroalloyResult,jdbcType=VARCHAR}
        from dual  
    </foreach> )
   </insert>
@@ -1537,6 +1581,14 @@
        <foreach close="end" collection="list" index="index" item="item" open="case POINT_NO" separator=" ">
           when #{item.pointNo,jdbcType=VARCHAR} then #{item.weightStatus,jdbcType=VARCHAR}
        </foreach>
+       ,FERROALLOY_CONFIRM=
+       <foreach close="end" collection="list" index="index" item="item" open="case POINT_NO" separator=" ">
+          when #{item.pointNo,jdbcType=VARCHAR} then #{item.ferroalloyConfirm,jdbcType=VARCHAR}
+       </foreach>
+       ,FERROALLOY_RESULT=
+       <foreach close="end" collection="list" index="index" item="item" open="case POINT_NO" separator=" ">
+          when #{item.pointNo,jdbcType=VARCHAR} then #{item.ferroalloyResult,jdbcType=VARCHAR}
+       </foreach>
      where POINT_NO in 
      <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
     #{item.pointNo,jdbcType=VARCHAR}
@@ -1946,20 +1998,21 @@
   <select id="weightByCarNo" parameterType="java.util.HashMap" resultMap="BaseResultMap">
     <include refid="select" />
     where 1 != 1
-      <if test="setCar != null and setCar != ''">
-        or set_car = #{setCar}
-      </if>
-      <if test="rfidCar != null and rfidCar != ''">
-        or RFID_CAR = #{rfidCar}
-      </if>
-      <if test="photoCar != null and photoCar != ''">
-        or PHOTO_CAR = #{photoCar}
-      </if>
-      <if test="scanCar != null and scanCar != ''">
-        or SCAN_CAR = #{scanCar}
-      </if>
-      <if test="editCar != null and editCar != ''">
-        or EDIT_CAR = #{editCar}
-      </if>
+    <if test="setCar != null and setCar != ''">
+      or set_car = #{setCar}
+    </if>
+    <if test="rfidCar != null and rfidCar != ''">
+      or RFID_CAR = #{rfidCar}
+    </if>
+    <if test="photoCar != null and photoCar != ''">
+      or PHOTO_CAR = #{photoCar}
+    </if>
+    <if test="scanCar != null and scanCar != ''">
+      or SCAN_CAR = #{scanCar}
+    </if>
+    <if test="editCar != null and editCar != ''">
+      or EDIT_CAR = #{editCar}
+    </if>
   </select>
+  
 </mapper>

+ 31 - 0
src/main/java/com/steerinfo/meterwork/meterworkmonitor/model/MeterWorkMonitor.java

@@ -3,6 +3,7 @@ package com.steerinfo.meterwork.meterworkmonitor.model;
 import com.steerinfo.framework.model.IBasePO;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
+
 import java.util.Date;
 
 @ApiModel(value="计量监控表")
@@ -349,6 +350,18 @@ public class MeterWorkMonitor implements IBasePO<String> {
     @ApiModelProperty(value="重量是否稳定     0不稳定    1稳定",required=false)
     private String weightStatus;
 
+    /**
+     * 铁合金确认       0未确认  1已确认(FERROALLOY_CONFIRM,VARCHAR,1)
+     */
+    @ApiModelProperty(value="铁合金确认       0未确认  1已确认",required=false)
+    private String ferroalloyConfirm;
+
+    /**
+     * 铁合金确认结果(FERROALLOY_RESULT,VARCHAR,200)
+     */
+    @ApiModelProperty(value="铁合金确认结果",required=false)
+    private String ferroalloyResult;
+
     private static final long serialVersionUID = 1L;
 
     @Override
@@ -817,6 +830,22 @@ public class MeterWorkMonitor implements IBasePO<String> {
         this.weightStatus = weightStatus == null ? null : weightStatus.trim();
     }
 
+    public String getFerroalloyConfirm() {
+        return ferroalloyConfirm;
+    }
+
+    public void setFerroalloyConfirm(String ferroalloyConfirm) {
+        this.ferroalloyConfirm = ferroalloyConfirm == null ? null : ferroalloyConfirm.trim();
+    }
+
+    public String getFerroalloyResult() {
+        return ferroalloyResult;
+    }
+
+    public void setFerroalloyResult(String ferroalloyResult) {
+        this.ferroalloyResult = ferroalloyResult == null ? null : ferroalloyResult.trim();
+    }
+
     @Override
     public String toString() {
         StringBuilder sb = new StringBuilder();
@@ -880,6 +909,8 @@ public class MeterWorkMonitor implements IBasePO<String> {
         sb.append(", rfidState=").append(rfidState);
         sb.append(", validArea=").append(validArea);
         sb.append(", weightStatus=").append(weightStatus);
+        sb.append(", ferroalloyConfirm=").append(ferroalloyConfirm);
+        sb.append(", ferroalloyResult=").append(ferroalloyResult);
         sb.append(", serialVersionUID=").append(serialVersionUID);
         sb.append("]");
         return sb.toString();

+ 13 - 1
src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/controller/MeterWorkScheduledHelpController.java

@@ -63,7 +63,19 @@ public class MeterWorkScheduledHelpController extends BaseRESTfulController {
         PageList<MeterWorkScheduledHelp> list = meterWorkScheduledHelpService.queryLikeForPage(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("meterworkscheduledhelp:view")
+    @GetMapping(value = "/likeByDesc")
+    public RESTfulResult likeByDesc(@RequestParam HashMap parmas,Integer pageNum, Integer pageSize){
+        PageList<MeterWorkScheduledHelp> list = meterWorkScheduledHelpService.likeByDesc(parmas, pageNum, pageSize);
+        return success(list);
+    }
+
     @ApiOperation(value="创建", notes="根据MeterWorkScheduledHelp对象创建")
     @ApiImplicitParam(name = "meterWorkScheduledHelp", value = "详细实体meterWorkScheduledHelp", required = true, dataType = "MeterWorkScheduledHelp")
     //@RequiresPermissions("meterworkscheduledhelp:create")

+ 5 - 0
src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/mapper/MeterWorkScheduledHelpMapper.java

@@ -5,7 +5,12 @@ import com.steerinfo.meterwork.meterworkscheduledhelp.model.MeterWorkScheduledHe
 import feign.Param;
 import org.apache.ibatis.annotations.Mapper;
 
+import java.util.List;
+import java.util.Map;
+
 @Mapper
 public interface MeterWorkScheduledHelpMapper extends IBaseMapper<MeterWorkScheduledHelp, String> {
     String getNewID(@Param(value = "afl") String afl);
+
+    List<MeterWorkScheduledHelp> likeByDesc(Map<String, Object> var1);
 }

+ 18 - 0
src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/mapper/MeterWorkScheduledHelpMapper.xml

@@ -76,6 +76,12 @@
       <if test="warmTypeName != null and warmTypeName != ''">
         and WARM_TYPE_NAME = #{warmTypeName}
       </if>
+      <if test="startTime01 != null and startTime01 != ''">
+        and create_time >= to_date(#{startTime01}, 'yyyy-MM-dd HH24:mi:ss')
+      </if>
+      <if test="endTime01 != null and endTime01 != ''">
+        and create_time &lt;= to_date(#{endTime01}, 'yyyy-MM-dd HH24:mi:ss')
+      </if>
     </where>
   </sql>
   <sql id="whereLike">
@@ -122,6 +128,12 @@
       <if test="warmTypeName != null and warmTypeName != ''">
         and WARM_TYPE_NAME LIKE '%${warmTypeName}%'
       </if>
+      <if test="startTime01 != null and startTime01 != ''">
+        and create_time >= to_date(#{startTime01}, 'yyyy-MM-dd HH24:mi:ss')
+      </if>
+      <if test="endTime01 != null and endTime01 != ''">
+        and create_time &lt;= to_date(#{endTime01}, 'yyyy-MM-dd HH24:mi:ss')
+      </if>
     </where>
   </sql>
   <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
@@ -443,4 +455,10 @@
     SELECT LPAD(NVL(MAX(TO_NUMBER(SUBSTR(HELP_ID, LENGTH(HELP_ID) - 3))),0) + 1,4,'0') HELP_ID
     FROM METER_WORK_SCHEDULED_HELP where instr(HELP_ID,#{afl,jdbcType=VARCHAR})>0
   </select>
+
+  <select id="likeByDesc" parameterType="java.util.HashMap" resultMap="BaseResultMap">
+    <include refid="select"/>
+    <include refid="whereLike"/>
+    order by create_time desc
+  </select>
 </mapper>

+ 4 - 0
src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/service/IMeterWorkScheduledHelpService.java

@@ -2,8 +2,11 @@ package com.steerinfo.meterwork.meterworkscheduledhelp.service;
 
 import com.steerinfo.framework.controller.RESTfulResult;
 import com.steerinfo.framework.service.IBaseService;
+import com.steerinfo.framework.service.pagehelper.PageList;
 import com.steerinfo.meterwork.meterworkscheduledhelp.model.MeterWorkScheduledHelp;
 
+import java.util.Map;
+
 /**
  * MeterWorkScheduledHelp服务接口:
  * @author generator
@@ -21,4 +24,5 @@ public interface IMeterWorkScheduledHelpService extends IBaseService<MeterWorkSc
     RESTfulResult scheduledHelp(String carNo, String baseSpotNo, String baseSpotName, String helpContent);
     RESTfulResult scheduledHelpConfirm(String id, String createNo, String createName, String result);
     RESTfulResult checkAdd(MeterWorkScheduledHelp model);
+    PageList<MeterWorkScheduledHelp> likeByDesc(Map<String, Object> var1, Integer var2, Integer var3);
 }

+ 11 - 0
src/main/java/com/steerinfo/meterwork/meterworkscheduledhelp/service/impl/MeterWorkScheduledHelpServiceImpl.java

@@ -4,6 +4,8 @@ import com.steerinfo.baseinfo.appphonehelp.model.AppPhoneHelp;
 import com.steerinfo.framework.controller.RESTfulResult;
 import com.steerinfo.framework.mapper.IBaseMapper;
 import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import com.steerinfo.framework.service.pagehelper.PageHelper;
+import com.steerinfo.framework.service.pagehelper.PageList;
 import com.steerinfo.meterwork.except.MarkerMetException;
 import com.steerinfo.meterwork.meterworkscheduledhelp.mapper.MeterWorkScheduledHelpMapper;
 import com.steerinfo.meterwork.meterworkscheduledhelp.model.MeterWorkScheduledHelp;
@@ -17,6 +19,7 @@ import java.text.SimpleDateFormat;
 import java.util.Date;
 import java.util.HashMap;
 import java.util.List;
+import java.util.Map;
 
 /**
  * MeterWorkScheduledHelp服务实现:
@@ -143,4 +146,12 @@ public class MeterWorkScheduledHelpServiceImpl extends BaseServiceImpl<MeterWork
             return rm;
         }
     }
+
+    @Override
+    public PageList<MeterWorkScheduledHelp> likeByDesc(Map<String, Object> parameters, Integer pageNum, Integer pageSize) {
+        PageHelper.startPage(pageNum, pageSize);
+        List<MeterWorkScheduledHelp> rows = meterWorkScheduledHelpMapper.likeByDesc(parameters);
+        PageList pageInfo = new PageList(rows);
+        return pageInfo;
+    }
 }

+ 17 - 0
src/main/java/com/steerinfo/pretrack/pretrackscale/controller/PreTrackScaleController.java

@@ -87,6 +87,23 @@ public class PreTrackScaleController extends BaseRESTfulController {
         }
     }
 
+    @ApiOperation(value = "获取列表", notes = "分页模糊查询")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+            @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer")
+    })
+    //@RequiresPermissions("pretrackscale:view")
+    @GetMapping(value = "/likeByDesc")
+    public RESTfulResult likeByDesc(@RequestParam HashMap parmas, Integer pageNum, Integer pageSize) {
+        try {
+            PageList<PreTrackScale> list = preTrackScaleService.likeByDesc(parmas, pageNum, pageSize);
+            return success(list);
+        } catch (Exception ex) {
+            ex.printStackTrace();
+            throw new MarkerMetException(500, "操作异常!!");
+        }
+    }
+
     @ApiOperation(value = "获取列表", notes = "分页模糊查询")
     @ApiImplicitParams({
             @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),

+ 2 - 0
src/main/java/com/steerinfo/pretrack/pretrackscale/mapper/PreTrackScaleMapper.java

@@ -16,6 +16,8 @@ public interface PreTrackScaleMapper extends IBaseMapper<PreTrackScale, String>
     // 根据车号查询未使用和使用中的预报
     List<PreTrackScale> selectlist(@Param( value = "carNo") String carNo);
 
+    List<PreTrackScale> likeByDesc(Map<String, Object> var1);
+
     List<PreTrackScale> selectuselist(@Param( value = "carNo") String carNo);
 
     List<PreTrackScale> selectView(Map<String, Objects> param);

+ 6 - 0
src/main/java/com/steerinfo/pretrack/pretrackscale/mapper/PreTrackScaleMapper.xml

@@ -3307,4 +3307,10 @@
     <include refid="where"/>
     and TRUST_AVAILABILITY_TIME &gt; SYSDATE
   </select>
+
+  <select id="likeByDesc" parameterType="java.util.HashMap" resultMap="BaseResultMap">
+    <include refid="select"/>
+    <include refid="whereLike"/>
+    order By TRUST_DATE_TIME desc
+  </select>
 </mapper>

+ 3 - 0
src/main/java/com/steerinfo/pretrack/pretrackscale/service/IPreTrackScaleService.java

@@ -2,10 +2,12 @@ package com.steerinfo.pretrack.pretrackscale.service;
 
 import com.steerinfo.framework.controller.RESTfulResult;
 import com.steerinfo.framework.service.IBaseService;
+import com.steerinfo.framework.service.pagehelper.PageList;
 import com.steerinfo.pretrack.pretrackscale.model.PreTrackScale;
 
 import java.util.HashMap;
 import java.util.List;
+import java.util.Map;
 
 /**
  * PreTrackScale服务接口:
@@ -23,6 +25,7 @@ import java.util.List;
 public interface IPreTrackScaleService extends IBaseService<PreTrackScale, String>{
 
     List<PreTrackScale> selectlist(String carNo);
+    PageList<PreTrackScale> likeByDesc(Map<String, Object> var1, Integer var2, Integer var3);
 
     List<PreTrackScale> selectByCarNo(String carNo, String valueFlag);
 

+ 10 - 0
src/main/java/com/steerinfo/pretrack/pretrackscale/service/impl/PreTrackScaleServiceImpl.java

@@ -12,6 +12,8 @@ import com.steerinfo.baseinfo.meterbaselimitchemical.model.MeterBaseLimitChemica
 import com.steerinfo.framework.controller.RESTfulResult;
 import com.steerinfo.framework.mapper.IBaseMapper;
 import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import com.steerinfo.framework.service.pagehelper.PageHelper;
+import com.steerinfo.framework.service.pagehelper.PageList;
 import com.steerinfo.framework.user.UserPayload;
 import com.steerinfo.meterwork.except.MarkerMetException;
 import com.steerinfo.meterwork.meterworkcarcheck.mapper.MeterWorkCarCheckMapper;
@@ -119,6 +121,14 @@ public class PreTrackScaleServiceImpl extends BaseServiceImpl<PreTrackScale, Str
         }
     }
 
+    @Override
+    public PageList<PreTrackScale> likeByDesc(Map<String, Object> parameters, Integer pageNum, Integer pageSize) {
+        PageHelper.startPage(pageNum, pageSize);
+        List<PreTrackScale> rows = preTrackScaleMapper.likeByDesc(parameters);
+        PageList pageInfo = new PageList(rows);
+        return pageInfo;
+    }
+
     @Override
     @Transactional(rollbackFor = Exception.class)
     public List<PreTrackScale> selectView(HashMap param) {