|
|
|
@@ -2,6 +2,7 @@ package com.iformall.controller.mem; |
|
|
|
|
|
|
|
import com.github.pagehelper.PageInfo; |
|
|
|
import com.iformall.annotation.SystemControllerLog; |
|
|
|
import com.iformall.common.ErrorCode; |
|
|
|
import com.iformall.common.Result; |
|
|
|
import com.iformall.common.ResultData; |
|
|
|
import com.iformall.controller.base.BaseController; |
|
|
|
@@ -13,6 +14,7 @@ import com.iformall.service.WxCreditHistoryService; |
|
|
|
import io.swagger.annotations.ApiImplicitParam; |
|
|
|
import io.swagger.annotations.ApiImplicitParams; |
|
|
|
import io.swagger.annotations.ApiOperation; |
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
import org.slf4j.Logger; |
|
|
|
import org.slf4j.LoggerFactory; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
@@ -20,6 +22,7 @@ import org.springframework.web.bind.annotation.*; |
|
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest; |
|
|
|
import javax.servlet.http.HttpServletResponse; |
|
|
|
import java.util.Objects; |
|
|
|
|
|
|
|
@RestController |
|
|
|
@RequestMapping("wxCreditHistory") |
|
|
|
@@ -49,8 +52,11 @@ public class WxCreditHistoryController extends BaseController { |
|
|
|
@ApiImplicitParam(name = "spend", value = "消费金额", dataType = "int", paramType = "query", required = true), |
|
|
|
@ApiImplicitParam(name = "userId", value = "会员Id", dataType = "long", paramType = "query", required = true)}) |
|
|
|
@SystemControllerLog(description = "积分历史-根据商户ID和消费金额获取所增加积分") |
|
|
|
public ResultData findByMerchantIdAndSpend(@RequestParam Long merchantId, @RequestParam String spendStr,@RequestParam Long userId) { |
|
|
|
public ResultData findByMerchantIdAndSpend(Long merchantId, String spendStr,Long userId) { |
|
|
|
logger.debug("[" + getIpAddr() + "] WxCreditHistoryController::findByMerchantIdAndSpend"); |
|
|
|
if(Objects.isNull(merchantId)|| StringUtils.isEmpty(spendStr)||Objects.isNull(userId)) { |
|
|
|
return new ResultData(ErrorCode.SYS_PARAMETER_NOT_NULL) ; |
|
|
|
} |
|
|
|
return new ResultData(wxCreditHistoryService.findByMerchantIdAndSpend(merchantId, spendStr, userId,getTenantId())); |
|
|
|
} |
|
|
|
|
|
|
|
|