|
|
|
@@ -4,6 +4,7 @@ import com.iformall.common.ErrorCode; |
|
|
|
import com.iformall.common.ResultData; |
|
|
|
import com.iformall.domain.po.*; |
|
|
|
import com.iformall.enums.EnumGameStatus; |
|
|
|
import com.iformall.exception.MallinkException; |
|
|
|
import com.iformall.service.WxCouponOrderService; |
|
|
|
import com.iformall.service.WxGameService; |
|
|
|
import com.iformall.utils.Constant; |
|
|
|
@@ -96,7 +97,7 @@ public class WxGameController extends BaseController { |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "gameId", value = "游戏ID", dataType = "String", paramType = "query", required = true)}) |
|
|
|
public ResultData freeGameGo(@RequestBody Map<String,String> paramMap) { |
|
|
|
// try { |
|
|
|
try { |
|
|
|
Long gameIdL = Long.valueOf(paramMap.get("gameId")); |
|
|
|
if(gameIdL == null){ |
|
|
|
return new ResultData(ErrorCode.SYS_PARAMETER_NOT_NULL); |
|
|
|
@@ -121,9 +122,11 @@ public class WxGameController extends BaseController { |
|
|
|
ResultData resultData = wxGameService.luckDraw(gameIdL, getMemberId(),0); |
|
|
|
removeCacheCUser(); |
|
|
|
return resultData; |
|
|
|
// } catch (Exception e){ |
|
|
|
// return new ResultData(ErrorCode.SYS_PARAMETER_ERROR); |
|
|
|
// } |
|
|
|
} catch (MallinkException e){ |
|
|
|
return new ResultData(ErrorCode.getByCode(e.getErrorCode())); |
|
|
|
} catch (Exception e){ |
|
|
|
return new ResultData(ErrorCode.SYS_PARAMETER_ERROR); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
@@ -132,7 +135,7 @@ public class WxGameController extends BaseController { |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "gameId", value = "游戏ID", dataType = "String", paramType = "query", required = true)}) |
|
|
|
public ResultData freeCridetGameGo(@RequestBody Map<String,String> paramMap) { |
|
|
|
// try { |
|
|
|
try { |
|
|
|
Long gameIdL = Long.valueOf(paramMap.get("gameId")); |
|
|
|
if(gameIdL == null){ |
|
|
|
return new ResultData(ErrorCode.SYS_PARAMETER_NOT_NULL); |
|
|
|
@@ -163,9 +166,11 @@ public class WxGameController extends BaseController { |
|
|
|
ResultData resultData = wxGameService.cridetLuckDraw(gameIdL, getMemberId()); |
|
|
|
removeCacheCUser(); |
|
|
|
return resultData; |
|
|
|
// } catch (Exception e){ |
|
|
|
// return new ResultData(ErrorCode.SYS_PARAMETER_ERROR); |
|
|
|
// } |
|
|
|
} catch (MallinkException e){ |
|
|
|
return new ResultData(ErrorCode.getByCode(e.getErrorCode())); |
|
|
|
} catch (Exception e){ |
|
|
|
return new ResultData(ErrorCode.SYS_PARAMETER_ERROR); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|