super权限无法获取问题处理,拼团表单校验问题,购物车渲染流程优化

This commit is contained in:
Chopper
2021-08-11 12:18:42 +08:00
parent 45e65e71e1
commit f9a18ffbe1
20 changed files with 171 additions and 42 deletions

View File

@@ -19,6 +19,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import springfox.documentation.annotations.ApiIgnore;
import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
@@ -50,8 +52,10 @@ public class DistributionCashBuyerController {
@ApiImplicitParam(name = "price", value = "申请金额", required = true, paramType = "query", dataType = "double")
})
@PostMapping
public ResultMessage<Object> cash(@NotNull @ApiIgnore Double price) {
if(distributionCashService.cash(price)){
public ResultMessage<Object> cash(@Max(value = 1000, message = "充值金额单次最多允许提现1000元")
@Min(value = 1, message = "充值金额单次最少提现金额为1元")
@NotNull @ApiIgnore Double price) {
if (distributionCashService.cash(price)) {
return ResultUtil.success();
}
throw new ServiceException(ResultCode.ERROR);