Commit 2bba3859 by zhiwj

修复bug

parent a2ed0a42
......@@ -180,7 +180,7 @@ public interface StoreImportApiService {
* @return com.gic.api.base.commons.ServiceResponse<java.lang.Boolean>
* @throws
*/
ServiceResponse<Boolean> validateStoreName(Integer enterpriseId, String storeName);
ServiceResponse<Boolean> validateStoreName(Integer enterpriseId, Integer regionId, String storeName);
/**
* @Title: getStoreBatchProcess
......
......@@ -12,7 +12,6 @@ import com.gic.store.dto.StoreFieldDTO;
import com.gic.store.dto.StoreTmpDTO;
import com.gic.store.entity.TabStoreBrand;
import com.gic.store.entity.TabStoreExtend;
import com.gic.store.entity.TabStoreField;
import com.gic.store.entity.TabStoreGroup;
import com.gic.store.service.*;
import org.apache.commons.collections.CollectionUtils;
......@@ -250,8 +249,8 @@ public class StoreImportApiServiceImpl implements StoreImportApiService {
}
@Override
public ServiceResponse<Boolean> validateStoreName(Integer enterpriseId, String storeName) {
return ServiceResponse.success(storeService.countByStoreName(enterpriseId, storeName, null) > 0);
public ServiceResponse<Boolean> validateStoreName(Integer enterpriseId, Integer regionId, String storeName) {
return ServiceResponse.success(storeService.validateStoreNameIsExist(enterpriseId, regionId, storeName, null));
}
@Override
......
......@@ -320,7 +320,7 @@ public class StoreImportController {
}
if (!isNeedReplaceStoreCode) {
// 验证门店name唯一
if (storeImportApiService.validateStoreName(enterpriseId, storeName).getResult()) {
if (storeImportApiService.validateStoreName(enterpriseId, regionId, storeName).getResult()) {
errorMessage.append("门店名称已经存在,");
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment