From 077a2cab498cf3359f4c7fd6ebe6d7b9544a3cae Mon Sep 17 00:00:00 2001
From: 张磊磊 <201175954@qq.com>
Date: 星期五, 24 十一月 2023 11:18:06 +0800
Subject: [PATCH] 称重记录(地磅)
---
hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/impl/WeighServiceImpl.java | 14 +++
hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/mapper/WeighMapper.java | 3
hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/entity/TWeighbridge.java | 137 ++++++++++++++++++++++++++++++++++
hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/WeighService.java | 3
hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/controller/WeighController.java | 11 ++
hd/pipe/materialsManage/src/main/resources/mapping/WeighMapper.xml | 35 ++++++++
6 files changed, 203 insertions(+), 0 deletions(-)
diff --git a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/controller/WeighController.java b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/controller/WeighController.java
index a6d58b0..c782925 100644
--- a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/controller/WeighController.java
+++ b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/controller/WeighController.java
@@ -6,11 +6,14 @@
import com.thhy.materials.modules.biz.weigh.dto.QueryWeighDto;
import com.thhy.materials.modules.biz.weigh.entity.WeighVo;
import com.thhy.materials.modules.biz.weigh.service.WeighService;
+import org.omg.CORBA.StringHolder;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
+
+import java.util.Map;
/**
* @Author QiuYuHao
@@ -31,4 +34,12 @@
PageInfo<WeighVo> weighVoPageInfo = new PageInfo<>(weighService.findAll(queryWeighDto));
return BasicResult.success(weighVoPageInfo);
}
+
+ @PostMapping("/weighbridgeList")
+ public BasicResult weighbridgeList(@RequestBody Map<String,Object> values){
+ return weighService.weighbridgeList(values);
+ }
+
+
+
}
diff --git a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/entity/TWeighbridge.java b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/entity/TWeighbridge.java
new file mode 100644
index 0000000..928d851
--- /dev/null
+++ b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/entity/TWeighbridge.java
@@ -0,0 +1,137 @@
+package com.thhy.materials.modules.biz.weigh.entity;
+
+import lombok.Data;
+import lombok.Getter;
+import lombok.Setter;
+import lombok.ToString;
+
+import java.io.Serializable;
+
+@Data
+@Getter
+@Setter
+@ToString
+public class TWeighbridge implements Serializable {
+ /**
+ *
+ */
+ private Integer weighbridgeId;
+
+ /**
+ * 数据id
+ */
+ private String id;
+
+ /**
+ * 过磅编号
+ */
+ private String code;
+
+ /**
+ * 业务所属机构
+ */
+ private String orgname;
+
+ /**
+ * 供应单位名称
+ */
+ private String supplyorgname;
+
+ /**
+ * 运输车牌号
+ */
+ private String carnumber;
+
+ /**
+ * 运输司机
+ */
+ private String drivername;
+
+ /**
+ * 原料名称
+ */
+ private String matname;
+
+ /**
+ * 原材料型号
+ */
+ private String matmodel;
+
+ /**
+ * 过毛时间
+ */
+ private String mpoundtime;
+
+ /**
+ * 过磅毛重 千克 kg
+ */
+ private String mpoundweight;
+
+ /**
+ * 过毛人
+ */
+ private String mpoundname;
+
+ /**
+ * 皮重时间
+ */
+ private String ppoundtime;
+
+ /**
+ * 皮重
+ */
+ private String ppoundweight;
+
+ /**
+ * 过皮人
+ */
+ private String ppoundname;
+
+ /**
+ * 过磅净重
+ */
+ private String jpoundweight;
+
+ /**
+ * 扣重
+ */
+ private String buckleweight;
+
+ /**
+ * 毛重
+ */
+ private String mweight;
+
+ /**
+ * 皮重
+ */
+ private String pweight;
+
+ /**
+ * 净重
+ */
+ private String jweight;
+
+ /**
+ * 入库仓名称
+ */
+ private String warename;
+
+ /**
+ * 过磅图片,最多会有四张图片路径,逗号隔开
+ */
+ private String fileimage;
+
+ /**
+ * 1未同步2已同步
+ */
+ private Integer types;
+
+ /**
+ * This field was generated by MyBatis Generator.
+ * This field corresponds to the database table t_weighbridge
+ *
+ * @mbg.generated Fri Nov 24 11:06:42 CST 2023
+ */
+ private static final long serialVersionUID = 1L;
+}
\ No newline at end of file
diff --git a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/mapper/WeighMapper.java b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/mapper/WeighMapper.java
index 32fd32d..cde8c15 100644
--- a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/mapper/WeighMapper.java
+++ b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/mapper/WeighMapper.java
@@ -6,6 +6,7 @@
import com.thhy.materials.modules.biz.concret.entity.dto.WeighDto;
import com.thhy.materials.modules.biz.video.entity.TVideoNo;
import com.thhy.materials.modules.biz.weigh.dto.QueryWeighDto;
+import com.thhy.materials.modules.biz.weigh.entity.TWeighbridge;
import com.thhy.materials.modules.biz.weigh.entity.WeighVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@@ -70,4 +71,6 @@
Integer netWeighNew(Integer byId);
void netWeighUpdateNew(@Param("byId") Integer byId,@Param("netWeight") double netWeight);
+
+ List<TWeighbridge> weighbridgeList(Map<String, Object> values);
}
diff --git a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/WeighService.java b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/WeighService.java
index 98d3b2e..895dc22 100644
--- a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/WeighService.java
+++ b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/WeighService.java
@@ -37,4 +37,7 @@
List<WeighDto> findAlltaskNew(Integer byId, String dictName);
List<WeighDto> findAlltaskAllNew(String dictName);
+
+ BasicResult weighbridgeList(Map<String, Object> values);
+
}
diff --git a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/impl/WeighServiceImpl.java b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/impl/WeighServiceImpl.java
index c45000c..3e1f773 100644
--- a/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/impl/WeighServiceImpl.java
+++ b/hd/pipe/materialsManage/src/main/java/com/thhy/materials/modules/biz/weigh/service/impl/WeighServiceImpl.java
@@ -1,9 +1,13 @@
package com.thhy.materials.modules.biz.weigh.service.impl;
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
+import com.thhy.general.common.BasicResult;
import com.thhy.materials.modules.biz.concret.entity.dto.DicetName;
import com.thhy.materials.modules.biz.concret.entity.dto.TMinxingPlant;
import com.thhy.materials.modules.biz.concret.entity.dto.WeighDto;
import com.thhy.materials.modules.biz.weigh.dto.QueryWeighDto;
+import com.thhy.materials.modules.biz.weigh.entity.TWeighbridge;
import com.thhy.materials.modules.biz.weigh.entity.WeighVo;
import com.thhy.materials.modules.biz.weigh.mapper.WeighMapper;
import com.thhy.materials.modules.biz.weigh.service.WeighService;
@@ -81,4 +85,14 @@
List<WeighDto> WeighVo= weighMapper.findAlltaskAllNew(dictName);
return WeighVo;
}
+
+ @Override
+ public BasicResult weighbridgeList(Map<String, Object> values) {
+ Integer pageSize = Integer.valueOf(values.get("pageSize").toString());
+ Integer pageNum = Integer.valueOf(values.get("pageNum").toString());
+ PageHelper.startPage(pageNum,pageSize);
+ List<TWeighbridge> weighbridges = weighMapper.weighbridgeList(values);
+ PageInfo<TWeighbridge> tWeighbridgePageInfo = new PageInfo<>(weighbridges);
+ return BasicResult.success(tWeighbridgePageInfo);
+ }
}
diff --git a/hd/pipe/materialsManage/src/main/resources/mapping/WeighMapper.xml b/hd/pipe/materialsManage/src/main/resources/mapping/WeighMapper.xml
index 2523497..ddadc5f 100644
--- a/hd/pipe/materialsManage/src/main/resources/mapping/WeighMapper.xml
+++ b/hd/pipe/materialsManage/src/main/resources/mapping/WeighMapper.xml
@@ -579,5 +579,40 @@
where by_id=#{byId}
</update>
+ <select id="weighbridgeList" resultType="com.thhy.materials.modules.biz.weigh.entity.TWeighbridge">
+ select
+ weighbridge_id as weighbridgeId,
+ id,
+ code,
+ orgName,
+ supplyOrgName,
+ carNumber,
+ driverName,
+ matName,
+ matModel,
+ mPoundTime,
+ mPoundWeight,
+ mPoundName,
+ pPoundTime,
+ pPoundWeight,
+ pPoundName,
+ jPoundWeight,
+ buckleWeight,
+ mWeight,
+ pWeight,
+ jWeight,
+ wareName,
+ fileImage,
+ types
+ from t_weighbridge where
+ 1=1
+ <if test="carNumber!=null and carNumber!='' ">
+ and carNumber like concat('%',#{carNumber},'%')
+ </if>
+ <if test="matName!=null and matName!='' ">
+ and matName like concat('%',#{matName},'%')
+ </if>
+ order by weighbridge_id desc
+ </select>
</mapper>
\ No newline at end of file
--
Gitblit v1.9.3