diff --git a/src/main/java/com/xujie/modules/srm/entity/SrmSupplier.java b/src/main/java/com/xujie/modules/srm/entity/SrmSupplier.java index a7216c6..0331c4b 100644 --- a/src/main/java/com/xujie/modules/srm/entity/SrmSupplier.java +++ b/src/main/java/com/xujie/modules/srm/entity/SrmSupplier.java @@ -157,4 +157,9 @@ public class SrmSupplier extends QueryPage { * 生产 Lead Time(srm_supplier.production_lead_time),由 Lead Time 维护页单独编辑。 */ private Integer productionLeadTime; + + /** + * 默认始发港(srm_supplier.default_origin_port),非必填。 + */ + private String defaultOriginPort; } diff --git a/src/main/java/com/xujie/modules/srm/mapper/SrmSupplierMapper.java b/src/main/java/com/xujie/modules/srm/mapper/SrmSupplierMapper.java index 7dfa59d..6212cbb 100644 --- a/src/main/java/com/xujie/modules/srm/mapper/SrmSupplierMapper.java +++ b/src/main/java/com/xujie/modules/srm/mapper/SrmSupplierMapper.java @@ -50,11 +50,12 @@ public interface SrmSupplierMapper extends BaseMapper { void updateSrmSupplier(SrmSupplier supplier); /** - * Lead Time 维护页专用:按 site + supplierNo 单独更新 production_lead_time(允许 null 清空)。 + * Lead Time 维护页专用:按 site + supplierNo 单独更新 production_lead_time 与 default_origin_port(均允许 null 清空)。 */ int updateProductionLeadTime(@Param("site") String site, @Param("supplierNo") String supplierNo, @Param("productionLeadTime") Integer productionLeadTime, + @Param("defaultOriginPort") String defaultOriginPort, @Param("updateBy") String updateBy); SrmSupplier selectSrmSupplierById(@Param("id") Integer id); diff --git a/src/main/java/com/xujie/modules/srm/service/impl/SrmSupplierServiceImpl.java b/src/main/java/com/xujie/modules/srm/service/impl/SrmSupplierServiceImpl.java index 0d5ef8e..ec020b1 100644 --- a/src/main/java/com/xujie/modules/srm/service/impl/SrmSupplierServiceImpl.java +++ b/src/main/java/com/xujie/modules/srm/service/impl/SrmSupplierServiceImpl.java @@ -360,12 +360,21 @@ public class SrmSupplierServiceImpl extends ServiceImpl @@ -59,7 +59,8 @@ s.min_ship_account AS minShipAccount, s.handling_charge as handlingCharge, - s.production_lead_time AS productionLeadTime + s.production_lead_time AS productionLeadTime, + s.default_origin_port AS defaultOriginPort FROM srm_supplier s LEFT JOIN sys_dict_data sg ON sg.dict_value = s.supplier_group AND sg.dict_type='supplier_group' @@ -395,7 +396,7 @@ Other_contact1, Other_contact2, Other_contact3, - Memo,c_short_office,c_short_npc,planner,min_ship_account,handling_charge + Memo,c_short_office,c_short_npc,planner,min_ship_account,handling_charge,default_origin_port ) VALUES ( #{site}, #{supplierNo}, @@ -430,7 +431,7 @@ #{otherContact1}, #{otherContact2}, #{otherContact3}, - #{memo},#{cShortOffice},#{cShortNpc},#{planner},#{minShipAccount},#{handlingCharge} + #{memo},#{cShortOffice},#{cShortNpc},#{planner},#{minShipAccount},#{handlingCharge},#{defaultOriginPort} ) @@ -441,7 +442,8 @@ phoneNo = #{phoneNo},phoneNo2 = #{phoneNo2},phoneNo3 = #{phoneNo3},email = #{email}, email2 = #{email2},faxNo = #{faxNo},Other_contact1 = #{otherContact1},Other_contact2 = #{otherContact2}, Other_contact3 = #{otherContact3},bankName= #{bankName},bankAccount = #{bankAccount}, address = #{address},memo = #{memo},c_short_office=#{cShortOffice},c_short_npc=#{cShortNpc},planner=#{planner}, min_ship_account = #{minShipAccount}, - handling_charge = #{handlingCharge} + handling_charge = #{handlingCharge}, + default_origin_port = #{defaultOriginPort} WHERE id = #{id} @@ -451,6 +453,7 @@ UPDATE srm_supplier SET production_lead_time = #{productionLeadTime,jdbcType=INTEGER}, + default_origin_port = #{defaultOriginPort,jdbcType=VARCHAR}, update_date = GETDATE(), update_by = #{updateBy} WHERE site = #{site}