123456789101112131415161718192021222324252627282930313233343536 |
- package com.slibra.web.controller.business;
- import com.slibra.business.domain.TXinyiDaily;
- import com.slibra.business.mapper.TXinyiDailyMapper;
- import com.slibra.common.core.domain.AjaxResult;
- import lombok.extern.slf4j.Slf4j;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.util.CollectionUtils;
- import org.springframework.web.bind.annotation.*;
- import java.util.List;
- @RestController
- @RequestMapping("/out")
- @Slf4j
- public class OutController {
- @Autowired
- private TXinyiDailyMapper xinyiDailyMapper;
- /**
- * 通过日期获取某天的日报情况
- * @return
- */
- @GetMapping("/getDailyByDate")
- public AjaxResult recommendQAList(@RequestParam String date)
- {
- log.info("进入了 通过日期获取某天的日报情况 接口");
- List<TXinyiDaily> xinyiDailies = xinyiDailyMapper.selectTXinyiDailyList(TXinyiDaily.builder().testDate(date).build());
- if(!CollectionUtils.isEmpty(xinyiDailies))
- return AjaxResult.success(xinyiDailies.get(0));
- return AjaxResult.error("没有查询到对应的日报数据");
- }
- }
|