fix(buildpackage): 修复公司代码过滤逻辑
- 在多个插件中,将公司代码过滤条件改为使用 trim() 方法去除前后空格 - 涉及到的插件包括: - ConsignmachiningIn - ProxyPurchaseReturn - ProxyPurchaseWarehousOrder - ProxyPurchaseWarehousWarehouse - SoSaleOutPluginInitializerToB - SoSaleOutPluginInitializerToC - SoSaleReturnPluginInitializerToB - SoSaleReturnPluginInitializerToC - 通过使用 trim() 方法,确保公司代码比较时不会因为前后空格导致不匹配问题
This commit is contained in:
parent
4ffb40feb6
commit
db32f85f31
|
@ -231,7 +231,7 @@ public class ConsignmachiningIn extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -289,7 +289,7 @@ public class ConsignmachiningIn extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -230,7 +230,7 @@ public class ProxyPurchaseReturn extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -287,7 +287,7 @@ public class ProxyPurchaseReturn extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -229,7 +229,7 @@ public class ProxyPurchaseWarehousOrder extends PluginBaseEntity {
|
|||
public boolean test(OfsPoOrderData headerDetailsDto) {
|
||||
OfsPoOrderHeader header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -286,7 +286,7 @@ public class ProxyPurchaseWarehousOrder extends PluginBaseEntity {
|
|||
public boolean test(OfsPoOrderData headerDetailsDto) {
|
||||
OfsPoOrderHeader header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -227,7 +227,7 @@ public class ProxyPurchaseWarehousWarehouse extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -284,7 +284,7 @@ public class ProxyPurchaseWarehousWarehouse extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -278,7 +278,7 @@ public class SoSaleOutPluginInitializerToB extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -336,7 +336,7 @@ public class SoSaleOutPluginInitializerToB extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -390,7 +390,7 @@ public class SoSaleOutPluginInitializerToB extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -251,7 +251,7 @@ public class SoSaleOutPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (header.getCompanyCode().contains(ProfilesActiveConstant.FILTER_COMPANY)) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -311,7 +311,7 @@ public class SoSaleOutPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -365,7 +365,7 @@ public class SoSaleOutPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -430,7 +430,7 @@ public class SoSaleOutPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(HeaderDetailsDto headerDetailsDto) {
|
||||
HeaderDto header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -278,7 +278,7 @@ public class SoSaleReturnPluginInitializerToB extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -338,7 +338,7 @@ public class SoSaleReturnPluginInitializerToB extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -396,7 +396,7 @@ public class SoSaleReturnPluginInitializerToB extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -238,7 +238,7 @@ public class SoSaleReturnPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -292,7 +292,7 @@ public class SoSaleReturnPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -350,7 +350,7 @@ public class SoSaleReturnPluginInitializerToC extends PluginBaseEntity {
|
|||
public boolean test(StockinOrderSearchResponse.StockinOrder headerDetailsDto) {
|
||||
StockinOrderSearchResponse.StockinOrder.StockinH header = headerDetailsDto.getHeader();
|
||||
if (header != null && header.getCompanyCode() != null) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode())) {
|
||||
if (ProfilesActiveConstant.FILTER_COMPANY.contains(header.getCompanyCode().trim())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -110,7 +110,7 @@ class SoSaleOutPluginInitializerToCTest {
|
|||
// soSaleOutPluginInitializerToC.startImplementStockByCode(aaa, "tran");
|
||||
|
||||
// String aaa = "LETS-SH2024102800021196";
|
||||
soSaleOutPluginInitializerToC.startImplementStockByTime("2024-12-06 09:25:39", "2024-12-06 09:25:39");
|
||||
// soSaleOutPluginInitializerToC.startImplementStockByTime("2024-12-06 09:25:39", "2024-12-06 09:25:39");
|
||||
|
||||
// soSaleOutPluginInitializerToC.startImplementStockByTime("2024-11-15 00:00:00", "2024-11-15 23:59:59");
|
||||
} catch (Exception e) {
|
||||
|
@ -120,7 +120,7 @@ class SoSaleOutPluginInitializerToCTest {
|
|||
// soSaleOutPluginInitializerToC.sendU8CTOCOrder("123446");
|
||||
|
||||
try {
|
||||
// soSaleOutPluginInitializerToC.startImplementStockByCode("LETS-SH2024120500018494", "stock");
|
||||
soSaleOutPluginInitializerToC.startImplementStockByCode("LETS-SH2024113000012787", "stock");
|
||||
// soSaleOutPluginInitializerToC.startImplementStockByCode("LETS-SH2024110500013375", "tran");
|
||||
|
||||
// soSaleOutPluginInitializerToC.startImplementStockByCode("LETS-SH2024111700013756", "tran");
|
||||
|
|
Loading…
Reference in New Issue