Browse Source

新增统一信用代码添加

anderx 3 years ago
parent
commit
68db7abff9

+ 5 - 0
src/main/java/com/goafanti/customer/controller/AdminCustomerApiController.java

@@ -18,6 +18,7 @@ import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
 import com.goafanti.common.utils.*;
+import com.goafanti.core.mybatis.page.Pagination;
 import com.goafanti.customer.bo.*;
 import org.apache.poi.xssf.usermodel.XSSFWorkbook;
 import org.springframework.beans.factory.annotation.Value;
@@ -229,6 +230,10 @@ public class AdminCustomerApiController extends BaseApiController{
 	@RequestMapping(value = "/listAllOrganizationCustomer" , method = RequestMethod.POST)
 	public Result listAllOrganizationCustomer(CustomerListIn cli,Integer pageNo, Integer pageSize){
 		Result res = new Result();
+		if (StringUtils.isBlank(cli.getName())){
+			res.setData( new Pagination<>());
+			return res;
+		}
 		res.setData(customerService.listAllOrganizationCustomer(cli, pageNo, pageSize));
 		return res;
 	}

+ 0 - 3
src/main/java/com/goafanti/customer/service/impl/CustomerServiceImpl.java

@@ -221,9 +221,6 @@ public class CustomerServiceImpl extends BaseMybatisDao<UserMapper> implements C
 		if (StringUtils.isContainChinese(cli.getName())){
 			name= cli.getName();
 		}else {
-			if (StringUtils.isBlank(cli.getName())){
-				return new Pagination<>();
-			}
 			orgCode= cli.getName();
 		}
 		if (TokenManager.hasRole(AFTConstants.SUPERADMIN)||TokenManager.hasRole(AFTConstants.APPROVAL_DECISION)) {