Commit 79de5a00 authored by lwy's avatar lwy

工时管理

parent 1322ac77
...@@ -36,6 +36,7 @@ public class TimesheetController extends BaseController ...@@ -36,6 +36,7 @@ public class TimesheetController extends BaseController
@Autowired @Autowired
private ITimesheetService timesheetService; private ITimesheetService timesheetService;
/** /**
* 查询工时记录列表 * 查询工时记录列表
*/ */
...@@ -44,7 +45,7 @@ public class TimesheetController extends BaseController ...@@ -44,7 +45,7 @@ public class TimesheetController extends BaseController
public TableDataInfo list(Timesheet timesheet) public TableDataInfo list(Timesheet timesheet)
{ {
startPage(); startPage();
List<TimesheetVo> list = timesheetService.selectTimesheetList(timesheet); List<Timesheet> list = timesheetService.selectTimesheetList(timesheet);
return getDataTable(list); return getDataTable(list);
} }
...@@ -52,6 +53,32 @@ public class TimesheetController extends BaseController ...@@ -52,6 +53,32 @@ public class TimesheetController extends BaseController
* 导出工时记录列表 * 导出工时记录列表
*/ */
@PreAuthorize("@ss.hasPermi('timesheet:timesheet:export')") @PreAuthorize("@ss.hasPermi('timesheet:timesheet:export')")
@Log(title = "工时记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, Timesheet timesheet)
{
List<Timesheet> list = timesheetService.selectTimesheetList(timesheet);
ExcelUtil<Timesheet> util = new ExcelUtil<Timesheet>(Timesheet.class);
util.exportExcel(response, list, "工时记录数据");
}
/**
* 查询工时记录列表
*/
/*@PreAuthorize("@ss.hasPermi('timesheet:timesheet:list')")
@GetMapping("/list")
public TableDataInfo list(Timesheet timesheet)
{
startPage();
List<TimesheetVo> list = timesheetService.selectTimesheetList(timesheet);
return getDataTable(list);
}*/
/**
* 导出工时记录列表
*/
/* @PreAuthorize("@ss.hasPermi('timesheet:timesheet:export')")
@Log(title = "工时记录", businessType = BusinessType.EXPORT) @Log(title = "工时记录", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, Timesheet timesheet) public void export(HttpServletResponse response, Timesheet timesheet)
...@@ -59,7 +86,7 @@ public class TimesheetController extends BaseController ...@@ -59,7 +86,7 @@ public class TimesheetController extends BaseController
List<TimesheetVo> list = timesheetService.selectTimesheetList(timesheet); List<TimesheetVo> list = timesheetService.selectTimesheetList(timesheet);
ExcelUtil<TimesheetVo> util = new ExcelUtil<TimesheetVo>(TimesheetVo.class); ExcelUtil<TimesheetVo> util = new ExcelUtil<TimesheetVo>(TimesheetVo.class);
util.exportExcel(response, list, "工时记录数据"); util.exportExcel(response, list, "工时记录数据");
} }*/
/** /**
* 获取工时记录详细信息 * 获取工时记录详细信息
......
...@@ -28,7 +28,16 @@ public interface ITimesheetService ...@@ -28,7 +28,16 @@ public interface ITimesheetService
*/ */
// public List<TimesheetVo> selectTimesheetList(Timesheet timesheet); // public List<TimesheetVo> selectTimesheetList(Timesheet timesheet);
/**
* 查询工时记录列表
*
* @param timesheet 工时记录
* @return 工时记录集合
*/
public List<Timesheet> selectTimesheetList(Timesheet timesheet);
/** /**
*
* 新增工时记录 * 新增工时记录
* *
* @param timesheet 工时记录 * @param timesheet 工时记录
......
...@@ -37,6 +37,18 @@ public class TimesheetServiceImpl implements ITimesheetService ...@@ -37,6 +37,18 @@ public class TimesheetServiceImpl implements ITimesheetService
return timesheetMapper.selectTimesheetById(id); return timesheetMapper.selectTimesheetById(id);
} }
/**
* 查询工时记录列表
*
* @param timesheet 工时记录
* @return 工时记录
*/
@Override
public List<Timesheet> selectTimesheetList(Timesheet timesheet)
{
return timesheetMapper.selectTimesheetList(timesheet);
}
/** /**
* 查询工时记录列表 * 查询工时记录列表
* *
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment