Commit c81c9f7f by zhouhaibao

fix(store): 解决门店数据导入验证逻辑问题

- 注释掉渗透率必填项验证逻辑
- 注释掉转化率必填项验证逻辑
- 注释掉单车采购产值必填项验证逻辑
- 注释掉门店单台利润额必填项验证逻辑
- 保留数值范围验证逻辑以确保数据准确性
1 parent c332032c
...@@ -410,7 +410,7 @@ public class StoreExcelImportService { ...@@ -410,7 +410,7 @@ public class StoreExcelImportService {
// 兜底要求 - 必填项 // 兜底要求 - 必填项
if (productDetail.getPenetrationRate() == null) { if (productDetail.getPenetrationRate() == null) {
errors.add(new ImportErrorInfo(rowNum, "必填项缺失:渗透率", dto)); /*errors.add(new ImportErrorInfo(rowNum, "必填项缺失:渗透率", dto));*/
}else{ }else{
if (productDetail.getPenetrationRate().compareTo(new BigDecimal(0)) < 0 || if (productDetail.getPenetrationRate().compareTo(new BigDecimal(0)) < 0 ||
productDetail.getPenetrationRate().compareTo(new BigDecimal(100)) > 0) { productDetail.getPenetrationRate().compareTo(new BigDecimal(100)) > 0) {
...@@ -418,7 +418,7 @@ public class StoreExcelImportService { ...@@ -418,7 +418,7 @@ public class StoreExcelImportService {
} }
} }
if (productDetail.getConversionRate() == null) { if (productDetail.getConversionRate() == null) {
errors.add(new ImportErrorInfo(rowNum, "必填项缺失:转化率", dto)); /* errors.add(new ImportErrorInfo(rowNum, "必填项缺失:转化率", dto));*/
}else{ }else{
if (productDetail.getConversionRate().compareTo(new BigDecimal(0)) < 0 || if (productDetail.getConversionRate().compareTo(new BigDecimal(0)) < 0 ||
productDetail.getConversionRate().compareTo(new BigDecimal(100)) > 0) { productDetail.getConversionRate().compareTo(new BigDecimal(100)) > 0) {
...@@ -426,7 +426,7 @@ public class StoreExcelImportService { ...@@ -426,7 +426,7 @@ public class StoreExcelImportService {
} }
} }
if (productDetail.getRevenuePerCar() == null) { if (productDetail.getRevenuePerCar() == null) {
errors.add(new ImportErrorInfo(rowNum, "必填项缺失:单车采购产值", dto)); /*errors.add(new ImportErrorInfo(rowNum, "必填项缺失:单车采购产值", dto));*/
}else{ }else{
if (productDetail.getRevenuePerCar().compareTo(new BigDecimal(0)) < 0 || productDetail.getRevenuePerCar().compareTo(new BigDecimal(999999)) > 0) { if (productDetail.getRevenuePerCar().compareTo(new BigDecimal(0)) < 0 || productDetail.getRevenuePerCar().compareTo(new BigDecimal(999999)) > 0) {
errors.add(new ImportErrorInfo(rowNum, "单车采购产值超出范围", dto)); errors.add(new ImportErrorInfo(rowNum, "单车采购产值超出范围", dto));
...@@ -568,7 +568,7 @@ public class StoreExcelImportService { ...@@ -568,7 +568,7 @@ public class StoreExcelImportService {
} }
} }
if (dto.getStoreProfitPerCar() == null) { if (dto.getStoreProfitPerCar() == null) {
errors.add(new ImportErrorInfo(rowNum, "必填项缺失:门店单台利润额", dto)); /* errors.add(new ImportErrorInfo(rowNum, "必填项缺失:门店单台利润额", dto));*/
}else{ }else{
if (dto.getOtherCost().compareTo(new BigDecimal(0)) < 0 || if (dto.getOtherCost().compareTo(new BigDecimal(0)) < 0 ||
dto.getOtherCost().compareTo(new BigDecimal(999999)) > 0) { dto.getOtherCost().compareTo(new BigDecimal(999999)) > 0) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!