| | |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | |
| | | |
| | | /** |
| | | * 专家费用分发汇总主Controller |
| | | * |
| | | * |
| | | * @author ruoyi |
| | | * @date 2022-03-01 |
| | | */ |
| | | @Slf4j |
| | | @Api("专家费用分发汇总主") |
| | | @RestController |
| | | @RequestMapping("/project/distributesummary") |
| | | public class ServiceDistributesummaryController extends BaseController |
| | | { |
| | | public class ServiceDistributesummaryController extends BaseController { |
| | | @Autowired |
| | | private IServiceDistributesummaryService serviceDistributesummaryService; |
| | | |
| | |
| | | */ |
| | | @ApiOperation("查询专家费用分发汇总主列表") |
| | | @GetMapping("/list") |
| | | public TableDataInfo list(ServiceDistributesummary serviceDistributesummary) |
| | | { |
| | | public TableDataInfo list(ServiceDistributesummary serviceDistributesummary) { |
| | | log.info("查询专家费用分发汇总主列表:{}", serviceDistributesummary); |
| | | startPage(); |
| | | List<ServiceDistributesummary> list = serviceDistributesummaryService.queryList(serviceDistributesummary); |
| | | return getDataTable(list); |
| | |
| | | @ApiOperation("导出专家费用分发汇总主列表") |
| | | @Log(title = "专家费用分发汇总主", businessType = BusinessType.EXPORT) |
| | | @GetMapping("/export") |
| | | public AjaxResult export(ServiceDistributesummary serviceDistributesummary) |
| | | { |
| | | public AjaxResult export(ServiceDistributesummary serviceDistributesummary) { |
| | | log.info("导出专家费用分发汇总主列表:{}", serviceDistributesummary); |
| | | List<ServiceDistributesummary> list = serviceDistributesummaryService.queryList(serviceDistributesummary); |
| | | ExcelUtil<ServiceDistributesummary> util = new ExcelUtil<ServiceDistributesummary>(ServiceDistributesummary.class); |
| | | return util.exportExcel(list, "专家费用分发汇总主数据"); |
| | |
| | | */ |
| | | @ApiOperation("获取专家费用分发汇总主详细信息") |
| | | @GetMapping(value = "/{id}") |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) |
| | | { |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) { |
| | | log.info("获取专家费用分发汇总主详细信息:{}", id); |
| | | return AjaxResult.success(serviceDistributesummaryService.getById(id)); |
| | | } |
| | | |
| | |
| | | */ |
| | | @ApiOperation("新增专家费用分发汇总主") |
| | | @Log(title = "专家费用分发汇总主", businessType = BusinessType.INSERT) |
| | | @PostMapping |
| | | @PostMapping("/add") |
| | | @RepeatSubmit |
| | | public AjaxResult add(@RequestBody ServiceDistributesummary serviceDistributesummary) |
| | | { |
| | | return toAjax(serviceDistributesummaryService.save(serviceDistributesummary)); |
| | | public AjaxResult add(@RequestBody ServiceDistributesummary serviceDistributesummary) { |
| | | log.info("新增专家费用分发汇总主:{}", serviceDistributesummary); |
| | | boolean save = serviceDistributesummaryService.save(serviceDistributesummary); |
| | | log.info("新增专家费用分发汇总主serviceDistributesummary的ID:{}", serviceDistributesummary.getId()); |
| | | return AjaxResult.success(serviceDistributesummary); |
| | | } |
| | | |
| | | /** |
| | |
| | | @ApiOperation("修改专家费用分发汇总主") |
| | | @Log(title = "专家费用分发汇总主", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/edit") |
| | | @RepeatSubmit |
| | | public AjaxResult edit(@RequestBody ServiceDistributesummary serviceDistributesummary) |
| | | { |
| | | @RepeatSubmit |
| | | public AjaxResult edit(@RequestBody ServiceDistributesummary serviceDistributesummary) { |
| | | log.info("修改专家费用分发汇总主:{}", serviceDistributesummary); |
| | | return toAjax(serviceDistributesummaryService.updateById(serviceDistributesummary)); |
| | | } |
| | | |
| | |
| | | @ApiOperation("删除专家费用分发汇总主") |
| | | @Log(title = "专家费用分发汇总主", businessType = BusinessType.DELETE) |
| | | @GetMapping("/remove/{ids}") |
| | | public AjaxResult remove(@PathVariable Long[] ids) |
| | | { |
| | | public AjaxResult remove(@PathVariable Long[] ids) { |
| | | log.info("删除专家费用分发汇总主:{}", ids); |
| | | return toAjax(serviceDistributesummaryService.removeByIds(Arrays.asList(ids))); |
| | | } |
| | | |
| | | @GetMapping(value ="/getSummaryByInfoId/{infoid}") |
| | | public AjaxResult getSummaryByInfoId(@PathVariable("infoid") Long infoid){ |
| | | @GetMapping(value = "/getSummaryByInfoId/{infoid}") |
| | | public AjaxResult getSummaryByInfoId(@PathVariable("infoid") Long infoid) { |
| | | log.info("getSummaryByInfoId的入参:{}", infoid); |
| | | return AjaxResult.success(serviceDistributesummaryService.getSummaryByInfoId(infoid)); |
| | | } |
| | | |
| | | |
| | | |
| | | } |