| | |
| | | import com.whyc.dto.Response; |
| | | import com.whyc.service.BattgroupBaojigroupService; |
| | | import com.whyc.service.BatttestdataInfService; |
| | | import com.whyc.service.ExcelExportService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.http.HttpRequest; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.time.LocalDate; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | @RestController |
| | |
| | | @Autowired |
| | | private BatttestdataInfService service; |
| | | |
| | | @Autowired |
| | | private ExcelExportService exportService; |
| | | |
| | | @ApiOperation(value = "测试统计本年/本月") |
| | | @GetMapping("getDevTinfByYearMonth") |
| | |
| | | public Map<String, Object> getDevTinfByWeek(@RequestParam Integer uid){ |
| | | return service.getDevTinfByWeek(uid); |
| | | } |
| | | |
| | | @ApiOperation(value = "获取设备的充放电记录") |
| | | @GetMapping("getTinfById") |
| | | public Response getTinfById(@RequestParam Integer devId){ |
| | |
| | | public Response getTdataById(@RequestParam Integer devId,@RequestParam Integer testRecordCount){ |
| | | return service.getTdataById(devId,testRecordCount); |
| | | } |
| | | |
| | | @ApiOperation(value = "导出某次记录详细的单体放电记录") |
| | | @GetMapping("exportData") |
| | | public void exportData(@RequestParam Integer devId, @RequestParam Integer testRecordCount |
| | | , HttpServletResponse resp){ |
| | | if(devId/100000000==1){ |
| | | exportService.exportExcelA200(devId,testRecordCount,resp); |
| | | }else{ |
| | | exportService.exportExcelActm(devId,testRecordCount,resp); |
| | | } |
| | | |
| | | } |
| | | } |