| | |
| | | |
| | | /** |
| | | * 捐献随访Controller |
| | | * |
| | | * |
| | | * @author ruoyi |
| | | * @date 2021-12-10 |
| | | */ |
| | | @Api("捐献随访") |
| | | @RestController |
| | | @RequestMapping("/project/donatefollowup") |
| | | public class ServiceDonatefollowupController extends BaseController |
| | | { |
| | | public class ServiceDonatefollowupController extends BaseController { |
| | | @Autowired |
| | | private IServiceDonatefollowupService serviceDonatefollowupService; |
| | | |
| | |
| | | @ApiOperation("查询捐献随访列表") |
| | | //@PreAuthorize("@ss.hasPermi('project:donatefollowup:list')") |
| | | @GetMapping("/list") |
| | | public TableDataInfo list(ServiceDonatefollowup serviceDonatefollowup) |
| | | { |
| | | public TableDataInfo list(ServiceDonatefollowup serviceDonatefollowup) { |
| | | startPage(); |
| | | //List<ServiceDonatefollowup> list = serviceDonatefollowupService.queryList(serviceDonatefollowup); |
| | | List<ServiceDonatefollowup> list = serviceDonatefollowupService.selectAll(serviceDonatefollowup); |
| | |
| | | } |
| | | |
| | | @GetMapping("/listnew") |
| | | public TableDataInfo listnew (DonateFollowupVO donateFollowupVO){ |
| | | public TableDataInfo listnew(DonateFollowupVO donateFollowupVO) { |
| | | startPage(); |
| | | List<DonateFollowupVO> list = serviceDonatefollowupService.selectVOList(donateFollowupVO); |
| | | return getDataTable(list); |
| | |
| | | //@PreAuthorize("@ss.hasPermi('project:donatefollowup:export')") |
| | | @Log(title = "捐献随访", businessType = BusinessType.EXPORT) |
| | | @GetMapping("/export") |
| | | public AjaxResult export(ServiceDonatefollowup serviceDonatefollowup) |
| | | { |
| | | public AjaxResult export(ServiceDonatefollowup serviceDonatefollowup) { |
| | | List<ServiceDonatefollowup> list = serviceDonatefollowupService.queryList(serviceDonatefollowup); |
| | | ExcelUtil<ServiceDonatefollowup> util = new ExcelUtil<ServiceDonatefollowup>(ServiceDonatefollowup.class); |
| | | return util.exportExcel(list, "捐献随访数据"); |
| | |
| | | @ApiOperation("获取捐献随访详细信息") |
| | | //@PreAuthorize("@ss.hasPermi('project:donatefollowup:query')") |
| | | @GetMapping(value = "/{id}") |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) |
| | | { |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) { |
| | | //return AjaxResult.success(serviceDonatefollowupService.getById(id)); |
| | | return AjaxResult.success(serviceDonatefollowupService.selectFollowUpById(id)); |
| | | } |
| | |
| | | @ApiOperation("新增捐献随访") |
| | | //@PreAuthorize("@ss.hasPermi('project:donatefollowup:add')") |
| | | @Log(title = "捐献随访", businessType = BusinessType.INSERT) |
| | | @PostMapping |
| | | @PostMapping("/add") |
| | | @RepeatSubmit |
| | | public AjaxResult add(@RequestBody ServiceDonatefollowup serviceDonatefollowup) |
| | | { |
| | | return toAjax(serviceDonatefollowupService.save(serviceDonatefollowup)); |
| | | public AjaxResult add(@RequestBody ServiceDonatefollowup serviceDonatefollowup) { |
| | | boolean save = serviceDonatefollowupService.save(serviceDonatefollowup); |
| | | return AjaxResult.success(serviceDonatefollowup); |
| | | } |
| | | |
| | | /** |
| | |
| | | //@PreAuthorize("@ss.hasPermi('project:donatefollowup:edit')") |
| | | @Log(title = "捐献随访", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/edit") |
| | | @RepeatSubmit |
| | | public AjaxResult edit(@RequestBody ServiceDonatefollowup serviceDonatefollowup) |
| | | { |
| | | @RepeatSubmit |
| | | public AjaxResult edit(@RequestBody ServiceDonatefollowup serviceDonatefollowup) { |
| | | return toAjax(serviceDonatefollowupService.updateById(serviceDonatefollowup)); |
| | | |
| | | } |
| | |
| | | //@PreAuthorize("@ss.hasPermi('project:donatefollowup:remove')") |
| | | @Log(title = "捐献随访", businessType = BusinessType.DELETE) |
| | | @GetMapping("/remove/{ids}") |
| | | public AjaxResult remove(@PathVariable Long[] ids) |
| | | { |
| | | public AjaxResult remove(@PathVariable Long[] ids) { |
| | | return toAjax(serviceDonatefollowupService.removeByIds(Arrays.asList(ids))); |
| | | } |
| | | } |