| | |
| | | package com.xiaopeng.maintenance.controller; |
| | | |
| | | |
| | | import com.xiaopeng.api.model.maintenance.XpErrorType; |
| | | import com.xiaopeng.common.core.domain.R; |
| | | import com.xiaopeng.api.model.account.SysUser;import com.xiaopeng.api.model.maintenance.XpErrorType; |
| | | import com.xiaopeng.api.vo.account.LoginUser;import com.xiaopeng.common.core.domain.R; |
| | | import com.xiaopeng.common.core.web.page.PageInfo; |
| | | import com.xiaopeng.common.security.service.TokenService; |
| | | import com.xiaopeng.common.security.utils.SecurityUtils; |
| | | import com.xiaopeng.maintenance.dto.SchedulingDetailDto; |
| | | import com.xiaopeng.maintenance.dto.ShiftAttendanceDTO; |
| | | import com.xiaopeng.maintenance.service.IXpSchedulingDetailService; |
| | | import com.xiaopeng.maintenance.vo.SaveSchedulingVo; |
| | | import com.xiaopeng.maintenance.vo.SchedulingDetailVo; |
| | | import com.xiaopeng.maintenance.vo.ShiftAttendanceVO; |
| | | import io.swagger.annotations.Api; |
| | |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | |
| | | /** |
| | |
| | | @RequestMapping("") |
| | | public class XpSchedulingDetailController { |
| | | |
| | | @Autowired |
| | | @Resource |
| | | private IXpSchedulingDetailService xpSchedulingDetailService; |
| | | @Autowired |
| | | |
| | | @Resource |
| | | private TokenService tokenService; |
| | | |
| | | @ApiOperation(value = "查询个人排班与考勤信息", response = XpErrorType.class, tags = "运维APP-排班与考勤") |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | // public R<PageInfo<SchedulingDetailDto>> pageList(@RequestBody SchedulingDetailVo query){ |
| | | // |
| | | // } |
| | | @ApiOperation(value = "排班考勤-排班计划管理-查询列表", response = XpErrorType.class, tags = "管理后台-运维执行") |
| | | @PostMapping("/api/v1/scheduling/pageList") |
| | | public R<PageInfo<SchedulingDetailDto>> pageList(@RequestBody SchedulingDetailVo query){ |
| | | PageInfo<SchedulingDetailDto> pageInfo = xpSchedulingDetailService.pageList(query); |
| | | return R.ok(pageInfo); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "排班考勤-排班计划管理-保存排班数据", response = XpErrorType.class, tags = "管理后台-运维执行") |
| | | @PostMapping("/api/v1/scheduling/saveSchedulingDetail") |
| | | public R<?> saveSchedulingDetail(@RequestBody SaveSchedulingVo vo){ |
| | | SysUser sysUser = SecurityUtils.getLoginUser().getSysUser(); |
| | | return xpSchedulingDetailService.saveSchedulingDetail(vo, sysUser.getId()); |
| | | } |
| | | |
| | | |
| | | |
| | | @ApiOperation(value = "排班考勤-排班计划管理-导出排班数据", response = XpErrorType.class, tags = "管理后台-运维执行") |
| | | @GetMapping("/api/v1/scheduling/exportExcel") |
| | | public void exportExcel(@RequestParam("month") String month, HttpServletResponse response) { |
| | | xpSchedulingDetailService.exportExcel(month, response); |
| | | } |
| | | } |
| | | |