Commit 3d5a1343fc2c0863bb8eaf6c86bf0ca28f3453c5

Authored by 陈浩
1 parent 689a53b2

update

src/main/java/com/cnlive/shenhe/controller/VideosController.java
@@ -63,9 +63,21 @@ public class VideosController { @@ -63,9 +63,21 @@ public class VideosController {
63 public ResponseBean shenheInfo(Integer id, String activity_id, Integer state, String attr_tags, String msg, String callback, HttpSession session) { 63 public ResponseBean shenheInfo(Integer id, String activity_id, Integer state, String attr_tags, String msg, String callback, HttpSession session) {
64 SessionUser sessionUser = (SessionUser) session.getAttribute(SessionUser.getSessionKey()); 64 SessionUser sessionUser = (SessionUser) session.getAttribute(SessionUser.getSessionKey());
65 String userId = sessionUser.getUserId(); 65 String userId = sessionUser.getUserId();
66 - JSONObject result = Pass.auditPass(activity_id, state, attr_tags, msg, callback); 66 + JSONObject result = null;
  67 + try {
  68 + result = Pass.auditPass(activity_id, state, attr_tags, msg, callback);
  69 + } catch (Exception e) {
  70 + e.printStackTrace();
  71 + System.out.println("视频审核失败");
  72 + return new ResponseBean(ErrorEnum.ERROR);
  73 + }
  74 + if (result == null) {
  75 + System.out.println("视频审核失败且接口错误没有返回信息");
  76 + return new ResponseBean(ErrorEnum.ERROR);
  77 + }
67 Integer code = result.getInteger("code"); 78 Integer code = result.getInteger("code");
68 if (code != 0) { 79 if (code != 0) {
  80 + System.out.println("审核失败,");
69 return new ResponseBean(code, result.getString("msg")); 81 return new ResponseBean(code, result.getString("msg"));
70 } 82 }
71 state = state == 4 ? 2 : 1; 83 state = state == 4 ? 2 : 1;
@@ -101,7 +113,7 @@ public class VideosController { @@ -101,7 +113,7 @@ public class VideosController {
101 List<ShyVideos> list = videoPage.getList(); 113 List<ShyVideos> list = videoPage.getList();
102 if (!list.isEmpty()) { 114 if (!list.isEmpty()) {
103 for (ShyVideos videos : list) { 115 for (ShyVideos videos : list) {
104 - if (videos.getState() != CommonConst.AUDIT_INTT){ 116 + if (videos.getState() != CommonConst.AUDIT_INTT) {
105 String auditor = "白名单"; 117 String auditor = "白名单";
106 String auditor_id = videos.getAuditor_id(); 118 String auditor_id = videos.getAuditor_id();
107 if (CommonUtils.isNotEmpty(auditor_id)) { 119 if (CommonUtils.isNotEmpty(auditor_id)) {