|
@@ -1,7 +1,11 @@
|
|
package com.xy.controller;
|
|
package com.xy.controller;
|
|
|
|
|
|
|
|
+import cn.hutool.core.collection.CollUtil;
|
|
|
|
+import com.xy.annotate.RestMappingController;
|
|
import com.xy.dto.DeviceSimChargeDto;
|
|
import com.xy.dto.DeviceSimChargeDto;
|
|
|
|
+import com.xy.dto.DeviceSimDto;
|
|
import com.xy.service.DeviceSimChargeServiceImpl;
|
|
import com.xy.service.DeviceSimChargeServiceImpl;
|
|
|
|
+import com.xy.service.DeviceSimServiceImpl;
|
|
import com.xy.utils.MercAuthUtils;
|
|
import com.xy.utils.MercAuthUtils;
|
|
import com.xy.utils.PageBean;
|
|
import com.xy.utils.PageBean;
|
|
import com.xy.utils.R;
|
|
import com.xy.utils.R;
|
|
@@ -9,15 +13,18 @@ import io.swagger.annotations.Api;
|
|
import io.swagger.annotations.ApiOperation;
|
|
import io.swagger.annotations.ApiOperation;
|
|
import lombok.AllArgsConstructor;
|
|
import lombok.AllArgsConstructor;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
|
|
+import org.springframework.validation.annotation.Validated;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
import org.springframework.web.bind.annotation.RequestBody;
|
|
import org.springframework.web.bind.annotation.RequestBody;
|
|
|
|
|
|
@Service
|
|
@Service
|
|
@AllArgsConstructor
|
|
@AllArgsConstructor
|
|
@Api(tags = "小程序-设备流量卡充值表")
|
|
@Api(tags = "小程序-设备流量卡充值表")
|
|
|
|
+@RestMappingController("merc-mini/deviceSimCharge")
|
|
public class DeviceSimChargeController {
|
|
public class DeviceSimChargeController {
|
|
|
|
|
|
private DeviceSimChargeServiceImpl deviceSimChargeService;
|
|
private DeviceSimChargeServiceImpl deviceSimChargeService;
|
|
|
|
+ private DeviceSimServiceImpl deviceSimService;
|
|
|
|
|
|
@PostMapping("page")
|
|
@PostMapping("page")
|
|
@ApiOperation("分页查询")
|
|
@ApiOperation("分页查询")
|
|
@@ -25,4 +32,18 @@ public class DeviceSimChargeController {
|
|
page.setMercId(MercAuthUtils.getMercId());
|
|
page.setMercId(MercAuthUtils.getMercId());
|
|
return deviceSimChargeService.page(page);
|
|
return deviceSimChargeService.page(page);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @ApiOperation("商管端-月统计分页")
|
|
|
|
+ @PostMapping("mercMoonCountPage")
|
|
|
|
+ public R<PageBean<DeviceSimChargeDto.MoonCountVo>> mercMoonCountPage(@RequestBody DeviceSimChargeDto.MoonCountPage moonCountPage) {
|
|
|
|
+ moonCountPage.setMercIds(CollUtil.newArrayList(MercAuthUtils.getMercId()));
|
|
|
|
+ return deviceSimChargeService.moonCountPage(moonCountPage);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @PostMapping("deviceSimDetailPage")
|
|
|
|
+ @ApiOperation("商管端-流量卡明细")
|
|
|
|
+ public R<PageBean<DeviceSimDto.PageVo>> deviceSimDetailPage(@RequestBody @Validated DeviceSimDto.Page page) {
|
|
|
|
+ page.setMercId(MercAuthUtils.getMercId());
|
|
|
|
+ return deviceSimService.page(page);
|
|
|
|
+ }
|
|
}
|
|
}
|