部分Long类型相等判断修复

20230922-ljl-fixBug
wangchaoxu 1 year ago
parent 5323fbba28
commit e09d081fdc

@ -227,7 +227,7 @@ public class CategoryServiceImpl implements CategoryService{
DataItem category = shopAllCategoryMap.get(existCategoryInfo.getCategoryId());
Integer hasChildren = (ObjectUtil.isNotNull(category.getIsLeaf()) && category.getIsLeaf() ? 0 : 1);
if (category.getName().equals(existCategoryInfo.getCategoryName())
&& category.getParentId() == Long.valueOf(existCategoryInfo.getParentCategoryId())
&& category.getParentId() != null && category.getParentId().longValue() == Long.valueOf(existCategoryInfo.getParentCategoryId())
&& category.getLevel() == existCategoryInfo.getLevel()
&& hasChildren == existCategoryInfo.getHasChildren()) {
continue;

@ -150,7 +150,7 @@ public class DsOrderTool {
manualRelateSkuInfo = skuInfo;
break;
}
if (skuInfo.getSourceSkuId() == sourceItemId && StringUtils.isEmpty(manualRelateSourceSkuId)) {
if (sourceItemId != null && skuInfo.getSourceSkuId() == sourceItemId.longValue() && StringUtils.isEmpty(manualRelateSourceSkuId)) {
matchSkuInfo = skuInfo;
break;
}
@ -170,8 +170,8 @@ public class DsOrderTool {
int purchaseQuantity = platformItemTotal;
GetPurchaseOrderItemsAndSourceItemsResponseDTO.SourceItemSkuRelation manualSourceSkuInfo = platformSkuIdAndSourceSkuInfoMap.get(platformSkuId);
boolean isSourceItemNoSkuFlag = (matchSourceSkuInfo.getSourceItemId() == matchSourceSkuInfo.getSourceSkuId());
if (manualSourceSkuInfo != null && ((manualSourceSkuInfo.getSourceSkuId() == matchSourceSkuInfo.getSourceSkuId()) || (isSourceItemNoSkuFlag && (matchSourceSkuInfo.getSourceItemId() == manualSourceSkuInfo.getSourceItemId())))) {
boolean isSourceItemNoSkuFlag = (matchSourceSkuInfo.getSourceItemId().equals(matchSourceSkuInfo.getSourceSkuId()));
if (manualSourceSkuInfo != null && ((manualSourceSkuInfo.getSourceSkuId().equals(matchSourceSkuInfo.getSourceSkuId())) || (isSourceItemNoSkuFlag && (matchSourceSkuInfo.getSourceItemId().equals(manualSourceSkuInfo.getSourceItemId()))))) {
purchaseQuantity = (manualSourceSkuInfo.getSourceNum() != null && manualSourceSkuInfo.getSourceNum() != 0) ? (platformItemTotal * manualSourceSkuInfo.getSourceNum()) : platformItemTotal;
}

Loading…
Cancel
Save