浏览代码

Merge branch 'test' of jishutao/jitao-server into master

anderx 3 年之前
父节点
当前提交
ed7c056768
共有 38 个文件被更改,包括 811 次插入679 次删除
  1. 4 7
      .gitignore
  2. 2 2
      .idea/artifacts/jitao_server_war.xml
  3. 13 0
      .idea/libraries/Maven__com_sun_xml_bind_jaxb_core_2_3_0.xml
  4. 13 0
      .idea/libraries/Maven__com_sun_xml_bind_jaxb_impl_2_3_0.xml
  5. 13 0
      .idea/libraries/Maven__javax_activation_activation_1_1_1.xml
  6. 13 0
      .idea/libraries/Maven__javax_xml_bind_jaxb_api_2_3_0.xml
  7. 4 1
      .idea/misc.xml
  8. 10 0
      .idea/webContexts.xml
  9. 13 1
      README.md
  10. 5 5
      jitao-server.iml
  11. 20 0
      pom.xml
  12. 11 1
      src/main/java/com/goafanti/common/bo/PolicyEntity.java
  13. 5 0
      src/main/java/com/goafanti/common/controller/BaseController.java
  14. 59 56
      src/main/java/com/goafanti/common/controller/WebpageController.java
  15. 3 1
      src/main/java/com/goafanti/common/dao/IndustryCategoryMapper.java
  16. 156 176
      src/main/java/com/goafanti/common/mapper/AchievementMapper.xml
  17. 115 117
      src/main/java/com/goafanti/common/mapper/DemandMapper.xml
  18. 41 41
      src/main/java/com/goafanti/common/mapper/NewsMapper.xml
  19. 2 1
      src/main/java/com/goafanti/common/model/Policy.java
  20. 26 18
      src/main/java/com/goafanti/news/bo/InputNews.java
  21. 18 6
      src/main/java/com/goafanti/news/bo/NewsPortalList.java
  22. 3 11
      src/main/java/com/goafanti/news/bo/NewsSummary.java
  23. 35 26
      src/main/java/com/goafanti/news/controller/AdminNewsApiController.java
  24. 42 29
      src/main/java/com/goafanti/news/controller/AdminPolicyApiController.java
  25. 17 12
      src/main/resources/props/config_local.properties
  26. 10 11
      src/main/resources/spring/spring-mvc.xml
  27. 19 14
      src/main/webapp/WEB-INF/views/common.html
  28. 49 49
      src/main/webapp/WEB-INF/views/portal/aboutUs.html
  29. 9 9
      src/main/webapp/WEB-INF/views/portal/contactUs.html
  30. 13 17
      src/main/webapp/WEB-INF/views/portal/index.html
  31. 9 9
      src/main/webapp/WEB-INF/views/portal/invitation.html
  32. 2 2
      src/main/webapp/WEB-INF/views/portal/news/agreement.html
  33. 4 4
      src/main/webapp/WEB-INF/views/portal/news/newsDetail.html
  34. 1 1
      src/main/webapp/WEB-INF/views/portal/privacyStatement.html
  35. 13 13
      src/main/webapp/WEB-INF/views/portal/service/services.html
  36. 7 7
      src/main/webapp/WEB-INF/views/portal/thinkTank/policyList.html
  37. 27 27
      src/main/webapp/WEB-INF/views/user/msignIn.html
  38. 5 5
      src/main/webapp/WEB-INF/views/user/signIn.html

+ 4 - 7
.gitignore

@@ -1,9 +1,6 @@
-/target/
-/bin/
-/.classpath
-/.settings
-/bin/
-/bin/
-/bin/
+/target/
 /bin/
+/.classpath
+/.settings
 /bin/
+/out/

+ 2 - 2
.idea/artifacts/jitao_server_war.xml

@@ -1,6 +1,6 @@
 <component name="ArtifactManager">
-  <artifact type="war" name="jitao-server:war">
-    <output-path>$PROJECT_DIR$/target</output-path>
+  <artifact type="war" build-on-make="true" name="jitao-server:war">
+    <output-path>$PROJECT_DIR$/out</output-path>
     <properties id="maven-jee-properties">
       <options>
         <module>jitao-server</module>

+ 13 - 0
.idea/libraries/Maven__com_sun_xml_bind_jaxb_core_2_3_0.xml

@@ -0,0 +1,13 @@
+<component name="libraryTable">
+  <library name="Maven: com.sun.xml.bind:jaxb-core:2.3.0">
+    <CLASSES>
+      <root url="jar://$MAVEN_REPOSITORY$/com/sun/xml/bind/jaxb-core/2.3.0/jaxb-core-2.3.0.jar!/" />
+    </CLASSES>
+    <JAVADOC>
+      <root url="jar://$MAVEN_REPOSITORY$/com/sun/xml/bind/jaxb-core/2.3.0/jaxb-core-2.3.0-javadoc.jar!/" />
+    </JAVADOC>
+    <SOURCES>
+      <root url="jar://$MAVEN_REPOSITORY$/com/sun/xml/bind/jaxb-core/2.3.0/jaxb-core-2.3.0-sources.jar!/" />
+    </SOURCES>
+  </library>
+</component>

+ 13 - 0
.idea/libraries/Maven__com_sun_xml_bind_jaxb_impl_2_3_0.xml

@@ -0,0 +1,13 @@
+<component name="libraryTable">
+  <library name="Maven: com.sun.xml.bind:jaxb-impl:2.3.0">
+    <CLASSES>
+      <root url="jar://$MAVEN_REPOSITORY$/com/sun/xml/bind/jaxb-impl/2.3.0/jaxb-impl-2.3.0.jar!/" />
+    </CLASSES>
+    <JAVADOC>
+      <root url="jar://$MAVEN_REPOSITORY$/com/sun/xml/bind/jaxb-impl/2.3.0/jaxb-impl-2.3.0-javadoc.jar!/" />
+    </JAVADOC>
+    <SOURCES>
+      <root url="jar://$MAVEN_REPOSITORY$/com/sun/xml/bind/jaxb-impl/2.3.0/jaxb-impl-2.3.0-sources.jar!/" />
+    </SOURCES>
+  </library>
+</component>

+ 13 - 0
.idea/libraries/Maven__javax_activation_activation_1_1_1.xml

@@ -0,0 +1,13 @@
+<component name="libraryTable">
+  <library name="Maven: javax.activation:activation:1.1.1">
+    <CLASSES>
+      <root url="jar://$MAVEN_REPOSITORY$/javax/activation/activation/1.1.1/activation-1.1.1.jar!/" />
+    </CLASSES>
+    <JAVADOC>
+      <root url="jar://$MAVEN_REPOSITORY$/javax/activation/activation/1.1.1/activation-1.1.1-javadoc.jar!/" />
+    </JAVADOC>
+    <SOURCES>
+      <root url="jar://$MAVEN_REPOSITORY$/javax/activation/activation/1.1.1/activation-1.1.1-sources.jar!/" />
+    </SOURCES>
+  </library>
+</component>

+ 13 - 0
.idea/libraries/Maven__javax_xml_bind_jaxb_api_2_3_0.xml

@@ -0,0 +1,13 @@
+<component name="libraryTable">
+  <library name="Maven: javax.xml.bind:jaxb-api:2.3.0">
+    <CLASSES>
+      <root url="jar://$MAVEN_REPOSITORY$/javax/xml/bind/jaxb-api/2.3.0/jaxb-api-2.3.0.jar!/" />
+    </CLASSES>
+    <JAVADOC>
+      <root url="jar://$MAVEN_REPOSITORY$/javax/xml/bind/jaxb-api/2.3.0/jaxb-api-2.3.0-javadoc.jar!/" />
+    </JAVADOC>
+    <SOURCES>
+      <root url="jar://$MAVEN_REPOSITORY$/javax/xml/bind/jaxb-api/2.3.0/jaxb-api-2.3.0-sources.jar!/" />
+    </SOURCES>
+  </library>
+</component>

+ 4 - 1
.idea/misc.xml

@@ -2,6 +2,7 @@
 <project version="4">
   <component name="FrameworkDetectionExcludesConfiguration">
     <file type="web" url="file://$PROJECT_DIR$" />
+    <type id="Spring" />
   </component>
   <component name="MavenProjectsManager">
     <option name="originalFiles">
@@ -10,5 +11,7 @@
       </list>
     </option>
   </component>
-  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK" />
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
+    <output url="file://$PROJECT_DIR$/out" />
+  </component>
 </project>

+ 10 - 0
.idea/webContexts.xml

@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="WebContextManager">
+    <option name="state">
+      <map>
+        <entry key="file://$PROJECT_DIR$/src/main/webapp/WEB-INF/views/portal/service/services.html" value="file://$PROJECT_DIR$/src/main/webapp/WEB-INF/views/portal/service" />
+      </map>
+    </option>
+  </component>
+</project>

+ 13 - 1
README.md

@@ -1 +1,13 @@
-#jitao-server
+#jitao-server
+
+在命令行工具中输入命令,git clone ,把复制的链接粘贴进去。
+下载好项目文件后,进入项目文件夹,右键,选择Git Bash Here,打开命令行工具。输入
+npm install,下载 node_modules文件。
+
+三:运行项目
+1.每一个项目都要生成公共文件,依次输入命令: npm  run  dlldev;npm  run  dllpro 。
+2.进行项目打包:npm run build(本地),npm run dev(开服务器),
+3.打生产包,先改版本号npm run dllpro,npm run pro。打包完成后,在build文件夹里找到版本文件夹,压缩后发给后台。
+四:代码上传
+在命令行中依次输入:
+git status(查看改动的文件);git add .(添加到本地库);git commit -am “修改个BUG”(推送更改消息);git pull(拉取仓库的文件合并到本地文件);git push(提交代码到仓库)。

+ 5 - 5
jitao-server.iml

@@ -12,7 +12,6 @@
         </webroots>
         <sourceRoots>
           <root url="file://$MODULE_DIR$/src/main/java" />
-          <root url="file://$MODULE_DIR$/src/main/resources" />
         </sourceRoots>
       </configuration>
     </facet>
@@ -20,12 +19,9 @@
       <configuration />
     </facet>
   </component>
-  <component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8">
-    <output url="file://$MODULE_DIR$/target/classes" />
-    <output-test url="file://$MODULE_DIR$/target/test-classes" />
+  <component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8" inherit-compiler-output="true">
     <content url="file://$MODULE_DIR$">
       <sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
       <sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
       <excludeFolder url="file://$MODULE_DIR$/target" />
     </content>
@@ -91,6 +87,10 @@
     <orderEntry type="library" name="Maven: cglib:cglib:2.2.2" level="project" />
     <orderEntry type="library" name="Maven: asm:asm:3.3.1" level="project" />
     <orderEntry type="library" name="Maven: org.hibernate:hibernate-validator:5.2.4.Final" level="project" />
+    <orderEntry type="library" name="Maven: javax.xml.bind:jaxb-api:2.3.0" level="project" />
+    <orderEntry type="library" name="Maven: com.sun.xml.bind:jaxb-impl:2.3.0" level="project" />
+    <orderEntry type="library" name="Maven: com.sun.xml.bind:jaxb-core:2.3.0" level="project" />
+    <orderEntry type="library" name="Maven: javax.activation:activation:1.1.1" level="project" />
     <orderEntry type="library" name="Maven: javax.validation:validation-api:1.1.0.Final" level="project" />
     <orderEntry type="library" name="Maven: org.jboss.logging:jboss-logging:3.2.1.Final" level="project" />
     <orderEntry type="library" name="Maven: com.fasterxml:classmate:1.1.0" level="project" />

+ 20 - 0
pom.xml

@@ -305,6 +305,26 @@
 			<version>5.2.4.Final</version>
 		</dependency>
 		<dependency>
+     <groupId>javax.xml.bind</groupId>
+     <artifactId>jaxb-api</artifactId>
+     <version>2.3.0</version>
+ </dependency>
+ <dependency>
+     <groupId>com.sun.xml.bind</groupId>
+     <artifactId>jaxb-impl</artifactId>
+     <version>2.3.0</version>
+ </dependency>
+ <dependency>
+     <groupId>com.sun.xml.bind</groupId>
+     <artifactId>jaxb-core</artifactId>
+     <version>2.3.0</version>
+ </dependency>
+ <dependency>
+     <groupId>javax.activation</groupId>
+     <artifactId>activation</artifactId>
+     <version>1.1.1</version>
+ </dependency>
+		<dependency>
 			<groupId>javax.validation</groupId>
 			<artifactId>validation-api</artifactId>
 			<version>1.1.0.Final</version>

+ 11 - 1
src/main/java/com/goafanti/common/bo/PolicyEntity.java

@@ -17,7 +17,17 @@ String titleImg;
 String source;
 //String firstPictureUrl;
 String sourceUrl;
