Pārlūkot izejas kodu

去掉冗余代码

wanghui 7 gadi atpakaļ
vecāks
revīzija
46628576e6

+ 1 - 1
src/main/java/com/goafanti/app/controller/AppUserController.java

@@ -371,7 +371,7 @@ public class AppUserController extends BaseApiController {
         if (!StringUtils.isBlank(keyword3)) {
         	keyword.add(keyword3);
 		}
-        String[] keywords=(String[])keyword.toArray(new String[keyword.size()]);
+        String[] keywords = keyword.toArray(new String[keyword.size()]);
         ia.setKeyword(StringUtils.join(keywords,","));
         if (bindingResult.hasErrors()) {
             res.getError().add(buildErrorByMsg(bindingResult.getFieldError().getDefaultMessage(),

+ 0 - 1
src/main/java/com/goafanti/common/constant/PageConstants.java

@@ -5,7 +5,6 @@ import java.util.List;
 import java.util.Map;
 
 import com.goafanti.common.utils.StringUtils;
-import com.goafanti.news.bo.newsInterestBo;
 
 public class PageConstants {
 	static final Map<String,String> WEB_DEMAND_PAGES = new HashMap<String, String>();

+ 2 - 5
src/main/java/com/goafanti/common/controller/WebpageController.java

@@ -1040,8 +1040,7 @@ public class WebpageController extends BaseController {
 				else {
 					List<PolicyEntity> newsList = achievementService.getIntellectualProperty(6);
 					PolicyEntity newsDetail = newsService.getPolicyDetail(id+"");
-					if (null != newsDetail) {
-			
+					if (null != newsDetail) {		
 						String summary = newsDetail.getSummary();
 						modelview.addObject("hasHighTech",
 								summary != null && (summary.indexOf("高新") > -1 || summary.indexOf("高企") > -1));
@@ -1051,9 +1050,7 @@ public class WebpageController extends BaseController {
 							summary != null && (summary.indexOf("软著") > -1 || summary.indexOf("知识产权") > -1));
 						modelview.addObject("hasTechProj",
 								summary != null && (summary.indexOf("科技") > -1 || summary.indexOf("项目") > -1));
-					}
-					@SuppressWarnings("unchecked")
-					List<PolicyEntity> la = (List<PolicyEntity>) newsList;
+					}			
 					if(newsDetail.getTitleImg()!=null) {
 						String[] imgs=newsDetail.getTitleImg().split(",");
 						if(imgs[0]==null || imgs[0].length()<1)modelview.addObject("imgs",null);

+ 2 - 2
src/main/java/com/goafanti/message/service/impl/MessageServiceImpl.java

@@ -88,7 +88,7 @@ public class MessageServiceImpl  extends BaseMybatisDao<MessageFromSystemMapper>
 					}
 					if(!flag) list.add(data[i]);
 				}
-				String[] tmp = (String[])list.toArray(new String[list.size()]);
+				String[] tmp = list.toArray(new String[list.size()]);
 				return Arrays.toString(tmp);
 			}
 		}else if(selectMap.containsKey(ConsumerType.INDUSTRY.getTypeCode())){ //行业
@@ -428,5 +428,5 @@ public class MessageServiceImpl  extends BaseMybatisDao<MessageFromSystemMapper>
 		jea.setEasemobPass(easemobPass);
 		return jpushEasemobAccountMapper.insert(jea);
 	}
-	
+
 }