|
|
@@ -4,6 +4,7 @@ import java.math.BigDecimal;
|
|
|
import java.util.List;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
+import javax.servlet.http.HttpServletRequest;
|
|
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
@@ -42,12 +43,14 @@ public class PortalSearchController extends BaseController {
|
|
|
*/
|
|
|
@SuppressWarnings("unchecked")
|
|
|
@RequestMapping(value = "/achievementList", method = RequestMethod.GET)
|
|
|
- public Result achievementSearchList( String keyword,Integer dataCategory,Integer category,
|
|
|
+ public Result achievementSearchList(HttpServletRequest req, String keyword,Integer dataCategory,Integer category,
|
|
|
Integer fieldA, String pageNo, String pageSize,String transferMode, Integer dateSort,String upperPrice,String lowerPrice,
|
|
|
Integer internationalFlag) {
|
|
|
Result res = new Result();
|
|
|
Integer pNo = 1;
|
|
|
Integer pSize = 20;
|
|
|
+ String url=req.getServerName();
|
|
|
+ url=url.substring(url.indexOf(".")+1, url.length());
|
|
|
if(null != dateSort && dateSort != 0 && dateSort != 1){
|
|
|
res.getError().add(buildError(ErrorConstants.PARAM_ERROR, "", "时间排序"));
|
|
|
}
|
|
|
@@ -71,7 +74,7 @@ public class PortalSearchController extends BaseController {
|
|
|
}
|
|
|
|
|
|
|
|
|
- Pagination<AchievementSearchListBo> achievementSearchList = achievementService.listAchievementSearchList(
|
|
|
+ Pagination<AchievementSearchListBo> achievementSearchList = achievementService.listAchievementSearchList( url,
|
|
|
keyword, dataCategory,category,fieldA, transferMode, pNo, pSize,dateSort,upperPrice,lowerPrice,internationalFlag);
|
|
|
|
|
|
|
|
|
@@ -110,10 +113,12 @@ public class PortalSearchController extends BaseController {
|
|
|
* 科技需求搜索
|
|
|
*/
|
|
|
@RequestMapping(value = "/demandList", method = RequestMethod.GET)
|
|
|
- public Result demandSearchList(Integer sign, String keyword, Integer industryCategoryA, Integer industryCategoryB,
|
|
|
+ public Result demandSearchList(HttpServletRequest req,Integer sign, String keyword, Integer industryCategoryA, Integer industryCategoryB,
|
|
|
Integer demandType, BigDecimal budgetCostLower, BigDecimal budgetCostUpper, String pageNo,
|
|
|
String pageSize,Integer dateSort) {
|
|
|
Result res = new Result();
|
|
|
+ String url=req.getServerName();
|
|
|
+ url=url.substring(url.indexOf(".")+1, url.length());
|
|
|
Integer pNo = 1;
|
|
|
Integer pSize = 10;
|
|
|
if (null == sign) {
|
|
|
@@ -135,7 +140,7 @@ public class PortalSearchController extends BaseController {
|
|
|
if (StringUtils.isNumeric(pageNo)) {
|
|
|
pNo = Integer.parseInt(pageNo);
|
|
|
}
|
|
|
- res.setData(demandService.listDemandSearchList(sign, keyword, industryCategoryA, industryCategoryB, demandType,
|
|
|
+ res.setData(demandService.listDemandSearchList(url,sign, keyword, industryCategoryA, industryCategoryB, demandType,
|
|
|
budgetCostLower, budgetCostUpper, pNo, pSize,dateSort));
|
|
|
return res;
|
|
|
}
|
|
|
@@ -144,9 +149,11 @@ public class PortalSearchController extends BaseController {
|
|
|
* 用户搜索
|
|
|
*/
|
|
|
@RequestMapping(value = "/subscriberList", method = RequestMethod.GET)
|
|
|
- public Result subscriberSearchList(String name, Integer level, Integer type, String field, Integer province,
|
|
|
+ public Result subscriberSearchList(HttpServletRequest req,String name, Integer level, Integer type, String field, Integer province,
|
|
|
Integer city, Integer area,Integer international, String pageNo, String pageSize) {
|
|
|
Result res = new Result();
|
|
|
+ String url=req.getServerName();
|
|
|
+ url=url.substring(url.indexOf(".")+1, url.length());
|
|
|
if (null == type) {
|
|
|
res.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR, "", "用户类型"));
|
|
|
return res;
|
|
|
@@ -171,9 +178,9 @@ public class PortalSearchController extends BaseController {
|
|
|
pNo = Integer.parseInt(pageNo);
|
|
|
}
|
|
|
if (UserType.PERSONAL.getCode().equals(type)) {
|
|
|
- res.setData(userIdentityService.listSubscriber(name, level, field, province, city, area, international, pNo, pSize));
|
|
|
+ res.setData(userIdentityService.listSubscriber(url,name, level, field, province, city, area, international, pNo, pSize));
|
|
|
} else {
|
|
|
- res.setData(organizationIdentityService.listSubscriber(name, level, field, province, city, area, pNo, pSize));
|
|
|
+ res.setData(organizationIdentityService.listSubscriber(url,name, level, field, province, city, area, pNo, pSize));
|
|
|
}
|
|
|
return res;
|
|
|
}
|