-public String getSourceUrl() {
+Date releaseDate;
+
+	public Date getReleaseDate() {
+		return releaseDate;
+	}
+
+	public void setReleaseDate(Date releaseDate) {
+		this.releaseDate = releaseDate;
+	}
+
+	public String getSourceUrl() {
 	return sourceUrl;
 }
 public void setSourceUrl(String sourceUrl) {

+ 5 - 0
src/main/java/com/goafanti/common/controller/BaseController.java

@@ -3,6 +3,7 @@ package com.goafanti.common.controller;
 import java.text.DateFormat;
 import java.text.MessageFormat;
 import java.text.SimpleDateFormat;
+import java.util.Calendar;
 import java.util.Date;
 
 import javax.annotation.Resource;
@@ -126,6 +127,10 @@ public class BaseController {
 		model.addAttribute("csrf", TokenManager.getCSRF());
 		model.addAttribute("videoServer", videoServer);
 		model.addAttribute("isAdmin", false);
+		int yearCount=0;
+		Calendar c=Calendar.getInstance();
+		yearCount=c.getWeekYear()-2001;
+		model.addAttribute("yearCount", yearCount);
 		if (TokenManager.isLogin() && TokenManager.getToken() instanceof User) {
 			model.addAttribute("userData", TokenManager.getUserToken());
 			model.addAttribute("userName", TokenManager.getUserToken().getNickname());

+ 59 - 56
src/main/java/com/goafanti/common/controller/WebpageController.java

@@ -103,12 +103,12 @@ public class WebpageController extends BaseController {
 
 	@Resource
 	private ProjectInterestMapper projectInterestMapper;
-	
+
 	@Resource
-	private JtBusinessCategoryMapper jtBusinessCategoryMapper; 
+	private JtBusinessCategoryMapper jtBusinessCategoryMapper;
 	@Resource
-	private JtTagService jtTagService; 
-	
+	private JtTagService jtTagService;
+
 	@Resource
 	private AdminVideoService adminVideoService;
 
@@ -369,11 +369,11 @@ public class WebpageController extends BaseController {
 		map.put("ownUse", jtBusinessService.getProjectByTag("他山己用", 4));
 		modelview.addObject("prolist", map);//标签项目
 		modelview.addObject("technologyProject", jtBusinessService.getCategoryByModule(5,2,12));//科技项目3级
-		
+
 		//科技项目下面的一级
 		//modelview.addObject("tProject", jtBusinessService.getCategoryByModule(5,1,4));//科技项目2级
-		
-		
+
+
 		// 政策
 		// List<PolicyEntity>policyEntities=achievementService.getIntellectualProperty(8);
 		/*List<PolicyResult> policies = (List<PolicyResult>) policyService
@@ -388,7 +388,7 @@ public class WebpageController extends BaseController {
 		for (JtBusinessProject project : l) {
 			//去除数据中的标签
 			if(StringUtils.isNotBlank(project.getIntroduce())){
-				project.setIntroduce(project.getIntroduce().replaceAll("\\<.*?>", "")); 
+				project.setIntroduce(project.getIntroduce().replaceAll("\\<.*?>", ""));
 			}
 		}
 		modelview.addObject("military", military);
@@ -404,7 +404,7 @@ public class WebpageController extends BaseController {
 					project.setMinImgUrl(null);
 				//去除数据中的标签
 				if(StringUtils.isNotBlank(project.getIntroduce())){
-					project.setIntroduce(project.getIntroduce().replaceAll("\\<.*?>", "")); 
+					project.setIntroduce(project.getIntroduce().replaceAll("\\<.*?>", ""));
 				}
 			}
 			modelview.addObject("gaoqiList", gaoqiList);
@@ -479,7 +479,7 @@ public class WebpageController extends BaseController {
 			modelview.addObject("manageSystemList", qyrzCategories);
 			modelview.addObject("managerSysc1", manageSys2);
 		}
-		
+
 		//军工认证
 		JtBusinessCategory jungong1 = jtBusinessService.getBusinessCategoryByLayerAndName(1, "军工认证");
 		category.setLayer(3);
@@ -489,8 +489,8 @@ public class WebpageController extends BaseController {
 			modelview.addObject("jungongList", jungongList);
 			modelview.addObject("jungong1", jungong1);
 		}
-		
-		
+
+
 		//科技项目
 		//获得所有模块为5的科技项目id
 		JtBusinessCategory scienceProject1 = jtBusinessService.getBusinessCategoryByLayerAndName(1, "科技项目");
@@ -522,7 +522,7 @@ public class WebpageController extends BaseController {
 
 	/*
 	 * 服务详情
-	 * 
+	 *
 	 * @param id String
 	 */
 	@RequestMapping(value = "/portal/service/serviceDetail", method = RequestMethod.GET)
@@ -553,7 +553,7 @@ public class WebpageController extends BaseController {
 		}
 		modelview.addObject("owner", owner);
 		modelview.addObject("pj", jtBusinessProject);
-		
+
 		//判断是否是个人还是组织
 		if(null != jtBusinessProject.getType() && 0 == jtBusinessProject.getType()){//个人
 			UserIdentity uide =  userIdentityService.selectUserIdentityByUserId(jtBusinessProject.getOwnerId());
@@ -584,7 +584,7 @@ public class WebpageController extends BaseController {
 
 	/*
 	 * 服务详情2
-	 * 
+	 *
 	 * @param id String
 	 */
 	@RequestMapping(value = "/portal/service/patentDetail", method = RequestMethod.GET)
@@ -668,7 +668,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 知识产权
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -681,7 +681,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 高企认定
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -707,9 +707,9 @@ public class WebpageController extends BaseController {
 	}
 
 	/**
-	 * 
+	 *
 	 * 智库咨询
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -722,7 +722,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 政策列表
-	 * 
+	 *
 	 * @return
 	 */
 	@SuppressWarnings("unchecked")
@@ -737,7 +737,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 会员介绍
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -750,7 +750,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 技术评估
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -764,7 +764,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 关于我们
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -777,7 +777,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 联系我们
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -797,7 +797,7 @@ public class WebpageController extends BaseController {
 
 	/**
 	 * 服务-推荐
-	 * 
+	 *
 	 * @param request
 	 * @param modelview
 	 * @return
@@ -810,7 +810,7 @@ public class WebpageController extends BaseController {
 
 	/*
 	 * 首页
-	 * 
+	 *
 	 */
 
 	@SuppressWarnings("unchecked")
@@ -830,7 +830,7 @@ public class WebpageController extends BaseController {
 				project.setMinImgUrl(null);
 			//去除数据中的标签
 			if(StringUtils.isNotBlank(project.getIntroduce())){
-				project.setIntroduce(project.getIntroduce().replaceAll("\\<.*?>", "")); 
+				project.setIntroduce(project.getIntroduce().replaceAll("\\<.*?>", ""));
 			}
 		}
 		modelview.addObject("projects", jtBusinessProjects);
@@ -854,7 +854,7 @@ public class WebpageController extends BaseController {
 				&& subscriptions.get(0).getSourceUrl().contains(".")) {
 			modelview.addObject("videoUrl", subscriptions.get(0).getSourceUrl());
 		}
-		
+
 		//获得轮播图数据
 		List<Banners> blist = bannersService.findBannersList("index", 0, 4, 1);
 		if(null != blist){
@@ -894,16 +894,16 @@ public class WebpageController extends BaseController {
 	}
 
 	/*
-	 * 
-	 * 
+	 *
+	 *
 	 * 技淘3.0-科技需求页
-	 * 
+	 *
 	 * @param request
-	 * 
+	 *
 	 * @param modelview
-	 * 
+	 *
 	 * @return
-	 * 
+	 *
 	 */
 	// 需求首页
 	@RequestMapping(value = "/portal/technologyTrading/demand")
@@ -998,7 +998,7 @@ public class WebpageController extends BaseController {
 		}
 		LimitLengthUtil.limiteDemandLength(sixMaxPersonnelDemand, 7, 30);
 		modelview.addObject("personnelDemandList", sixMaxPersonnelDemand);
-		
+
 		//获得轮播图数据
 		List<Banners> blist = bannersService.findBannersList("demand", 0, 3, 1);
 		if(null != blist){
@@ -1070,13 +1070,13 @@ public class WebpageController extends BaseController {
 		List<PolicyResult> policies = (List<PolicyResult>) policyService
 				.searchPolicy("", 2, null, null, "web_index", 1, 5, null).getList();
 		modelview.addObject("policyList", policies);
-		
+
 		//获得轮播图数据
 		List<Banners> blist = bannersService.findBannersList("achievement", 0, 3, 1);
 		if(null != blist){
 			modelview.addObject("abannerlist", blist);
 		}
-		
+
 		return modelview;
 	}
 
@@ -1179,7 +1179,7 @@ public class WebpageController extends BaseController {
 			modelAndView.addObject("copyrightTopId", bq.get(0).getSuperId());
 		}
 		/*********************************结束**************************************/
-		
+
 		// 知产百科
 		List<News> news = (List<News>) newsService
 				.listNews(98, null, null, null, null, null, null, 1, 4, 2 + "", null, null,null)
@@ -1203,10 +1203,11 @@ public class WebpageController extends BaseController {
 	 */
 	@RequestMapping(value = "/portal/technologyTrading/tradingIndex")
 	public ModelAndView patentTrading(HttpServletRequest request, ModelAndView modelAndView) {
-		String url = com.goafanti.common.utils.StringUtils.getDomainByHttpRequest(request);
+		//取消原全国多网站判断
+//		String url = com.goafanti.common.utils.StringUtils.getDomainByHttpRequest(request);
 		modelAndView.setViewName("/portal/technologyTrading/tradingIndex");
 		// 成果
-		List<AchievementObject> achievementObjects = achievementService.getHotAchievements(4, url,
+		List<AchievementObject> achievementObjects = achievementService.getHotAchievements(4, null,
 				"web_achievement_trading_index");
 		for (AchievementObject a : achievementObjects) {
 			if (null != a.getTechnicalPictureUrl() && a.getTechnicalPictureUrl().contains(",")) {
@@ -1217,7 +1218,7 @@ public class WebpageController extends BaseController {
 		modelAndView.addObject("achievement", achievementObjects);
 
 		// 需求
-		List<DemandListBo> demandListBos = demandService.getHotDemand(2, url, "web_demand_trading_index",0);
+		List<DemandListBo> demandListBos = demandService.getHotDemand(2, null, "web_demand_trading_index",0);
 		for (DemandListBo d : demandListBos) {
 			if (null != d.getFirstPic() && d.getFirstPic().contains(",")) {
 				d.setFirstPic(d.getFirstPic().substring(0, d.getFirstPic().indexOf(",")));
@@ -1227,12 +1228,12 @@ public class WebpageController extends BaseController {
 		return modelAndView;
 	}
 
-	
+
 
 	@RequestMapping(value = "/portal/facilitatorDetails")
 	public ModelAndView companyProfile(HttpServletRequest request, ModelAndView modelAndView, String uid) {
 		modelAndView.setViewName("/portal/facilitator");
-		
+
 		OrgIdentityBo org = organizationIdentityService.selectOrgIdentityBoByUserId(uid);
 		modelAndView.addObject("org", org);
 		/*List<JtBusinessProjectResult> projectResults = (List<JtBusinessProjectResult>) jtBusinessService
@@ -1403,7 +1404,7 @@ public class WebpageController extends BaseController {
 		res.setData(globalSearchService.globalSearchList(name,pageNo,pageSize));
 		return res;
 	}
-	
+
 	/**
 	 * 知识产权维权
 	 * @param request
@@ -1417,12 +1418,14 @@ public class WebpageController extends BaseController {
 		if(null != u&&u.getType()!=null){
 			modelview.addObject("userType",u.getType() );
 		}
-		
+
 		modelview.addObject("slist", userIdentityService.consultantList( null, 1,  4,  null, null, null,  0,  12).getList());
 		modelview.setViewName("/portal/service/safeguarding");
 		return modelview;
 	}
-	
+
+
+
 	/**
 	 * 高企自评
 	 * @param request
@@ -1434,7 +1437,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/evaluation/evaluate");
 		return modelview;
 	}
-	
+
 	/**
 	 * 顾问详情
 	 * @param modelview
@@ -1482,7 +1485,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/search");
 		return modelview;
 	}
-	
+
 	/**
 	 * 邀请好友
 	 * @param modelview
@@ -1493,7 +1496,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/invitation");
 		return modelview;
 	}
-	
+
 	/**
 	 * 政策 资讯 百科
 	 * @param policy
@@ -1529,8 +1532,8 @@ public class WebpageController extends BaseController {
 			res.setData(policyList);
 		}
 		return res;
-	} 
-	
+	}
+
 	/**
 	 * 法律顾问列表
 	 * @param modelview
@@ -1541,7 +1544,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/service/safeguardingList");
 		return modelview;
 	}
-	
+
 	/**
 	 * 获得除了指定数据的其他随机法律顾问
 	 * @param id
@@ -1557,7 +1560,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/service/safeguardingDetail");
 		return modelview;
 	}
-	
+
 	/**
 	 * 品牌建设
 	 * @param modelview
@@ -1604,7 +1607,7 @@ public class WebpageController extends BaseController {
 		modelview.setViewName("/portal/service/taxFinance");
 		return modelview;
 	}
-	
+
 	private List<JtBusinessProject> handleAdvertisement(List<JtBusinessProject> list){
 		for (JtBusinessProject jtBusinessProject : list) {
 			if(StringUtils.isNotBlank(jtBusinessProject.getAdvertisement())){
@@ -1624,11 +1627,11 @@ public class WebpageController extends BaseController {
 		modelAndView.setViewName("/portal/assessment");
 		return modelAndView;
 	}
-	
+
 	@RequestMapping("/portal/privacyStatement")
 	public ModelAndView privacyStatement(ModelAndView modelAndView){
 		modelAndView.setViewName("/portal/privacyStatement");
 		return modelAndView;
 	}
-	
+
 }

+ 3 - 1
src/main/java/com/goafanti/common/dao/IndustryCategoryMapper.java

@@ -2,6 +2,8 @@ package com.goafanti.common.dao;
 
 import java.util.List;
 
+import org.apache.ibatis.annotations.Param;
+
 import com.goafanti.common.bo.ReletivelyIndustry;
 import com.goafanti.common.bo.fieldGlossoryBo;
 import com.goafanti.common.model.IndustryCategory;
@@ -19,7 +21,7 @@ public interface IndustryCategoryMapper {
 
     int updateByPrimaryKey(IndustryCategory record);
     
-    List<IndustryCategory> listByPid(Integer pid);
+    List<IndustryCategory> listByPid(@Param("pid") Integer pid);
 
 	List<fieldGlossoryBo> selectindustryList();
 

+ 156 - 176
src/main/java/com/goafanti/common/mapper/AchievementMapper.xml

@@ -62,18 +62,18 @@
     <result column="picture_url_min" property="pictureUrlMin" jdbcType="VARCHAR" />
   </resultMap>
   <sql id="Base_Column_List">
-    id, serial_number, data_category, name, keyword, category, summary, introduction, 
-    technical_picture_url, field_a, field_b, field_c, maturity, maturity_picture_url, 
-    maturity_text_file_url, maturity_video_url, innovation, owner_id, owner_name, owner_type, owner_id_number, 
-    owner_mobile, owner_email, owner_postal_address, cooperation_mode, transfer_mode, 
-    bargaining_mode, transfer_price, technical_scene, breakthrough, patent_case, awards, 
-    team_des, parameter, tech_plan_url, business_plan_url, org_id, org_name, org_address, 
-    org_email, org_contacts, org_contacts_mobile, contacts, manager_id, salesman_id, 
+    id, serial_number, data_category, name, keyword, category, summary, introduction,
+    technical_picture_url, field_a, field_b, field_c, maturity, maturity_picture_url,
+    maturity_text_file_url, maturity_video_url, innovation, owner_id, owner_name, owner_type, owner_id_number,
+    owner_mobile, owner_email, owner_postal_address, cooperation_mode, transfer_mode,
+    bargaining_mode, transfer_price, technical_scene, breakthrough, patent_case, awards,
+    team_des, parameter, tech_plan_url, business_plan_url, org_id, org_name, org_address,
+    org_email, org_contacts, org_contacts_mobile, contacts, manager_id, salesman_id,
     status, create_time, release_status, release_date, deleted_sign, audit_status, tech_broker_id,
     country_name_zh,international_flag,jmrh_flag,boutique,picture_url_min
   </sql>
   <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
-    select 
+    select
     <include refid="Base_Column_List" />
     from achievement
     where id = #{id,jdbcType=VARCHAR}
@@ -83,26 +83,26 @@
     where id = #{id,jdbcType=VARCHAR}
   </delete>
   <insert id="insert" parameterType="com.goafanti.common.model.Achievement">
-    insert into achievement (id, serial_number, data_category, 
-      name, keyword, category, 
-      summary, introduction, technical_picture_url, 
-      field_a, field_b, field_c, 
-      maturity, innovation, owner_id, owner_postal_address, cooperation_mode, 
-      transfer_mode, bargaining_mode, transfer_price,  patent_case, 
-      awards, team_des, parameter,  status, 
-      create_time, release_status, release_date, 
+    insert into achievement (id, serial_number, data_category,
+      name, keyword, category,
+      summary, introduction, technical_picture_url,
+      field_a, field_b, field_c,
+      maturity, innovation, owner_id, owner_postal_address, cooperation_mode,
+      transfer_mode, bargaining_mode, transfer_price,  patent_case,
+      awards, team_des, parameter,  status,
+      create_time, release_status, release_date,
       deleted_sign, audit_status,international_flag,boutique,is_hot,info_sources,picture_url_min)
-    values (#{id,jdbcType=VARCHAR}, #{serialNumber,jdbcType=INTEGER}, #{dataCategory,jdbcType=INTEGER}, 
-      #{name,jdbcType=VARCHAR}, #{keyword,jdbcType=VARCHAR}, #{category,jdbcType=INTEGER}, 
-      #{summary,jdbcType=VARCHAR}, #{introduction,jdbcType=LONGVARCHAR}, #{technicalPictureUrl,jdbcType=VARCHAR}, 
-      #{fieldA,jdbcType=INTEGER}, #{fieldB,jdbcType=INTEGER}, #{fieldC,jdbcType=INTEGER}, 
+    values (#{id,jdbcType=VARCHAR}, #{serialNumber,jdbcType=INTEGER}, #{dataCategory,jdbcType=INTEGER},
+      #{name,jdbcType=VARCHAR}, #{keyword,jdbcType=VARCHAR}, #{category,jdbcType=INTEGER},
+      #{summary,jdbcType=VARCHAR}, #{introduction,jdbcType=LONGVARCHAR}, #{technicalPictureUrl,jdbcType=VARCHAR},
+      #{fieldA,jdbcType=INTEGER}, #{fieldB,jdbcType=INTEGER}, #{fieldC,jdbcType=INTEGER},
       #{maturity,jdbcType=INTEGER}, #{innovation,jdbcType=INTEGER}, #{ownerId,jdbcType=VARCHAR}
-      , #{ownerPostalAddress,jdbcType=VARCHAR}, #{cooperationMode,jdbcType=INTEGER}, 
-      #{transferMode,jdbcType=INTEGER}, #{bargainingMode,jdbcType=INTEGER}, #{transferPrice,jdbcType=DECIMAL}, 
-     #{patentCase,jdbcType=VARCHAR}, 
-      #{awards,jdbcType=VARCHAR}, #{teamDes,jdbcType=VARCHAR}, #{parameter,jdbcType=VARCHAR}, 
-    #{status,jdbcType=INTEGER}, 
-      #{createTime,jdbcType=TIMESTAMP}, #{releaseStatus,jdbcType=INTEGER}, #{releaseDate,jdbcType=TIMESTAMP}, 
+      , #{ownerPostalAddress,jdbcType=VARCHAR}, #{cooperationMode,jdbcType=INTEGER},
+      #{transferMode,jdbcType=INTEGER}, #{bargainingMode,jdbcType=INTEGER}, #{transferPrice,jdbcType=DECIMAL},
+     #{patentCase,jdbcType=VARCHAR},
+      #{awards,jdbcType=VARCHAR}, #{teamDes,jdbcType=VARCHAR}, #{parameter,jdbcType=VARCHAR},
+    #{status,jdbcType=INTEGER},
+      #{createTime,jdbcType=TIMESTAMP}, #{releaseStatus,jdbcType=INTEGER}, #{releaseDate,jdbcType=TIMESTAMP},
       #{deletedSign,jdbcType=INTEGER}, #{auditStatus,jdbcType=INTEGER},
        #{internationalFlag,jdbcType=INTEGER},#{boutique,jdbcType=INTEGER},#{isHot,jdbcType=INTEGER},#{infoSources,jdbcType=INTEGER},#{pictureUrlMin,jdbcType=VARCHAR})
   </insert>
@@ -599,16 +599,16 @@
       picture_url_min=#{pictureUrlMin,jdbcType=VARCHAR},
     where id = #{id,jdbcType=VARCHAR}
   </update>
-  
+
   <update id="batchDeleteByPrimaryKey" parameterType="java.util.List">
   	update achievement set deleted_sign = 1
-  	where  id in 
+  	where  id in
 	<foreach item="item"  collection="list" open="(" separator="," close=")">
 		#{item}
 	</foreach>
   </update>
   <select id="findAchievementListWithPid" resultType="com.goafanti.portal.bo.AchievementObject">
-  select a.name,a.id,release_date as releaseDate,technical_picture_url as technicalPictureUrl,data_category as dataCategory,is_hot as isHot 
+  select a.name,a.id,release_date as releaseDate,technical_picture_url as technicalPictureUrl,data_category as dataCategory,is_hot as isHot
   ,field_a as fieldA,field_b as fieldB,ic.name as fieldAS,icc.name as fieldBS
   from achievement a
   left join industry_category ic on ic.id=a.field_a
@@ -650,19 +650,19 @@
   </if>
   </select>
    <select id="findAppAchievementListByPage" parameterType="String" resultType="com.goafanti.achievement.bo.AchievementListBo">
-  	
-	select 
+
+	select
   		a.id,a.name, a.keyword, a.introduction,a.field_a as fieldA,a.field_b as fieldB,a.data_category as dataCategory,
   		a.status, a.release_date as releaseDate, a.audit_status as auditStatus,a.maturity,
-		f.name as field1,f2.name as field2,ifnull(b.countInterest,0) as interestCount,if(isnull(c.achievement_id),0,1) as interested  
+		f.name as field1,f2.name as field2,ifnull(b.countInterest,0) as interestCount,if(isnull(c.achievement_id),0,1) as interested
   	from achievement a
-  	left join (select count(0)  as countInterest,achievement_id from achievement_interest 
+  	left join (select count(0)  as countInterest,achievement_id from achievement_interest
   		group by achievement_id)b on a.id = b.achievement_id
 	left join (select achievement_id  from achievement_interest where uid=#{uid,jdbcType=VARCHAR} group by achievement_id)c
 	on a.id=c.achievement_id
   	left join industry_category f on a.field_a=f.id
   	left join industry_category f2 on a.field_b=f2.id
-  	where a.deleted_sign = 0 and a.audit_status = 2 and a.info_sources=1 
+  	where a.deleted_sign = 0 and a.audit_status = 2 and a.info_sources=1
   	<if test="ownerId != null">
   	and a.owner_id = #{ownerId,jdbcType=VARCHAR}
   	</if>
@@ -707,12 +707,12 @@
 			${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppAchievementCount" parameterType="String" resultType="java.lang.Integer">
-  	select 
+  	select
   		count(1)
   from achievement a
-  	where a.deleted_sign = 0 and a.audit_status = 2 and a.info_sources=1 
+  	where a.deleted_sign = 0 and a.audit_status = 2 and a.info_sources=1
 	<if test="ownerId != null">
   	and a.owner_id = #{ownerId,jdbcType=VARCHAR}
   	</if>
@@ -757,27 +757,27 @@
 	   and  a.release_status = #{releaseStatus,jdbcType=INTEGER}
 	</if>
 	</select>
-  
+
   <select id="selectUserOwnerDetail" parameterType="java.lang.String" resultType="com.goafanti.achievement.bo.AchievementUserOwnerDetailBo">
-		select  
-		  	a.id, a.serial_number as serialNumber, a.data_category as dataCategory, 
-		  	a.name, a.keyword, a.category, 
-		  	a.summary, a.introduction, a.technical_picture_url as technicalPictureUrl, 
+		select
+		  	a.id, a.serial_number as serialNumber, a.data_category as dataCategory,
+		  	a.name, a.keyword, a.category,
+		  	a.summary, a.introduction, a.technical_picture_url as technicalPictureUrl,
 		  	a.field_a as fieldA, a.field_b as fieldB, a.field_c as fieldC, f.name as field1, f2.name as field2,
-		  	a.maturity, a.maturity_picture_url as maturityPictureUrl, a.maturity_text_file_url as maturityTextFileUrl, 
-		  	a.maturity_video_url as maturityVideoUrl, a.innovation, a.owner_id as ownerId, 
-		  	a.owner_name as ownerName, a.owner_type as ownerType, a.owner_id_number as ownerIdNumber, 
-		    a.owner_mobile as ownerMobile, a.owner_email as ownerEmail, a.owner_postal_address as ownerPostalAddress, 
-		    a.cooperation_mode as cooperationMode, a.transfer_mode as transferMode, a.bargaining_mode as bargainingMode, 
-		    a.transfer_price as transferPrice, a.technical_scene as technicalScene, a.breakthrough, 
-		    a.patent_case as patentCase, a.awards, a.team_des as teamDes, 
-		    a.parameter, a.tech_plan_url as techPlanUrl, a.business_plan_url as businessPlanUrl, 
-		    a.contacts, a.manager_id as managerId, a.salesman_id as salesmanId, 
-		    a.create_time as createTime, a.release_status as releaseStatus, 
+		  	a.maturity, a.maturity_picture_url as maturityPictureUrl, a.maturity_text_file_url as maturityTextFileUrl,
+		  	a.maturity_video_url as maturityVideoUrl, a.innovation, a.owner_id as ownerId,
+		  	a.owner_name as ownerName, a.owner_type as ownerType, a.owner_id_number as ownerIdNumber,
+		    a.owner_mobile as ownerMobile, a.owner_email as ownerEmail, a.owner_postal_address as ownerPostalAddress,
+		    a.cooperation_mode as cooperationMode, a.transfer_mode as transferMode, a.bargaining_mode as bargainingMode,
+		    a.transfer_price as transferPrice, a.technical_scene as technicalScene, a.breakthrough,
+		    a.patent_case as patentCase, a.awards, a.team_des as teamDes,
+		    a.parameter, a.tech_plan_url as techPlanUrl, a.business_plan_url as businessPlanUrl,
+		    a.contacts, a.manager_id as managerId, a.salesman_id as salesmanId,
+		    a.create_time as createTime, a.release_status as releaseStatus,
 		    a.release_date as releaseDate, a.audit_status as auditStatus, a.tech_broker_id as techBrokerId,
 		    ui.username as iOwnerName, ui.province, ui.city, ui.area, u.email as iOwnerEmail,
 			ui.id_number as iOwnerIdNumber, u.mobile as iOwnerMobile,j.easemob_name as easemobName,a.remark,
-			ifnull(t2.x,0) as orderCount,a.boutique,a.contacts,a.contact_mobile as contactMobile, 
+			ifnull(t2.x,0) as orderCount,a.boutique,a.contacts,a.contact_mobile as contactMobile,
 			a.international_flag as internationalFlag
 	from achievement a
     left join user_identity ui on a.owner_id = ui.uid
@@ -786,26 +786,26 @@
     left join (select count(0) as x,tl.commodity_id from t_order tr
 				left join t_order_detail tl on tl.order_no=tr.order_no
 				where tr.order_status != 4 and tr.order_status != 0
-				group by  tl.commodity_id) t2 on a.id=t2.commodity_id 
+				group by  tl.commodity_id) t2 on a.id=t2.commodity_id
     left join jpush_easemob_account j on a.owner_id=j.uid
     left join user u on u.id = a.owner_id
   where a.id =#{id,jdbcType=VARCHAR}
   </select>
-  
+
    <select id="selectOrgOwnerDetail" parameterType="java.lang.String" resultType="com.goafanti.achievement.bo.AchievementOrgOwnerDetailBo">
-  	select  
-		  	a.id, a.serial_number as serialNumber, a.data_category as dataCategory, 
-		  	a.name, a.keyword, a.category, 
-		  	a.summary, a.introduction, a.technical_picture_url as technicalPictureUrl, 
-		  	a.field_a as fieldA, a.field_b as fieldB, a.field_c as fieldC, 
-		  	a.maturity, a.maturity_picture_url as maturityPictureUrl, a.maturity_text_file_url as maturityTextFileUrl, 
-		  	a.maturity_video_url as maturityVideoUrl, a.innovation, a.owner_id as ownerId, 
-		  	a.owner_name as ownerName, a.owner_type as ownerType, a.owner_id_number as ownerIdNumber, 
-		    a.owner_mobile as ownerMobile, a.owner_email as ownerEmail, a.owner_postal_address as ownerPostalAddress, 
-		    a.cooperation_mode as cooperationMode, a.transfer_mode as transferMode, a.bargaining_mode as bargainingMode, 
-		    a.transfer_price as transferPrice, a.technical_scene as technicalScene, a.breakthrough, 
-		    a.patent_case as patentCase, a.awards, a.team_des as teamDes, 
-		    a.parameter, a.tech_plan_url as techPlanUrl, a.business_plan_url as businessPlanUrl, 
+  	select
+		  	a.id, a.serial_number as serialNumber, a.data_category as dataCategory,
+		  	a.name, a.keyword, a.category,
+		  	a.summary, a.introduction, a.technical_picture_url as technicalPictureUrl,
+		  	a.field_a as fieldA, a.field_b as fieldB, a.field_c as fieldC,
+		  	a.maturity, a.maturity_picture_url as maturityPictureUrl, a.maturity_text_file_url as maturityTextFileUrl,
+		  	a.maturity_video_url as maturityVideoUrl, a.innovation, a.owner_id as ownerId,
+		  	a.owner_name as ownerName, a.owner_type as ownerType, a.owner_id_number as ownerIdNumber,
+		    a.owner_mobile as ownerMobile, a.owner_email as ownerEmail, a.owner_postal_address as ownerPostalAddress,
+		    a.cooperation_mode as cooperationMode, a.transfer_mode as transferMode, a.bargaining_mode as bargainingMode,
+		    a.transfer_price as transferPrice, a.technical_scene as technicalScene, a.breakthrough,
+		    a.patent_case as patentCase, a.awards, a.team_des as teamDes,
+		    a.parameter, a.tech_plan_url as techPlanUrl, a.business_plan_url as businessPlanUrl,
 		    a.contacts, a.manager_id as managerId, a.salesman_id as salesmanId,  a.international_flag as internationalFlag,
 		    a.create_time as createTime, a.release_status as releaseStatus,
 		    a.release_date as releaseDate, a.audit_status as auditStatus, a.tech_broker_id as techBrokerId,
@@ -817,23 +817,23 @@
     left join marketing_management mm on a.id = mm.product_id
     where a.id = #{id,jdbcType=VARCHAR}
   </select>
-  
+
    <insert id="insertBatch" parameterType="com.goafanti.common.model.Achievement">
     insert into achievement
     	(id, deleted_sign, audit_status,
     	 patent_case,parameter,owner_id,
     	 create_time, release_status, data_category,
-    	 info_sources,name, keyword, 
+    	 info_sources,name, keyword,
     	 category,field_a,field_b,
     	 owner_name, owner_type, owner_id_number,
     	 owner_mobile, owner_email, owner_postal_address,
     	 cooperation_mode, introduction, tech_broker_id,
     	 international_flag,maturity,team_des
     	 )
-    values 
+    values
     <foreach item="item" index="index" collection="list" separator=",">
       (
-      	#{item.id,jdbcType=VARCHAR}, #{item.deletedSign,jdbcType=INTEGER}, #{item.auditStatus,jdbcType=INTEGER}, 
+      	#{item.id,jdbcType=VARCHAR}, #{item.deletedSign,jdbcType=INTEGER}, #{item.auditStatus,jdbcType=INTEGER},
       	#{item.patentCase,jdbcType=LONGVARCHAR}, #{item.parameter,jdbcType=LONGVARCHAR},#{item.ownerId,jdbcType=VARCHAR},
       	#{item.createTime,jdbcType=TIMESTAMP}, #{item.releaseStatus,jdbcType=INTEGER}, #{item.dataCategory,jdbcType=INTEGER},
       	#{item.infoSources,jdbcType=INTEGER},#{item.name,jdbcType=VARCHAR}, #{item.keyword,jdbcType=VARCHAR},
@@ -847,40 +847,40 @@
   </insert>
 
   <select id="selectAchievementDetail"  resultType="com.goafanti.portal.bo.AchievementDetailBo">
-  	select 
-  		a.id, 
+  	select
+  		a.id,
   		a.owner_name as ownerName,
-  		a.serial_number as serialNumber, 
-  		a.keyword, 
-  		a.name, 
-  		a.data_category as dataCategory, 
+  		a.serial_number as serialNumber,
+  		a.keyword,
+  		a.name,
+  		a.data_category as dataCategory,
   		a.category,
-  		ui.username, 
-  		oi.unit_name as unitName, 
+  		ui.username,
+  		oi.unit_name as unitName,
   		a.release_date as releaseDate,
-  		a.owner_type as ownerType, 
-  		a.field_a as fieldA, 
+  		a.owner_type as ownerType,
+  		a.field_a as fieldA,
   		a.field_b as fieldB,
-  		a.transfer_price as transferPrice, 
-  		a.maturity, 
+  		a.transfer_price as transferPrice,
+  		a.maturity,
   		a.transfer_mode as transferMode,
-  		a.bargaining_mode as bargainingMode, 
-  		a.summary, 
+  		a.bargaining_mode as bargainingMode,
+  		a.summary,
   		a.introduction,
-  		a.technical_picture_url as technicalPictureUrl, 
-  		a.maturity_picture_url as maturityPictureUrl, 
+  		a.technical_picture_url as technicalPictureUrl,
+  		a.maturity_picture_url as maturityPictureUrl,
   		a.maturity_text_file_url as maturityTextFileUrl,
-  		a.maturity_video_url as maturityVideoUrl, 
-  		a.innovation, 
+  		a.maturity_video_url as maturityVideoUrl,
+  		a.innovation,
   		a.cooperation_mode as cooperationMode,
-  		a.bargaining_mode as bargainingMode, 
-  		a.technical_scene as technicalScene, 
+  		a.bargaining_mode as bargainingMode,
+  		a.technical_scene as technicalScene,
   		a.breakthrough,
-  		a.patent_case as patentCase, 
-  		a.awards, 
-  		a.team_des as teamDes, 
-  		a.parameter, 
-  		a.tech_plan_url as techPlanUrl, 
+  		a.patent_case as patentCase,
+  		a.awards,
+  		a.team_des as teamDes,
+  		a.parameter,
+  		a.tech_plan_url as techPlanUrl,
   		a.business_plan_url as businessPlanUrl,
   		ai.id as achievementInterestId
   	from achievement a
@@ -889,7 +889,7 @@
   	left join achievement_interest ai on ai.achievement_id = a.id and ai.uid = #{0}
   	where a.id = #{1}
   </select>
-  
+
   <select id="findPartnerAchievementListByPage" parameterType="java.lang.String" resultType="com.goafanti.achievement.bo.AchievementPartnerListBo">
   	SELECT
 		id,
@@ -914,7 +914,7 @@
 	AND deleted_sign = 0
 	AND owner_id = #{ownerId,jdbcType=VARCHAR}
   </select>
-  
+
   <select id="findPartnerAchievementCount" parameterType="java.lang.String" resultType="java.lang.Integer">
   	SELECT
 		count(1)
@@ -926,7 +926,7 @@
 	AND deleted_sign = 0
 	AND owner_id = #{ownerId,jdbcType=VARCHAR}
   </select>
-  
+
   <select id="findUserPortalAchievementDetail" parameterType="java.lang.String" resultType="com.goafanti.portal.bo.AchievementPortalDetailBo">
   	SELECT
 		a.id,
@@ -963,7 +963,7 @@
 	WHERE
 		a.id = #{id,jdbcType=VARCHAR}
   </select>
-  
+
    <select id="findOrgPortalAchievementDetail" parameterType="java.lang.String" resultType="com.goafanti.portal.bo.AchievementPortalDetailBo">
   	SELECT
 		a.id,
@@ -998,34 +998,34 @@
 	WHERE
 		a.id = #{id,jdbcType=VARCHAR}
   </select>
- 
+
   <select id="listAchievement" resultType="com.goafanti.achievement.bo.AchievementListBo">
-  		select 
+  		select
   		a.id, a.name, a.keyword,a.introduction,a.category,
-  		a.serial_number as serialNumber, 
-  		a.data_category as dataCategory, 
-  	    a.owner_type as ownerType, 
+  		a.serial_number as serialNumber,
+  		a.data_category as dataCategory,
+  	    a.owner_type as ownerType,
   		a.owner_name as ownerName,
-  		a.field_a as fieldA, 
+  		a.field_a as fieldA,
   		a.transfer_price as transferPrice,
   		a.transfer_mode as transfermode,
   		a.maturity,
   		a.technical_picture_url as technicalpictureurl
-  		from achievement a 
-  		where 
-  	    a.deleted_sign = 0 
+  		from achievement a
+  		where
+  	    a.deleted_sign = 0
 		and a.category = 0
   	    and a.release_status = 1
-  	    and a.audit_status = 3 
+  	    and a.audit_status = 3
   	    order by a.release_date desc limit 0,12
   </select>
- 
+
   <select id="countInterest" resultType="Integer">
   	select count(0)
-  	from achievement_interest 
+  	from achievement_interest
   	where achievement_id=#{achievementId,jdbcType=VARCHAR}
   	</select>
-  	
+
   	<select id="achievementInterest" resultType="com.goafanti.achievement.bo.AchievementInterestBo">
   	select
 		a.id,a.name,a.create_time as createTime
@@ -1033,18 +1033,18 @@
 	LEFT  join achievement a on ai.achievement_id=a.id
 	where uid=#{uid,jdbcType=VARCHAR}
   	</select>
-  	
+
   <select id="findMyAchievementListByPage" parameterType="String" resultType="com.goafanti.achievement.bo.AchievementListBo">
-  	select 
+  	select
 	  a.id, a.boutique,a.name,a.category, a.audit_status as auditStatus,ifnull(t.x,0) as buyIntention,
 	  a.release_date as releaseDate,a.create_time as createTime,ifnull(i.y,0) as countInterest
-	from  achievement a 
+	from  achievement a
 	left join (select count(0) as x, tl.commodity_id from t_order tr
 				left join t_order_detail tl on tr.order_no=tl.order_no
 				where tr.order_status != 4
-				group by  tl.commodity_id ) t on a.id=t.commodity_id 
+				group by  tl.commodity_id ) t on a.id=t.commodity_id
 	left join (select count(0) as y,achievement_id from achievement_interest
-				group by achievement_id ) i on a.id=i.achievement_id	
+				group by achievement_id ) i on a.id=i.achievement_id
 	where a.deleted_sign = 0
 	<if test="ownerId != null">
   	and a.owner_id = #{ownerId,jdbcType=VARCHAR}
@@ -1054,11 +1054,11 @@
 			${page_sql}
 	</if>
   </select>
-  
+
   <select id="findMyAchievementCount" parameterType="String" resultType="java.lang.Integer">
-  	select 
+  	select
   		count(1)
-  	from  achievement a 
+  	from  achievement a
 	where a.deleted_sign = 0
 	<if test="ownerId != null">
   	and  a.owner_id  = #{ownerId,jdbcType=VARCHAR}
@@ -1066,7 +1066,7 @@
   </select>
 
   <select id="getAppHomeAchievement" resultType="com.goafanti.app.bo.HomeAchievemend">
-  select ap.achievement_id as id ,a.name as name ,a.technical_picture_url as img, 
+  select ap.achievement_id as id ,a.name as name ,a.technical_picture_url as img,
 		ap.if_top,ap.top_number,ap.show_number
 		from achievement_publish ap
 		left join achievement a on ap.achievement_id=a.id
@@ -1078,7 +1078,7 @@
  <select id="getAppHomeRecommended" resultType="com.goafanti.achievement.bo.AchievementRecommended">
  	select ap.achievement_id as id,a.name,a.introduction,a.technical_picture_url as technicalpictureUrl,
 	a.field_a,a.field_b,f1.name as fieldA,f2.name as fieldB,a.boutique
-	from achievement_publish ap 
+	from achievement_publish ap
 	left join achievement a on ap.achievement_id = a.id
 	left join field_glossory f1 on a.field_a=f1.id
 	left join field_glossory f2 on a.field_b=f2.id
@@ -1090,7 +1090,7 @@ order by
 	ap.top_number,
 	ap.show_number asc limit 0,
 	6
-</select> 	
+</select>
 
 <select id="getRecentAchievements" resultType="com.goafanti.portal.bo.AchievementObject">
  select
@@ -1125,41 +1125,19 @@ order by
 </select>
 
 <select id="getHotAchievements" resultType="com.goafanti.portal.bo.AchievementObject">
-select 
-a.name as name ,
-a.id as id,
-a.technical_picture_url as technicalPictureUrl,
-a.picture_url_min as pictureUrlMin,
-b.ct as interestCount,
-a.category,
-a.data_category as dataCategory,
-	fg.name as fieldAS,
-	fgg.name as fieldBS,
-	a.introduction
-from achievement a
-left join branch_information branchInfo 
-on INSTR(#{1},branchInfo.domain_name)>0
-left join achievement_publish ap
- on ap.achievement_id=a.id
- left join industry_category fg on
-	fg.id = a.field_a
-left join industry_category fgg on
-	fgg.id = a.field_b
-left join 
-(select  
-count(0) as ct,
-achievement_id as interest_aid
-from achievement_interest
-group by
-achievement_id
-) b 
-on b.interest_aid=a.id
-where a.audit_status=2
-and ap.achievement_id=a.id
-and branchInfo.id = ap.publish_platform
-and instr(ap.publish_page,#{2})>0
-and info_sources=1
-order by a.release_date desc limit #{0}
+  select
+    a.name as name ,
+    a.id as id,
+    a.technical_picture_url as technicalPictureUrl,
+    a.picture_url_min as pictureUrlMin,
+    a.category
+  from achievement a
+         left join achievement_publish ap
+                   on ap.achievement_id=a.id
+  where a.audit_status=2
+    and ap.publish_page= #{2}
+    and info_sources=1
+  order by a.release_date desc limit #{0};
 
 </select>
 
@@ -1212,7 +1190,9 @@ order by release_date desc limit #{0}
 </select>
 
 <select id="getIntellectualProperty" resultType="com.goafanti.common.bo.PolicyEntity" >
-select p.id,p.title,p.title_img as titleImg,p.summary,dg1.name as provinceS,dg2.name as cityS,edit_time as editTime ,create_time as createTime,p.id,p.source,p.source_url as sourceUrl  from policy p 
+select p.id,p.title,p.title_img as titleImg,p.summary,dg1.name as provinceS,dg2.name as cityS,
+       edit_time as editTime ,create_time as createTime,p.release_date as releaseDate,
+       p.id,p.source,p.source_url as sourceUrl  from policy p
 left join district_glossory dg1 on dg1.id=p.province
 left join district_glossory dg2 on dg2.id=p.city
 where audit_status = 2
@@ -1290,14 +1270,14 @@ and info_sources=1
 order by release_date limit #{0}
 </select>
 <select id="listMyAchievementByPage"   resultType="com.goafanti.portal.bo.AchievementObject">
-	select 
-  		a.id, 
+	select
+  		a.id,
   		a.serial_number as serialNumber,
   		a.category,
   		a.data_category as dataCategory,
-  		a.name, 
+  		a.name,
   		a.release_date as releaseDate,
-  		a.create_time as createTime, 
+  		a.create_time as createTime,
   		a.audit_status as auditStatus,
   		a.boutique,
   		if(isnull(c.interestCount),0,c.interestCount) as interestCount,
@@ -1343,7 +1323,7 @@ order by release_date limit #{0}
 	</if>
 </select>
 <select id="listMyAchievementCount" resultType="java.lang.Integer">
-	select 
+	select
   		count(0)
   	from achievement a
   	left join user b on a.owner_id = b.id left join (select achievement_id,count(*)as interestCount from achievement_interest group by achievement_id) c
@@ -1417,13 +1397,13 @@ where
 	a.id = #{0}
 </select>
 <select id="listInterestedAchievement" resultType="com.goafanti.portal.bo.AchievementObject">
-	select 
-  		a.id, 
+	select
+  		a.id,
   		a.serial_number as serialNumber,
   		a.category,
   		a.data_category as dataCategory,
-  		a.name, 
-  		a.release_date as releaseDate, 
+  		a.name,
+  		a.release_date as releaseDate,
   		a.audit_status as auditStatus,
   		a.technical_picture_url as technicalPictureUrl,
   		a.boutique,
@@ -1437,7 +1417,7 @@ where
 	</if>
   	</select>
   	<select id="listInterestedAchievementCount" resultType="java.lang.Integer">
-	select 
+	select
   		count(0)
   	from achievement a
   	left join achievement_interest ai on ai.achievement_id=a.id
@@ -1452,15 +1432,15 @@ where
   left join industry_category f2 on a.field_b=f2.id
   left join industry_category f3 on a.field_c=f3.id
   left join (select b.commodity_id as id,count(*) as count from jt_order a left join jt_order_detail b on a.order_no=b.order_no
-	GROUP by b.commodity_id) t on a.id=t.id 
-  left join (select achievement_id,count(*) as count from achievement_interest group by achievement_id ) b 
+	GROUP by b.commodity_id) t on a.id=t.id
+  left join (select achievement_id,count(*) as count from achievement_interest group by achievement_id ) b
   on a.id=b.achievement_id left join (select achievement_id from achievement_interest where uid= #{uid,jdbcType=VARCHAR} )d  on a.id=d.achievement_id
   where a.deleted_sign = 0 and a.info_sources=1
   AND  a.id =#{id,jdbcType=VARCHAR}
   	</select>
   	<select id="myCollectionAchievementList" resultType="com.goafanti.common.bo.MyCollection">
-  	select 
-  		a.id, a.name, a.introduction, b.name as fieidA, ai.uid, a.maturity as textA,ifnull(c.x,0) as interestCount 
+  	select
+  		a.id, a.name, a.introduction, b.name as fieidA, ai.uid, a.maturity as textA,ifnull(c.x,0) as interestCount
   	from achievement a
   	left join achievement_interest ai on ai.achievement_id=a.id
   	left join industry_category b on a.field_a= b.id
@@ -1474,7 +1454,7 @@ where
 	</if>
   	</select>
   	<select id="myCollectionAchievementCount" resultType="java.lang.Integer">
-	select 
+	select
   		count(0)
   	from achievement a
   	left join achievement_interest ai on ai.achievement_id=a.id

+ 115 - 117
src/main/java/com/goafanti/common/mapper/DemandMapper.xml

@@ -46,22 +46,22 @@
     <result column="picture_url_min" property="pictureUrlMin" jdbcType="VARCHAR" />
   </resultMap>
   <sql id="Base_Column_List" >
-    id, serial_number, data_category, name, keyword, info_sources, industry_category_a, 
-    industry_category_b, industry_category_c, demand_type, problem_des, technical_requirements, 
-    picture_url, text_file_url, video_url, fixed_budget, fixed_cycle, people_number, 
-    fixed_scheme, cost_escrow, budget_cost, validity_period, employer_id, employer_name, 
-    employer_address, employer_contacts, employer_contacts_mobile, employer_contacts_mailbox, 
+    id, serial_number, data_category, name, keyword, info_sources, industry_category_a,
+    industry_category_b, industry_category_c, demand_type, problem_des, technical_requirements,
+    picture_url, text_file_url, video_url, fixed_budget, fixed_cycle, people_number,
+    fixed_scheme, cost_escrow, budget_cost, validity_period, employer_id, employer_name,
+    employer_address, employer_contacts, employer_contacts_mobile, employer_contacts_mailbox,
     contacts, status, release_status, release_date, create_time, principal_id, deleted_sign,
     audit_status, tech_broker_id,boutique,urgent_money,urgent_days,picture_url_min
   </sql>
   <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
-    select 
+    select
     <include refid="Base_Column_List" />
     from demand
     where id = #{id,jdbcType=VARCHAR}
   </select>
   <select id="selectAppByPrimaryKey" resultType="com.goafanti.demand.bo.AppDemandBo" parameterType="java.lang.String" >
-       select 
+       select
     d.id, d.serial_number AS serialNumber, d.data_category AS dataCategory, d.name, d.keyword,d.budget_cost as budgetCost,
     d.info_sources AS infoSources, d.industry_category_a AS fieldA,d.industry_category_b AS fieldB,f.name as field1,
     f2.name as field2,d.is_hot as isHot,d.release_date as releaseDate,d.demand_type as demandType,d.name,
@@ -77,7 +77,7 @@
 	left join (select demand_id from demand_interest where uid=#{uid,jdbcType=VARCHAR}  group by demand_id) a on d.id=a.demand_id
 	left join industry_category f on d.industry_category_a=f.id
   	left join industry_category f2 on d.industry_category_b=f2.id
-	where d.deleted_sign=0 and d.info_sources=1			
+	where d.deleted_sign=0 and d.info_sources=1
     and  d.id = #{id,jdbcType=VARCHAR}
 	</select>
   <delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
@@ -85,30 +85,30 @@
     where id = #{id,jdbcType=VARCHAR}
   </delete>
   <insert id="insert" parameterType="com.goafanti.common.model.Demand" >
-    insert into demand (id, serial_number, data_category, 
-      name, keyword, info_sources, 
-      industry_category_a, industry_category_b, industry_category_c, 
-      demand_type, problem_des, technical_requirements, 
-      picture_url, text_file_url, video_url, 
-      fixed_budget, fixed_cycle, people_number, 
-      fixed_scheme, cost_escrow, budget_cost, 
-      validity_period, employer_id, employer_name, 
-      employer_address, employer_contacts, employer_contacts_mobile, 
-      employer_contacts_mailbox, contacts, status, 
-      release_status, release_date, create_time, 
+    insert into demand (id, serial_number, data_category,
+      name, keyword, info_sources,
+      industry_category_a, industry_category_b, industry_category_c,
+      demand_type, problem_des, technical_requirements,
+      picture_url, text_file_url, video_url,
+      fixed_budget, fixed_cycle, people_number,
+      fixed_scheme, cost_escrow, budget_cost,
+      validity_period, employer_id, employer_name,
+      employer_address, employer_contacts, employer_contacts_mobile,
+      employer_contacts_mailbox, contacts, status,
+      release_status, release_date, create_time,
       principal_id, deleted_sign, audit_status, tech_broker_id,boutique,remark,urgent_days,urgent_money,contact_mobile,crowd_cost,
       is_hot,is_urgent,research_type,picture_url_min)
-    values (#{id,jdbcType=VARCHAR}, #{serialNumber,jdbcType=INTEGER}, #{dataCategory,jdbcType=INTEGER}, 
-      #{name,jdbcType=VARCHAR}, #{keyword,jdbcType=VARCHAR}, #{infoSources,jdbcType=INTEGER}, 
-      #{industryCategoryA,jdbcType=INTEGER}, #{industryCategoryB,jdbcType=INTEGER}, #{industryCategoryC,jdbcType=INTEGER}, 
-      #{demandType,jdbcType=INTEGER}, #{problemDes,jdbcType=VARCHAR}, #{technicalRequirements,jdbcType=VARCHAR}, 
-      #{pictureUrl,jdbcType=LONGVARCHAR}, #{textFileUrl,jdbcType=VARCHAR}, #{videoUrl,jdbcType=VARCHAR}, 
-      #{fixedBudget,jdbcType=DECIMAL}, #{fixedCycle,jdbcType=VARCHAR}, #{peopleNumber,jdbcType=INTEGER}, 
-      #{fixedScheme,jdbcType=VARCHAR}, #{costEscrow,jdbcType=DECIMAL}, #{budgetCost,jdbcType=DECIMAL}, 
-      #{validityPeriod,jdbcType=TIMESTAMP}, #{employerId,jdbcType=VARCHAR}, #{employerName,jdbcType=VARCHAR}, 
-      #{employerAddress,jdbcType=VARCHAR}, #{employerContacts,jdbcType=VARCHAR}, #{employerContactsMobile,jdbcType=VARCHAR}, 
-      #{employerContactsMailbox,jdbcType=VARCHAR}, #{contacts,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, 
-      #{releaseStatus,jdbcType=INTEGER}, #{releaseDate,jdbcType=TIMESTAMP}, #{createTime,jdbcType=TIMESTAMP}, 
+    values (#{id,jdbcType=VARCHAR}, #{serialNumber,jdbcType=INTEGER}, #{dataCategory,jdbcType=INTEGER},
+      #{name,jdbcType=VARCHAR}, #{keyword,jdbcType=VARCHAR}, #{infoSources,jdbcType=INTEGER},
+      #{industryCategoryA,jdbcType=INTEGER}, #{industryCategoryB,jdbcType=INTEGER}, #{industryCategoryC,jdbcType=INTEGER},
+      #{demandType,jdbcType=INTEGER}, #{problemDes,jdbcType=VARCHAR}, #{technicalRequirements,jdbcType=VARCHAR},
+      #{pictureUrl,jdbcType=LONGVARCHAR}, #{textFileUrl,jdbcType=VARCHAR}, #{videoUrl,jdbcType=VARCHAR},
+      #{fixedBudget,jdbcType=DECIMAL}, #{fixedCycle,jdbcType=VARCHAR}, #{peopleNumber,jdbcType=INTEGER},
+      #{fixedScheme,jdbcType=VARCHAR}, #{costEscrow,jdbcType=DECIMAL}, #{budgetCost,jdbcType=DECIMAL},
+      #{validityPeriod,jdbcType=TIMESTAMP}, #{employerId,jdbcType=VARCHAR}, #{employerName,jdbcType=VARCHAR},
+      #{employerAddress,jdbcType=VARCHAR}, #{employerContacts,jdbcType=VARCHAR}, #{employerContactsMobile,jdbcType=VARCHAR},
+      #{employerContactsMailbox,jdbcType=VARCHAR}, #{contacts,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER},
+      #{releaseStatus,jdbcType=INTEGER}, #{releaseDate,jdbcType=TIMESTAMP}, #{createTime,jdbcType=TIMESTAMP},
       #{principalId,jdbcType=VARCHAR}, #{deletedSign,jdbcType=INTEGER}, #{auditStatus,jdbcType=INTEGER},
       #{techBrokerId,jdbcType=VARCHAR},#{boutique,jdbcType=INTEGER},#{remark,jdbcType=VARCHAR},#{urgentDays,jdbcType=VARCHAR},#{urgentMoney,jdbcType=VARCHAR},#{contactMobile,jdbcType=VARCHAR},#{crowdCost,jdbcType=DECIMAL},
       #{isHot,jdbcType=INTEGER},#{isUrgent,jdbcType=INTEGER},#{researchType,jdbcType=INTEGER},#{pictureUrlMin,jdbcType=VARCHAR})
@@ -358,7 +358,7 @@
             <if test="pictureUrlMin != null" >
       #{pictureUrlMin,jdbcType=VARCHAR},
       </if>
-      
+
     </trim>
   </insert>
   <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.Demand" >
@@ -450,7 +450,7 @@
       </if>
       <if test="contacts != null" >
         contacts = #{contacts,jdbcType=VARCHAR},
-      </if>   
+      </if>
       <if test="contactMobile  != null" >
         contact_mobile  = #{contactMobile ,jdbcType=VARCHAR},
       </if>
@@ -491,7 +491,7 @@
         urgent_days = #{urgentDays,jdbcType=INTEGER},
       </if>
       <if test="urgentMoney != null" >
-        urgent_money = #{urgentMoney,jdbcType=VARCHAR}, 
+        urgent_money = #{urgentMoney,jdbcType=VARCHAR},
       </if>
       <if test="researchType != null">
       	research_type = #{researchType,jdbcType=VARCHAR},
@@ -555,20 +555,20 @@
   </update>
 
   <select id="findAppDemandListByPage" parameterType="String" resultType="com.goafanti.demand.bo.DemandListBo">
-  	select 
-	  d.id,d.name, d.keyword, d.is_urgent as isUrgent, d.demand_type as demandType, d.industry_category_a as industryCategoryA, d.industry_category_b as industryCategoryB, 
+  	select
+	  d.id,d.name, d.keyword, d.is_urgent as isUrgent, d.demand_type as demandType, d.industry_category_a as industryCategoryA, d.industry_category_b as industryCategoryB,
 	  d.validity_period as validityPeriod, d.status, d.release_status as releaseStatus,d.release_date as releaseDate, d.employer_id as employerId,
 	  d.audit_status as auditStatus,d.urgent_money as urgentMoney,d.urgent_days as  urgentDays,d.problem_des as problemDes,
 	  ifnull(t.countInterest,0) as interestCount,if(isnull(y.demand_id),0,1) as interested,
 	  g.name as industryCategory1,g2.name as industryCategory2
-	from  demand d 
+	from  demand d
 	left join  user_identity t on d.employer_id=t.uid
 	left join	industry_category g on d.industry_category_a=g.id
 	left join	industry_category g2 on d.industry_category_b=g2.id
-	left join (select count(0)  as countInterest ,demand_id from demand_interest 
+	left join (select count(0)  as countInterest ,demand_id from demand_interest
 				group by demand_id) t on d.id=t.demand_id
-	left join (select demand_id from demand_interest where uid= #{uid,jdbcType=VARCHAR} group by demand_id) y on d.id=y.demand_id		
-	where d.deleted_sign = 0 and d.audit_status=2 and d.info_sources=1  
+	left join (select demand_id from demand_interest where uid= #{uid,jdbcType=VARCHAR} group by demand_id) y on d.id=y.demand_id
+	where d.deleted_sign = 0 and d.audit_status=2 and d.info_sources=1
 	<if test="employerId != null">
 	and d.employer_id = #{employerId, jdbcType=VARCHAR}
 	</if>
@@ -613,11 +613,11 @@
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppDemandCount" parameterType="String" resultType="java.lang.Integer">
   		select count(1)
-	from  demand d 
-	where d.deleted_sign = 0 and d.audit_status=2 and d.info_sources=1  
+	from  demand d
+	where d.deleted_sign = 0 and d.audit_status=2 and d.info_sources=1
 	<if test="employerId != null">
 	and d.employer_id = #{employerId, jdbcType=VARCHAR}
 	</if>
@@ -658,19 +658,19 @@
 	   and  d.release_date <![CDATA[ < ]]> #{rEnd,jdbcType=TIMESTAMP}
 	</if>
   </select>
-  
+
   <update id="batchDeleteByPrimaryKey" parameterType="java.util.List">
   	update demand set deleted_sign = 1
-  	where  id in 
+  	where  id in
 	<foreach item="item"  collection="list" open="(" separator="," close=")">
 		#{item}
 	</foreach>
   </update>
-  
+
   <insert id="insertBatch" parameterType="com.goafanti.common.model.Demand">
-    insert into demand 
-    	(id, deleted_sign, audit_status, 
-    	status, release_status, create_time, 
+    insert into demand
+    	(id, deleted_sign, audit_status,
+    	status, release_status, create_time,
     	keyword, data_category, name,
     	employer_id,demand_type, problem_des,
     	employer_name,employer_contacts, employer_contacts_mobile,
@@ -678,7 +678,7 @@
     	remark,urgent_days ,urgent_money,
     	is_hot,industry_category_a,industry_category_b
     	 )
-    values 
+    values
     <foreach item="item" index="index" collection="list" separator=",">
       (
       	#{item.id,jdbcType=VARCHAR}, #{item.deletedSign,jdbcType=INTEGER}, #{item.auditStatus,jdbcType=INTEGER},
@@ -692,7 +692,7 @@
       )
     </foreach>
   </insert>
-  
+
   <select id="findUserPortalDemandDetail" parameterType="java.lang.String" resultType="com.goafanti.portal.bo.DemandPortalDetailBo">
   	SELECT
 		d.id,
@@ -725,7 +725,7 @@
 	WHERE
 		d.id = #{id,jdbcType=VARCHAR}
   </select>
-  
+
   <select id="findOrgPortalDemandDetail" parameterType="java.lang.String" resultType="com.goafanti.portal.bo.DemandPortalDetailBo">
   	SELECT
 		d.id,
@@ -771,7 +771,7 @@
 			b.identify_name as employerName,
 			a.is_hot as isHot,
 			a.is_urgent as isUrgent
-		from demand a left join user b on a.employer_id = b.id 
+		from demand a left join user b on a.employer_id = b.id
 		where  a.info_sources=1
 		and a.deleted_sign=0
 		<if test="employerId != null">
@@ -812,7 +812,7 @@
 	<select id="selectDemandListCount" resultType="java.lang.Integer">
 		select
 			count(0)
-		from demand a left join user b on a.employer_id = b.id 
+		from demand a left join user b on a.employer_id = b.id
 		where  a.info_sources=1
 		and a.deleted_sign=0
 		<if test="employerId != null">
@@ -846,19 +846,19 @@
 			and b.identify_name like concat('%',#{identifyName,jdbcType=VARCHAR},'%')
 		</if>
 	</select>
-  
+
 	<select id="countInterest" resultType="Integer">
 	select count(0)
 	from demand_interest
 	where demand_id = #{demandId,jdbcType=VARCHAR}
-	</select> 
-	
+	</select>
+
   <select id="findAppMyDemandListByPage" parameterType="String" resultType="com.goafanti.demand.bo.AppDemandBo">
-  	select 
+  	select
 	  d.id, d.boutique,d.name, d.audit_status as auditStatus,d.release_date as releaseDate,
 	  d.create_time as createTime,ifnull(i.y,0) as interestCount,
 	  if(isnull(a.demand_id),0,1) as interest
-	from  demand d 
+	from  demand d
 	left join (select count(0) as y,demand_id from demand_interest
 				group by demand_id ) i on d.id=i.demand_id
 	left join (select demand_id from demand_interest where uid=#{employerId, jdbcType=VARCHAR}) a on d.id=a.demand_id
@@ -871,16 +871,16 @@
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppMyDemandCount" parameterType="String" resultType="java.lang.Integer">
   	select count(*)
-	from  demand d 
-	where d.deleted_sign = 0 
+	from  demand d
+	where d.deleted_sign = 0
 	<if test="employerId != null">
 		and d.employer_id = #{employerId, jdbcType=VARCHAR}
 	</if>
   </select>
-  
+
   <select id="selectDemandDetail" resultType="com.goafanti.demand.bo.DemandDetailBo" parameterType="java.lang.String" >
 	select
 		id,
@@ -907,7 +907,7 @@
 		demand
 	where id = #{id,jdbcType=VARCHAR}
   </select>
- 
+
 	<select id="findAppNewsInterestByPage" parameterType="String" resultType="com.goafanti.demand.bo.ObjectInterestListBo">
   	select	n.id,n.title as name,n.create_time as createTime
 	from news_interest ni
@@ -918,52 +918,52 @@
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppNewsInterestCount" parameterType="String" resultType="java.lang.Integer">
   		select count(1)
 	from news_interest ni
 	LEFT  join news n on ni.new_id=n.id
 	where ni.uid=#{uid,jdbcType=VARCHAR}
 	</select>
-	
+
 	<select id="findAppUserInterestByPage" parameterType="String" resultType="com.goafanti.demand.bo.ObjectInterestListBo">
   	select y.uid as id,y.username as name ,t.create_time as createTime
 	from user_interest t
 	left join  user_identity y on t.to_uid=y.uid
-	where expert=1  
+	where expert=1
 	and from_uid=#{uid,jdbcType=VARCHAR}
   	<if test="page_sql!=null">
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppUserInterestCount" parameterType="String" resultType="java.lang.Integer">
   	select count(1)
 	from user_interest t
 	left join  user_identity y on t.to_uid=y.uid
-	where expert=1  
+	where expert=1
 	and  from_uid=#{uid,jdbcType=VARCHAR}
 	</select>
-	
+
 	<select id="findAppCounselorInterestByPage" parameterType="String" resultType="com.goafanti.demand.bo.ObjectInterestListBo">
   	select y.uid as id,y.username as name ,t.create_time as createTime
 	from user_interest t
 	left join  user_identity y on t.to_uid=y.uid
-	where expert=2  
+	where expert=2
 	and from_uid=#{uid,jdbcType=VARCHAR}
   	<if test="page_sql!=null">
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppCounselorInterestCount" parameterType="String" resultType="java.lang.Integer">
   	select count(1)
 	from user_interest t
 	left join  user_identity y on t.to_uid=y.uid
-	where  expert=2  
+	where  expert=2
 	and from_uid=#{uid,jdbcType=VARCHAR}
 	</select>
-	
+
 	<select id="findAppDemandInterestByPage"  resultType="com.goafanti.demand.bo.ObjectInterestListBo">
   	select d.id ,d.name,t.create_time as createTime
 	from demand_interest t
@@ -973,14 +973,14 @@
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppDemandInterestCount" parameterType="String" resultType="java.lang.Integer">
   	select count(1)
 	from demand_interest t
 	left join  demand d on t.demand_id=d.id
 	where  uid=#{uid,jdbcType=VARCHAR}
 	</select>
-	
+
 	<select id="findAppAchievementInterestByPage" parameterType="String" resultType="com.goafanti.demand.bo.ObjectInterestListBo">
   	select a.id ,a.name,t.create_time as createTime
 	from achievement_interest t
@@ -990,14 +990,14 @@
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppAchievementInterestCount" parameterType="String" resultType="java.lang.Integer">
   	select count(1)
 	from achievement_interest t
 	left join  achievement a on t.achievement_id=a.id
 	where  t.uid=#{uid,jdbcType=VARCHAR}
 	</select>
-	
+
 	<select id="findAppProjectInterestByPage" parameterType="String" resultType="com.goafanti.demand.bo.ObjectInterestListBo">
   	 select b.id ,b.bname as name,t.uid,t.create_time as createTime
 	from project_interest t
@@ -1007,7 +1007,7 @@
 		${page_sql}
 	</if>
   </select>
-  
+
   <select id="findAppProjectInterestCount" parameterType="String" resultType="java.lang.Integer">
   	select count(1)
 	from project_interest t
@@ -1019,7 +1019,7 @@
 	  		select dp.demand_id as id,d.name,d.demand_type as demandType,d.problem_des as introduction,d.picture_url as pictureUrl,
 		d.urgent_days as urgentDays,d.urgent_money as urgentMoney,d.industry_category_a as industryCategoryA,
 		d.industry_category_b as industryCategoryB,f1.name as fieldA,f2.name as fieldB,d.boutique
-		from demand_publish dp 
+		from demand_publish dp
 		left join demand d on dp.demand_id = d.id
 		left join field_glossory f1 on d.industry_category_a=f1.id
 		left join field_glossory f2 on d.industry_category_b=f2.id
@@ -1033,9 +1033,9 @@
 		6
   </select>
   <select id="selectRecentDemand" resultType="com.goafanti.demand.bo.DemandListBo">
- select d.name,employer_name as employerName,d.id ,data_category as dataCategory,release_date as releaseDate,demand_type as demandType,budget_cost as budgetCost 
+ select d.name,employer_name as employerName,d.id ,data_category as dataCategory,release_date as releaseDate,demand_type as demandType,budget_cost as budgetCost
  ,fg.name as industryCategory1,fgg.name as industryCategory2,problem_des as problemDes,d.picture_url as pictureUrl
- from demand d 
+ from demand d
      left join industry_category  fg  on fg.id=d.industry_category_a
     left join industry_category fgg  on fgg.id=d.industry_category_b
   left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
@@ -1043,79 +1043,77 @@ left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchI
  where audit_status=2 and info_sources=1 and dp.demand_id=d.id and dp.publish_platform=branchInfo.id  and instr(dp.publish_page,#{2})>0
  order by  release_date  desc limit #{0}
   </select>
-  
+
 
    <select id="selectCompanyDemand" resultType="com.goafanti.demand.bo.DemandListBo">
  select d.name,picture_url as pictureUrl,d.id ,data_category as dataCategory
- from demand d  
+ from demand d
    left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
 left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
  where d.demand_type=0 and info_sources=1 and d.audit_status=2  and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
   order by  release_date  desc limit #{0}
   </select>
-  
-  
+
+
    <select id="getUrgentDemand" resultType="com.goafanti.demand.bo.DemandListBo">
  select name,release_date as releaseDate,d.id,problem_des as problemDes,research_type as researchType,budget_cost as fundForPersonnel,crowd_cost as fundForCrowd,demand_type as demandType,
  data_category as dataCategory,validity_period as validityPeriod
-  from demand d  
+  from demand d
     left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
 left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
   where d.is_urgent=1 and d.audit_status=2 and info_sources=1 and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
    order by  release_date  desc limit #{0}
   </select>
-  
+
   <select id="getHotDemand" resultType="com.goafanti.demand.bo.DemandListBo">
- select d.name,release_date as releaseDate,d.id,problem_des as problemDes,
- research_type as researchType,budget_cost as fundForPersonnel,crowd_cost as fundForCrowd,demand_type as demandType,
- fg.name as industryCategory1,fgg.name as industryCategory2,d.picture_url as pictureUrl,d.picture_url_min as pictureUrlMin,
- data_category as dataCategory,validity_period as validityPeriod
-  from demand d 
-      left join industry_category  fg  on fg.id=d.industry_category_a
-    left join industry_category fgg  on fgg.id=d.industry_category_b
-      left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
-left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
-   where  d.audit_status=2 and info_sources=1 and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
+    select d.name,release_date as releaseDate,d.id,problem_des as problemDes,
+    research_type as researchType,budget_cost as fundForPersonnel,crowd_cost as fundForCrowd,demand_type as demandType,
+    d.picture_url as pictureUrl,d.picture_url_min as pictureUrlMin,
+    data_category as dataCategory,validity_period as validityPeriod
+    from demand d
+    left join demand_publish dp on dp.demand_id=d.id
+    where  d.audit_status=2 and info_sources=1 and dp.demand_id=d.id
+    and dp.publish_page =#{2}
     <if test="#{3} != null">
-    and d.deleted_sign = #{3}
+      and d.deleted_sign = #{3}
     </if>
     order by  release_date  desc limit #{0}
   </select>
-  
+
    <select id="getAreaDemand" resultType="com.goafanti.demand.bo.DemandListBo">
-select name,picture_url as pictureUrl ,problem_des as problemDes , data_category as dataCategory,d.id from demand d 
+select name,picture_url as pictureUrl ,problem_des as problemDes , data_category as dataCategory,d.id from demand d
        left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
 left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
   where d.demand_type=4 and d.audit_status=2 and info_sources=1  and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
   order by  release_date  desc limit #{0}
   </select>
-  
+
    <select id="getProLearnStudyDemand" resultType="com.goafanti.demand.bo.DemandListBo">
-    select d.name as name,picture_url as pictureUrl ,problem_des as problemDes,employer_name as employerName,d.id,fg.name as industryCategory1,data_category as dataCategory,fgg.name as industryCategory2 from demand d  
+    select d.name as name,picture_url as pictureUrl ,problem_des as problemDes,employer_name as employerName,d.id,fg.name as industryCategory1,data_category as dataCategory,fgg.name as industryCategory2 from demand d
     left join industry_category  fg  on fg.id=d.industry_category_a
     left join industry_category fgg  on fgg.id=d.industry_category_b
            left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
-left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id 
+left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
  where d.demand_type=2 and d.audit_status=2 and info_sources=1  and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
  order by  release_date  desc limit #{0}
   </select>
    <select id="getFundCrowdDemand" resultType="com.goafanti.demand.bo.DemandListBo">
-  select d.name,picture_url as pictureUrl ,problem_des as problemDes ,d.id,crowd_cost as fundForCrowd,data_category as dataCategory,research_type as researchType from demand d  
+  select d.name,picture_url as pictureUrl ,problem_des as problemDes ,d.id,crowd_cost as fundForCrowd,data_category as dataCategory,research_type as researchType from demand d
              left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
-left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id 
+left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
   where d.demand_type=3 and d.audit_status=2 and info_sources=1 and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
-  order by  release_date 
+  order by  release_date
    desc limit #{0}
   </select>
-  
+
    <select id="getPersonnelDemand" resultType="com.goafanti.demand.bo.DemandListBo">
-  select d.name,picture_url as pictureUrl ,problem_des as problemDes ,d.id,data_category as dataCategory,budget_cost as fundForPersonnel from demand d  
+  select d.name,picture_url as pictureUrl ,problem_des as problemDes ,d.id,data_category as dataCategory,budget_cost as fundForPersonnel from demand d
  left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
-left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id 
+left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
   where d.demand_type=5 and d.audit_status=2 and info_sources=1 and dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
   order by  release_date  desc limit #{0}
   </select>
-  
+
  <select id="getDemandDetail" resultType="com.goafanti.demand.bo.DemandListBo">
   select d.name,d.budget_cost as budgetCost,d.validity_period as validityPeriod,data_category as dataCategory,d.picture_url as pictureUrl,problem_des as problemDes,
   fg.name as industryCategory1,fgg.name as industryCategory2,u.identify_name as employerName
@@ -1129,11 +1127,11 @@ left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchI
  select d.id,d.name,picture_url as picture_url,data_category as dataCategory,problem_des as problemDes
  from demand d
  left join branch_information branchInfo on INSTR(#{1},branchInfo.domain_name)>0
-left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id 
+left join demand_publish dp on dp.demand_id=d.id and dp.publish_platform=branchInfo.id
 where info_sources=1 and d.boutique=1 and  dp.demand_id=d.id and dp.publish_platform=branchInfo.id and instr(dp.publish_page,#{2})>0
 order by release_date desc limit #{0}
-  </select> 
-  
+  </select>
+
   <select id="listMyDemand" resultType="com.goafanti.portal.bo.DemandSearchListBo">
 	select
 		id,
@@ -1160,7 +1158,7 @@ order by release_date desc limit #{0}
 		and create_time <![CDATA[ < ]]>  #{endDate,jdbcType=VARCHAR}
 	</if>
   </select>
-  
+
     <select id="searchDemandList" resultType="com.goafanti.demand.bo.DemandListBo">
   select a.name,a.id,create_time as createTime ,picture_url as pictureUrl,data_category as dataCategory,is_hot as isHot,demand_type as demandType,
   industry_category_a as industryCategoryA,industry_category_b as industryCategoryB,ic.name as industryCategory1,icc.name as industryCategory2,a.release_date as releaseDate
@@ -1201,8 +1199,8 @@ order by release_date desc limit #{0}
    and a.deleted_sign = #{deletedSign,jdbcType=INTEGER}
   </if>
   </select>
-  
-  
+
+
   <select id="findInterestedDemand" resultType="com.goafanti.demand.bo.DemandListBo">
    select a.name,a.id,a.create_time as createTime ,picture_url as pictureUrl,data_category as dataCategory,is_hot as isHot,demand_type as demandType,
   industry_category_a as industryCategoryA,industry_category_b as industryCategoryB,a.release_date as releaseDate,problem_des as problemDes
@@ -1238,7 +1236,7 @@ order by release_date desc limit #{0}
    select count(0)
    from demand a
    left join demand_interest di on di.demand_id=a.id
-     where a.deleted_sign=0 
+     where a.deleted_sign=0
    and di.uid= #{uid,jdbcType=VARCHAR}
    </select>
   </mapper>

+ 41 - 41
src/main/java/com/goafanti/common/mapper/NewsMapper.xml

@@ -15,31 +15,31 @@
     <result column="summary" jdbcType="VARCHAR" property="summary" />
     <result column="jmrh_flag" jdbcType="INTEGER" property="jmrhFlag" />
     <result column="province_id" jdbcType="INTEGER" property="provinceId" />
-    <result column="keyword" jdbcType="VARCHAR" property="keyword" /> 
+    <result column="keyword" jdbcType="VARCHAR" property="keyword" />
   </resultMap>
   <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.goafanti.common.model.News">
     <result column="content" jdbcType="LONGVARCHAR" property="content" />
   </resultMap>
   <sql id="Base_Column_List">
-    id, create_time, edit_time, title, title_img, author, type, hot, source, source_url, 
+    id, create_time, edit_time, title, title_img, author, type, hot, source, source_url,
     summary,jmrh_flag,province_id,keyword
   </sql>
   <sql id="Blob_Column_List">
     content
   </sql>
   <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultType="com.goafanti.news.bo.NewsResult">
-    select 
+    select
     n.id,
     n.content,
-    n.create_time as createTime, 
-    n.edit_time as editTime, 
-    n.title, 
-    n.title_img as titleImg, 
-    n.author, 
-    n.type, 
+    n.create_time as createTime,
+    n.edit_time as editTime,
+    n.title,
+    n.title_img as titleImg,
+    n.author,
+    n.type,
     n.hot,
-    n.source, 
-    n.source_url as sourceUrl, 
+    n.source,
+    n.source_url as sourceUrl,
     n.summary,
     n.province_id as provinceId,
     n.audit_status as auditStatus,
@@ -56,14 +56,14 @@
     where id = #{id,jdbcType=BIGINT}
   </delete>
   <insert id="insert" parameterType="com.goafanti.common.model.News">
-    insert into news (id, create_time, edit_time, 
-      title, title_img, author, 
-      type, hot, source, 
+    insert into news (id, create_time, edit_time,
+      title, title_img, author,
+      type, hot, source,
       source_url, summary, content,province_id,top_number,hotspot,audit_status,release_status,release_date,keyword
       )
-    values (#{id,jdbcType=BIGINT}, #{createTime,jdbcType=TIMESTAMP}, #{editTime,jdbcType=TIMESTAMP}, 
-      #{title,jdbcType=VARCHAR}, #{titleImg,jdbcType=VARCHAR}, #{author,jdbcType=VARCHAR}, 
-      #{type,jdbcType=INTEGER}, #{hot,jdbcType=INTEGER}, #{source,jdbcType=VARCHAR}, 
+    values (#{id,jdbcType=BIGINT}, #{createTime,jdbcType=TIMESTAMP}, #{editTime,jdbcType=TIMESTAMP},
+      #{title,jdbcType=VARCHAR}, #{titleImg,jdbcType=VARCHAR}, #{author,jdbcType=VARCHAR},
+      #{type,jdbcType=INTEGER}, #{hot,jdbcType=INTEGER}, #{source,jdbcType=VARCHAR},
       #{sourceUrl,jdbcType=VARCHAR}, #{summary,jdbcType=VARCHAR}, #{content,jdbcType=LONGVARCHAR},
       #{provinceId,jdbcType=INTEGER}, #{topNumber,jdbcType=INTEGER}, #{hotspot,jdbcType=INTEGER},#{auditStatus,jdbcType=INTEGER},
       #{releaseStatus,jdbcType=INTEGER},#{releaseDate,jdbcType=TIMESTAMP},#{keyword,jdbcType=VARCHAR}
@@ -276,38 +276,38 @@
 			a.summary,
 			a.source,
 			a.content,
-			release_date as releaseDate
+            a.release_date  as releaseDate
 		from news a
 		where 1=1
-		 and (a.type = 0 or a.type = 99 or a.type =98) 
+		 and (a.type = 0 or a.type = 99 or a.type =98)
 		<if test="provinceId != null">
 			and a.province_id = #{provinceId,jdbcType=INTEGER}
 		</if>
 		<if test="type != null" >
 			and a.type = #{type,jdbcType=INTEGER}
 		</if>
-		<!-- 
+		<!--
 		<if test="hot != null">
 			and a.hot = #{hot,jdbcType=INTEGER}
-		</if> 
+		</if>
 		-->
 		<if test="keyword != null">
 			and a.title like concat('%',#{keyword},'%')
 		</if>
 		<if test="auditStatus!=null">
 		and a.audit_status=#{auditStatus,jdbcType=INTEGER}
-		</if>	
+		</if>
 		order by release_date desc
 		<if test="page_sql != null">
 			${page_sql}
 		</if>
 	</select>
-	
+
 	<select id="portalNewsCount" resultType="java.lang.Integer">
-		select 
+		select
 			count(0)
 		from news a
-		where 
+		where
 		(a.type = 0 or a.type = 99 or a.type =98)
 		<if test="provinceId != null">
 			and a.province_id = #{provinceId,jdbcType=INTEGER}
@@ -315,7 +315,7 @@
 		<if test="type != null and type != 0 and type != 1 and type != 2" >
 			and a.type = #{type,jdbcType=INTEGER}
 		</if>
-		<!-- 	
+		<!--
 		<if test="hot != null">
 			and a.hot = #{hot,jdbcType=INTEGER}
 		</if>
@@ -325,7 +325,7 @@
 		</if>
 		<if test="auditStatus!=null">
 		and a.audit_status=#{auditStatus,jdbcType=INTEGER}
-		</if>	
+		</if>
 	</select>
 	<select id="portalNewsPolicy" resultType="com.goafanti.news.bo.NewsPortalList">
 		select
@@ -366,9 +366,9 @@
 	LEFT  join news n on ni.new_id=n.id
 	where uid=#{uid,jdbcType=VARCHAR}
 	</select>
-	
-	
-	
+
+
+
 <select id="getNewsList" resultType="com.goafanti.common.model.News">
 select
 	title,
@@ -378,17 +378,17 @@ from
 	news
 order by
 	create_time desc limit #{0}
-</select>	
+</select>
 <select id="getPolicyDetail" resultType="com.goafanti.common.bo.PolicyEntity">
-select p.id,p.title,p.title_img as titleImg,p.summary,
-p.content,dg1.name as provinceS,dg2.name as cityS,edit_time as editTime ,create_time as createTime,p.id,p.source,p.source_url as sourceUrl from policy p 
+select p.id,p.title,p.title_img as titleImg,p.summary,p.release_date as releaseDate,
+p.content,dg1.name as provinceS,dg2.name as cityS,edit_time as editTime ,create_time as createTime,p.id,p.source,p.source_url as sourceUrl from policy p
 left join district_glossory dg1 on dg1.id=p.province
 left join district_glossory dg2 on dg2.id=p.city
 where audit_status = 2 and p.id=#{0}
 </select>
 
-	
-	
+
+
 	<select id="selectTypeNewsList" resultType="com.goafanti.app.bo.AppDiscoveryBo">
 		select
 			a.id,
@@ -399,7 +399,7 @@ where audit_status = 2 and p.id=#{0}
 		from news a
 		left join district_glossory d on a.province_id=d.id
 		where audit_status=2
-		<if test="type != null"> 
+		<if test="type != null">
 		and a.type =#{type}
 		</if>
 		order by a.release_date desc
@@ -407,17 +407,17 @@ where audit_status = 2 and p.id=#{0}
 			${page_sql}
 		</if>
 	</select>
-	
+
 	<select id="selectTypeNewsCount" resultType="java.lang.Integer">
-		select 
+		select
 			count(0)
 		from news a
 		left join district_glossory d on a.province_id=d.id
-		where audit_status=2 
-		<if test="type != null"> 
+		where audit_status=2
+		<if test="type != null">
 		and a.type =#{type}
 		</if>
 	</select>
 
 
-</mapper>
+</mapper>

+ 2 - 1
src/main/java/com/goafanti/common/model/Policy.java

@@ -9,6 +9,7 @@ import javax.validation.constraints.Size;
 import com.fasterxml.jackson.annotation.JsonFormat;
 import com.fasterxml.jackson.annotation.JsonFormat.Shape;
 import com.goafanti.common.constant.ErrorConstants;
+import org.springframework.format.annotation.DateTimeFormat;
 
 public class Policy {
 
@@ -399,4 +400,4 @@ public class Policy {
 	public void setKeyword(String keyword) {
 		this.keyword = keyword;
 	}
-}
+}

+ 26 - 18
src/main/java/com/goafanti/news/bo/InputNews.java

@@ -9,70 +9,78 @@ import javax.validation.constraints.Size;
 import com.goafanti.common.constant.ErrorConstants;
 
 public class InputNews {
-	
+
 	private Long	id;
-	
+
 	Date releaseDate;
 	Date createTime;
 	@Size(min = 0, max = 45, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String	title;
-	
+
 	@Size(min = 0, max = 128, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String	titleImg;
-	
+
 	@Size(min = 0, max = 45, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String	author;
-	
+
 	@Max(value = 99, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	@Min(value = 0, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	private Integer	type;
-	
+
 	@Max(value = 1, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	@Min(value = 0, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	private Integer	hot;
-	
+
 	@Size(min = 0, max = 45, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String	source;
-	
+
 	@Size(min = 0, max = 255, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String	sourceUrl;
-	
+
 	@Size(min = 0, max = 144, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String	summary;
-	
+
 	@Max(value = 1, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	@Min(value = 0, message = "{" + ErrorConstants.PARAM_ERROR + "}")
     private Integer jmrhFlag;
-	
+
 	@Max(value = 34, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	@Min(value = 0, message = "{" + ErrorConstants.PARAM_ERROR + "}")
 	private Integer provinceId;
-	
+
 	private String	content;
-	
+
 	/**
 	 * 审核状态
 	 */
 	private Integer auditStatus;
-	
+
 	/**
 	 * 是否发布
 	 */
 	private Integer releaseStatus;
-	
+
 	/**
 	 * 置顶
 	 */
 	private Integer topNumber;
-	
+
 	/**
 	 * 热门
 	 */
 	private Integer hotspot;
 	@Size(min = 0, max = 64, message = "{" + ErrorConstants.PARAM_SIZE_ERROR + "}")
 	private String keyword;
-	
-	
+
+	private String releaseDateStr;
+
+	public String getReleaseDateStr() {
+		return releaseDateStr;
+	}
+
+	public void setReleaseDateStr(String releaseDateStr) {
+		this.releaseDateStr = releaseDateStr;
+	}
 
 	public Date getReleaseDate() {
 		return releaseDate;

+ 18 - 6
src/main/java/com/goafanti/news/bo/NewsPortalList.java

@@ -4,9 +4,9 @@ package com.goafanti.news.bo;
 public class NewsPortalList extends NewsSummary {
 
 	private String	content;
-	
+
 	private String title;
-	
+
 	private String DataS;
 
 	private String source;
@@ -14,11 +14,23 @@ public class NewsPortalList extends NewsSummary {
 	 * 置顶
 	 */
 	private Integer topNumber;
-	
+
 	/**
 	 * 热门
 	 */
 	private Integer hotspot;
+	/**
+	 * 发布时间
+	 */
+	private String releaseDate;
+
+	public String getReleaseDate() {
+		return releaseDate;
+	}
+
+	public void setReleaseDate(String releaseDate) {
+		this.releaseDate = releaseDate;
+	}
 
 	public String getTitle() {
 		return title;
@@ -35,7 +47,7 @@ public class NewsPortalList extends NewsSummary {
 	public void setContent(String content) {
 		this.content = content;
 	}
-	
+
 	public String getSource() {
 		return source;
 	}
@@ -67,7 +79,7 @@ public class NewsPortalList extends NewsSummary {
 	public void setHotspot(Integer hotspot) {
 		this.hotspot = hotspot;
 	}
-	
-	
+
+
 
 }

+ 3 - 11
src/main/java/com/goafanti/news/bo/NewsSummary.java

@@ -43,17 +43,17 @@ public class NewsSummary {
 	 * 简介
 	 */
 	private String	summary;
-	
+
 	/**
 	 * 来源
 	 */
 	private String	source;
-	
+
 	/**
 	 * 审核状态
 	 */
 	private Integer auditStatus;
-	
+
 	/**
 	 * 是否发布
 	 */
@@ -161,14 +161,6 @@ public class NewsSummary {
 		}
 	}
 
-	public void setCreateTimeFormattedDate(String createTimeFormattedDate) {
-
-	}
-	public void setCreateTimeFormattedDate_md(String createTimeFormattedDate) {
-
-	}
-	public void setCreateTimeFormattedDate_y(String createTimeFormattedDate) {
 
-	}
 
 }

+ 35 - 26
src/main/java/com/goafanti/news/controller/AdminNewsApiController.java

@@ -47,7 +47,7 @@ public class AdminNewsApiController extends BaseApiController {
 	@Autowired
 	private JDBCIdGenerator	idGenerator;
 
-	
+
 	/**
 	 * 新闻列表
 	 */
@@ -56,7 +56,7 @@ public class AdminNewsApiController extends BaseApiController {
 			String source, Integer hot, String pageSize, String pageNo,String auditStatus,String releaseStatus,String publishPage) {
 		Result res = new Result();
 //		if (null == type) {
-//			res.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR, "", "新闻类型"));  
+//			res.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR, "", "新闻类型"));
 //			return res;
 //		}
 		Integer pNo = 1;
@@ -67,7 +67,7 @@ public class AdminNewsApiController extends BaseApiController {
 		if (StringUtils.isNumeric(pageNo)) {
 			pNo = Integer.parseInt(pageNo);
 		}
-		res.setData(newsService.listNews(type, title, author, startCreateTime, endCreateTime, source, hot, pNo, pSize,auditStatus,releaseStatus,publishPage,null)); 
+		res.setData(newsService.listNews(type, title, author, startCreateTime, endCreateTime, source, hot, pNo, pSize,auditStatus,releaseStatus,publishPage,null));
 		return res;
 	}
 
@@ -86,13 +86,13 @@ public class AdminNewsApiController extends BaseApiController {
 		if (!res.getError().isEmpty()) {
 			return res;
 		}
-		newsService.save(idGenerator.generateId(), (News) res.getData()); 
+		newsService.save(idGenerator.generateId(), (News) res.getData());
 		return res;
 	}
-	
+
 /*
  * 新增
- * 
+ *
  * */
 	@RequestMapping(value="/apply",method=RequestMethod.POST)
 public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] publishPages) {
@@ -100,7 +100,7 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 		if (bindingResult.hasErrors()) {
 			result.getError().add(
 					buildErrorByMsg(bindingResult.getFieldError()
-							.getDefaultMessage(), NewsFields 
+							.getDefaultMessage(), NewsFields
 							.getFieldDesc(bindingResult.getFieldError()
 									.getField())));
 			return result;
@@ -121,22 +121,22 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 		if(news.getType()==null)
 		news.setType(0);
 		BeanUtils.copyProperties(news, news2);
-		result.setData(newsService.save( news2,webPages,appPages)); 
+		result.setData(newsService.save( news2,webPages,appPages));
 		return result;
 	}
-	
+
 	/*
 	 * 修改
-	 * 
+	 *
 	 * */
 		@RequestMapping(value="/updateNews",method=RequestMethod.POST)
 	public Result updateNews(@Valid InputNews news,BindingResult bindingResult,String[] publishPages) {
 			Result result=new Result();
-			
+
 			if (bindingResult.hasErrors()) {
 				result.getError().add(
 						buildErrorByMsg(bindingResult.getFieldError()
-								.getDefaultMessage(), NewsFields 
+								.getDefaultMessage(), NewsFields
 								.getFieldDesc(bindingResult.getFieldError()
 										.getField())));
 				return result;
@@ -150,15 +150,24 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 			}
 			news.setCreateTime(new Date());
 			if(news.getAuditStatus() == 2) {
-				news.setReleaseDate(new Date());
+				if (news.getReleaseDateStr() !=null){
+					try {
+						news.setReleaseDate(DateUtils.parseDate(news.getReleaseDateStr(),AFTConstants.YYYYMMDDHHMMSS));
+					} catch (ParseException e) {
+						e.printStackTrace();
+					}
+				}else {
+					news.setReleaseDate(new Date());
+				}
+
 			}
 			News news2=new News();
 			BeanUtils.copyProperties(news, news2);
-			result.setData(newsService.updateSelectively( news2,webPages,appPages)); 
+			result.setData(newsService.updateSelectively( news2,webPages,appPages));
 			//publishPages
 			return result;
 		}
-	
+
 
 	/*
 	 * 变更发布状态、发布时间
@@ -183,10 +192,10 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 				}
 				news.setReleaseDate(new Date());}
 			if(auditStatus!=null) {
-				news.setAuditStatus(auditStatus); 
+				news.setAuditStatus(auditStatus);
 			if(auditStatus ==2){
 				news.setReleaseDate(new Date());
-				
+
 				newsService.updateJtCollectSearch(news);
 				newsService.addJtCollectSearch(news);
 				}
@@ -194,13 +203,13 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 				newsService.updateJtCollectSearch(news);
 				}
 			}
-			
-			result.setData(newsService.updateSelectivelyWithoutPages(news));  
+
+			result.setData(newsService.updateSelectivelyWithoutPages(news));
 			return result;
-			
+
 		}
-		
-		
+
+
 	private void checkApplyParams(InputNews news, List<String>webPages,List<String>appPages, Result result) {
 	/*if(webPages.size()<1 && appPages.size()<1)
 	{
@@ -224,7 +233,7 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 		result.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR,"","是否热门"));
 		return;
 	}
-	
+
 }
 
 	/**
@@ -262,7 +271,7 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 			res.getError().add(buildError(ErrorConstants.PARAM_EMPTY_ERROR, "", "新闻Id"));
 			return res;
 		}
-		res.setData(newsService.findNewsDetail(id));  
+		res.setData(newsService.findNewsDetail(id));
 		return res;
 	}
 
@@ -288,7 +297,7 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 		if (id == null) {
 			res.getError().add(buildError(ErrorConstants.PARAM_ERROR, "", ""));
 		} else {
-			res.setData(newsService.deleteByPrimaryKey(id)); 
+			res.setData(newsService.deleteByPrimaryKey(id));
 		}
 		return res;
 	}
@@ -331,7 +340,7 @@ public Result apply(@Valid InputNews news,BindingResult bindingResult,String[] p
 		}
 		return res;
 	}
-	
+
 
 	private Result disposeInputNews(Result res, InputNews news, String createTimeFormattedDate) {
 		if (StringUtils.isBlank(news.getTitle())) {

+ 42 - 29
src/main/java/com/goafanti/news/controller/AdminPolicyApiController.java

@@ -1,5 +1,6 @@
 package com.goafanti.news.controller;
 
+import java.text.ParseException;
 import java.util.ArrayList;
 import java.util.Date;
 import java.util.HashMap;
@@ -9,9 +10,13 @@ import java.util.Map;
 import javax.annotation.Resource;
 import javax.validation.Valid;
 
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.goafanti.common.constant.AFTConstants;
+import com.goafanti.common.utils.DateUtils;
 import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.validation.BindingResult;
+import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMethod;
 import org.springframework.web.bind.annotation.RestController;
@@ -33,14 +38,14 @@ import com.goafanti.news.service.PolicyService;
 @RestController
 @RequestMapping(value = "/api/admin/policy")
 public class AdminPolicyApiController extends BaseApiController {
-	
+
 	@Autowired
 	private JDBCIdGenerator	idGenerator;
 	@Resource
 	private PolicyService policyService;
 	/*
 	 * 新增
-	 * 
+	 *
 	 * */
 		@RequestMapping(value="/apply",method=RequestMethod.POST)
 		public Result insertPolicy(@Valid Policy policy,String[]publishPages,BindingResult bindingResult) {
@@ -48,7 +53,7 @@ public class AdminPolicyApiController extends BaseApiController {
 			if (bindingResult.hasErrors()) {
 				result.getError().add(
 						buildErrorByMsg(bindingResult.getFieldError()
-								.getDefaultMessage(), NewsFields 
+								.getDefaultMessage(), NewsFields
 								.getFieldDesc(bindingResult.getFieldError()
 										.getField())));
 				return result;
@@ -72,12 +77,11 @@ public class AdminPolicyApiController extends BaseApiController {
 			policy.setType(0);
 			if(policy.getAuditStatus()!=null &&policy.getAuditStatus() == 2) {
 				policy.setReleaseDate(new Date());
-			
 			}
 			result.setData(policyService.saveNewPolicy(policy, webPages, appPages));
 			return result;
 		}
-		
+
 
 		private void disposePolicyParams(Policy policy,Result result) {
 			if(StringUtils.isBlank(policy.getTitle())) {
@@ -102,9 +106,9 @@ public class AdminPolicyApiController extends BaseApiController {
 		}
 		/*
 		 * 删除
-		 * 
+		 *
 		 * */
-		
+
 		@RequestMapping(value="/delete",method=RequestMethod.POST)
 		public Result deleteById(Long id) {
 			Result result=new Result();
@@ -118,7 +122,7 @@ public class AdminPolicyApiController extends BaseApiController {
 			}
 			return result;
 		}
-		
+
 		/*
 		 * 详情
 		 * */
@@ -131,18 +135,18 @@ public class AdminPolicyApiController extends BaseApiController {
 			result.setData(policyService.getPolicyDetail(id));
 			return result;
 		}
-		
+
 		/*
 		 * 修改
-		 * 
+		 *
 		 * */
 			@RequestMapping(value="/update",method=RequestMethod.POST)
-		public Result updateNews(@Valid Policy policy,BindingResult bindingResult,String[] publishPages) {
+		public Result updateNews( @Valid Policy policy, BindingResult bindingResult, String[] publishPages, String releaseDateStr) {
 				Result result=new Result();
 				if (bindingResult.hasErrors()) {
 					result.getError().add(
 							buildErrorByMsg(bindingResult.getFieldError()
-									.getDefaultMessage(), NewsFields 
+									.getDefaultMessage(), NewsFields
 									.getFieldDesc(bindingResult.getFieldError()
 											.getField())));
 					return result;
@@ -159,24 +163,33 @@ public class AdminPolicyApiController extends BaseApiController {
 					return result;
 				}
 				if(policy.getAuditStatus()!=null ) {
-					policy.setReleaseDate(new Date());
+
+
 					if(policy.getAuditStatus() ==2){
-						policy.setReleaseDate(new Date());
+						if (releaseDateStr !=null){
+							try {
+								policy.setReleaseDate(DateUtils.parseDate(releaseDateStr, AFTConstants.YYYYMMDDHHMMSS));
+							} catch (ParseException e) {
+								e.printStackTrace();
+							}
+						}else {
+							policy.setReleaseDate(new Date());
+						}
 						policyService.addJtCollectSearch(policy);
 						}
 					if(policy.getAuditStatus()==4) {
 						policyService.updateJtCollectSearch(policy);
 					}
-					
+
 				}
 				policy.setEditTime(new Date());
-		
-				result.setData(policyService.updateSelectively( policy,webPages,appPages)); 
-	
+
+				result.setData(policyService.updateSelectively( policy,webPages,appPages));
+
 				return result;
 			}
-			
-			
+
+
 			/*
 			 * 变更发布状态、发布时间
 			 * */
@@ -199,7 +212,7 @@ public class AdminPolicyApiController extends BaseApiController {
 						}
 						policy.setReleaseDate(new Date());}
 					if(auditStatus!=null) {
-						policy.setAuditStatus(auditStatus); 
+						policy.setAuditStatus(auditStatus);
 					if(auditStatus ==2){
 						policy.setReleaseDate(new Date());
 						policyService.updateJtCollectSearch(policy);
@@ -209,12 +222,12 @@ public class AdminPolicyApiController extends BaseApiController {
 						policyService.updateJtCollectSearch(policy);
 					}
 					}
-					
-					result.setData(policyService.updateSelectivelyWithoutPages(policy));  
+
+					result.setData(policyService.updateSelectivelyWithoutPages(policy));
 					return result;
-					
+
 				}
-				
+
 				/*
 				 * 政策搜索
 				 * */
@@ -226,8 +239,8 @@ public class AdminPolicyApiController extends BaseApiController {
 					result.setData(policyService.searchPolicy(title,auditStatus,startReleaseDate,endReleaseDate,publishPage,pageNo,pageSize,null));
 					return result;
 				}
-				
-				
-		
-		
+
+
+
+
 }

+ 17 - 12
src/main/resources/props/config_local.properties

@@ -1,11 +1,11 @@
 
 jdbc.driverClassName=com.mysql.jdbc.Driver
-#jdbc.url=jdbc:mysql://localhost:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
-#jdbc.username=dev
-#jdbc.password=123456
-jdbc.url=jdbc:mysql://101.37.32.31:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
+jdbc.url=jdbc:mysql://localhost:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
 jdbc.username=root
-jdbc.password=aftdev
+jdbc.password=123456
+#jdbc.url=jdbc:mysql://101.37.32.31:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
+#jdbc.username=root
+#jdbc.password=aftdev
 jdbc.validationQuery=SELECT 'x'
 jdbc.initialSize=3
 jdbc.maxActive=20
@@ -38,16 +38,21 @@ app.name=AFT
 app.mobile.website=http://m.jishutao.com/1.0/template/index.html
 template.cacheable=false
 
-static.host=//statics.jishutao.com/client/1.2.7
-portal.host=//statics.jishutao.com/portal/1.2.9
-skjt.host=//statics.jishutao.com/skjt/1.3
+#static.host=//ss.jishutao.com/client/1.2.8
+#portal.host=//ss.jishutao.com/portal/1.2.11
+skjt.host=//ss.jishutao.com/skjt/1.3
+
 
 #本地
-#static.host=//sclient.jishutao.com:8088/client/1.0.2
-#portal.host=//sportal.jishutao.com:80/portal/1.0.2
+#static.host=//172.16.0.255/client/1.2.8
+static.host=//172.16.0.255:3000/jitao/client/1.2.9
+portal.host=//172.16.0.255:3000/jitao/portal/1.2.11
+
+#avatar.host=//ss.jishutao.com
+#avatar.upload.host=//ss.jishutao.com/upload
 
-avatar.host=//ss.jishutao.com
-avatar.upload.host=//ss.jishutao.com/upload
+avatar.host=//172.16.0.255:3000
+avatar.upload.host=//172.16.0.255:3000/upload
 
 upload.path=F:/data/public/upload
 upload.private.path=F:/data/private/upload

+ 10 - 11
src/main/resources/spring/spring-mvc.xml

@@ -25,21 +25,20 @@
 	</bean>
 	
 	<!-- spring bean validator -->
+	
+<!-- 配置注解驱动 -->
+	<mvc:annotation-driven validator="validator"></mvc:annotation-driven>
+	
+	<!-- 校验器 -->
 	<bean id="validator"
 		class="org.springframework.validation.beanvalidation.LocalValidatorFactoryBean">
+		<!-- hibernate校验器-->
 		<property name="providerClass" value="org.hibernate.validator.HibernateValidator" />
+		<!-- 指定校验使用的资源文件,在文件中配置校验错误信息,如果不指定则默认使用classpath下的ValidationMessages.properties -->
 		<property name="validationMessageSource" ref="messageSource" />
-	</bean>
-
-	<mvc:annotation-driven validator="validator" />
-
-	<bean
-		class="org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor">
-		<property name="securityManager" ref="securityManager" />
-	</bean>
-
-
-
+	</bean>	
+	
+	<!-- 校验错误信息配置文件 -->
 	<bean id="messageSource"
 		class="org.springframework.context.support.ReloadableResourceBundleMessageSource">
 		<property name="defaultEncoding" value="UTF-8"></property>

+ 19 - 14
src/main/webapp/WEB-INF/views/common.html

@@ -7,8 +7,8 @@
   <meta charset="UTF-8">
   <link rel="shortcut icon " type="images/x-icon" th:href="${portalHost+ '/img/ico_logo.png'}">
   <meta name="Keywords" content="高新技术企业认定_双软评估_军工认证_知识产权贯标_知识产权转移_科德"/>
-  <meta name="Description" content="科德信息咨询有限公司17年来专注于国家高新技术企业认定,知识产权贯标,知识产权转移,双软评估,
-	体系认证,专利申请,军工三证,工程技术研究中心,创新小巨人等湖南省市科技项目申报、成果转化的信息咨询旗舰企业,获得政府部门权威认证的咨询服务机构."/>
+  <meta name="Description" th:content="${'科德信息咨询有限公司'+yearCount+'年来专注于国家高新技术企业认定,知识产权贯标,知识产权转移,双软评估,
+	体系认证,专利申请,军工三证,工程技术研究中心,创新小巨人等湖南省市科技项目申报、成果转化的信息咨询旗舰企业,获得政府部门权威认证的咨询服务机构.'}"/>
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   <meta http-equiv="X-UA-Compatible" content="ie=edge">
   <th:block th:replace="${link}" />
@@ -67,7 +67,7 @@
 		<div class="navWrapper webkitHover">
 			<ol>
 				<li>
-					<div>知识产权申请</div>
+					<div>技术交易</div>
 					<span>
 						<img th:src="${portalHost+'/img/index/index_webkit1.png'}" alt="">
 					</span>
@@ -89,7 +89,7 @@
 
 				</li>
 				<li>
-					<div>知识产权运用</div>
+					<div>科技传播</div>
 					<span>
 						<img th:src="${portalHost+'/img/index/index_webkit2.png'}" alt="">
 					</span>
@@ -112,7 +112,7 @@
 					</p>
 				</li>
 				<li>
-					<div>知识产权交易</div>
+					<div>科技咨询</div>
 					<span>
 						<img th:src="${portalHost+'/img/index/index_webkit3.png'}" alt="">
 					</span>
@@ -207,24 +207,24 @@
                     </li>
                     <li th:class="${subM}=='apply'?active:''" >
                     <div>
-                        <a th:href="@{/portal/service/patent}">申请</a>
+                        <a th:href="@{/portal/service/patent}">技术交易</a>
 
                        </div>
                     </li>
                     <li th:class="${subM}=='serviceIndex'?active:''" >
                     <div>
-                        <a th:href="@{/portal/service/serviceIndex}">运用</a>
+                        <a th:href="@{/portal/service/serviceIndex}">科技传播</a>
 
                        </div>
                     </li>
                     <li th:class="${subM}=='adviser'?active:''" >
                        <div>
-                         <a th:href="@{/portal/adviser}">顾问</a>
+                         <a th:href="@{/portal/adviser}">科技咨询</a>
                        </div>
                     </li>
                     <li th:class="${subM}=='trading'?active:''" >
                    		 <div>
-	                        <a th:href="@{/portal/technologyTrading/tradingIndex}">交易</a>
+	                        <a th:href="@{/portal/technologyTrading/tradingIndex}">绿色金融</a>
 	 						<!-- <ol class="subnavigation">
 	                            <li>
 	                                 <a th:href="@{/portal/technologyTrading/achievement}">技术成果</a>
@@ -235,11 +235,16 @@
 	                        </ol> -->
                         </div>
                     </li>
-                     <li th:class="${subM}=='safeguarding'?active:''" >
-                     	<div>
-                         <a th:href="@{/portal/service/safeguarding}">维权</a>
-                        </div>
-                     </li>
+					<li th:class="${subM}=='safeguarding'?active:''" >
+						<div>
+							<a th:href="@{/portal/service/safeguarding}">维权</a>
+						</div>
+					</li>
+					<li th:class="${subM}=='eventPlanning'?active:''" >
+						<div>
+							<a th:href="@{/portal/thinkTank/policyList?type=0}" >活动策划</a>
+						</div>
+					</li>
                      <!-- <li th:class="${subM}=='special'?active:''" >
                      	<div>
                          <a th:href="@{/portal/special}">社区</a>

文件差异内容过多而无法显示
+ 49 - 49
src/main/webapp/WEB-INF/views/portal/aboutUs.html


+ 9 - 9
src/main/webapp/WEB-INF/views/portal/contactUs.html

@@ -10,7 +10,7 @@
 <!-- <script type="text/javascript" src="http://api.map.baidu.com/api?key=&v=1.0&services=true"></script> -->
 </head>
 <body>
-	
+
 		<div th:replace="common::nav('','')"></div>
 
 	<!--banner-->
@@ -18,7 +18,7 @@
 		<ul class="ct-img-big clear">
 			<li data-index=0 ><a href=""><img th:src="${portalHost+'/img/contactUs.png'}" alt=""/></a></li>
 			<li data-index=1 ><a href=""><img th:src="${portalHost+'/img/contactUs.png'}" alt=""/></a></li>
-			<li data-index=2 ><a href=""><img th:src="${portalHost+'/img/contactUs.png'}" alt=""/></a></li>		
+			<li data-index=2 ><a href=""><img th:src="${portalHost+'/img/contactUs.png'}" alt=""/></a></li>
 		</ul>
 		<a class="btn btn-next" href="">
 			<img th:src="${portalHost+'/img/index_next.png'}" alt=""/>
@@ -36,18 +36,18 @@
 			<div class="contact_cont">
 				<div class="contact_left">
 					<div class="contact_left_top">
-						
+
 					</div>
 					<div class="contact_left_center">
-						
+
 					</div>
 					<div class="contact_left_bottom">
-						
+
 					</div>
 				</div>
 				<div class="contact_center">
 					<div class="contact_center_top">
-						<h5>湖南科德信息咨询有限公司(总部)</h5>
+						<h5>湖南科德信息咨询集团有限公司(总部)</h5>
 						<p>联 系 人:胡小姐</p>
 						<p>联系电话:400-8800-962</p>
 						<p>邮&nbsp;&nbsp;编:410005</p>
@@ -212,7 +212,7 @@
 						<p>地&nbsp;&nbsp;址:广州市白云区嘉禾望岗望岗大道88号金塬大厦4018</p>
 					</div>
 					<div class="hunandiv">
-						<h5>湖南科德信息咨询有限公司</h5>
+						<h5>湖南科德信息咨询集团有限公司</h5>
 						<p>联 系 人:胡小姐</p>
 						<p>联系电话:400-8800-962</p>
 						<p>邮&nbsp;&nbsp;编:410005</p>
@@ -221,7 +221,7 @@
 					</div>
 				</div>
 			</div>
- 		</div>	
+ 		</div>
  	</div>
   	<!--主体内容区域结束-->
 	<footer>
@@ -234,4 +234,4 @@
 		<script type="text/javascript" th:src="${portalHost + '/contactUs.js'}"></script>
 	</div>
 </body>
-</html>
+</html>

+ 13 - 17
src/main/webapp/WEB-INF/views/portal/index.html

@@ -17,7 +17,7 @@
 <link th:href="${portalHost+'/index.css'}" rel="stylesheet"></head>
 <body>
 	<div th:replace="common::nav('','index')"></div>
-	
+
 	<!-- banner -->
 		<div id="myCarousel" class="carousel" th:if="${#lists.size(bannerlist) eq 1}">
 			<!-- 轮播(Carousel)项目 -->
@@ -50,7 +50,7 @@
 			<a class="carousel-control left" href="#myCarousel" data-slide="prev">&lsaquo;</a>
 			<a class="carousel-control right" href="#myCarousel" data-slide="next">&rsaquo;</a>
 		</div>
-		
+
 	<!-- 	<div class="indexSearch">
 			<ul class="jumpType">
 				<li class="active">成果</li>
@@ -63,11 +63,11 @@
 				<div class="input-group searchDiv">
 					<input type="text" class="form-control demandSearch" placeholder="输入你感兴趣的内容">
 					<img th:src="${portalHost+'/img/newMenu/searchImg.png'}" alt="" class="searchImg">
-				
+
 				</div>
 				 <a  th:href="@{/portal/assessment}" class="zaixian">在线评估</a>
-				 
-				
+
+
 				<a th:href="@{/portal/evaluation/evaluate}" href="/portal/evaluation/evaluate" class="gaoqi">高企自评</a>
 			</div>
 			<ul class="jump">
@@ -90,10 +90,10 @@
 	<!-- 主体内容区域 -->
 	<div id="terrace">
 			<div class="terrace_title">
-			
+
 				<img th:src="${portalHost+'/img/indedImg/inded12.png'}" alt="" />
 			</div>
-			<!-- 
+			<!--
 			<div class="terrace_cont">
 				<div>
 					<img th:src="${portalHost+'/img/indedImg/inded1.png'}" alt="" />
@@ -116,7 +116,7 @@
 					</div>
 				</div>
 			</div>-->
-		</div> 
+		</div>
 		<div id="apply">
 			<div class="apply">
 				<div class="apply_left">
@@ -138,7 +138,7 @@
 					</div>
 				</div>
 			</div>
-			
+
 		</div>
 		<div class="container">
 		<div class="RecommendTitle">
@@ -147,15 +147,11 @@
 		</div>
 		<div class="news">
 			<div class="consultation"  style="width: 1200px;">
-				<a href="/portal/thinkTank/policyList?type=0" style="color: black;position: relative;left: 1120px;font-size: 16px;">更多资讯&gt;&gt;</a>
+				<a href="/portal/thinkTank/policyList?type=0" style="color: black;position: relative;left: 1120px;font-size: 16px;">更多&gt;&gt;</a>
 				<ul style="display: flex; flex-wrap: wrap;">
-					
+
 					<li th:each="n:${news}" style="width: 600px;">
 						<a th:href="@{/portal/news/newsDetail(id=${n.id},type=1)}">
-							<div class="time">
-								<span th:text="${#dates.format(n.releaseDate,'MM-dd')}">03-12</span>
-								<span th:text="${#dates.format(n.releaseDate,'yyyy')}">2018</span>
-							</div>
 							<div class="newTxt">
 								<h5 th:text="${#strings.abbreviate(n.title,18)}">加奖金哦违法爱按金额积分经济积分经济积分经济if啊积分经济交往和居委会看看哇卡哇卡...</h5>
 								<p th:text="${#strings.abbreviate(n.summary,65)}">哈哈哈哈海鸥科技打飞机附近的啊我的㘝技打飞机附近的啊我的技打飞机附近的啊我的技打飞机附近的啊我的技打飞机附近的啊我的酒店设计大姐姐 但是大家觉得结算单基督教圣诞节ajd...</p>
@@ -228,8 +224,8 @@
 				</div>
 			</div>
 		</div>
-	
-		
+
+
 	<footer>
 		<div th:replace="common::copyright"></div>
 		<div th:replace="common::login"></div>

文件差异内容过多而无法显示
+ 9 - 9
src/main/webapp/WEB-INF/views/portal/invitation.html


文件差异内容过多而无法显示
+ 2 - 2
src/main/webapp/WEB-INF/views/portal/news/agreement.html


+ 4 - 4
src/main/webapp/WEB-INF/views/portal/news/newsDetail.html

@@ -17,10 +17,10 @@
 			<div class="content_left" th:each="newsDetail:${newsDetail}">
 				<h3 th:text="${newsDetail.title}?${newsDetail.title}:''"></h3>
 				<div class="small_title">
-					<span>时间:<span th:text="${newsDetail.createTime}?${#dates.format(newsDetail.createTime,'yyyy-MM-dd')}:''"></span></span>
+					<span>时间:<span th:text="${newsDetail.createTime}?${#dates.format(newsDetail.releaseDate,'yyyy-MM-dd')}:''"></span></span>
 					<span>来源:<span th:text="${newsDetail.source}?${newsDetail.source}:行业新闻"></span></span>
 				</div>
-				<div th:each="img:${imgs}" class="content_img">					
+				<div th:each="img:${imgs}" class="content_img">
 					<img th:src="${avatarUploadHost+img}" alt="" />
 				</div>
 				<p th:utext="${newsDetail.content}?${newsDetail.content}:'暂无内容'">
@@ -53,7 +53,7 @@
 				<div th:each="newsList:${newsList}">
 					<h5 ><a th:href="@{/portal/news/newsDetail(id=${newsList.id},type=${type})}"  th:text="${newsList.title}?${newsList.title}:''"></a></h5>
 					 <!-- <img th:src="${avatarUploadHost+newsDetail.titleImg}" alt="" /> -->
-					<p th:text="${newsList.createTime}?${#dates.format(newsList.createTime,'yyyy-MM-dd')}:''"></p>
+					<p th:text="${newsList.releaseDate}?${newsList.releaseDate}:''"></p>
 				</div>
 			</div>
 		</div>
@@ -71,4 +71,4 @@
 </body>
 
 
-</html>
+</html>

文件差异内容过多而无法显示
+ 1 - 1
src/main/webapp/WEB-INF/views/portal/privacyStatement.html


+ 13 - 13
src/main/webapp/WEB-INF/views/portal/service/services.html

@@ -77,7 +77,7 @@
                     <li>
                     	<a th:href="@{/portal/evaluation/evaluate}">
                         <img th:src="${portalHost+'/img/newMenu/serves_1.png'}" alt="">
-                        <span>高企在线评测</span>
+                        <span>技术评估</span>
                         </a>
                     </li>
                     <li class="reldemand">
@@ -87,7 +87,7 @@
                     <li>
                     	<a onclick="openZoosUrl('chatwin');">
                         <img th:src="${portalHost+'/img/newMenu/serves_3.png'}" alt="">
-                        <span>入驻为服务商</span>
+                        <span>技术创业</span>
                         </a>
                     </li>
                 </ul>
@@ -97,7 +97,7 @@
                     <input type="text" class="form-control demandSearch" placeholder="输入你感兴趣的内容">
                     <span class="input-group-btn">
                         <button class="btn btn-default searchBtn" type="button">
-                            <img th:src="${portalHost+'/img/newMenu/search-icon.jpg'}" alt=""> 
+                            <img th:src="${portalHost+'/img/newMenu/search-icon.jpg'}" alt="">
                         </button>
                     </span>
                 </div>
@@ -112,11 +112,11 @@
              <div class="jsLeft">
                  <div>
                      <a onclick="openZoosUrl('chatwin');">立即申请</a>
-                 </div>   
+                 </div>
                  <div>
                      <a onclick="openZoosUrl('chatwin');">立即申请</a>
-                 </div> 
-             </div>  
+                 </div>
+             </div>
              <div class="jsRight">
                  <div>
                      <h3>高新技术企业</h3>
@@ -137,7 +137,7 @@
                     <a onclick="openZoosUrl('chatwin');" class="blur">立即办理贯标业务</a>
                     <a href="/portal/practicalPatent">了解更多贯标知识</a>
                  </div>
-             </div> 
+             </div>
         </div>
     </div>
     <div class="applicationSC">
@@ -166,7 +166,7 @@
                  <div class="Wtitle">
                      <h2>军工市场采购</h2>
                      <span>军队不会选择知识产权有争议的企业产品</span>
-                 </div>  
+                 </div>
                  <div class="applicationShop">
                      <div class="shopLeft">
                          <h3>民参军</h3>
@@ -209,7 +209,7 @@
                             </li>
                         </ul>
                      </div>
-                 </div> 
+                 </div>
             </div>
         </div>
         <div class="applicationGj">
@@ -220,7 +220,7 @@
                     <p th:text="${#strings.abbreviate(i.advertisement,30)}">国际市场开发</p>
                     <a th:href="@{/portal/service/serviceDetail(id=${i.id})}">立即办理</a>
                 </li>
-               
+
             </ul>
         </div>
     </div>
@@ -301,7 +301,7 @@
                     </div>
                     <div class="gfLeftBox">
                         <div th:each="d:${prolist.defenseWeapon}">
-                             <h3 th:text="${d.name}">攻防利器</h3>   
+                             <h3 th:text="${d.name}">攻防利器</h3>
                              <p th:text="${#strings.abbreviate(d.advertisement,40)}">知名大所</p>
                              <a th:href="@{/portal/service/serviceDetail(id=${d.id})}" class="lJ">立即办理</a><br />
                              <a th:href="@{/portal/service/serviceList}" >了解更多</a>
@@ -316,7 +316,7 @@
                 <div class="gfRightList">
                     <ul>
                         <li th:each="o,useStat :${prolist.ownUse}">
-                            <h3 th:text="${o.name}">他山己用</h3>   
+                            <h3 th:text="${o.name}">他山己用</h3>
                             <p th:text="${#strings.abbreviate(o.advertisement,40)}">专利转让</p>
                             <div>
                                 <a th:href="@{/portal/service/serviceDetail(id=${o.id})}" class="ljB">立即办理</a>
@@ -338,4 +338,4 @@
 		<script type="text/javascript" th:src="${portalHost + '/newMenu/services.js'}"></script>
 	</div>
 </body>
-</html>
+</html>

+ 7 - 7
src/main/webapp/WEB-INF/views/portal/thinkTank/policyList.html

@@ -40,11 +40,11 @@
 					<li value='99'>技淘观点</li>
 					<li value='98'>知产百科</li>
 				</ol>
-			</div>	
+			</div>
 			<div class="area">
 				<p>地区</p>
 				<ol>
-					
+
 				</ol>
 				<span class="more">更多+</span>
 			</div>
@@ -52,7 +52,7 @@
 		<div class="listContent">
 			<div class="newLsit">
 				<ul>
-					
+
 				</ul>
 				<div class="pagination_box">
 					<nav aria-label="Page navigation" class="clearfix">
@@ -82,9 +82,9 @@
   					<li th:each="news:${newsList}">
   						<a th:href="@{/portal/news/newsDetail(id=${news.id})}">
    						<p th:text="${#strings.abbreviate(news.title,18)}"></p>
-   						<time th:text="${news.createTimeFormattedDate}"></time>
+   						<time th:text="${news.releaseDate}"></time>
   						</a>
-  					</li>     					
+  					</li>
     			</ul>
 			</div>
 		</div>
@@ -92,7 +92,7 @@
   	<!--主体内容区域结束-->
 	<footer>
 		<div th:replace="common::copyright"></div>
-		<div th:replace="common::login"></div>	
+		<div th:replace="common::login"></div>
 	</footer>
 	<div th:replace="common::footer(~{::script})">
 		<script type="text/javascript" th:src="${portalHost + '/dll/dll.js'}"></script>
@@ -100,4 +100,4 @@
 		<script type="text/javascript" th:src="${portalHost + '/thinkTank/policyList.js'}"></script>
 	</div>
 </body>
-</html>
+</html>

文件差异内容过多而无法显示
+ 27 - 27
src/main/webapp/WEB-INF/views/user/msignIn.html


文件差异内容过多而无法显示
+ 5 - 5
src/main/webapp/WEB-INF/views/user/signIn.html