Compare commits
2 Commits
2f5bf785a7
...
5c5a27bdea
Author | SHA1 | Date | |
---|---|---|---|
5c5a27bdea | |||
137b495af7 |
@ -0,0 +1,69 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.controller;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import com.zhyc.common.annotation.Log;
|
||||||
|
import com.zhyc.common.core.controller.BaseController;
|
||||||
|
import com.zhyc.common.core.domain.AjaxResult;
|
||||||
|
import com.zhyc.common.enums.BusinessType;
|
||||||
|
import com.zhyc.common.core.page.TableDataInfo;
|
||||||
|
import com.zhyc.common.utils.poi.ExcelUtil;
|
||||||
|
import com.zhyc.module.dairyProducts.domain.NpMilkProdClasses;
|
||||||
|
import com.zhyc.module.dairyProducts.service.INpMilkProdClassesService;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/milkProdclasses/milkProdclasses")
|
||||||
|
public class NpMilkProdClassesController extends BaseController {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private INpMilkProdClassesService npMilkProdClassesService;
|
||||||
|
|
||||||
|
@PreAuthorize("@ss.hasPermi('milkProdclasses:milkProdclasses:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(
|
||||||
|
@RequestParam(required = false) Date datetimeStart,
|
||||||
|
@RequestParam(required = false) Date datetimeEnd,
|
||||||
|
@RequestParam(required = false) String manageEarNo, // 改为单个字符串,模糊
|
||||||
|
@RequestParam(required = false) String factory,
|
||||||
|
@RequestParam(required = false) Integer classes) {
|
||||||
|
startPage();
|
||||||
|
List<NpMilkProdClasses> list = npMilkProdClassesService
|
||||||
|
.selectNpMilkProdClassesList(datetimeStart, datetimeEnd,
|
||||||
|
manageEarNo, factory, classes);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("@ss.hasPermi('milkProdclasses:milkProdclasses:import')")
|
||||||
|
@Log(title = "班次产奶", businessType = BusinessType.IMPORT)
|
||||||
|
@PostMapping("/import")
|
||||||
|
public AjaxResult importData(MultipartFile file) {
|
||||||
|
try {
|
||||||
|
ExcelUtil<NpMilkProdClasses> util = new ExcelUtil<>(NpMilkProdClasses.class);
|
||||||
|
List<NpMilkProdClasses> list = util.importExcel(file.getInputStream());
|
||||||
|
int rows = npMilkProdClassesService.importMilkProdClasses(list);
|
||||||
|
return success("成功导入 " + rows + " 行数据");
|
||||||
|
} catch (Exception e) {
|
||||||
|
return error("导入失败:" + e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreAuthorize("@ss.hasPermi('milkProdclasses:milkProdclasses:export')")
|
||||||
|
@Log(title = "班次产奶", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response,
|
||||||
|
@RequestParam(required = false) Date datetimeStart,
|
||||||
|
@RequestParam(required = false) Date datetimeEnd,
|
||||||
|
@RequestParam(required = false) String manageEarNos,
|
||||||
|
@RequestParam(required = false) String factory,
|
||||||
|
@RequestParam(required = false) Integer classes) {
|
||||||
|
List<NpMilkProdClasses> list = npMilkProdClassesService.selectNpMilkProdClassesList(datetimeStart, datetimeEnd, manageEarNos, factory, classes);
|
||||||
|
ExcelUtil<NpMilkProdClasses> util = new ExcelUtil<>(NpMilkProdClasses.class);
|
||||||
|
util.exportExcel(response, list, "班次产奶数据");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,23 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.controller;
|
||||||
|
|
||||||
|
import com.zhyc.common.core.controller.BaseController;
|
||||||
|
import com.zhyc.common.core.domain.AjaxResult;
|
||||||
|
import com.zhyc.module.dairyProducts.domain.Ranch;
|
||||||
|
import com.zhyc.module.dairyProducts.service.IRanchService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/dairyProducts/ranch")
|
||||||
|
public class RanchController extends BaseController {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IRanchService ranchService;
|
||||||
|
|
||||||
|
@GetMapping("/list")
|
||||||
|
public AjaxResult list() {
|
||||||
|
return success(ranchService.selectAllRanch());
|
||||||
|
}
|
||||||
|
}
|
@ -38,12 +38,20 @@ public class XzParityCorrectionController extends BaseController
|
|||||||
* 查询胎次校正列表
|
* 查询胎次校正列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('parityCorrection:parityCorrection:list')")
|
@PreAuthorize("@ss.hasPermi('parityCorrection:parityCorrection:list')")
|
||||||
@GetMapping("/list")
|
// @GetMapping("/list")
|
||||||
public TableDataInfo list(XzParityCorrection xzParityCorrection)
|
// public TableDataInfo list(XzParityCorrection xzParityCorrection)
|
||||||
{
|
// {
|
||||||
startPage();
|
// startPage();
|
||||||
|
// List<XzParityCorrection> list = xzParityCorrectionService.selectXzParityCorrectionList(xzParityCorrection);
|
||||||
|
// return getDataTable(list);
|
||||||
|
// }
|
||||||
|
/**
|
||||||
|
* 获取全部胎次校正(无需分页,供下拉/列表直接显示)
|
||||||
|
*/
|
||||||
|
@GetMapping("/listAll")
|
||||||
|
public AjaxResult listAll(XzParityCorrection xzParityCorrection){
|
||||||
List<XzParityCorrection> list = xzParityCorrectionService.selectXzParityCorrectionList(xzParityCorrection);
|
List<XzParityCorrection> list = xzParityCorrectionService.selectXzParityCorrectionList(xzParityCorrection);
|
||||||
return getDataTable(list);
|
return success(list); // 直接返回数组
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -0,0 +1,80 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.domain;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.zhyc.common.annotation.Excel;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public class NpMilkProdClasses implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
private Long id; // 主键ID
|
||||||
|
private Date createTime; // 创建时间
|
||||||
|
private Date updateTime; // 更新时间
|
||||||
|
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "日期")
|
||||||
|
private Date datetime;
|
||||||
|
|
||||||
|
@Excel(name = "管理耳号")
|
||||||
|
private String manageEarNo;
|
||||||
|
|
||||||
|
@Excel(name = "电子耳号")
|
||||||
|
private String electronicEarNo;
|
||||||
|
|
||||||
|
@Excel(name = "胎次")
|
||||||
|
private Integer parity;
|
||||||
|
|
||||||
|
@Excel(name = "厂区")
|
||||||
|
private String factory;
|
||||||
|
|
||||||
|
@Excel(name = "班次")
|
||||||
|
private Integer classes;
|
||||||
|
|
||||||
|
@Excel(name = "班次产奶量")
|
||||||
|
private Double milk;
|
||||||
|
|
||||||
|
@Excel(name = "班次校正奶量")
|
||||||
|
private Double correctedMilk;
|
||||||
|
|
||||||
|
private String sheepId;
|
||||||
|
|
||||||
|
// Getters and Setters
|
||||||
|
public Long getId() { return id; }
|
||||||
|
public void setId(Long id) { this.id = id; }
|
||||||
|
|
||||||
|
public Date getCreateTime() { return createTime; }
|
||||||
|
public void setCreateTime(Date createTime) { this.createTime = createTime; }
|
||||||
|
|
||||||
|
public Date getUpdateTime() { return updateTime; }
|
||||||
|
public void setUpdateTime(Date updateTime) { this.updateTime = updateTime; }
|
||||||
|
|
||||||
|
public Date getDatetime() { return datetime; }
|
||||||
|
public void setDatetime(Date datetime) { this.datetime = datetime; }
|
||||||
|
|
||||||
|
public String getManageEarNo() { return manageEarNo; }
|
||||||
|
public void setManageEarNo(String manageEarNo) { this.manageEarNo = manageEarNo; }
|
||||||
|
|
||||||
|
public String getElectronicEarNo() { return electronicEarNo; }
|
||||||
|
public void setElectronicEarNo(String electronicEarNo) { this.electronicEarNo = electronicEarNo; }
|
||||||
|
|
||||||
|
public Integer getParity() { return parity; }
|
||||||
|
public void setParity(Integer parity) { this.parity = parity; }
|
||||||
|
|
||||||
|
public String getFactory() { return factory; }
|
||||||
|
public void setFactory(String factory) { this.factory = factory; }
|
||||||
|
|
||||||
|
public Integer getClasses() { return classes; }
|
||||||
|
public void setClasses(Integer classes) { this.classes = classes; }
|
||||||
|
|
||||||
|
public Double getMilk() { return milk; }
|
||||||
|
public void setMilk(Double milk) { this.milk = milk; }
|
||||||
|
|
||||||
|
public Double getCorrectedMilk() { return correctedMilk; }
|
||||||
|
public void setCorrectedMilk(Double correctedMilk) { this.correctedMilk = correctedMilk; }
|
||||||
|
|
||||||
|
public String getSheepId() { return sheepId; }
|
||||||
|
public void setSheepId(String sheepId) { this.sheepId = sheepId; }
|
||||||
|
}
|
@ -0,0 +1,12 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.domain;
|
||||||
|
|
||||||
|
public class Ranch {
|
||||||
|
private String ranchCode;
|
||||||
|
private String ranchName;
|
||||||
|
|
||||||
|
public String getRanchCode() { return ranchCode; }
|
||||||
|
public void setRanchCode(String ranchCode) { this.ranchCode = ranchCode; }
|
||||||
|
|
||||||
|
public String getRanchName() { return ranchName; }
|
||||||
|
public void setRanchName(String ranchName) { this.ranchName = ranchName; }
|
||||||
|
}
|
@ -0,0 +1,25 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.mapper;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.zhyc.module.dairyProducts.domain.NpMilkProdClasses;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface NpMilkProdClassesMapper {
|
||||||
|
List<NpMilkProdClasses> selectNpMilkProdClassesList(
|
||||||
|
@Param("datetimeStart") Date datetimeStart,
|
||||||
|
@Param("datetimeEnd") Date datetimeEnd,
|
||||||
|
@Param("manageEarNo") String manageEarNo,
|
||||||
|
@Param("factory") String factory,
|
||||||
|
@Param("classes") Integer classes);
|
||||||
|
|
||||||
|
int insertNpMilkProdClasses(NpMilkProdClasses row);
|
||||||
|
|
||||||
|
String selectSheepIdByManageEarNo(@Param("manageEarNo") String manageEarNo);
|
||||||
|
|
||||||
|
Double getWeightCorrection(@Param("date") Date date, @Param("factory") String factory);
|
||||||
|
|
||||||
|
Double getParityCorrection(@Param("parity") Integer parity);
|
||||||
|
|
||||||
|
Double getDryMatterCorrection(@Param("date") Date date, @Param("factory") String factory);
|
||||||
|
}
|
@ -0,0 +1,10 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.mapper;
|
||||||
|
|
||||||
|
import com.zhyc.module.dairyProducts.domain.Ranch;
|
||||||
|
import org.apache.ibatis.annotations.Select;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface RanchMapper {
|
||||||
|
@Select("SELECT ranch AS ranchName, ranch AS ranchCode FROM da_ranch")
|
||||||
|
List<Ranch> selectAllRanch();
|
||||||
|
}
|
@ -0,0 +1,16 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.service;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
import com.zhyc.module.dairyProducts.domain.NpMilkProdClasses;
|
||||||
|
|
||||||
|
public interface INpMilkProdClassesService {
|
||||||
|
List<NpMilkProdClasses> selectNpMilkProdClassesList(
|
||||||
|
Date datetimeStart,
|
||||||
|
Date datetimeEnd,
|
||||||
|
String manageEarNo, // 改为单个 String
|
||||||
|
String factory,
|
||||||
|
Integer classes);
|
||||||
|
|
||||||
|
int importMilkProdClasses(List<NpMilkProdClasses> list);
|
||||||
|
}
|
@ -0,0 +1,8 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.service;
|
||||||
|
|
||||||
|
import com.zhyc.module.dairyProducts.domain.Ranch;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface IRanchService {
|
||||||
|
List<Ranch> selectAllRanch();
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.service.impl;
|
||||||
|
|
||||||
|
import com.zhyc.module.dairyProducts.domain.NpMilkProdClasses;
|
||||||
|
import com.zhyc.module.dairyProducts.mapper.NpMilkProdClassesMapper;
|
||||||
|
import com.zhyc.module.dairyProducts.service.INpMilkProdClassesService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class NpMilkProdClassesServiceImpl implements INpMilkProdClassesService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private NpMilkProdClassesMapper mapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<NpMilkProdClasses> selectNpMilkProdClassesList(Date datetimeStart, Date datetimeEnd,
|
||||||
|
String manageEarNo, String factory, Integer classes) {
|
||||||
|
return mapper.selectNpMilkProdClassesList(datetimeStart, datetimeEnd, manageEarNo, factory, classes);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int importMilkProdClasses(List<NpMilkProdClasses> list) {
|
||||||
|
int count = 0;
|
||||||
|
for (NpMilkProdClasses item : list) {
|
||||||
|
// 根据管理耳号查 sheep_id
|
||||||
|
String sheepId = mapper.selectSheepIdByManageEarNo(item.getManageEarNo());
|
||||||
|
if (sheepId == null) continue;
|
||||||
|
|
||||||
|
item.setSheepId(sheepId);
|
||||||
|
|
||||||
|
// 计算校正奶量
|
||||||
|
Double correctedMilk = calculateCorrectedMilk(item);
|
||||||
|
item.setCorrectedMilk(correctedMilk);
|
||||||
|
|
||||||
|
// 插入数据
|
||||||
|
count += mapper.insertNpMilkProdClasses(item);
|
||||||
|
}
|
||||||
|
return count;
|
||||||
|
}
|
||||||
|
|
||||||
|
private Double calculateCorrectedMilk(NpMilkProdClasses item) {
|
||||||
|
Double milk = item.getMilk();
|
||||||
|
if (milk == null) return null;
|
||||||
|
|
||||||
|
// 1. 称重矫正系数
|
||||||
|
Double weightCorrection = mapper.getWeightCorrection(item.getDatetime(), item.getFactory());
|
||||||
|
if (weightCorrection == null) weightCorrection = 1.0;
|
||||||
|
|
||||||
|
// 2. 胎次矫正系数
|
||||||
|
Double parityCorrection = mapper.getParityCorrection(item.getParity());
|
||||||
|
if (parityCorrection == null) parityCorrection = 1.0;
|
||||||
|
|
||||||
|
// 3. 干物质矫正系数
|
||||||
|
Double dryMatterCorrection = mapper.getDryMatterCorrection(item.getDatetime(), item.getFactory());
|
||||||
|
if (dryMatterCorrection == null) dryMatterCorrection = 1.0;
|
||||||
|
|
||||||
|
return milk * weightCorrection * parityCorrection * dryMatterCorrection;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,19 @@
|
|||||||
|
package com.zhyc.module.dairyProducts.service.impl;
|
||||||
|
|
||||||
|
import com.zhyc.module.dairyProducts.domain.Ranch;
|
||||||
|
import com.zhyc.module.dairyProducts.mapper.RanchMapper;
|
||||||
|
import com.zhyc.module.dairyProducts.service.IRanchService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class RanchServiceImpl implements IRanchService {
|
||||||
|
@Autowired
|
||||||
|
private RanchMapper ranchMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Ranch> selectAllRanch() {
|
||||||
|
return ranchMapper.selectAllRanch();
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,93 @@
|
|||||||
|
<?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.zhyc.module.dairyProducts.mapper.NpMilkProdClassesMapper">
|
||||||
|
|
||||||
|
<resultMap id="NpMilkProdClassesResult" type="com.zhyc.module.dairyProducts.domain.NpMilkProdClasses">
|
||||||
|
<result property="id" column="id"/>
|
||||||
|
<result property="datetime" column="datetime"/>
|
||||||
|
<result property="manageEarNo" column="bs_manage_tags"/>
|
||||||
|
<result property="electronicEarNo" column="electronic_tags"/>
|
||||||
|
<result property="parity" column="parity"/>
|
||||||
|
<result property="factory" column="dr_ranch"/>
|
||||||
|
<result property="classes" column="classes"/>
|
||||||
|
<result property="milk" column="milk"/>
|
||||||
|
<result property="correctedMilk" column="corrected_milk"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="selectNpMilkProdClassesList" resultMap="NpMilkProdClassesResult">
|
||||||
|
SELECT
|
||||||
|
mpc.id,
|
||||||
|
mpc.datetime,
|
||||||
|
v.bs_manage_tags, <!-- 取消别名,使用原列名 -->
|
||||||
|
v.electronic_tags,
|
||||||
|
v.parity,
|
||||||
|
v.dr_ranch,
|
||||||
|
mpc.classes,
|
||||||
|
mpc.milk,
|
||||||
|
mpc.corrected_milk AS corrected_milk
|
||||||
|
<!-- 修改为与 resultMap 对应的列名 -->
|
||||||
|
FROM np_milk_prod_classes mpc
|
||||||
|
JOIN sheep_file v ON mpc.sheep_id = v.id
|
||||||
|
LEFT JOIN xz_wegih_correction wc ON DATE(mpc.datetime) = DATE(wc.datetime) AND v.dr_ranch = wc.factory
|
||||||
|
LEFT JOIN xz_parity_correction pc ON v.parity = pc.parity
|
||||||
|
LEFT JOIN xz_dry_matter_correction dmco ON DATE_FORMAT(mpc.datetime, '%Y-%m') = DATE_FORMAT(dmco.datetime, '%Y-%m') AND v.dr_ranch = dmco.standard
|
||||||
|
<where>
|
||||||
|
<if test="datetimeStart != null">
|
||||||
|
AND mpc.datetime >= #{datetimeStart}
|
||||||
|
</if>
|
||||||
|
<if test="datetimeEnd != null">
|
||||||
|
AND mpc.datetime <= #{datetimeEnd}
|
||||||
|
</if>
|
||||||
|
<if test="manageEarNo != null and manageEarNo != ''">
|
||||||
|
AND v.bs_manage_tags LIKE CONCAT('%', #{manageEarNo}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="factory != null and factory != ''">
|
||||||
|
AND v.dr_ranch = #{factory}
|
||||||
|
</if>
|
||||||
|
<if test="classes != null">
|
||||||
|
AND mpc.classes = #{classes}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 称重矫正系数 -->
|
||||||
|
<select id="getWeightCorrection" resultType="java.lang.Double">
|
||||||
|
SELECT actual / system_milk
|
||||||
|
FROM xz_wegih_correction
|
||||||
|
WHERE DATE(datetime) = DATE(#{date})
|
||||||
|
AND factory = #{factory}
|
||||||
|
AND system_milk > 0
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 胎次矫正系数 -->
|
||||||
|
<select id="getParityCorrection" resultType="java.lang.Double">
|
||||||
|
SELECT
|
||||||
|
CASE
|
||||||
|
WHEN parity = 1 THEN 1.2
|
||||||
|
WHEN parity BETWEEN 2 AND 4 THEN 0.96
|
||||||
|
ELSE 1
|
||||||
|
END
|
||||||
|
FROM xz_parity_correction
|
||||||
|
WHERE parity = #{parity}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 干物质矫正系数 -->
|
||||||
|
<select id="getDryMatterCorrection" resultType="java.lang.Double">
|
||||||
|
SELECT coefficient
|
||||||
|
FROM xz_dry_matter_correction
|
||||||
|
WHERE DATE_FORMAT(datetime, '%Y-%m') = DATE_FORMAT(#{date}, '%Y-%m')
|
||||||
|
AND factory = #{factory}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertNpMilkProdClasses" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
INSERT INTO np_milk_prod_classes (datetime, sheep_id, classes, milk, corrected_milk)
|
||||||
|
VALUES (#{datetime}, #{sheepId}, #{classes}, #{milk}, #{correctedMilk})
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<select id="selectSheepIdByManageEarNo" resultType="java.lang.String">
|
||||||
|
SELECT id
|
||||||
|
FROM sheep_file
|
||||||
|
WHERE bs_manage_tags = #{manageEarNo}
|
||||||
|
</select>
|
||||||
|
</mapper>
|
Loading…
x
Reference in New Issue
Block a user