<?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.huimv.produce.produce.mapper.WeightInformationMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.huimv.produce.produce.entity.WeightInformation">
        <id column="id" property="id" />
        <result column="serial_number" property="serialNumber" />
        <result column="stationid" property="stationid" />
        <result column="stationname" property="stationname" />
        <result column="car_number" property="carNumber" />
        <result column="vin_number" property="vinNumber" />
        <result column="pound_type" property="poundType" />
        <result column="consigner" property="consigner" />
        <result column="consignee" property="consignee" />
        <result column="variety" property="variety" />
        <result column="specification" property="specification" />
        <result column="gross_weight" property="grossWeight" />
        <result column="tare_weight" property="tareWeight" />
        <result column="net_weight" property="netWeight" />
        <result column="deduction_weight" property="deductionWeight" />
        <result column="actual_weight" property="actualWeight" />
        <result column="price" property="price" />
        <result column="money" property="money" />
        <result column="coefficient" property="coefficient" />
        <result column="capacity" property="capacity" />
        <result column="weighing_charges" property="weighingCharges" />
        <result column="gross_weighman" property="grossWeighman" />
        <result column="tare_weighman" property="tareWeighman" />
        <result column="gross_pound_number" property="grossPoundNumber" />
        <result column="tare_pound_number" property="tarePoundNumber" />
        <result column="gross_weight_time" property="grossWeightTime" />
        <result column="tare_weight_time" property="tareWeightTime" />
        <result column="first_weighing_time" property="firstWeighingTime" />
        <result column="second_weighing_time" property="secondWeighingTime" />
        <result column="weighing_time" property="weighingTime" />
        <result column="update_user" property="updateUser" />
        <result column="update_time" property="updateTime" />
        <result column="remarks" property="remarks" />
        <result column="times_of_prints" property="timesOfPrints" />
        <result column="is_upload" property="isUpload" />
        <result column="is_upload2" property="isUpload2" />
        <result column="is_upload3" property="isUpload3" />
        <result column="is_upload_cloud" property="isUploadCloud" />
        <result column="data_status" property="dataStatus" />
        <result column="memo1" property="memo1" />
        <result column="memo2" property="memo2" />
        <result column="memo3" property="memo3" />
        <result column="memo4" property="memo4" />
        <result column="memo5" property="memo5" />
        <result column="memo6" property="memo6" />
        <result column="memo7" property="memo7" />
        <result column="memo8" property="memo8" />
        <result column="memo9" property="memo9" />
        <result column="memo10" property="memo10" />
        <result column="memo11" property="memo11" />
        <result column="memo12" property="memo12" />
        <result column="memo13" property="memo13" />
        <result column="memo14" property="memo14" />
        <result column="memo15" property="memo15" />
        <result column="memo16" property="memo16" />
        <result column="memo17" property="memo17" />
        <result column="memo18" property="memo18" />
        <result column="memo19" property="memo19" />
        <result column="memo20" property="memo20" />
        <result column="memo21" property="memo21" />
        <result column="weighing_type" property="weighingType" />
        <result column="uploadKdState" property="uploadKdState" />
        <result column="uploadKdState2" property="uploadKdState2" />
        <result column="uploadKdState3" property="uploadKdState3" />
        <result column="upload_time" property="uploadTime" />
    </resultMap>
    <select id="dayWeight" resultType="com.huimv.produce.produce.entity.dto.WeightInformationVo">


    SELECT DATE_FORMAT(weighing_time,'%m/%d') days,COUNT(*) counts ,SUM(actual_weight) weight FROM `weight_information`
        ${ew.customSqlSegment}
    GROUP BY days ;
    </select>

</mapper>
