Browse Source

科技成果、科技需求、智者查看条件由表中发布字段更变为对应发布表

anderx 8 years ago
parent
commit
a5645e5bf9

+ 1 - 9
src/main/java/com/goafanti/common/mapper/AchievementMapper.xml

@@ -1352,7 +1352,6 @@
   	<if test="internationalFlag != null ">
   		and a.international_flag = #{internationalFlag,jdbcType=INTEGER}
   	</if>
-  	and a.release_status = 1
   	and a.audit_status = 3 
   	<if test="dateSort == 0">
   		order by order by ap.if_top,ap.top_number,ap.show_number,a.release_date  asc
@@ -1399,15 +1398,8 @@
   	<if test="internationalFlag != null ">
   		and a.international_flag = #{internationalFlag,jdbcType=INTEGER}
   	</if>	
-  	
-  	and a.release_status = 1
   	and a.audit_status = 3 
-  	<if test="dateSort == 0">
-  		order by a.release_date asc
-  	</if>
-  	<if test="dateSort == 1">
-  		order by a.release_date desc
-  	</if>	
+  		
   </select>
   
   <select id="selectAchievementSearchDetail"  resultType="com.goafanti.portal.bo.AchievementDetailBo">

+ 0 - 4
src/main/java/com/goafanti/common/mapper/DemandMapper.xml

@@ -1078,7 +1078,6 @@
   			and d.budget_cost is null
   		</if>
   		and d.deleted_sign = 0 
-  		and d.release_status = 1
   		and d.audit_status = 3
   		<if test="dateSort == 0">
   			order by dp.if_top,dp.top_number,dp.show_number,d.release_date asc
@@ -1122,9 +1121,6 @@
   		<if test="sign == 1">
   			and d.budget_cost is null
   		</if>
-  		and d.deleted_sign = 0 
-  		and d.release_status = 1
-  		and d.audit_status = 3
   </select>
   
   <select id="selectDemandSearchDetail" parameterType="java.lang.String" resultType="com.goafanti.portal.bo.DemandSearchDetailBo"> 

+ 9 - 5
src/main/java/com/goafanti/portal/controller/PortalSearchController.java

@@ -58,13 +58,17 @@ public class PortalSearchController extends BaseController {
 		if (StringUtils.isNumeric(pageNo)) {
 			pNo = Integer.parseInt(pageNo);
 		}
-		try{
-			new BigDecimal(upperPrice);
-			new BigDecimal(lowerPrice);
-		}catch (Exception e) {
-			res.getError().add(buildError(ErrorConstants.PARAM_ERROR, "", "金额"));
+		if (null!=upperPrice&&null!=lowerPrice) {
+			try{
+				new BigDecimal(upperPrice);
+				new BigDecimal(lowerPrice);
+			}catch (Exception e) {
+				res.getError().add(buildError(ErrorConstants.PARAM_ERROR, "", "金额"));
+				return res;
+			}
 		}
 		
+		
 		Pagination<AchievementSearchListBo> achievementSearchList = achievementService.listAchievementSearchList( 
 				  keyword, dataCategory,category,fieldA, transferMode, pNo, pSize,dateSort,upperPrice,lowerPrice,internationalFlag);