考勤基本代码
This commit is contained in:
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceArrangementVo;
|
||||
import org.dromara.property.domain.bo.AttendanceArrangementBo;
|
||||
import org.dromara.property.service.IAttendanceArrangementService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 排班
|
||||
* 前端访问路由地址为:/Property/arrangement
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/arrangement")
|
||||
public class AttendanceArrangementController extends BaseController {
|
||||
|
||||
private final IAttendanceArrangementService attendanceArrangementService;
|
||||
|
||||
/**
|
||||
* 查询排班列表
|
||||
*/
|
||||
@SaCheckPermission("Property:arrangement:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceArrangementVo> list(AttendanceArrangementBo bo, PageQuery pageQuery) {
|
||||
return attendanceArrangementService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出排班列表
|
||||
*/
|
||||
@SaCheckPermission("Property:arrangement:export")
|
||||
@Log(title = "排班", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceArrangementBo bo, HttpServletResponse response) {
|
||||
List<AttendanceArrangementVo> list = attendanceArrangementService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "排班", AttendanceArrangementVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取排班详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:arrangement:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceArrangementVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceArrangementService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班
|
||||
*/
|
||||
@SaCheckPermission("Property:arrangement:add")
|
||||
@Log(title = "排班", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceArrangementBo bo) {
|
||||
return toAjax(attendanceArrangementService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班
|
||||
*/
|
||||
@SaCheckPermission("Property:arrangement:edit")
|
||||
@Log(title = "排班", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceArrangementBo bo) {
|
||||
return toAjax(attendanceArrangementService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除排班
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:arrangement:remove")
|
||||
@Log(title = "排班", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceArrangementService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceClockDateVo;
|
||||
import org.dromara.property.domain.bo.AttendanceClockDateBo;
|
||||
import org.dromara.property.service.IAttendanceClockDateService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡
|
||||
* 前端访问路由地址为:/Property/clockDate
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/clockDate")
|
||||
public class AttendanceClockDateController extends BaseController {
|
||||
|
||||
private final IAttendanceClockDateService attendanceClockDateService;
|
||||
|
||||
/**
|
||||
* 查询必须/无需打卡列表
|
||||
*/
|
||||
@SaCheckPermission("Property:clockDate:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceClockDateVo> list(AttendanceClockDateBo bo, PageQuery pageQuery) {
|
||||
return attendanceClockDateService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出必须/无需打卡列表
|
||||
*/
|
||||
@SaCheckPermission("Property:clockDate:export")
|
||||
@Log(title = "必须/无需打卡", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceClockDateBo bo, HttpServletResponse response) {
|
||||
List<AttendanceClockDateVo> list = attendanceClockDateService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "必须/无需打卡", AttendanceClockDateVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取必须/无需打卡详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:clockDate:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceClockDateVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceClockDateService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增必须/无需打卡
|
||||
*/
|
||||
@SaCheckPermission("Property:clockDate:add")
|
||||
@Log(title = "必须/无需打卡", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceClockDateBo bo) {
|
||||
return toAjax(attendanceClockDateService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改必须/无需打卡
|
||||
*/
|
||||
@SaCheckPermission("Property:clockDate:edit")
|
||||
@Log(title = "必须/无需打卡", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceClockDateBo bo) {
|
||||
return toAjax(attendanceClockDateService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除必须/无需打卡
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:clockDate:remove")
|
||||
@Log(title = "必须/无需打卡", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceClockDateService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceFixedScheduleVo;
|
||||
import org.dromara.property.domain.bo.AttendanceFixedScheduleBo;
|
||||
import org.dromara.property.service.IAttendanceFixedScheduleService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 固定班制表
|
||||
* 前端访问路由地址为:/Property/fixedSchedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/fixedSchedule")
|
||||
public class AttendanceFixedScheduleController extends BaseController {
|
||||
|
||||
private final IAttendanceFixedScheduleService attendanceFixedScheduleService;
|
||||
|
||||
/**
|
||||
* 查询固定班制表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:fixedSchedule:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceFixedScheduleVo> list(AttendanceFixedScheduleBo bo, PageQuery pageQuery) {
|
||||
return attendanceFixedScheduleService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出固定班制表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:fixedSchedule:export")
|
||||
@Log(title = "固定班制表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceFixedScheduleBo bo, HttpServletResponse response) {
|
||||
List<AttendanceFixedScheduleVo> list = attendanceFixedScheduleService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "固定班制表", AttendanceFixedScheduleVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取固定班制表详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:fixedSchedule:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceFixedScheduleVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceFixedScheduleService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增固定班制表
|
||||
*/
|
||||
@SaCheckPermission("Property:fixedSchedule:add")
|
||||
@Log(title = "固定班制表", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceFixedScheduleBo bo) {
|
||||
return toAjax(attendanceFixedScheduleService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改固定班制表
|
||||
*/
|
||||
@SaCheckPermission("Property:fixedSchedule:edit")
|
||||
@Log(title = "固定班制表", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceFixedScheduleBo bo) {
|
||||
return toAjax(attendanceFixedScheduleService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除固定班制表
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:fixedSchedule:remove")
|
||||
@Log(title = "固定班制表", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceFixedScheduleService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceGroupVo;
|
||||
import org.dromara.property.domain.bo.AttendanceGroupBo;
|
||||
import org.dromara.property.service.IAttendanceGroupService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 考勤组基本信息
|
||||
* 前端访问路由地址为:/Property/group
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/group")
|
||||
public class AttendanceGroupController extends BaseController {
|
||||
|
||||
private final IAttendanceGroupService attendanceGroupService;
|
||||
|
||||
/**
|
||||
* 查询考勤组基本信息列表
|
||||
*/
|
||||
@SaCheckPermission("Property:group:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceGroupVo> list(AttendanceGroupBo bo, PageQuery pageQuery) {
|
||||
return attendanceGroupService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出考勤组基本信息列表
|
||||
*/
|
||||
@SaCheckPermission("Property:group:export")
|
||||
@Log(title = "考勤组基本信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceGroupBo bo, HttpServletResponse response) {
|
||||
List<AttendanceGroupVo> list = attendanceGroupService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "考勤组基本信息", AttendanceGroupVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取考勤组基本信息详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:group:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceGroupVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceGroupService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增考勤组基本信息
|
||||
*/
|
||||
@SaCheckPermission("Property:group:add")
|
||||
@Log(title = "考勤组基本信息", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceGroupBo bo) {
|
||||
return toAjax(attendanceGroupService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改考勤组基本信息
|
||||
*/
|
||||
@SaCheckPermission("Property:group:edit")
|
||||
@Log(title = "考勤组基本信息", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceGroupBo bo) {
|
||||
return toAjax(attendanceGroupService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除考勤组基本信息
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:group:remove")
|
||||
@Log(title = "考勤组基本信息", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceGroupService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleCycleVo;
|
||||
import org.dromara.property.domain.bo.AttendanceScheduleCycleBo;
|
||||
import org.dromara.property.service.IAttendanceScheduleCycleService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 排班周期表
|
||||
* 前端访问路由地址为:/Property/scheduleCycle
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/scheduleCycle")
|
||||
public class AttendanceScheduleCycleController extends BaseController {
|
||||
|
||||
private final IAttendanceScheduleCycleService attendanceScheduleCycleService;
|
||||
|
||||
/**
|
||||
* 查询排班周期表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleCycle:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceScheduleCycleVo> list(AttendanceScheduleCycleBo bo, PageQuery pageQuery) {
|
||||
return attendanceScheduleCycleService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出排班周期表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleCycle:export")
|
||||
@Log(title = "排班周期表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceScheduleCycleBo bo, HttpServletResponse response) {
|
||||
List<AttendanceScheduleCycleVo> list = attendanceScheduleCycleService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "排班周期表", AttendanceScheduleCycleVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取排班周期表详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleCycle:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceScheduleCycleVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceScheduleCycleService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班周期表
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleCycle:add")
|
||||
@Log(title = "排班周期表", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceScheduleCycleBo bo) {
|
||||
return toAjax(attendanceScheduleCycleService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班周期表
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleCycle:edit")
|
||||
@Log(title = "排班周期表", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceScheduleCycleBo bo) {
|
||||
return toAjax(attendanceScheduleCycleService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除排班周期表
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleCycle:remove")
|
||||
@Log(title = "排班周期表", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceScheduleCycleService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleMemberVo;
|
||||
import org.dromara.property.domain.bo.AttendanceScheduleMemberBo;
|
||||
import org.dromara.property.service.IAttendanceScheduleMemberService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 排班人员
|
||||
* 前端访问路由地址为:/Property/scheduleMember
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/scheduleMember")
|
||||
public class AttendanceScheduleMemberController extends BaseController {
|
||||
|
||||
private final IAttendanceScheduleMemberService attendanceScheduleMemberService;
|
||||
|
||||
/**
|
||||
* 查询排班人员列表
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleMember:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceScheduleMemberVo> list(AttendanceScheduleMemberBo bo, PageQuery pageQuery) {
|
||||
return attendanceScheduleMemberService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出排班人员列表
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleMember:export")
|
||||
@Log(title = "排班人员", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceScheduleMemberBo bo, HttpServletResponse response) {
|
||||
List<AttendanceScheduleMemberVo> list = attendanceScheduleMemberService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "排班人员", AttendanceScheduleMemberVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取排班人员详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleMember:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceScheduleMemberVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceScheduleMemberService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班人员
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleMember:add")
|
||||
@Log(title = "排班人员", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceScheduleMemberBo bo) {
|
||||
return toAjax(attendanceScheduleMemberService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班人员
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleMember:edit")
|
||||
@Log(title = "排班人员", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceScheduleMemberBo bo) {
|
||||
return toAjax(attendanceScheduleMemberService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除排班人员
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:scheduleMember:remove")
|
||||
@Log(title = "排班人员", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceScheduleMemberService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftVo;
|
||||
import org.dromara.property.domain.bo.AttendanceShiftBo;
|
||||
import org.dromara.property.service.IAttendanceShiftService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 班次表
|
||||
* 前端访问路由地址为:/Property/shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/shift")
|
||||
public class AttendanceShiftController extends BaseController {
|
||||
|
||||
private final IAttendanceShiftService attendanceShiftService;
|
||||
|
||||
/**
|
||||
* 查询班次表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:shift:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceShiftVo> list(AttendanceShiftBo bo, PageQuery pageQuery) {
|
||||
return attendanceShiftService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出班次表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:shift:export")
|
||||
@Log(title = "班次表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceShiftBo bo, HttpServletResponse response) {
|
||||
List<AttendanceShiftVo> list = attendanceShiftService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "班次表", AttendanceShiftVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取班次表详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:shift:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceShiftVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceShiftService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增班次表
|
||||
*/
|
||||
@SaCheckPermission("Property:shift:add")
|
||||
@Log(title = "班次表", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceShiftBo bo) {
|
||||
return toAjax(attendanceShiftService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改班次表
|
||||
*/
|
||||
@SaCheckPermission("Property:shift:edit")
|
||||
@Log(title = "班次表", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceShiftBo bo) {
|
||||
return toAjax(attendanceShiftService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除班次表
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:shift:remove")
|
||||
@Log(title = "班次表", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceShiftService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftScheduleVo;
|
||||
import org.dromara.property.domain.bo.AttendanceShiftScheduleBo;
|
||||
import org.dromara.property.service.IAttendanceShiftScheduleService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 排班制表
|
||||
* 前端访问路由地址为:/Property/shiftSchedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/shiftSchedule")
|
||||
public class AttendanceShiftScheduleController extends BaseController {
|
||||
|
||||
private final IAttendanceShiftScheduleService attendanceShiftScheduleService;
|
||||
|
||||
/**
|
||||
* 查询排班制表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:shiftSchedule:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceShiftScheduleVo> list(AttendanceShiftScheduleBo bo, PageQuery pageQuery) {
|
||||
return attendanceShiftScheduleService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出排班制表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:shiftSchedule:export")
|
||||
@Log(title = "排班制表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceShiftScheduleBo bo, HttpServletResponse response) {
|
||||
List<AttendanceShiftScheduleVo> list = attendanceShiftScheduleService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "排班制表", AttendanceShiftScheduleVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取排班制表详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:shiftSchedule:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceShiftScheduleVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceShiftScheduleService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班制表
|
||||
*/
|
||||
@SaCheckPermission("Property:shiftSchedule:add")
|
||||
@Log(title = "排班制表", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceShiftScheduleBo bo) {
|
||||
return toAjax(attendanceShiftScheduleService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班制表
|
||||
*/
|
||||
@SaCheckPermission("Property:shiftSchedule:edit")
|
||||
@Log(title = "排班制表", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceShiftScheduleBo bo) {
|
||||
return toAjax(attendanceShiftScheduleService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除排班制表
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:shiftSchedule:remove")
|
||||
@Log(title = "排班制表", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceShiftScheduleService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceWeekSetVo;
|
||||
import org.dromara.property.domain.bo.AttendanceWeekSetBo;
|
||||
import org.dromara.property.service.IAttendanceWeekSetService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 周设置表
|
||||
* 前端访问路由地址为:/Property/weekSet
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/weekSet")
|
||||
public class AttendanceWeekSetController extends BaseController {
|
||||
|
||||
private final IAttendanceWeekSetService attendanceWeekSetService;
|
||||
|
||||
/**
|
||||
* 查询周设置表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:weekSet:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceWeekSetVo> list(AttendanceWeekSetBo bo, PageQuery pageQuery) {
|
||||
return attendanceWeekSetService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出周设置表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:weekSet:export")
|
||||
@Log(title = "周设置表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceWeekSetBo bo, HttpServletResponse response) {
|
||||
List<AttendanceWeekSetVo> list = attendanceWeekSetService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "周设置表", AttendanceWeekSetVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取周设置表详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:weekSet:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceWeekSetVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceWeekSetService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增周设置表
|
||||
*/
|
||||
@SaCheckPermission("Property:weekSet:add")
|
||||
@Log(title = "周设置表", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceWeekSetBo bo) {
|
||||
return toAjax(attendanceWeekSetService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改周设置表
|
||||
*/
|
||||
@SaCheckPermission("Property:weekSet:edit")
|
||||
@Log(title = "周设置表", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceWeekSetBo bo) {
|
||||
return toAjax(attendanceWeekSetService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除周设置表
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:weekSet:remove")
|
||||
@Log(title = "周设置表", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceWeekSetService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,106 @@
|
||||
package org.dromara.property.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.property.domain.vo.AttendanceWeeksetShiftVo;
|
||||
import org.dromara.property.domain.bo.AttendanceWeeksetShiftBo;
|
||||
import org.dromara.property.service.IAttendanceWeeksetShiftService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 排班制表
|
||||
* 前端访问路由地址为:/Property/weeksetShift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/weeksetShift")
|
||||
public class AttendanceWeeksetShiftController extends BaseController {
|
||||
|
||||
private final IAttendanceWeeksetShiftService attendanceWeeksetShiftService;
|
||||
|
||||
/**
|
||||
* 查询排班制表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:weeksetShift:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<AttendanceWeeksetShiftVo> list(AttendanceWeeksetShiftBo bo, PageQuery pageQuery) {
|
||||
return attendanceWeeksetShiftService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出排班制表列表
|
||||
*/
|
||||
@SaCheckPermission("Property:weeksetShift:export")
|
||||
@Log(title = "排班制表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(AttendanceWeeksetShiftBo bo, HttpServletResponse response) {
|
||||
List<AttendanceWeeksetShiftVo> list = attendanceWeeksetShiftService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "排班制表", AttendanceWeeksetShiftVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取排班制表详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("Property:weeksetShift:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<AttendanceWeeksetShiftVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
return R.ok(attendanceWeeksetShiftService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班制表
|
||||
*/
|
||||
@SaCheckPermission("Property:weeksetShift:add")
|
||||
@Log(title = "排班制表", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody AttendanceWeeksetShiftBo bo) {
|
||||
return toAjax(attendanceWeeksetShiftService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班制表
|
||||
*/
|
||||
@SaCheckPermission("Property:weeksetShift:edit")
|
||||
@Log(title = "排班制表", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody AttendanceWeeksetShiftBo bo) {
|
||||
return toAjax(attendanceWeeksetShiftService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除排班制表
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("Property:weeksetShift:remove")
|
||||
@Log(title = "排班制表", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable("ids") Long[] ids) {
|
||||
return toAjax(attendanceWeeksetShiftService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@@ -0,0 +1,68 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 排班对象 attendance_arrangement
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_arrangement")
|
||||
public class AttendanceArrangement extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 排班名称
|
||||
*/
|
||||
private String scheduleName;
|
||||
|
||||
/**
|
||||
* 考勤组ID
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 排班类型:1-固定班制,2-排班制
|
||||
*/
|
||||
private Long scheduleType;
|
||||
|
||||
/**
|
||||
* 日期类型:1-单个日期,2-长期有效,3-期间有效
|
||||
*/
|
||||
private Long dateType;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
private Date startDate;
|
||||
|
||||
/**
|
||||
* 结束日期(仅date_type=3时有效)
|
||||
*/
|
||||
private Date endDate;
|
||||
|
||||
/**
|
||||
* 状态:0-未生效,1-已生效
|
||||
*/
|
||||
private Long status;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,68 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡对象 attendance_clock_date
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_clock_date")
|
||||
public class AttendanceClockDate extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 关联考勤组ID
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡(0:无需打卡,1必须打卡)
|
||||
*/
|
||||
private Long mustNoCheck;
|
||||
|
||||
/**
|
||||
* 日期类型(0:单个日期,1:时间段)
|
||||
*/
|
||||
private Long dateType;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
private Date startDate;
|
||||
|
||||
/**
|
||||
* 结束日期(单个日期时与start_date相同)
|
||||
*/
|
||||
private Date endDate;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡原因
|
||||
*/
|
||||
private String reason;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private Long createdBy;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,41 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 固定班制表对象 attendance_fixed_schedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_fixed_schedule")
|
||||
public class AttendanceFixedSchedule extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组关联id
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 考勤类型名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,46 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 考勤组基本信息对象 attendance_group
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_group")
|
||||
public class AttendanceGroup extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组名称
|
||||
*/
|
||||
private String groupName;
|
||||
|
||||
/**
|
||||
* 状态(1:启用,0:禁用)
|
||||
*/
|
||||
private Long status;
|
||||
|
||||
/**
|
||||
* 考勤类型(0:固定班制,1:排班制)
|
||||
*/
|
||||
private Long attendanceType;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,46 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 排班周期表对象 attendance_schedule_cycle
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_schedule_cycle")
|
||||
public class AttendanceScheduleCycle extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 周期中的第几天(1开始)
|
||||
*/
|
||||
private Long dayNumber;
|
||||
|
||||
/**
|
||||
* 关联排班组id
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 是否休息日(1:是,0:否)
|
||||
*/
|
||||
private Long isRest;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,51 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 排班人员对象 attendance_schedule_member
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_schedule_member")
|
||||
public class AttendanceScheduleMember extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 排班ID
|
||||
*/
|
||||
private Long scheduleId;
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 部门ID
|
||||
*/
|
||||
private Long deptId;
|
||||
|
||||
/**
|
||||
* 部门名称
|
||||
*/
|
||||
private String deptName;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,68 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 班次表对象 attendance_shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_shift")
|
||||
public class AttendanceShift extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 班次名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 考勤开始时间
|
||||
*/
|
||||
private Date startTime;
|
||||
|
||||
/**
|
||||
* 考勤结束时间
|
||||
*/
|
||||
private Date endTime;
|
||||
|
||||
/**
|
||||
* 状态(0:off,1:on)
|
||||
*/
|
||||
private Long status;
|
||||
|
||||
/**
|
||||
* 是否休息(0:不休息,1:休息)
|
||||
*/
|
||||
private Long isRest;
|
||||
|
||||
/**
|
||||
* 休息开始时间
|
||||
*/
|
||||
private Date restStartTime;
|
||||
|
||||
/**
|
||||
* 休息结束时间
|
||||
*/
|
||||
private Date restEndTime;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,41 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 排班制表对象 attendance_shift_schedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_shift_schedule")
|
||||
public class AttendanceShiftSchedule extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组关联id
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 排班制考勤类型名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,41 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 周设置表对象 attendance_week_set
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_week_set")
|
||||
public class AttendanceWeekSet extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 固定班制关联id
|
||||
*/
|
||||
private Long fixedScheduleId;
|
||||
|
||||
/**
|
||||
* 星期(1代表周一,7代表周日)
|
||||
*/
|
||||
private Long dayOfWeek;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,46 @@
|
||||
package org.dromara.property.domain;
|
||||
|
||||
import org.dromara.common.tenant.core.TenantEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 排班制表对象 attendance_weekset_shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("attendance_weekset_shift")
|
||||
public class AttendanceWeeksetShift extends TenantEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 班次id
|
||||
*/
|
||||
private Long weekId;
|
||||
|
||||
/**
|
||||
* 固定班制的的工作日id
|
||||
*/
|
||||
private Long shiftSetId;
|
||||
|
||||
/**
|
||||
* 排班制的排班周期id
|
||||
*/
|
||||
private Long scheduleSchedule;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,67 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceArrangement;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 排班业务对象 attendance_arrangement
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceArrangement.class, reverseConvertGenerate = false)
|
||||
public class AttendanceArrangementBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 排班名称
|
||||
*/
|
||||
private String scheduleName;
|
||||
|
||||
/**
|
||||
* 考勤组ID
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 排班类型:1-固定班制,2-排班制
|
||||
*/
|
||||
private Long scheduleType;
|
||||
|
||||
/**
|
||||
* 日期类型:1-单个日期,2-长期有效,3-期间有效
|
||||
*/
|
||||
private Long dateType;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
private Date startDate;
|
||||
|
||||
/**
|
||||
* 结束日期(仅date_type=3时有效)
|
||||
*/
|
||||
private Date endDate;
|
||||
|
||||
/**
|
||||
* 状态:0-未生效,1-已生效
|
||||
*/
|
||||
private Long status;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,67 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceClockDate;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡业务对象 attendance_clock_date
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceClockDate.class, reverseConvertGenerate = false)
|
||||
public class AttendanceClockDateBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 关联考勤组ID
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡(0:无需打卡,1必须打卡)
|
||||
*/
|
||||
private Long mustNoCheck;
|
||||
|
||||
/**
|
||||
* 日期类型(0:单个日期,1:时间段)
|
||||
*/
|
||||
private Long dateType;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
private Date startDate;
|
||||
|
||||
/**
|
||||
* 结束日期(单个日期时与start_date相同)
|
||||
*/
|
||||
private Date endDate;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡原因
|
||||
*/
|
||||
private String reason;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private Long createdBy;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,40 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceFixedSchedule;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 固定班制表业务对象 attendance_fixed_schedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceFixedSchedule.class, reverseConvertGenerate = false)
|
||||
public class AttendanceFixedScheduleBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组关联id
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 考勤类型名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,45 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceGroup;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 考勤组基本信息业务对象 attendance_group
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceGroup.class, reverseConvertGenerate = false)
|
||||
public class AttendanceGroupBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组名称
|
||||
*/
|
||||
private String groupName;
|
||||
|
||||
/**
|
||||
* 状态(1:启用,0:禁用)
|
||||
*/
|
||||
private Long status;
|
||||
|
||||
/**
|
||||
* 考勤类型(0:固定班制,1:排班制)
|
||||
*/
|
||||
private Long attendanceType;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,45 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleCycle;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 排班周期表业务对象 attendance_schedule_cycle
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceScheduleCycle.class, reverseConvertGenerate = false)
|
||||
public class AttendanceScheduleCycleBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 周期中的第几天(1开始)
|
||||
*/
|
||||
private Long dayNumber;
|
||||
|
||||
/**
|
||||
* 关联排班组id
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 是否休息日(1:是,0:否)
|
||||
*/
|
||||
private Long isRest;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,50 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleMember;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 排班人员业务对象 attendance_schedule_member
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceScheduleMember.class, reverseConvertGenerate = false)
|
||||
public class AttendanceScheduleMemberBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 排班ID
|
||||
*/
|
||||
private Long scheduleId;
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 部门ID
|
||||
*/
|
||||
private Long deptId;
|
||||
|
||||
/**
|
||||
* 部门名称
|
||||
*/
|
||||
private String deptName;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,67 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShift;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 班次表业务对象 attendance_shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceShift.class, reverseConvertGenerate = false)
|
||||
public class AttendanceShiftBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 班次名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 考勤开始时间
|
||||
*/
|
||||
private Date startTime;
|
||||
|
||||
/**
|
||||
* 考勤结束时间
|
||||
*/
|
||||
private Date endTime;
|
||||
|
||||
/**
|
||||
* 状态(0:off,1:on)
|
||||
*/
|
||||
private Long status;
|
||||
|
||||
/**
|
||||
* 是否休息(0:不休息,1:休息)
|
||||
*/
|
||||
private Long isRest;
|
||||
|
||||
/**
|
||||
* 休息开始时间
|
||||
*/
|
||||
private Date restStartTime;
|
||||
|
||||
/**
|
||||
* 休息结束时间
|
||||
*/
|
||||
private Date restEndTime;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,39 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShiftSchedule;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 排班制表业务对象 attendance_shift_schedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceShiftSchedule.class, reverseConvertGenerate = false)
|
||||
public class AttendanceShiftScheduleBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组关联id
|
||||
*/
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 排班制考勤类型名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,40 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeekSet;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 周设置表业务对象 attendance_week_set
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceWeekSet.class, reverseConvertGenerate = false)
|
||||
public class AttendanceWeekSetBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 固定班制关联id
|
||||
*/
|
||||
private Long fixedScheduleId;
|
||||
|
||||
/**
|
||||
* 星期(1代表周一,7代表周日)
|
||||
*/
|
||||
private Long dayOfWeek;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,45 @@
|
||||
package org.dromara.property.domain.bo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeeksetShift;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 排班制表业务对象 attendance_weekset_shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = AttendanceWeeksetShift.class, reverseConvertGenerate = false)
|
||||
public class AttendanceWeeksetShiftBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@NotNull(message = "主键id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 班次id
|
||||
*/
|
||||
private Long weekId;
|
||||
|
||||
/**
|
||||
* 固定班制的的工作日id
|
||||
*/
|
||||
private Long shiftSetId;
|
||||
|
||||
/**
|
||||
* 排班制的排班周期id
|
||||
*/
|
||||
private Long scheduleSchedule;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,82 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.dromara.property.domain.AttendanceArrangement;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 排班视图对象 attendance_arrangement
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceArrangement.class)
|
||||
public class AttendanceArrangementVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@ExcelProperty(value = "主键ID")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 排班名称
|
||||
*/
|
||||
@ExcelProperty(value = "排班名称")
|
||||
private String scheduleName;
|
||||
|
||||
/**
|
||||
* 考勤组ID
|
||||
*/
|
||||
@ExcelProperty(value = "考勤组ID")
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 排班类型:1-固定班制,2-排班制
|
||||
*/
|
||||
@ExcelProperty(value = "排班类型:1-固定班制,2-排班制")
|
||||
private Long scheduleType;
|
||||
|
||||
/**
|
||||
* 日期类型:1-单个日期,2-长期有效,3-期间有效
|
||||
*/
|
||||
@ExcelProperty(value = "日期类型:1-单个日期,2-长期有效,3-期间有效")
|
||||
private Long dateType;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
@ExcelProperty(value = "开始日期")
|
||||
private Date startDate;
|
||||
|
||||
/**
|
||||
* 结束日期(仅date_type=3时有效)
|
||||
*/
|
||||
@ExcelProperty(value = "结束日期(仅date_type=3时有效)")
|
||||
private Date endDate;
|
||||
|
||||
/**
|
||||
* 状态:0-未生效,1-已生效
|
||||
*/
|
||||
@ExcelProperty(value = "状态:0-未生效,1-已生效")
|
||||
private Long status;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,83 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.dromara.property.domain.AttendanceClockDate;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 必须/无需打卡视图对象 attendance_clock_date
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceClockDate.class)
|
||||
public class AttendanceClockDateVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 关联考勤组ID
|
||||
*/
|
||||
@ExcelProperty(value = "关联考勤组ID")
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡(0:无需打卡,1必须打卡)
|
||||
*/
|
||||
@ExcelProperty(value = "必须/无需打卡", converter = ExcelDictConvert.class)
|
||||
@ExcelDictFormat(readConverterExp = "0=:无需打卡,1必须打卡")
|
||||
private Long mustNoCheck;
|
||||
|
||||
/**
|
||||
* 日期类型(0:单个日期,1:时间段)
|
||||
*/
|
||||
@ExcelProperty(value = "日期类型(0:单个日期,1:时间段)")
|
||||
private Long dateType;
|
||||
|
||||
/**
|
||||
* 开始日期
|
||||
*/
|
||||
@ExcelProperty(value = "开始日期")
|
||||
private Date startDate;
|
||||
|
||||
/**
|
||||
* 结束日期(单个日期时与start_date相同)
|
||||
*/
|
||||
@ExcelProperty(value = "结束日期(单个日期时与start_date相同)")
|
||||
private Date endDate;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡原因
|
||||
*/
|
||||
@ExcelProperty(value = "必须/无需打卡原因")
|
||||
private String reason;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
@ExcelProperty(value = "创建人")
|
||||
private Long createdBy;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,50 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceFixedSchedule;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 固定班制表视图对象 attendance_fixed_schedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceFixedSchedule.class)
|
||||
public class AttendanceFixedScheduleVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组关联id
|
||||
*/
|
||||
@ExcelProperty(value = "考勤组关联id")
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 考勤类型名称
|
||||
*/
|
||||
@ExcelProperty(value = "考勤类型名称")
|
||||
private String name;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,56 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceGroup;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 考勤组基本信息视图对象 attendance_group
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceGroup.class)
|
||||
public class AttendanceGroupVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组名称
|
||||
*/
|
||||
@ExcelProperty(value = "考勤组名称")
|
||||
private String groupName;
|
||||
|
||||
/**
|
||||
* 状态(1:启用,0:禁用)
|
||||
*/
|
||||
@ExcelProperty(value = "状态(1:启用,0:禁用)")
|
||||
private Long status;
|
||||
|
||||
/**
|
||||
* 考勤类型(0:固定班制,1:排班制)
|
||||
*/
|
||||
@ExcelProperty(value = "考勤类型(0:固定班制,1:排班制)")
|
||||
private Long attendanceType;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,56 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleCycle;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 排班周期表视图对象 attendance_schedule_cycle
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceScheduleCycle.class)
|
||||
public class AttendanceScheduleCycleVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 周期中的第几天(1开始)
|
||||
*/
|
||||
@ExcelProperty(value = "周期中的第几天(1开始)")
|
||||
private Long dayNumber;
|
||||
|
||||
/**
|
||||
* 关联排班组id
|
||||
*/
|
||||
@ExcelProperty(value = "关联排班组id")
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 是否休息日(1:是,0:否)
|
||||
*/
|
||||
@ExcelProperty(value = "是否休息日(1:是,0:否)")
|
||||
private Long isRest;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,62 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleMember;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 排班人员视图对象 attendance_schedule_member
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceScheduleMember.class)
|
||||
public class AttendanceScheduleMemberVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@ExcelProperty(value = "主键ID")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 排班ID
|
||||
*/
|
||||
@ExcelProperty(value = "排班ID")
|
||||
private Long scheduleId;
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
@ExcelProperty(value = "用户ID")
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 部门ID
|
||||
*/
|
||||
@ExcelProperty(value = "部门ID")
|
||||
private Long deptId;
|
||||
|
||||
/**
|
||||
* 部门名称
|
||||
*/
|
||||
@ExcelProperty(value = "部门名称")
|
||||
private String deptName;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,50 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShiftSchedule;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 排班制表视图对象 attendance_shift_schedule
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceShiftSchedule.class)
|
||||
public class AttendanceShiftScheduleVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 考勤组关联id
|
||||
*/
|
||||
@ExcelProperty(value = "考勤组关联id")
|
||||
private Long groupId;
|
||||
|
||||
/**
|
||||
* 排班制考勤类型名称
|
||||
*/
|
||||
@ExcelProperty(value = "排班制考勤类型名称")
|
||||
private String name;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,84 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.dromara.property.domain.AttendanceShift;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 班次表视图对象 attendance_shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceShift.class)
|
||||
public class AttendanceShiftVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 班次名称
|
||||
*/
|
||||
@ExcelProperty(value = "班次名称")
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 考勤开始时间
|
||||
*/
|
||||
@ExcelProperty(value = "考勤开始时间")
|
||||
private Date startTime;
|
||||
|
||||
/**
|
||||
* 考勤结束时间
|
||||
*/
|
||||
@ExcelProperty(value = "考勤结束时间")
|
||||
private Date endTime;
|
||||
|
||||
/**
|
||||
* 状态(0:off,1:on)
|
||||
*/
|
||||
@ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
|
||||
@ExcelDictFormat(readConverterExp = "0=:off,1:on")
|
||||
private Long status;
|
||||
|
||||
/**
|
||||
* 是否休息(0:不休息,1:休息)
|
||||
*/
|
||||
@ExcelProperty(value = "是否休息", converter = ExcelDictConvert.class)
|
||||
@ExcelDictFormat(readConverterExp = "0=:不休息,1:休息")
|
||||
private Long isRest;
|
||||
|
||||
/**
|
||||
* 休息开始时间
|
||||
*/
|
||||
@ExcelProperty(value = "休息开始时间")
|
||||
private Date restStartTime;
|
||||
|
||||
/**
|
||||
* 休息结束时间
|
||||
*/
|
||||
@ExcelProperty(value = "休息结束时间")
|
||||
private Date restEndTime;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,51 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeekSet;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 周设置表视图对象 attendance_week_set
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceWeekSet.class)
|
||||
public class AttendanceWeekSetVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 固定班制关联id
|
||||
*/
|
||||
@ExcelProperty(value = "固定班制关联id")
|
||||
private Long fixedScheduleId;
|
||||
|
||||
/**
|
||||
* 星期(1代表周一,7代表周日)
|
||||
*/
|
||||
@ExcelProperty(value = "星期", converter = ExcelDictConvert.class)
|
||||
@ExcelDictFormat(readConverterExp = "1=代表周一,7代表周日")
|
||||
private Long dayOfWeek;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,56 @@
|
||||
package org.dromara.property.domain.vo;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeeksetShift;
|
||||
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import org.dromara.common.excel.annotation.ExcelDictFormat;
|
||||
import org.dromara.common.excel.convert.ExcelDictConvert;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 排班制表视图对象 attendance_weekset_shift
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Data
|
||||
@ExcelIgnoreUnannotated
|
||||
@AutoMapper(target = AttendanceWeeksetShift.class)
|
||||
public class AttendanceWeeksetShiftVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@ExcelProperty(value = "主键id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 班次id
|
||||
*/
|
||||
@ExcelProperty(value = "班次id")
|
||||
private Long weekId;
|
||||
|
||||
/**
|
||||
* 固定班制的的工作日id
|
||||
*/
|
||||
@ExcelProperty(value = "固定班制的的工作日id")
|
||||
private Long shiftSetId;
|
||||
|
||||
/**
|
||||
* 排班制的排班周期id
|
||||
*/
|
||||
@ExcelProperty(value = "排班制的排班周期id")
|
||||
private Long scheduleSchedule;
|
||||
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceArrangement;
|
||||
import org.dromara.property.domain.vo.AttendanceArrangementVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 排班Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceArrangementMapper extends BaseMapperPlus<AttendanceArrangement, AttendanceArrangementVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceClockDate;
|
||||
import org.dromara.property.domain.vo.AttendanceClockDateVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceClockDateMapper extends BaseMapperPlus<AttendanceClockDate, AttendanceClockDateVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceFixedSchedule;
|
||||
import org.dromara.property.domain.vo.AttendanceFixedScheduleVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 固定班制表Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceFixedScheduleMapper extends BaseMapperPlus<AttendanceFixedSchedule, AttendanceFixedScheduleVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceGroup;
|
||||
import org.dromara.property.domain.vo.AttendanceGroupVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 考勤组基本信息Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceGroupMapper extends BaseMapperPlus<AttendanceGroup, AttendanceGroupVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleCycle;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleCycleVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 排班周期表Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceScheduleCycleMapper extends BaseMapperPlus<AttendanceScheduleCycle, AttendanceScheduleCycleVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleMember;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleMemberVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 排班人员Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceScheduleMemberMapper extends BaseMapperPlus<AttendanceScheduleMember, AttendanceScheduleMemberVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShift;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 班次表Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceShiftMapper extends BaseMapperPlus<AttendanceShift, AttendanceShiftVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShiftSchedule;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftScheduleVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 排班制表Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceShiftScheduleMapper extends BaseMapperPlus<AttendanceShiftSchedule, AttendanceShiftScheduleVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeekSet;
|
||||
import org.dromara.property.domain.vo.AttendanceWeekSetVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 周设置表Mapper接口
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceWeekSetMapper extends BaseMapperPlus<AttendanceWeekSet, AttendanceWeekSetVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,15 @@
|
||||
package org.dromara.property.mapper;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeeksetShift;
|
||||
import org.dromara.property.domain.vo.AttendanceWeeksetShiftVo;
|
||||
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
|
||||
|
||||
/**
|
||||
* 排班制表Mapper接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface AttendanceWeeksetShiftMapper extends BaseMapperPlus<AttendanceWeeksetShift, AttendanceWeeksetShiftVo> {
|
||||
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceArrangement;
|
||||
import org.dromara.property.domain.vo.AttendanceArrangementVo;
|
||||
import org.dromara.property.domain.bo.AttendanceArrangementBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 排班Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceArrangementService {
|
||||
|
||||
/**
|
||||
* 查询排班
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班
|
||||
*/
|
||||
AttendanceArrangementVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询排班列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceArrangementVo> queryPageList(AttendanceArrangementBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班列表
|
||||
*/
|
||||
List<AttendanceArrangementVo> queryList(AttendanceArrangementBo bo);
|
||||
|
||||
/**
|
||||
* 新增排班
|
||||
*
|
||||
* @param bo 排班
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceArrangementBo bo);
|
||||
|
||||
/**
|
||||
* 修改排班
|
||||
*
|
||||
* @param bo 排班
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceArrangementBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceClockDate;
|
||||
import org.dromara.property.domain.vo.AttendanceClockDateVo;
|
||||
import org.dromara.property.domain.bo.AttendanceClockDateBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceClockDateService {
|
||||
|
||||
/**
|
||||
* 查询必须/无需打卡
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 必须/无需打卡
|
||||
*/
|
||||
AttendanceClockDateVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询必须/无需打卡列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 必须/无需打卡分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceClockDateVo> queryPageList(AttendanceClockDateBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的必须/无需打卡列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 必须/无需打卡列表
|
||||
*/
|
||||
List<AttendanceClockDateVo> queryList(AttendanceClockDateBo bo);
|
||||
|
||||
/**
|
||||
* 新增必须/无需打卡
|
||||
*
|
||||
* @param bo 必须/无需打卡
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceClockDateBo bo);
|
||||
|
||||
/**
|
||||
* 修改必须/无需打卡
|
||||
*
|
||||
* @param bo 必须/无需打卡
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceClockDateBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除必须/无需打卡信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceFixedSchedule;
|
||||
import org.dromara.property.domain.vo.AttendanceFixedScheduleVo;
|
||||
import org.dromara.property.domain.bo.AttendanceFixedScheduleBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 固定班制表Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceFixedScheduleService {
|
||||
|
||||
/**
|
||||
* 查询固定班制表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 固定班制表
|
||||
*/
|
||||
AttendanceFixedScheduleVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询固定班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 固定班制表分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceFixedScheduleVo> queryPageList(AttendanceFixedScheduleBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的固定班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 固定班制表列表
|
||||
*/
|
||||
List<AttendanceFixedScheduleVo> queryList(AttendanceFixedScheduleBo bo);
|
||||
|
||||
/**
|
||||
* 新增固定班制表
|
||||
*
|
||||
* @param bo 固定班制表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceFixedScheduleBo bo);
|
||||
|
||||
/**
|
||||
* 修改固定班制表
|
||||
*
|
||||
* @param bo 固定班制表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceFixedScheduleBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除固定班制表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceGroup;
|
||||
import org.dromara.property.domain.vo.AttendanceGroupVo;
|
||||
import org.dromara.property.domain.bo.AttendanceGroupBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 考勤组基本信息Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceGroupService {
|
||||
|
||||
/**
|
||||
* 查询考勤组基本信息
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 考勤组基本信息
|
||||
*/
|
||||
AttendanceGroupVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询考勤组基本信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 考勤组基本信息分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceGroupVo> queryPageList(AttendanceGroupBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的考勤组基本信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 考勤组基本信息列表
|
||||
*/
|
||||
List<AttendanceGroupVo> queryList(AttendanceGroupBo bo);
|
||||
|
||||
/**
|
||||
* 新增考勤组基本信息
|
||||
*
|
||||
* @param bo 考勤组基本信息
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceGroupBo bo);
|
||||
|
||||
/**
|
||||
* 修改考勤组基本信息
|
||||
*
|
||||
* @param bo 考勤组基本信息
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceGroupBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除考勤组基本信息信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleCycle;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleCycleVo;
|
||||
import org.dromara.property.domain.bo.AttendanceScheduleCycleBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 排班周期表Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceScheduleCycleService {
|
||||
|
||||
/**
|
||||
* 查询排班周期表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班周期表
|
||||
*/
|
||||
AttendanceScheduleCycleVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询排班周期表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班周期表分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceScheduleCycleVo> queryPageList(AttendanceScheduleCycleBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班周期表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班周期表列表
|
||||
*/
|
||||
List<AttendanceScheduleCycleVo> queryList(AttendanceScheduleCycleBo bo);
|
||||
|
||||
/**
|
||||
* 新增排班周期表
|
||||
*
|
||||
* @param bo 排班周期表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceScheduleCycleBo bo);
|
||||
|
||||
/**
|
||||
* 修改排班周期表
|
||||
*
|
||||
* @param bo 排班周期表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceScheduleCycleBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班周期表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceScheduleMember;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleMemberVo;
|
||||
import org.dromara.property.domain.bo.AttendanceScheduleMemberBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 排班人员Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceScheduleMemberService {
|
||||
|
||||
/**
|
||||
* 查询排班人员
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班人员
|
||||
*/
|
||||
AttendanceScheduleMemberVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询排班人员列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班人员分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceScheduleMemberVo> queryPageList(AttendanceScheduleMemberBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班人员列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班人员列表
|
||||
*/
|
||||
List<AttendanceScheduleMemberVo> queryList(AttendanceScheduleMemberBo bo);
|
||||
|
||||
/**
|
||||
* 新增排班人员
|
||||
*
|
||||
* @param bo 排班人员
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceScheduleMemberBo bo);
|
||||
|
||||
/**
|
||||
* 修改排班人员
|
||||
*
|
||||
* @param bo 排班人员
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceScheduleMemberBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班人员信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShiftSchedule;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftScheduleVo;
|
||||
import org.dromara.property.domain.bo.AttendanceShiftScheduleBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 排班制表Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceShiftScheduleService {
|
||||
|
||||
/**
|
||||
* 查询排班制表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班制表
|
||||
*/
|
||||
AttendanceShiftScheduleVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班制表分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceShiftScheduleVo> queryPageList(AttendanceShiftScheduleBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班制表列表
|
||||
*/
|
||||
List<AttendanceShiftScheduleVo> queryList(AttendanceShiftScheduleBo bo);
|
||||
|
||||
/**
|
||||
* 新增排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceShiftScheduleBo bo);
|
||||
|
||||
/**
|
||||
* 修改排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceShiftScheduleBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班制表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceShift;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftVo;
|
||||
import org.dromara.property.domain.bo.AttendanceShiftBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 班次表Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceShiftService {
|
||||
|
||||
/**
|
||||
* 查询班次表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 班次表
|
||||
*/
|
||||
AttendanceShiftVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询班次表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 班次表分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceShiftVo> queryPageList(AttendanceShiftBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的班次表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 班次表列表
|
||||
*/
|
||||
List<AttendanceShiftVo> queryList(AttendanceShiftBo bo);
|
||||
|
||||
/**
|
||||
* 新增班次表
|
||||
*
|
||||
* @param bo 班次表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceShiftBo bo);
|
||||
|
||||
/**
|
||||
* 修改班次表
|
||||
*
|
||||
* @param bo 班次表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceShiftBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除班次表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeekSet;
|
||||
import org.dromara.property.domain.vo.AttendanceWeekSetVo;
|
||||
import org.dromara.property.domain.bo.AttendanceWeekSetBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 周设置表Service接口
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceWeekSetService {
|
||||
|
||||
/**
|
||||
* 查询周设置表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 周设置表
|
||||
*/
|
||||
AttendanceWeekSetVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询周设置表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 周设置表分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceWeekSetVo> queryPageList(AttendanceWeekSetBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的周设置表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 周设置表列表
|
||||
*/
|
||||
List<AttendanceWeekSetVo> queryList(AttendanceWeekSetBo bo);
|
||||
|
||||
/**
|
||||
* 新增周设置表
|
||||
*
|
||||
* @param bo 周设置表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceWeekSetBo bo);
|
||||
|
||||
/**
|
||||
* 修改周设置表
|
||||
*
|
||||
* @param bo 周设置表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceWeekSetBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除周设置表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,69 @@
|
||||
package org.dromara.property.service;
|
||||
|
||||
import org.dromara.property.domain.AttendanceWeeksetShift;
|
||||
import org.dromara.property.domain.vo.AttendanceWeeksetShiftVo;
|
||||
import org.dromara.property.domain.bo.AttendanceWeeksetShiftBo;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 排班制表Service接口
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
public interface IAttendanceWeeksetShiftService {
|
||||
|
||||
/**
|
||||
* 查询排班制表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班制表
|
||||
*/
|
||||
AttendanceWeeksetShiftVo queryById(Long id);
|
||||
|
||||
/**
|
||||
* 分页查询排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班制表分页列表
|
||||
*/
|
||||
TableDataInfo<AttendanceWeeksetShiftVo> queryPageList(AttendanceWeeksetShiftBo bo, PageQuery pageQuery);
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班制表列表
|
||||
*/
|
||||
List<AttendanceWeeksetShiftVo> queryList(AttendanceWeeksetShiftBo bo);
|
||||
|
||||
/**
|
||||
* 新增排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
Boolean insertByBo(AttendanceWeeksetShiftBo bo);
|
||||
|
||||
/**
|
||||
* 修改排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
Boolean updateByBo(AttendanceWeeksetShiftBo bo);
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班制表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||
}
|
@@ -0,0 +1,138 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceArrangementBo;
|
||||
import org.dromara.property.domain.vo.AttendanceArrangementVo;
|
||||
import org.dromara.property.domain.AttendanceArrangement;
|
||||
import org.dromara.property.mapper.AttendanceArrangementMapper;
|
||||
import org.dromara.property.service.IAttendanceArrangementService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 排班Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceArrangementServiceImpl implements IAttendanceArrangementService {
|
||||
|
||||
private final AttendanceArrangementMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询排班
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班
|
||||
*/
|
||||
@Override
|
||||
public AttendanceArrangementVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询排班列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceArrangementVo> queryPageList(AttendanceArrangementBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceArrangement> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceArrangementVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceArrangementVo> queryList(AttendanceArrangementBo bo) {
|
||||
LambdaQueryWrapper<AttendanceArrangement> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceArrangement> buildQueryWrapper(AttendanceArrangementBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceArrangement> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceArrangement::getId);
|
||||
lqw.like(StringUtils.isNotBlank(bo.getScheduleName()), AttendanceArrangement::getScheduleName, bo.getScheduleName());
|
||||
lqw.eq(bo.getGroupId() != null, AttendanceArrangement::getGroupId, bo.getGroupId());
|
||||
lqw.eq(bo.getScheduleType() != null, AttendanceArrangement::getScheduleType, bo.getScheduleType());
|
||||
lqw.eq(bo.getDateType() != null, AttendanceArrangement::getDateType, bo.getDateType());
|
||||
lqw.eq(bo.getStartDate() != null, AttendanceArrangement::getStartDate, bo.getStartDate());
|
||||
lqw.eq(bo.getEndDate() != null, AttendanceArrangement::getEndDate, bo.getEndDate());
|
||||
lqw.eq(bo.getStatus() != null, AttendanceArrangement::getStatus, bo.getStatus());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班
|
||||
*
|
||||
* @param bo 排班
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceArrangementBo bo) {
|
||||
AttendanceArrangement add = MapstructUtils.convert(bo, AttendanceArrangement.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班
|
||||
*
|
||||
* @param bo 排班
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceArrangementBo bo) {
|
||||
AttendanceArrangement update = MapstructUtils.convert(bo, AttendanceArrangement.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceArrangement entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,138 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceClockDateBo;
|
||||
import org.dromara.property.domain.vo.AttendanceClockDateVo;
|
||||
import org.dromara.property.domain.AttendanceClockDate;
|
||||
import org.dromara.property.mapper.AttendanceClockDateMapper;
|
||||
import org.dromara.property.service.IAttendanceClockDateService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 必须/无需打卡Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceClockDateServiceImpl implements IAttendanceClockDateService {
|
||||
|
||||
private final AttendanceClockDateMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询必须/无需打卡
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 必须/无需打卡
|
||||
*/
|
||||
@Override
|
||||
public AttendanceClockDateVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询必须/无需打卡列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 必须/无需打卡分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceClockDateVo> queryPageList(AttendanceClockDateBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceClockDate> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceClockDateVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的必须/无需打卡列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 必须/无需打卡列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceClockDateVo> queryList(AttendanceClockDateBo bo) {
|
||||
LambdaQueryWrapper<AttendanceClockDate> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceClockDate> buildQueryWrapper(AttendanceClockDateBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceClockDate> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceClockDate::getId);
|
||||
lqw.eq(bo.getGroupId() != null, AttendanceClockDate::getGroupId, bo.getGroupId());
|
||||
lqw.eq(bo.getMustNoCheck() != null, AttendanceClockDate::getMustNoCheck, bo.getMustNoCheck());
|
||||
lqw.eq(bo.getDateType() != null, AttendanceClockDate::getDateType, bo.getDateType());
|
||||
lqw.eq(bo.getStartDate() != null, AttendanceClockDate::getStartDate, bo.getStartDate());
|
||||
lqw.eq(bo.getEndDate() != null, AttendanceClockDate::getEndDate, bo.getEndDate());
|
||||
lqw.eq(StringUtils.isNotBlank(bo.getReason()), AttendanceClockDate::getReason, bo.getReason());
|
||||
lqw.eq(bo.getCreatedBy() != null, AttendanceClockDate::getCreatedBy, bo.getCreatedBy());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增必须/无需打卡
|
||||
*
|
||||
* @param bo 必须/无需打卡
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceClockDateBo bo) {
|
||||
AttendanceClockDate add = MapstructUtils.convert(bo, AttendanceClockDate.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改必须/无需打卡
|
||||
*
|
||||
* @param bo 必须/无需打卡
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceClockDateBo bo) {
|
||||
AttendanceClockDate update = MapstructUtils.convert(bo, AttendanceClockDate.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceClockDate entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除必须/无需打卡信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,133 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceFixedScheduleBo;
|
||||
import org.dromara.property.domain.vo.AttendanceFixedScheduleVo;
|
||||
import org.dromara.property.domain.AttendanceFixedSchedule;
|
||||
import org.dromara.property.mapper.AttendanceFixedScheduleMapper;
|
||||
import org.dromara.property.service.IAttendanceFixedScheduleService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 固定班制表Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceFixedScheduleServiceImpl implements IAttendanceFixedScheduleService {
|
||||
|
||||
private final AttendanceFixedScheduleMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询固定班制表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 固定班制表
|
||||
*/
|
||||
@Override
|
||||
public AttendanceFixedScheduleVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询固定班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 固定班制表分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceFixedScheduleVo> queryPageList(AttendanceFixedScheduleBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceFixedSchedule> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceFixedScheduleVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的固定班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 固定班制表列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceFixedScheduleVo> queryList(AttendanceFixedScheduleBo bo) {
|
||||
LambdaQueryWrapper<AttendanceFixedSchedule> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceFixedSchedule> buildQueryWrapper(AttendanceFixedScheduleBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceFixedSchedule> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceFixedSchedule::getId);
|
||||
lqw.eq(bo.getGroupId() != null, AttendanceFixedSchedule::getGroupId, bo.getGroupId());
|
||||
lqw.like(StringUtils.isNotBlank(bo.getName()), AttendanceFixedSchedule::getName, bo.getName());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增固定班制表
|
||||
*
|
||||
* @param bo 固定班制表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceFixedScheduleBo bo) {
|
||||
AttendanceFixedSchedule add = MapstructUtils.convert(bo, AttendanceFixedSchedule.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改固定班制表
|
||||
*
|
||||
* @param bo 固定班制表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceFixedScheduleBo bo) {
|
||||
AttendanceFixedSchedule update = MapstructUtils.convert(bo, AttendanceFixedSchedule.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceFixedSchedule entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除固定班制表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,134 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceGroupBo;
|
||||
import org.dromara.property.domain.vo.AttendanceGroupVo;
|
||||
import org.dromara.property.domain.AttendanceGroup;
|
||||
import org.dromara.property.mapper.AttendanceGroupMapper;
|
||||
import org.dromara.property.service.IAttendanceGroupService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 考勤组基本信息Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceGroupServiceImpl implements IAttendanceGroupService {
|
||||
|
||||
private final AttendanceGroupMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询考勤组基本信息
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 考勤组基本信息
|
||||
*/
|
||||
@Override
|
||||
public AttendanceGroupVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询考勤组基本信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 考勤组基本信息分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceGroupVo> queryPageList(AttendanceGroupBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceGroup> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceGroupVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的考勤组基本信息列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 考勤组基本信息列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceGroupVo> queryList(AttendanceGroupBo bo) {
|
||||
LambdaQueryWrapper<AttendanceGroup> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceGroup> buildQueryWrapper(AttendanceGroupBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceGroup> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceGroup::getId);
|
||||
lqw.like(StringUtils.isNotBlank(bo.getGroupName()), AttendanceGroup::getGroupName, bo.getGroupName());
|
||||
lqw.eq(bo.getStatus() != null, AttendanceGroup::getStatus, bo.getStatus());
|
||||
lqw.eq(bo.getAttendanceType() != null, AttendanceGroup::getAttendanceType, bo.getAttendanceType());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增考勤组基本信息
|
||||
*
|
||||
* @param bo 考勤组基本信息
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceGroupBo bo) {
|
||||
AttendanceGroup add = MapstructUtils.convert(bo, AttendanceGroup.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改考勤组基本信息
|
||||
*
|
||||
* @param bo 考勤组基本信息
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceGroupBo bo) {
|
||||
AttendanceGroup update = MapstructUtils.convert(bo, AttendanceGroup.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceGroup entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除考勤组基本信息信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,134 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceScheduleCycleBo;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleCycleVo;
|
||||
import org.dromara.property.domain.AttendanceScheduleCycle;
|
||||
import org.dromara.property.mapper.AttendanceScheduleCycleMapper;
|
||||
import org.dromara.property.service.IAttendanceScheduleCycleService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 排班周期表Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceScheduleCycleServiceImpl implements IAttendanceScheduleCycleService {
|
||||
|
||||
private final AttendanceScheduleCycleMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询排班周期表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班周期表
|
||||
*/
|
||||
@Override
|
||||
public AttendanceScheduleCycleVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询排班周期表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班周期表分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceScheduleCycleVo> queryPageList(AttendanceScheduleCycleBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceScheduleCycle> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceScheduleCycleVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班周期表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班周期表列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceScheduleCycleVo> queryList(AttendanceScheduleCycleBo bo) {
|
||||
LambdaQueryWrapper<AttendanceScheduleCycle> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceScheduleCycle> buildQueryWrapper(AttendanceScheduleCycleBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceScheduleCycle> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceScheduleCycle::getId);
|
||||
lqw.eq(bo.getDayNumber() != null, AttendanceScheduleCycle::getDayNumber, bo.getDayNumber());
|
||||
lqw.eq(bo.getGroupId() != null, AttendanceScheduleCycle::getGroupId, bo.getGroupId());
|
||||
lqw.eq(bo.getIsRest() != null, AttendanceScheduleCycle::getIsRest, bo.getIsRest());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班周期表
|
||||
*
|
||||
* @param bo 排班周期表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceScheduleCycleBo bo) {
|
||||
AttendanceScheduleCycle add = MapstructUtils.convert(bo, AttendanceScheduleCycle.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班周期表
|
||||
*
|
||||
* @param bo 排班周期表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceScheduleCycleBo bo) {
|
||||
AttendanceScheduleCycle update = MapstructUtils.convert(bo, AttendanceScheduleCycle.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceScheduleCycle entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班周期表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,135 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceScheduleMemberBo;
|
||||
import org.dromara.property.domain.vo.AttendanceScheduleMemberVo;
|
||||
import org.dromara.property.domain.AttendanceScheduleMember;
|
||||
import org.dromara.property.mapper.AttendanceScheduleMemberMapper;
|
||||
import org.dromara.property.service.IAttendanceScheduleMemberService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 排班人员Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceScheduleMemberServiceImpl implements IAttendanceScheduleMemberService {
|
||||
|
||||
private final AttendanceScheduleMemberMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询排班人员
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班人员
|
||||
*/
|
||||
@Override
|
||||
public AttendanceScheduleMemberVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询排班人员列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班人员分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceScheduleMemberVo> queryPageList(AttendanceScheduleMemberBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceScheduleMember> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceScheduleMemberVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班人员列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班人员列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceScheduleMemberVo> queryList(AttendanceScheduleMemberBo bo) {
|
||||
LambdaQueryWrapper<AttendanceScheduleMember> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceScheduleMember> buildQueryWrapper(AttendanceScheduleMemberBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceScheduleMember> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceScheduleMember::getId);
|
||||
lqw.eq(bo.getScheduleId() != null, AttendanceScheduleMember::getScheduleId, bo.getScheduleId());
|
||||
lqw.eq(bo.getUserId() != null, AttendanceScheduleMember::getUserId, bo.getUserId());
|
||||
lqw.eq(bo.getDeptId() != null, AttendanceScheduleMember::getDeptId, bo.getDeptId());
|
||||
lqw.like(StringUtils.isNotBlank(bo.getDeptName()), AttendanceScheduleMember::getDeptName, bo.getDeptName());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班人员
|
||||
*
|
||||
* @param bo 排班人员
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceScheduleMemberBo bo) {
|
||||
AttendanceScheduleMember add = MapstructUtils.convert(bo, AttendanceScheduleMember.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班人员
|
||||
*
|
||||
* @param bo 排班人员
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceScheduleMemberBo bo) {
|
||||
AttendanceScheduleMember update = MapstructUtils.convert(bo, AttendanceScheduleMember.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceScheduleMember entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班人员信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,133 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceShiftScheduleBo;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftScheduleVo;
|
||||
import org.dromara.property.domain.AttendanceShiftSchedule;
|
||||
import org.dromara.property.mapper.AttendanceShiftScheduleMapper;
|
||||
import org.dromara.property.service.IAttendanceShiftScheduleService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 排班制表Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceShiftScheduleServiceImpl implements IAttendanceShiftScheduleService {
|
||||
|
||||
private final AttendanceShiftScheduleMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询排班制表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班制表
|
||||
*/
|
||||
@Override
|
||||
public AttendanceShiftScheduleVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班制表分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceShiftScheduleVo> queryPageList(AttendanceShiftScheduleBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceShiftSchedule> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceShiftScheduleVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班制表列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceShiftScheduleVo> queryList(AttendanceShiftScheduleBo bo) {
|
||||
LambdaQueryWrapper<AttendanceShiftSchedule> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceShiftSchedule> buildQueryWrapper(AttendanceShiftScheduleBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceShiftSchedule> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceShiftSchedule::getId);
|
||||
lqw.eq(bo.getGroupId() != null, AttendanceShiftSchedule::getGroupId, bo.getGroupId());
|
||||
lqw.like(StringUtils.isNotBlank(bo.getName()), AttendanceShiftSchedule::getName, bo.getName());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceShiftScheduleBo bo) {
|
||||
AttendanceShiftSchedule add = MapstructUtils.convert(bo, AttendanceShiftSchedule.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceShiftScheduleBo bo) {
|
||||
AttendanceShiftSchedule update = MapstructUtils.convert(bo, AttendanceShiftSchedule.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceShiftSchedule entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班制表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,138 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceShiftBo;
|
||||
import org.dromara.property.domain.vo.AttendanceShiftVo;
|
||||
import org.dromara.property.domain.AttendanceShift;
|
||||
import org.dromara.property.mapper.AttendanceShiftMapper;
|
||||
import org.dromara.property.service.IAttendanceShiftService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 班次表Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceShiftServiceImpl implements IAttendanceShiftService {
|
||||
|
||||
private final AttendanceShiftMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询班次表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 班次表
|
||||
*/
|
||||
@Override
|
||||
public AttendanceShiftVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询班次表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 班次表分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceShiftVo> queryPageList(AttendanceShiftBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceShift> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceShiftVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的班次表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 班次表列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceShiftVo> queryList(AttendanceShiftBo bo) {
|
||||
LambdaQueryWrapper<AttendanceShift> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceShift> buildQueryWrapper(AttendanceShiftBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceShift> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceShift::getId);
|
||||
lqw.like(StringUtils.isNotBlank(bo.getName()), AttendanceShift::getName, bo.getName());
|
||||
lqw.eq(bo.getStartTime() != null, AttendanceShift::getStartTime, bo.getStartTime());
|
||||
lqw.eq(bo.getEndTime() != null, AttendanceShift::getEndTime, bo.getEndTime());
|
||||
lqw.eq(bo.getStatus() != null, AttendanceShift::getStatus, bo.getStatus());
|
||||
lqw.eq(bo.getIsRest() != null, AttendanceShift::getIsRest, bo.getIsRest());
|
||||
lqw.eq(bo.getRestStartTime() != null, AttendanceShift::getRestStartTime, bo.getRestStartTime());
|
||||
lqw.eq(bo.getRestEndTime() != null, AttendanceShift::getRestEndTime, bo.getRestEndTime());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增班次表
|
||||
*
|
||||
* @param bo 班次表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceShiftBo bo) {
|
||||
AttendanceShift add = MapstructUtils.convert(bo, AttendanceShift.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改班次表
|
||||
*
|
||||
* @param bo 班次表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceShiftBo bo) {
|
||||
AttendanceShift update = MapstructUtils.convert(bo, AttendanceShift.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceShift entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除班次表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,133 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceWeekSetBo;
|
||||
import org.dromara.property.domain.vo.AttendanceWeekSetVo;
|
||||
import org.dromara.property.domain.AttendanceWeekSet;
|
||||
import org.dromara.property.mapper.AttendanceWeekSetMapper;
|
||||
import org.dromara.property.service.IAttendanceWeekSetService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 周设置表Service业务层处理
|
||||
*
|
||||
* @author dy
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceWeekSetServiceImpl implements IAttendanceWeekSetService {
|
||||
|
||||
private final AttendanceWeekSetMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询周设置表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 周设置表
|
||||
*/
|
||||
@Override
|
||||
public AttendanceWeekSetVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询周设置表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 周设置表分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceWeekSetVo> queryPageList(AttendanceWeekSetBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceWeekSet> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceWeekSetVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的周设置表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 周设置表列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceWeekSetVo> queryList(AttendanceWeekSetBo bo) {
|
||||
LambdaQueryWrapper<AttendanceWeekSet> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceWeekSet> buildQueryWrapper(AttendanceWeekSetBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceWeekSet> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceWeekSet::getId);
|
||||
lqw.eq(bo.getFixedScheduleId() != null, AttendanceWeekSet::getFixedScheduleId, bo.getFixedScheduleId());
|
||||
lqw.eq(bo.getDayOfWeek() != null, AttendanceWeekSet::getDayOfWeek, bo.getDayOfWeek());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增周设置表
|
||||
*
|
||||
* @param bo 周设置表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceWeekSetBo bo) {
|
||||
AttendanceWeekSet add = MapstructUtils.convert(bo, AttendanceWeekSet.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改周设置表
|
||||
*
|
||||
* @param bo 周设置表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceWeekSetBo bo) {
|
||||
AttendanceWeekSet update = MapstructUtils.convert(bo, AttendanceWeekSet.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceWeekSet entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除周设置表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,134 @@
|
||||
package org.dromara.property.service.impl;
|
||||
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.dromara.property.domain.bo.AttendanceWeeksetShiftBo;
|
||||
import org.dromara.property.domain.vo.AttendanceWeeksetShiftVo;
|
||||
import org.dromara.property.domain.AttendanceWeeksetShift;
|
||||
import org.dromara.property.mapper.AttendanceWeeksetShiftMapper;
|
||||
import org.dromara.property.service.IAttendanceWeeksetShiftService;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
* 排班制表Service业务层处理
|
||||
*
|
||||
* @author mocheng
|
||||
* @date 2025-07-15
|
||||
*/
|
||||
@Slf4j
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class AttendanceWeeksetShiftServiceImpl implements IAttendanceWeeksetShiftService {
|
||||
|
||||
private final AttendanceWeeksetShiftMapper baseMapper;
|
||||
|
||||
/**
|
||||
* 查询排班制表
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 排班制表
|
||||
*/
|
||||
@Override
|
||||
public AttendanceWeeksetShiftVo queryById(Long id){
|
||||
return baseMapper.selectVoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @param pageQuery 分页参数
|
||||
* @return 排班制表分页列表
|
||||
*/
|
||||
@Override
|
||||
public TableDataInfo<AttendanceWeeksetShiftVo> queryPageList(AttendanceWeeksetShiftBo bo, PageQuery pageQuery) {
|
||||
LambdaQueryWrapper<AttendanceWeeksetShift> lqw = buildQueryWrapper(bo);
|
||||
Page<AttendanceWeeksetShiftVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||
return TableDataInfo.build(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询符合条件的排班制表列表
|
||||
*
|
||||
* @param bo 查询条件
|
||||
* @return 排班制表列表
|
||||
*/
|
||||
@Override
|
||||
public List<AttendanceWeeksetShiftVo> queryList(AttendanceWeeksetShiftBo bo) {
|
||||
LambdaQueryWrapper<AttendanceWeeksetShift> lqw = buildQueryWrapper(bo);
|
||||
return baseMapper.selectVoList(lqw);
|
||||
}
|
||||
|
||||
private LambdaQueryWrapper<AttendanceWeeksetShift> buildQueryWrapper(AttendanceWeeksetShiftBo bo) {
|
||||
Map<String, Object> params = bo.getParams();
|
||||
LambdaQueryWrapper<AttendanceWeeksetShift> lqw = Wrappers.lambdaQuery();
|
||||
lqw.orderByAsc(AttendanceWeeksetShift::getId);
|
||||
lqw.eq(bo.getWeekId() != null, AttendanceWeeksetShift::getWeekId, bo.getWeekId());
|
||||
lqw.eq(bo.getShiftSetId() != null, AttendanceWeeksetShift::getShiftSetId, bo.getShiftSetId());
|
||||
lqw.eq(bo.getScheduleSchedule() != null, AttendanceWeeksetShift::getScheduleSchedule, bo.getScheduleSchedule());
|
||||
return lqw;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否新增成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean insertByBo(AttendanceWeeksetShiftBo bo) {
|
||||
AttendanceWeeksetShift add = MapstructUtils.convert(bo, AttendanceWeeksetShift.class);
|
||||
validEntityBeforeSave(add);
|
||||
boolean flag = baseMapper.insert(add) > 0;
|
||||
if (flag) {
|
||||
bo.setId(add.getId());
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改排班制表
|
||||
*
|
||||
* @param bo 排班制表
|
||||
* @return 是否修改成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean updateByBo(AttendanceWeeksetShiftBo bo) {
|
||||
AttendanceWeeksetShift update = MapstructUtils.convert(bo, AttendanceWeeksetShift.class);
|
||||
validEntityBeforeSave(update);
|
||||
return baseMapper.updateById(update) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存前的数据校验
|
||||
*/
|
||||
private void validEntityBeforeSave(AttendanceWeeksetShift entity){
|
||||
//TODO 做一些数据校验,如唯一约束
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验并批量删除排班制表信息
|
||||
*
|
||||
* @param ids 待删除的主键集合
|
||||
* @param isValid 是否进行有效性校验
|
||||
* @return 是否删除成功
|
||||
*/
|
||||
@Override
|
||||
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||
if(isValid){
|
||||
//TODO 做一些业务上的校验,判断是否需要校验
|
||||
}
|
||||
return baseMapper.deleteByIds(ids) > 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceArrangementMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceClockDateMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceFixedScheduleMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceGroupMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceScheduleCycleMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceScheduleMemberMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceShiftMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceShiftScheduleMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceWeekSetMapper">
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="org.dromara.property.mapper.AttendanceWeeksetShiftMapper">
|
||||
|
||||
</mapper>
|
Reference in New Issue
Block a user