package com.template.api; import com.template.model.pojo.WelcomeBed; import com.template.model.pojo.WelcomeStudentDormitory; import com.template.model.request.InfoCollectionRequest; import com.template.model.request.InsertWelcomeBedRequest; import com.template.model.request.UpdateWelcomeBedRequest; import com.template.model.result.CommonResult; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.validation.BindingResult; import org.springframework.validation.annotation.Validated; import org.springframework.web.bind.annotation.*; import org.springframework.web.multipart.MultipartFile; import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.text.ParseException; @RequestMapping("/api/welcomeBed") @Api(tags = {"WelcomeBedController"}, value = "床位信息管理") public interface WelcomeBedControllerAPI { @PostMapping(value = "/insertBedInfo") @ApiOperation(value = "添加床位信息", notes = "添加床位信息", httpMethod = "POST") CommonResult insertBedInfo(@Validated @RequestBody InsertWelcomeBedRequest iwbr, BindingResult bindingResult) throws Exception; @PostMapping(value = "/updateBedInfo") @ApiOperation(value = "编辑床位信息", notes = "编辑床位信息", httpMethod = "POST") CommonResult updateBedInfo(@Validated @RequestBody UpdateWelcomeBedRequest uwbr, BindingResult bindingResult) throws Exception; @GetMapping(value = "/queryPageBeds") @ApiOperation(value = "床位信息分页数据", notes = "床位信息分页数据", httpMethod = "GET") CommonResult queryPageBeds(@RequestParam int currentPage, @RequestParam int pageCount, Integer schoolId,Integer buildId,Integer dormitoryId,String sex, Integer isCheck,Integer collegeId, Integer majorId, Integer classstrId); @GetMapping(value = "/deleteBedInfo") @ApiOperation(value = "删除床位信息", notes = "删除床位信息", httpMethod = "GET") CommonResult deleteBedInfo(@RequestParam int id) throws Exception; @PostMapping(value = "/importBedExcel") @ApiOperation(value = "导入床位基本信息数据", notes = "导入床位基本信息数据", httpMethod = "POST") CommonResult importBedExcel(@RequestParam("file") MultipartFile file) throws IOException, ParseException; @GetMapping(value = "/downloadBedExcel") @ApiOperation(value = "床位信息导出模板", notes = "床位信息导出模板", httpMethod = "GET") CommonResult downloadBedExcel(); @GetMapping(value = "welcomeBedExport") @ApiOperation(value = "导出床位信息数据", notes = "导出床位信息数据", httpMethod = "GET") void welcomeBedExport(HttpServletResponse response, Integer schoolId,Integer buildId,Integer dormitoryId,String sex, Integer isCheck,Integer collegeId, Integer majorId, Integer classstrId); @PostMapping(value = "/submit") @ApiOperation(value = "提交床位信息", notes = "提交床位信息", httpMethod = "POST") CommonResult submit(@RequestBody WelcomeBed welcomeBed); @GetMapping(value = "/bedDetails") @ApiOperation(value = "宿舍详情", notes = "宿舍详情", httpMethod = "GET") CommonResult bedDetails(Integer schoolId,Integer buildId,Integer dormitoryId,String studentCard); @GetMapping(value = "/queryBedDatas") @ApiOperation(value = "获取床位下拉数据", notes = "获取床位下拉数据", httpMethod = "GET") CommonResult queryBedDatas(@RequestParam int dormitoryId); @GetMapping(value = "/isCheck") @ApiOperation(value = "判断是否入住", notes = "判断是否入住", httpMethod = "GET") CommonResult isCheck(@RequestAttribute String studentCard); }