| | |
| | | package com.xinquan.system.controller; |
| | | |
| | | |
| | | import com.xinquan.common.core.domain.R; |
| | | import com.xinquan.system.domain.ContentSetting; |
| | | import com.xinquan.system.domain.VipSetting; |
| | | import com.xinquan.system.service.VipSettingService; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.omg.CORBA.PRIVATE_MEMBER; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | @RestController |
| | | @RequestMapping("/system/vip-setting") |
| | | public class VipSettingController { |
| | | |
| | | @Resource |
| | | private VipSettingService vipSettingService; |
| | | @PostMapping("/getVipPrice") |
| | | @ApiOperation(value = "安卓-获取月度 季度 年度会员价格",tags = "会员") |
| | | public R<VipSetting> getVipPrice() { |
| | | VipSetting one = vipSettingService.lambdaQuery().eq(VipSetting::getClientType, 1) |
| | | .eq(VipSetting::getSettingType, 1).one(); |
| | | return R.ok(one); |
| | | } |
| | | @PostMapping("/getVipPriceApple") |
| | | @ApiOperation(value = "苹果-获取月度 季度 年度会员价格",tags = "会员") |
| | | public R<VipSetting> getVipPriceApple() { |
| | | VipSetting one = vipSettingService.lambdaQuery().eq(VipSetting::getClientType, 2) |
| | | .eq(VipSetting::getSettingType, 1).one(); |
| | | return R.ok(one); |
| | | } |
| | | @PostMapping("/getVipContent") |
| | | @ApiOperation(value = "获取会员权益介绍/获取会员用户协议/获取续费管理说明",tags = "会员") |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(value = "内容类型 1=会员权益介绍 2=会员用户协议 3=续费管理说明", name = "type", required = true, dataType = "int"), |
| | | }) |
| | | public R<String> getVipPriceApple(Integer type) { |
| | | VipSetting one = vipSettingService.lambdaQuery() |
| | | .eq(VipSetting::getSettingType, type+1).one(); |
| | | return R.ok(one.getContent()); |
| | | } |
| | | } |
| | | |