LateClockController.java 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. package com.chuanghai.attendance.controller;
  2. import com.chuanghai.attendance.common.utils.CommonResult;
  3. import com.chuanghai.attendance.entity.LateClock;
  4. import com.chuanghai.attendance.service.LateClockService;
  5. import org.springframework.beans.factory.annotation.Autowired;
  6. import org.springframework.web.bind.annotation.GetMapping;
  7. import org.springframework.web.bind.annotation.RequestMapping;
  8. import org.springframework.web.bind.annotation.RequestParam;
  9. import org.springframework.web.bind.annotation.RestController;
  10. /**
  11. * 迟到早退
  12. *
  13. * @Author: binguo
  14. * @Date: 2022/9/20 星期二 17:01
  15. * @Description: com.chuanghai.attendance.controller
  16. * @Version: 1.0
  17. */
  18. @RestController
  19. @RequestMapping("late")
  20. public class LateClockController {
  21. @Autowired
  22. private LateClockService lateClockService;
  23. /**
  24. * 查询迟到早退规则
  25. *
  26. * @param campus 规则校区
  27. * @return
  28. */
  29. @GetMapping("queryLateClock")
  30. private CommonResult<LateClock> queryLateClock(@RequestParam("campus") String campus) {
  31. LateClock lateClock = lateClockService.queryCampusTime(campus);
  32. return CommonResult.ok().setResult(lateClock);
  33. }
  34. // /**
  35. // * 新增迟到早退规则
  36. // * @param lateClock
  37. // * @return
  38. // */
  39. // @PostMapping("saveOrUpdateLateClock")
  40. // private CommonResult saveOrUpdateLateClock(@RequestBody LateClock lateClock){
  41. // lateClockService.saveOrUpdateLateClock(lateClock);
  42. // return CommonResult.ok();
  43. // }
  44. }