package com.gkhy.safePlatform.account.controller;
|
|
import com.gkhy.safePlatform.account.entity.staffSchedule.UserScheduleDetail;
|
import com.gkhy.safePlatform.account.service.baseService.UserScheduleDetailService;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RestController;
|
|
import java.time.LocalDate;
|
import java.time.LocalDateTime;
|
import java.time.LocalTime;
|
import java.time.format.DateTimeFormatter;
|
import java.time.format.FormatStyle;
|
|
@RestController
|
@RequestMapping(value = "/schedule")
|
public class StaffScheduleController {
|
|
// @Autowired
|
// private UserScheduleDetailService detailService;
|
//
|
//// @RequestMapping(value = "/add",method = RequestMethod.GET)
|
// public Object testTime(){
|
// UserScheduleDetail detail = new UserScheduleDetail();
|
// detail.setUid(2L);
|
// detail.setWorkDay(LocalDate.of(2022,7,8));
|
// detail.setStartTime(LocalDateTime.of(detail.getWorkDay(), LocalTime.of(8,0,0)));
|
// detail.setEndTime(LocalDateTime.of(detail.getWorkDay(), LocalTime.of(18,0,0)));
|
// detail.setStatus((byte)1);
|
// return detailService.save(detail);
|
// }
|
//
|
// @RequestMapping(value = "/get/list",method = RequestMethod.GET)
|
// public Object getDetailListByDateZone(String startDayStr,String endDayStr){
|
// DateTimeFormatter df = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
// LocalDate startDay = LocalDate.parse(startDayStr,df);
|
// LocalDate endDay = LocalDate.parse(endDayStr,df);
|
// return detailService.findListByWorkDateZone(startDay,endDay);
|
// }
|
}
|