cloudroam
2024-12-27 c885a03818d37dceb22c558b9f23164e1f2ae749
src/main/java/com/mzl/flower/web/v2/sms/SmsTaskDetailController.java
@@ -5,7 +5,9 @@
import com.mzl.flower.base.BaseController;
import com.mzl.flower.base.R;
import com.mzl.flower.base.ReturnDataDTO;
import com.mzl.flower.dto.request.sms.SmsTaskDetailQueryDTO;
import com.mzl.flower.dto.request.sms.SmsTaskQueryDTO;
import com.mzl.flower.dto.response.sms.SmsPhoneResultVO;
import com.mzl.flower.dto.response.sms.SmsTaskDetailVO;
import com.mzl.flower.service.sms.SmsTaskDetailService;
import io.swagger.annotations.Api;
@@ -15,6 +17,8 @@
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.validation.constraints.NotNull;
/**
* @author @TaoJie
@@ -27,9 +31,19 @@
public class SmsTaskDetailController  extends BaseController {
    private final SmsTaskDetailService smsTaskDetailService;
    @GetMapping("/list")
    @ApiOperation(value = "任务详情列表", httpMethod = "GET")
    public ResponseEntity<ReturnDataDTO<Page<SmsTaskDetailVO>>> getSmsTaskList(Page page, SmsTaskQueryDTO dto) {
    public ResponseEntity<ReturnDataDTO<Page<SmsPhoneResultVO>>> getSmsTaskList(Page page, SmsTaskDetailQueryDTO dto) {
        return returnData(R.SUCCESS.getCode(), smsTaskDetailService.queryPage(dto, page));
    }
    @GetMapping("/taskStatistics")
    @ApiOperation(value = "任务详情列表", httpMethod = "GET")
    public ResponseEntity<ReturnDataDTO<SmsTaskDetailVO> >taskStatistics(@NotNull(message = "id不能为空") Long id ) {
        return returnData(R.SUCCESS.getCode(), smsTaskDetailService.getCountBySmsTaskId(id));
    }
}