| | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.annotation.Log; |
| | | import com.ruoyi.common.annotation.RepeatSubmit; |
| | | import com.ruoyi.common.annotation.UniqueCheck; |
| | | import com.ruoyi.common.core.controller.BaseController; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.enums.BusinessType; |
| | | import com.ruoyi.common.utils.PageUtils; |
| | | import com.ruoyi.common.utils.poi.ExcelUtil; |
| | | import com.ruoyi.project.domain.ServiceDonateorganBase; |
| | | import com.ruoyi.project.domain.vo.ServiceDonateorganBaseVO; |
| | | import com.ruoyi.project.domain.dto.DonateorganBaseInfoDTO; |
| | | import com.ruoyi.project.domain.vo.DonateorganBaseInfoVO; |
| | | import com.ruoyi.project.service.IServiceDonateorganBaseService; |
| | |
| | | /** |
| | | * 查询捐献器官分配基础列表 |
| | | */ |
| | | @ApiOperation("查询捐献器官分配基础列表") |
| | | @ApiOperation("查询器官分配基础列表") |
| | | @PostMapping("/list") |
| | | public Map<String, Object> list(@RequestBody ServiceDonateorganBase serviceDonateorganBase) { |
| | | Page<ServiceDonateorganBase> list = serviceDonateorganBaseService.queryList(serviceDonateorganBase); |
| | |
| | | return AjaxResult.success(serviceDonateorganBaseService.getById(id)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 新增捐献器官分配基础 |
| | | */ |
| | | @ApiOperation("新增捐献器官分配基础") |
| | | // @PreAuthorize("@ss.hasPermi('project:base:add')") |
| | | @Log(title = "捐献器官分配基础", businessType = BusinessType.INSERT) |
| | | @UniqueCheck( |
| | | fields = {"infoid"}, |
| | | entityClass = ServiceDonateorganBaseVO.class, |
| | | serviceClass = IServiceDonateorganBaseService.class, |
| | | message = "新增伦理审查的infoid已存在,无法保存!" |
| | | ) |
| | | @PostMapping("/add") |
| | | @RepeatSubmit |
| | | public AjaxResult add(@RequestBody ServiceDonateorganBase serviceDonateorganBase) { |
| | | return toAjax(serviceDonateorganBaseService.save(serviceDonateorganBase)); |
| | | public AjaxResult add(@RequestBody ServiceDonateorganBaseVO serviceDonateorganBaseVO) { |
| | | return toAjax(serviceDonateorganBaseService.add(serviceDonateorganBaseVO)); |
| | | } |
| | | |
| | | /** |
| | |
| | | @Log(title = "捐献器官分配基础", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/edit") |
| | | @RepeatSubmit |
| | | public AjaxResult edit(@RequestBody ServiceDonateorganBase serviceDonateorganBase) { |
| | | return toAjax(serviceDonateorganBaseService.updateById(serviceDonateorganBase)); |
| | | public AjaxResult edit(@RequestBody ServiceDonateorganBaseVO serviceDonateorganBaseVO) { |
| | | return toAjax(serviceDonateorganBaseService.updateByParam(serviceDonateorganBaseVO)); |
| | | } |
| | | |
| | | /** |