办公V3
This commit is contained in:
@@ -27,40 +27,34 @@ public class HrmShiftController extends BaseController {
|
||||
|
||||
private final IHrmShiftService service;
|
||||
|
||||
@SaCheckPermission("hrm:shift:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<HrmShiftVo> list(HrmShiftBo bo, PageQuery pageQuery) {
|
||||
return service.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
@SaCheckPermission("hrm:shift:query")
|
||||
@GetMapping("/{shiftId}")
|
||||
public R<HrmShiftVo> getInfo(@PathVariable @NotNull Long shiftId) {
|
||||
return R.ok(service.queryById(shiftId));
|
||||
}
|
||||
|
||||
@SaCheckPermission("hrm:shift:add")
|
||||
@Log(title = "班次", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public R<Void> add(@Validated @RequestBody HrmShiftBo bo) {
|
||||
return toAjax(service.insertByBo(bo));
|
||||
}
|
||||
|
||||
@SaCheckPermission("hrm:shift:edit")
|
||||
@Log(title = "班次", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public R<Void> edit(@Validated @RequestBody HrmShiftBo bo) {
|
||||
return toAjax(service.updateByBo(bo));
|
||||
}
|
||||
|
||||
@SaCheckPermission("hrm:shift:remove")
|
||||
@Log(title = "班次", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{shiftIds}")
|
||||
public R<Void> remove(@PathVariable @NotEmpty Long[] shiftIds) {
|
||||
return toAjax(service.deleteWithValidByIds(Arrays.asList(shiftIds), true));
|
||||
}
|
||||
|
||||
@SaCheckPermission("hrm:shift:list")
|
||||
@GetMapping("/all")
|
||||
public R<List<HrmShiftVo>> all(HrmShiftBo bo) {
|
||||
return R.ok(service.queryList(bo));
|
||||
|
||||
Reference in New Issue
Block a user