Quellcode durchsuchen

Merge branch 'master' into test

anderx vor 5 Jahren
Ursprung
Commit
17ed1585a7

+ 4 - 4
src/main/java/com/goafanti/achievement/controller/UserAchievementApiController.java

@@ -83,20 +83,20 @@ public class UserAchievementApiController extends CertifyApiController {
 	}
 
 	/**
-	 * 成果列表
+	 *	成果列表
 	 */
 	@RequestMapping(value = "/list", method = RequestMethod.GET)
 	private Result list(Integer auditStatus, String name, Integer dataCategory,
-		 String startDate, String endDate,
+		 String startDate, String endDate,String cStartDate, String cEndDate,
 		 Integer pageNo, Integer pageSize) {
 		Result res = new Result();
 		res.setData(achievementService.listMyAchievement(auditStatus, name, dataCategory,
-				 startDate, endDate, pageNo, pageSize));
+				 startDate, endDate,cStartDate,  cEndDate, pageNo, pageSize));
 		return res;
 	}
 
 	/**
-	 * 新增成果
+	 * 	新增成果
 	 */
 	@RequestMapping(value = "/apply", method = RequestMethod.POST)
 	private Result apply(@Valid InputAchievement ia, BindingResult bindingResult,

+ 1 - 1
src/main/java/com/goafanti/achievement/service/AchievementService.java

@@ -30,7 +30,7 @@ public interface AchievementService {
 	int deleteByPrimaryKey(List<String> asList);
 
 	Pagination<AchievementObject> listMyAchievement(Integer auditStatus, String name,Integer dataCategory,  String startDate,
-			String endDate,  Integer pNo, Integer pSize);
+			String endDate,  String cStartDate, String cEndDate, Integer pNo, Integer pSize);
 
 	Pagination<AchievementObject> listAchievement(String name,String ownerName,Integer category,Integer dataCategory,Integer auditStatus, 
 			String startDate,String endDate,Integer pageNo,Integer pageSize);

+ 4 - 2
src/main/java/com/goafanti/achievement/service/impl/AchievementServiceImpl.java

@@ -236,11 +236,13 @@ public class AchievementServiceImpl extends BaseMybatisDao<AchievementMapper> im
 	@SuppressWarnings("unchecked")
 	@Override
 	public Pagination<AchievementObject> listMyAchievement(Integer auditStatus, String name,Integer dataCategory, 
-			String startDate,String endDate, Integer pNo, Integer pSize) {
+			String startDate,String endDate,String cStartDate,String cEndDate, Integer pNo, Integer pSize) {
 		Map<String,Object> params = new HashMap<>();
 		params.put("ownerId", TokenManager.getUserId());
 		if (null != startDate) params.put("startDate", startDate);
-		if (null != endDate) params.put("endDate", endDate);
+		if (null != endDate) params.put("endDate", endDate+" 23:59:59");
+		if (null != cStartDate) params.put("cStartDate", cStartDate);
+		if (null != cEndDate) params.put("cEndDate", cEndDate+" 23:59:59");
 		if (null != auditStatus) params.put("auditStatus", auditStatus);
 		if(null != dataCategory) params.put("dataCategory", dataCategory);
 		if (!StringUtils.isBlank(name)) params.put("name", name);

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

@@ -630,7 +630,7 @@ public class AppUserController extends CertifyApiController {
 	 **/
 	@RequestMapping(value="/appAchievementList",method = RequestMethod.GET)
 	public Result msyJtAchievementList(Integer auditStatus, String name,Integer dataCategory,  String startDate,
-			String endDate,  Integer pageNo, Integer pageSize) {
+			String endDate,  String cStartDate, String cEndDate,  Integer pageNo, Integer pageSize) {
 		Result result=new Result();
 		if(null==pageNo||pageNo<0)pageNo=1;
 		if(null==pageSize||pageSize<0)pageSize=10;
@@ -638,7 +638,7 @@ public class AppUserController extends CertifyApiController {
 			result.getError().add(buildError(ErrorConstants.NON_LOGIN, "", ""));return result;
 		}
 		Pagination<AchievementObject> p=achievementService.listMyAchievement(auditStatus, name, dataCategory,
-				 startDate, endDate, pageNo, pageSize);
+				 startDate, endDate,cStartDate, cEndDate, pageNo, pageSize);
 		result.data(p); 
 		return result;
 	}

+ 12 - 0
src/main/java/com/goafanti/common/mapper/AchievementMapper.xml

@@ -1327,6 +1327,12 @@ order by release_date limit #{0}
 	<if test="endDate != null">
 	   and  a.release_date <![CDATA[ <= ]]> #{endDate,jdbcType=TIMESTAMP}
 	</if>
+	<if test="cStartDate != null">
+       and	a.create_time <![CDATA[ >= ]]> #{cStartDate,jdbcType=TIMESTAMP}
+	</if>
+	<if test="cEndDate != null">
+	   and  a.create_time <![CDATA[ <= ]]> #{cEndDate,jdbcType=TIMESTAMP}
+	</if>
 	order by a.release_date desc
 	<if test="page_sql!=null">
 			${page_sql}
@@ -1363,6 +1369,12 @@ order by release_date limit #{0}
 	<if test="endDate != null">
 	   and  a.release_date <![CDATA[ <= ]]> #{endDate,jdbcType=TIMESTAMP}
 	</if>
+		<if test="cStartDate != null">
+       and	a.create_time <![CDATA[ >= ]]> #{cStartDate,jdbcType=TIMESTAMP}
+	</if>
+	<if test="cEndDate != null">
+	   and  a.create_time <![CDATA[ <= ]]> #{cEndDate,jdbcType=TIMESTAMP}
+	</if>
 </select>
 <select id="getAchievementDetailById" resultType="com.goafanti.portal.bo.AchievementResultObject" >
 select

+ 2 - 2
src/main/resources/props/config_test.properties

@@ -56,8 +56,8 @@ app.name=AFT
 app.mobile.website=http://muat.jishutao.com
 template.cacheable=false
 
-static.host=//statics.jishutao.com/client/1.2.5
-portal.host=//statics.jishutao.com/portal/1.2.7
+static.host=//statics.jishutao.com/client/1.2.7
+portal.host=//statics.jishutao.com/portal/1.2.8
 skjt.host=//statics.jishutao.com/skjt/1.3
 skjt.userName=admin
 skjt.password=asd123..