From 08bc0a13c0c2e00658e5ea63839893e73902810f Mon Sep 17 00:00:00 2001
From: yujian <yujian@123.com>
Date: 星期五, 23 八月 2019 11:07:39 +0800
Subject: [PATCH] 金币任务

---
 fanli/src/main/java/com/yeshi/fanli/controller/client/v2/IntegralControllerV2.java |   29 +++++++++++++++++------------
 1 files changed, 17 insertions(+), 12 deletions(-)

diff --git a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/IntegralControllerV2.java b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/IntegralControllerV2.java
index 842c6da..8ccb63b 100644
--- a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/IntegralControllerV2.java
+++ b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/IntegralControllerV2.java
@@ -485,20 +485,25 @@
 			out.print(JsonUtil.loadFalseResult(1, "椤电爜涓嶆纭�"));
 			return;
 		}
+		
+		try {
+			List<CodePublishRecord> list = codePublishRecordService.listValid((page - 1) * Constant.PAGE_SIZE,
+					Constant.PAGE_SIZE);
+			if (list == null) {
+				list = new ArrayList<CodePublishRecord>();
+			}
 
-		List<CodePublishRecord> list = codePublishRecordService.listValid((page - 1) * Constant.PAGE_SIZE,
-				Constant.PAGE_SIZE);
-		if (list == null) {
-			list = new ArrayList<CodePublishRecord>();
+			long count = codePublishRecordService.countValid();
+
+			JSONObject data = new JSONObject();
+			data.put("count", count);
+			data.put("list", getGson().toJson(list));
+			data.put("helpLink", configService.get("publish_list_help_link"));
+			out.print(JsonUtil.loadTrueResult(data));
+		} catch (Exception e) {
+			out.print(JsonUtil.loadFalseResult(1, "鑾峰彇澶辫触"));
+			return;
 		}
-
-		long count = codePublishRecordService.countValid();
-
-		JSONObject data = new JSONObject();
-		data.put("count", count);
-		data.put("list", getGson().toJson(list));
-		data.put("helpLink", configService.get("publish_list_help_link"));
-		out.print(JsonUtil.loadTrueResult(data));
 	}
 
 	/**

--
Gitblit v1.8.0