tao.mo

kafka-cndc-server | 修改 | kafka501消息处理

mt
2024年11月1日18:21:05
......@@ -20,7 +20,7 @@
<result column="CUSTOMS_CURRENCY" jdbcType="VARCHAR" property="customsCurrency" />
<result column="CUSTOMS_VALUE" jdbcType="NUMERIC" property="customsValue" />
<result column="WEIGHT" jdbcType="NUMERIC" property="weight" />
<result column="WEIGHTUNIT" jdbcType="NUMERIC" property="weightunit" />
<result column="WEIGHTUNIT" jdbcType="VARCHAR" property="weightunit" />
<result column="SCANDATE" jdbcType="TIMESTAMP" property="scandate" />
<result column="SHIPPER_CONTACT_NAME" jdbcType="VARCHAR" property="shipperContactName" />
<result column="SHIPPER_PHONE" jdbcType="VARCHAR" property="shipperPhone" />
......@@ -160,7 +160,7 @@
#{createUserName,jdbcType=VARCHAR}, #{modifyTime,jdbcType=TIMESTAMP}, #{modifyUserId,jdbcType=NUMERIC},
#{modifyUserName,jdbcType=VARCHAR}, #{originCountry,jdbcType=VARCHAR}, #{destinationCountry,jdbcType=VARCHAR},
#{customsCurrency,jdbcType=VARCHAR}, #{customsValue,jdbcType=NUMERIC}, #{weight,jdbcType=NUMERIC},
#{weightunit,jdbcType=NUMERIC}, #{scandate,jdbcType=TIMESTAMP}, #{shipperContactName,jdbcType=VARCHAR},
#{weightunit,jdbcType=VARCHAR}, #{scandate,jdbcType=TIMESTAMP}, #{shipperContactName,jdbcType=VARCHAR},
#{shipperPhone,jdbcType=VARCHAR}, #{shipperAccount,jdbcType=VARCHAR}, #{shipperCompany,jdbcType=VARCHAR},
#{shipperAddrLine1,jdbcType=VARCHAR}, #{shipperAddrLine2,jdbcType=VARCHAR}, #{shipperCity,jdbcType=VARCHAR},
#{shipperEmail,jdbcType=VARCHAR}, #{recipientContactName,jdbcType=VARCHAR}, #{recipientPhone,jdbcType=VARCHAR},
......@@ -331,7 +331,7 @@
#{weight,jdbcType=NUMERIC},
</if>
<if test="weightunit != null">
#{weightunit,jdbcType=NUMERIC},
#{weightunit,jdbcType=VARCHAR},
</if>
<if test="scandate != null">
#{scandate,jdbcType=TIMESTAMP},
......@@ -447,7 +447,7 @@
WEIGHT = #{record.weight,jdbcType=NUMERIC},
</if>
<if test="record.weightunit != null">
WEIGHTUNIT = #{record.weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{record.weightunit,jdbcType=VARCHAR},
</if>
<if test="record.scandate != null">
SCANDATE = #{record.scandate,jdbcType=TIMESTAMP},
......@@ -522,7 +522,7 @@
CUSTOMS_CURRENCY = #{record.customsCurrency,jdbcType=VARCHAR},
CUSTOMS_VALUE = #{record.customsValue,jdbcType=NUMERIC},
WEIGHT = #{record.weight,jdbcType=NUMERIC},
WEIGHTUNIT = #{record.weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{record.weightunit,jdbcType=VARCHAR},
SCANDATE = #{record.scandate,jdbcType=TIMESTAMP},
SHIPPER_CONTACT_NAME = #{record.shipperContactName,jdbcType=VARCHAR},
SHIPPER_PHONE = #{record.shipperPhone,jdbcType=VARCHAR},
......@@ -598,7 +598,7 @@
WEIGHT = #{weight,jdbcType=NUMERIC},
</if>
<if test="weightunit != null">
WEIGHTUNIT = #{weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{weightunit,jdbcType=VARCHAR},
</if>
<if test="scandate != null">
SCANDATE = #{scandate,jdbcType=TIMESTAMP},
......@@ -670,7 +670,7 @@
CUSTOMS_CURRENCY = #{customsCurrency,jdbcType=VARCHAR},
CUSTOMS_VALUE = #{customsValue,jdbcType=NUMERIC},
WEIGHT = #{weight,jdbcType=NUMERIC},
WEIGHTUNIT = #{weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{weightunit,jdbcType=VARCHAR},
SCANDATE = #{scandate,jdbcType=TIMESTAMP},
SHIPPER_CONTACT_NAME = #{shipperContactName,jdbcType=VARCHAR},
SHIPPER_PHONE = #{shipperPhone,jdbcType=VARCHAR},
......
......@@ -13,7 +13,7 @@
<result column="CUSTOMS_CURRENCY" jdbcType="VARCHAR" property="customsCurrency" />
<result column="CUSTOMS_VALUE" jdbcType="NUMERIC" property="customsValue" />
<result column="WEIGHT" jdbcType="NUMERIC" property="weight" />
<result column="WEIGHTUNIT" jdbcType="NUMERIC" property="weightunit" />
<result column="WEIGHTUNIT" jdbcType="VARCHAR" property="weightunit" />
<result column="SCANDATE" jdbcType="TIMESTAMP" property="scandate" />
<result column="SHIPPER_CONTACT_NAME" jdbcType="VARCHAR" property="shipperContactName" />
<result column="SHIPPER_PHONE" jdbcType="VARCHAR" property="shipperPhone" />
......@@ -167,7 +167,7 @@
values (#{id,jdbcType=NUMERIC}, #{consignmentCode,jdbcType=VARCHAR}, #{shipDate,jdbcType=TIMESTAMP},
#{shipperCountry,jdbcType=VARCHAR}, #{recipientCountry,jdbcType=VARCHAR}, #{destIataCode,jdbcType=VARCHAR},
#{originCountry,jdbcType=VARCHAR}, #{destinationCountry,jdbcType=VARCHAR}, #{customsCurrency,jdbcType=VARCHAR},
#{customsValue,jdbcType=NUMERIC}, #{weight,jdbcType=NUMERIC}, #{weightunit,jdbcType=NUMERIC},
#{customsValue,jdbcType=NUMERIC}, #{weight,jdbcType=NUMERIC}, #{weightunit,jdbcType=VARCHAR},
#{scandate,jdbcType=TIMESTAMP}, #{shipperContactName,jdbcType=VARCHAR}, #{shipperPhone,jdbcType=VARCHAR},
#{shipperAccount,jdbcType=VARCHAR}, #{shipperCompany,jdbcType=VARCHAR}, #{shipperAddrLine1,jdbcType=VARCHAR},
#{shipperAddrLine2,jdbcType=VARCHAR}, #{shipperCity,jdbcType=VARCHAR}, #{shipperEmail,jdbcType=VARCHAR},
......@@ -341,7 +341,7 @@
#{weight,jdbcType=NUMERIC},
</if>
<if test="weightunit != null">
#{weightunit,jdbcType=NUMERIC},
#{weightunit,jdbcType=VARCHAR},
</if>
<if test="scandate != null">
#{scandate,jdbcType=TIMESTAMP},
......@@ -475,7 +475,7 @@
WEIGHT = #{record.weight,jdbcType=NUMERIC},
</if>
<if test="record.weightunit != null">
WEIGHTUNIT = #{record.weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{record.weightunit,jdbcType=VARCHAR},
</if>
<if test="record.scandate != null">
SCANDATE = #{record.scandate,jdbcType=TIMESTAMP},
......@@ -582,7 +582,7 @@
CUSTOMS_CURRENCY = #{record.customsCurrency,jdbcType=VARCHAR},
CUSTOMS_VALUE = #{record.customsValue,jdbcType=NUMERIC},
WEIGHT = #{record.weight,jdbcType=NUMERIC},
WEIGHTUNIT = #{record.weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{record.weightunit,jdbcType=VARCHAR},
SCANDATE = #{record.scandate,jdbcType=TIMESTAMP},
SHIPPER_CONTACT_NAME = #{record.shipperContactName,jdbcType=VARCHAR},
SHIPPER_PHONE = #{record.shipperPhone,jdbcType=VARCHAR},
......@@ -650,7 +650,7 @@
WEIGHT = #{weight,jdbcType=NUMERIC},
</if>
<if test="weightunit != null">
WEIGHTUNIT = #{weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{weightunit,jdbcType=VARCHAR},
</if>
<if test="scandate != null">
SCANDATE = #{scandate,jdbcType=TIMESTAMP},
......@@ -754,7 +754,7 @@
CUSTOMS_CURRENCY = #{customsCurrency,jdbcType=VARCHAR},
CUSTOMS_VALUE = #{customsValue,jdbcType=NUMERIC},
WEIGHT = #{weight,jdbcType=NUMERIC},
WEIGHTUNIT = #{weightunit,jdbcType=NUMERIC},
WEIGHTUNIT = #{weightunit,jdbcType=VARCHAR},
SCANDATE = #{scandate,jdbcType=TIMESTAMP},
SHIPPER_CONTACT_NAME = #{shipperContactName,jdbcType=VARCHAR},
SHIPPER_PHONE = #{shipperPhone,jdbcType=VARCHAR},
......
package com.fedex.connect.common.model.biz;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
/**
......@@ -91,17 +92,17 @@ public class CeInfo implements Serializable {
/**
* 申报价格
*/
private Long customsValue;
private BigDecimal customsValue;
/**
* 重量
*/
private Long weight;
private BigDecimal weight;
/**
* 重量单位
*/
private Long weightunit;
private String weightunit;
/**
* 扫描状态日期
......@@ -313,28 +314,28 @@ public class CeInfo implements Serializable {
this.customsCurrency = customsCurrency == null ? null : customsCurrency.trim();
}
public Long getCustomsValue() {
public BigDecimal getCustomsValue() {
return customsValue;
}
public void setCustomsValue(Long customsValue) {
public void setCustomsValue(BigDecimal customsValue) {
this.customsValue = customsValue;
}
public Long getWeight() {
public BigDecimal getWeight() {
return weight;
}
public void setWeight(Long weight) {
public void setWeight(BigDecimal weight) {
this.weight = weight;
}
public Long getWeightunit() {
public String getWeightunit() {
return weightunit;
}
public void setWeightunit(Long weightunit) {
this.weightunit = weightunit;
public void setWeightunit(String weightunit) {
this.weightunit = weightunit == null ? null : weightunit.trim();
}
public Date getScandate() {
......
package com.fedex.connect.common.model.biz;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
......@@ -1185,52 +1186,52 @@ public class CeInfoExample {
return (Criteria) this;
}
public Criteria andCustomsValueEqualTo(Long value) {
public Criteria andCustomsValueEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE =", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueNotEqualTo(Long value) {
public Criteria andCustomsValueNotEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE <>", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueGreaterThan(Long value) {
public Criteria andCustomsValueGreaterThan(BigDecimal value) {
addCriterion("CUSTOMS_VALUE >", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueGreaterThanOrEqualTo(Long value) {
public Criteria andCustomsValueGreaterThanOrEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE >=", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueLessThan(Long value) {
public Criteria andCustomsValueLessThan(BigDecimal value) {
addCriterion("CUSTOMS_VALUE <", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueLessThanOrEqualTo(Long value) {
public Criteria andCustomsValueLessThanOrEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE <=", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueIn(List<Long> values) {
public Criteria andCustomsValueIn(List<BigDecimal> values) {
addCriterion("CUSTOMS_VALUE in", values, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueNotIn(List<Long> values) {
public Criteria andCustomsValueNotIn(List<BigDecimal> values) {
addCriterion("CUSTOMS_VALUE not in", values, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueBetween(Long value1, Long value2) {
public Criteria andCustomsValueBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("CUSTOMS_VALUE between", value1, value2, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueNotBetween(Long value1, Long value2) {
public Criteria andCustomsValueNotBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("CUSTOMS_VALUE not between", value1, value2, "customsValue");
return (Criteria) this;
}
......@@ -1245,52 +1246,52 @@ public class CeInfoExample {
return (Criteria) this;
}
public Criteria andWeightEqualTo(Long value) {
public Criteria andWeightEqualTo(BigDecimal value) {
addCriterion("WEIGHT =", value, "weight");
return (Criteria) this;
}
public Criteria andWeightNotEqualTo(Long value) {
public Criteria andWeightNotEqualTo(BigDecimal value) {
addCriterion("WEIGHT <>", value, "weight");
return (Criteria) this;
}
public Criteria andWeightGreaterThan(Long value) {
public Criteria andWeightGreaterThan(BigDecimal value) {
addCriterion("WEIGHT >", value, "weight");
return (Criteria) this;
}
public Criteria andWeightGreaterThanOrEqualTo(Long value) {
public Criteria andWeightGreaterThanOrEqualTo(BigDecimal value) {
addCriterion("WEIGHT >=", value, "weight");
return (Criteria) this;
}
public Criteria andWeightLessThan(Long value) {
public Criteria andWeightLessThan(BigDecimal value) {
addCriterion("WEIGHT <", value, "weight");
return (Criteria) this;
}
public Criteria andWeightLessThanOrEqualTo(Long value) {
public Criteria andWeightLessThanOrEqualTo(BigDecimal value) {
addCriterion("WEIGHT <=", value, "weight");
return (Criteria) this;
}
public Criteria andWeightIn(List<Long> values) {
public Criteria andWeightIn(List<BigDecimal> values) {
addCriterion("WEIGHT in", values, "weight");
return (Criteria) this;
}
public Criteria andWeightNotIn(List<Long> values) {
public Criteria andWeightNotIn(List<BigDecimal> values) {
addCriterion("WEIGHT not in", values, "weight");
return (Criteria) this;
}
public Criteria andWeightBetween(Long value1, Long value2) {
public Criteria andWeightBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("WEIGHT between", value1, value2, "weight");
return (Criteria) this;
}
public Criteria andWeightNotBetween(Long value1, Long value2) {
public Criteria andWeightNotBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("WEIGHT not between", value1, value2, "weight");
return (Criteria) this;
}
......@@ -1305,52 +1306,62 @@ public class CeInfoExample {
return (Criteria) this;
}
public Criteria andWeightunitEqualTo(Long value) {
public Criteria andWeightunitEqualTo(String value) {
addCriterion("WEIGHTUNIT =", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotEqualTo(Long value) {
public Criteria andWeightunitNotEqualTo(String value) {
addCriterion("WEIGHTUNIT <>", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitGreaterThan(Long value) {
public Criteria andWeightunitGreaterThan(String value) {
addCriterion("WEIGHTUNIT >", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitGreaterThanOrEqualTo(Long value) {
public Criteria andWeightunitGreaterThanOrEqualTo(String value) {
addCriterion("WEIGHTUNIT >=", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitLessThan(Long value) {
public Criteria andWeightunitLessThan(String value) {
addCriterion("WEIGHTUNIT <", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitLessThanOrEqualTo(Long value) {
public Criteria andWeightunitLessThanOrEqualTo(String value) {
addCriterion("WEIGHTUNIT <=", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitIn(List<Long> values) {
public Criteria andWeightunitLike(String value) {
addCriterion("WEIGHTUNIT like", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotLike(String value) {
addCriterion("WEIGHTUNIT not like", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitIn(List<String> values) {
addCriterion("WEIGHTUNIT in", values, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotIn(List<Long> values) {
public Criteria andWeightunitNotIn(List<String> values) {
addCriterion("WEIGHTUNIT not in", values, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitBetween(Long value1, Long value2) {
public Criteria andWeightunitBetween(String value1, String value2) {
addCriterion("WEIGHTUNIT between", value1, value2, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotBetween(Long value1, Long value2) {
public Criteria andWeightunitNotBetween(String value1, String value2) {
addCriterion("WEIGHTUNIT not between", value1, value2, "weightunit");
return (Criteria) this;
}
......
package com.fedex.connect.common.model.biz;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
/**
......@@ -56,17 +57,17 @@ public class Consignment implements Serializable {
/**
* 申报价格
*/
private Long customsValue;
private BigDecimal customsValue;
/**
* 重量
*/
private Long weight;
private BigDecimal weight;
/**
* 重量单位
*/
private Long weightunit;
private String weightunit;
/**
* 扫描状态日期
......@@ -287,28 +288,28 @@ public class Consignment implements Serializable {
this.customsCurrency = customsCurrency == null ? null : customsCurrency.trim();
}
public Long getCustomsValue() {
public BigDecimal getCustomsValue() {
return customsValue;
}
public void setCustomsValue(Long customsValue) {
public void setCustomsValue(BigDecimal customsValue) {
this.customsValue = customsValue;
}
public Long getWeight() {
public BigDecimal getWeight() {
return weight;
}
public void setWeight(Long weight) {
public void setWeight(BigDecimal weight) {
this.weight = weight;
}
public Long getWeightunit() {
public String getWeightunit() {
return weightunit;
}
public void setWeightunit(Long weightunit) {
this.weightunit = weightunit;
public void setWeightunit(String weightunit) {
this.weightunit = weightunit == null ? null : weightunit.trim();
}
public Date getScandate() {
......
package com.fedex.connect.common.model.biz;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
......@@ -745,52 +746,52 @@ public class ConsignmentExample {
return (Criteria) this;
}
public Criteria andCustomsValueEqualTo(Long value) {
public Criteria andCustomsValueEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE =", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueNotEqualTo(Long value) {
public Criteria andCustomsValueNotEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE <>", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueGreaterThan(Long value) {
public Criteria andCustomsValueGreaterThan(BigDecimal value) {
addCriterion("CUSTOMS_VALUE >", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueGreaterThanOrEqualTo(Long value) {
public Criteria andCustomsValueGreaterThanOrEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE >=", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueLessThan(Long value) {
public Criteria andCustomsValueLessThan(BigDecimal value) {
addCriterion("CUSTOMS_VALUE <", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueLessThanOrEqualTo(Long value) {
public Criteria andCustomsValueLessThanOrEqualTo(BigDecimal value) {
addCriterion("CUSTOMS_VALUE <=", value, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueIn(List<Long> values) {
public Criteria andCustomsValueIn(List<BigDecimal> values) {
addCriterion("CUSTOMS_VALUE in", values, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueNotIn(List<Long> values) {
public Criteria andCustomsValueNotIn(List<BigDecimal> values) {
addCriterion("CUSTOMS_VALUE not in", values, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueBetween(Long value1, Long value2) {
public Criteria andCustomsValueBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("CUSTOMS_VALUE between", value1, value2, "customsValue");
return (Criteria) this;
}
public Criteria andCustomsValueNotBetween(Long value1, Long value2) {
public Criteria andCustomsValueNotBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("CUSTOMS_VALUE not between", value1, value2, "customsValue");
return (Criteria) this;
}
......@@ -805,52 +806,52 @@ public class ConsignmentExample {
return (Criteria) this;
}
public Criteria andWeightEqualTo(Long value) {
public Criteria andWeightEqualTo(BigDecimal value) {
addCriterion("WEIGHT =", value, "weight");
return (Criteria) this;
}
public Criteria andWeightNotEqualTo(Long value) {
public Criteria andWeightNotEqualTo(BigDecimal value) {
addCriterion("WEIGHT <>", value, "weight");
return (Criteria) this;
}
public Criteria andWeightGreaterThan(Long value) {
public Criteria andWeightGreaterThan(BigDecimal value) {
addCriterion("WEIGHT >", value, "weight");
return (Criteria) this;
}
public Criteria andWeightGreaterThanOrEqualTo(Long value) {
public Criteria andWeightGreaterThanOrEqualTo(BigDecimal value) {
addCriterion("WEIGHT >=", value, "weight");
return (Criteria) this;
}
public Criteria andWeightLessThan(Long value) {
public Criteria andWeightLessThan(BigDecimal value) {
addCriterion("WEIGHT <", value, "weight");
return (Criteria) this;
}
public Criteria andWeightLessThanOrEqualTo(Long value) {
public Criteria andWeightLessThanOrEqualTo(BigDecimal value) {
addCriterion("WEIGHT <=", value, "weight");
return (Criteria) this;
}
public Criteria andWeightIn(List<Long> values) {
public Criteria andWeightIn(List<BigDecimal> values) {
addCriterion("WEIGHT in", values, "weight");
return (Criteria) this;
}
public Criteria andWeightNotIn(List<Long> values) {
public Criteria andWeightNotIn(List<BigDecimal> values) {
addCriterion("WEIGHT not in", values, "weight");
return (Criteria) this;
}
public Criteria andWeightBetween(Long value1, Long value2) {
public Criteria andWeightBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("WEIGHT between", value1, value2, "weight");
return (Criteria) this;
}
public Criteria andWeightNotBetween(Long value1, Long value2) {
public Criteria andWeightNotBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("WEIGHT not between", value1, value2, "weight");
return (Criteria) this;
}
......@@ -865,52 +866,62 @@ public class ConsignmentExample {
return (Criteria) this;
}
public Criteria andWeightunitEqualTo(Long value) {
public Criteria andWeightunitEqualTo(String value) {
addCriterion("WEIGHTUNIT =", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotEqualTo(Long value) {
public Criteria andWeightunitNotEqualTo(String value) {
addCriterion("WEIGHTUNIT <>", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitGreaterThan(Long value) {
public Criteria andWeightunitGreaterThan(String value) {
addCriterion("WEIGHTUNIT >", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitGreaterThanOrEqualTo(Long value) {
public Criteria andWeightunitGreaterThanOrEqualTo(String value) {
addCriterion("WEIGHTUNIT >=", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitLessThan(Long value) {
public Criteria andWeightunitLessThan(String value) {
addCriterion("WEIGHTUNIT <", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitLessThanOrEqualTo(Long value) {
public Criteria andWeightunitLessThanOrEqualTo(String value) {
addCriterion("WEIGHTUNIT <=", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitIn(List<Long> values) {
public Criteria andWeightunitLike(String value) {
addCriterion("WEIGHTUNIT like", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotLike(String value) {
addCriterion("WEIGHTUNIT not like", value, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitIn(List<String> values) {
addCriterion("WEIGHTUNIT in", values, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotIn(List<Long> values) {
public Criteria andWeightunitNotIn(List<String> values) {
addCriterion("WEIGHTUNIT not in", values, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitBetween(Long value1, Long value2) {
public Criteria andWeightunitBetween(String value1, String value2) {
addCriterion("WEIGHTUNIT between", value1, value2, "weightunit");
return (Criteria) this;
}
public Criteria andWeightunitNotBetween(Long value1, Long value2) {
public Criteria andWeightunitNotBetween(String value1, String value2) {
addCriterion("WEIGHTUNIT not between", value1, value2, "weightunit");
return (Criteria) this;
}
......
package com.fedex.connect.common.dependencies.contants;
/**
* @Author mt
* @Description 类说明
* @Date 2024/11/1
*/
public interface BaseConstants {
//基础字段列名
interface BASE_TABLE_COLUMN_KEYS{
//创建时间
String CREATE_TIME = "createTime";
//创建人ID
String CREATE_USER_ID = "createUserId";
//创建人名称
String CREATE_USER_NAME = "createUserName";
//修改时间
String MODIFY_TIME = "modifyTime";
//修改人ID
String MODIFY_USER_ID = "modifyUserId";
//修改人名称
String MODIFY_USER_NAME = "modifyUserName";
}
}
\ No newline at end of file
package com.fedex.connect.common.dependencies.util;
import com.fedex.connect.common.dependencies.contants.BaseConstants;
import com.fedex.connect.common.dependencies.contants.SystemDefaultUserConstants;
import java.lang.reflect.Field;
import java.util.Date;
import java.util.Objects;
/**
* @Author mt
* @Description 分配字段
* @Date 2024/11/1
*/
public class AssignmentFieldUtils {
/**
* @Author mt
* @Description 初始化表基础字段,例如:create_time,update_time
* @Date 2024/11/1
* @param entity
* @return void
*/
public static void assignmentTableBaseField(Object entity) throws Exception{
Object createTime = getFieldValue(entity, BaseConstants.BASE_TABLE_COLUMN_KEYS.CREATE_TIME);
//创建时间
if(Objects.isNull(createTime)){
assignmentField(entity,BaseConstants.BASE_TABLE_COLUMN_KEYS.CREATE_TIME,new Date());
}
//创建人ID
Object createUserId = getFieldValue(entity, BaseConstants.BASE_TABLE_COLUMN_KEYS.CREATE_USER_ID);
if(Objects.isNull(createUserId)){
assignmentField(entity,BaseConstants.BASE_TABLE_COLUMN_KEYS.CREATE_USER_ID, SystemDefaultUserConstants.SYSTEM_USER_KEYS.ID);
}
//创建人名称
Object createUserName = getFieldValue(entity, BaseConstants.BASE_TABLE_COLUMN_KEYS.CREATE_USER_NAME);
if(Objects.isNull(createUserName)){
assignmentField(entity,BaseConstants.BASE_TABLE_COLUMN_KEYS.CREATE_USER_NAME,SystemDefaultUserConstants.SYSTEM_USER_KEYS.USER_NAME);
}
//修改时间
Object modifyTime = getFieldValue(entity, BaseConstants.BASE_TABLE_COLUMN_KEYS.MODIFY_TIME);
if(Objects.isNull(modifyTime)){
assignmentField(entity,BaseConstants.BASE_TABLE_COLUMN_KEYS.MODIFY_TIME,new Date());
}
//修改人ID
Object modifyUserId = getFieldValue(entity, BaseConstants.BASE_TABLE_COLUMN_KEYS.MODIFY_USER_ID);
if(Objects.isNull(modifyUserId)){
assignmentField(entity,BaseConstants.BASE_TABLE_COLUMN_KEYS.MODIFY_USER_ID,SystemDefaultUserConstants.SYSTEM_USER_KEYS.ID);
}
//修改人名称
Object modifyUserName = getFieldValue(entity, BaseConstants.BASE_TABLE_COLUMN_KEYS.MODIFY_USER_NAME);
if(Objects.isNull(modifyUserName)){
assignmentField(entity,BaseConstants.BASE_TABLE_COLUMN_KEYS.MODIFY_USER_NAME,SystemDefaultUserConstants.SYSTEM_USER_KEYS.USER_NAME);
}
}
/**
* @Author mt
* @Description 通过反射为字段赋值
* @Date 2024/7/26
* @param entity
* @param fieldName
* @param value
* @return void
*/
public static void assignmentField(Object entity, String fieldName, Object value) throws Exception{
Field field = entity.getClass().getDeclaredField(fieldName);
field.setAccessible(true);
field.set(entity,value);
}
/**
* @Author mt
* @Description 通过反射获取字段值
* @Date 2024/7/26
* @param entity
* @param fieldName
* @return void
*/
public static Object getFieldValue(Object entity, String fieldName) throws Exception{
Field field = entity.getClass().getDeclaredField(fieldName);
field.setAccessible(true);
Object value = field.get(entity);
return value;
}
}
\ No newline at end of file
package com.fedex.connect.common.dependencies.util;
public class TableColumnInitUtil {
}
package com.fedex.connect.kafka.util;
import com.fedex.connect.common.dependencies.contants.SystemDefaultUserConstants;
import com.fedex.connect.common.dependencies.util.AssignmentFieldUtils;
import com.fedex.connect.common.dependencies.util.DateUtil;
import com.fedex.connect.common.model.biz.CeInfo;
import com.fedex.connect.common.model.biz.Consignment;
......@@ -10,8 +10,10 @@ import com.fedex.connect.kafka.data.dto.dm.dm501.Dm501Consignments;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Component;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Objects;
@Component
public class Dm501Util {
......@@ -23,7 +25,7 @@ public class Dm501Util {
* @param dm501Consignment
* @return com.fedex.connect.common.model.biz.CeInfo
*/
public CeInfo generateCeInfo(Dm501Consignments dm501Consignment,Date sendTime){
public CeInfo generateCeInfo(Dm501Consignments dm501Consignment,Date sendTime) throws Exception{
CeInfo ceInfo = new CeInfo();
//地址信息
List<Dm501ConAddresses> addressList = dm501Consignment.getAddresses();
......@@ -50,7 +52,14 @@ public class Dm501Util {
* 报文主体处理
*/
this.generateCeInfoBody(ceInfo,dm501Consignment,sendTime);
/**
* 发件人信息处理
*/
this.generateCeInfoShipper();
/**
* 收件人信息处理
*/
this.generateCeInfoRecipient();
return ceInfo;
}
......@@ -61,7 +70,7 @@ public class Dm501Util {
* @param
* @return void
*/
private void generateCeInfoBody(CeInfo ceInfo,Dm501Consignments dm501Consignment,Date sendTime){
private void generateCeInfoBody(CeInfo ceInfo,Dm501Consignments dm501Consignment,Date sendTime) throws Exception{
ceInfo.setConsignmentCode(dm501Consignment.getTrackingNumber());
ceInfo.setDestIataCode(dm501Consignment.getDestIataCode());
//扫描状态日期
......@@ -73,9 +82,24 @@ public class Dm501Util {
if(StringUtils.isNotEmpty(shipDate)){
ceInfo.setShipDate(DateUtil.parse(shipDate));
}
ceInfo.setCreateTime(new Date());
ceInfo.setCreateUserId(SystemDefaultUserConstants.SYSTEM_USER_KEYS.ID);
// ceInfo.setCreateUserName();
//申报币制
ceInfo.setCustomsCurrency(dm501Consignment.getCustomsCurrency());
//申报价格
String customsValue = dm501Consignment.getCustomsValue();
if(Objects.nonNull(customsValue)){
ceInfo.setCustomsValue(new BigDecimal(customsValue));
}
//重量
String weight = dm501Consignment.getWeight();
if(Objects.nonNull(weight)){
ceInfo.setWeight(new BigDecimal(weight));
}
//重量单位
ceInfo.setWeightunit(dm501Consignment.getWeightUnit());
/**
* 初始化表基础字段
*/
AssignmentFieldUtils.assignmentTableBaseField(ceInfo);
}
/**
......