| | |
| | | import com.iailab.framework.common.pojo.CommonResult; |
| | | import com.iailab.framework.common.pojo.PageResult; |
| | | import com.iailab.framework.common.util.object.BeanUtils; |
| | | import com.iailab.framework.idempotent.core.annotation.Idempotent; |
| | | import com.iailab.module.data.common.xss.SQLFilter; |
| | | import com.iailab.module.data.plan.data.entity.PlanDataSetEntity; |
| | | import com.iailab.module.data.plan.data.service.PlanDataSetService; |
| | |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "创建计划数据集") |
| | | @Idempotent(timeout = 5, message = "重复请求,请稍后重试") |
| | | @PreAuthorize("@ss.hasPermission('data:plan-data-set:create')") |
| | | public CommonResult<Boolean> create(@Valid @RequestBody PlanDataSetSaveReqVO createReqVO) { |
| | | SQLFilter.sqlInject(createReqVO.getQuerySql()); |
| | | SQLFilter.sqlInject2(createReqVO.getQuerySql()); |
| | | indDataSetService.create(createReqVO); |
| | | return success(true); |
| | | } |
| | |
| | | @Operation(summary = "修改计划数据集") |
| | | @PreAuthorize("@ss.hasPermission('data:plan-data-set:update')") |
| | | public CommonResult<Boolean> update(@Valid @RequestBody PlanDataSetSaveReqVO updateReqVO) { |
| | | SQLFilter.sqlInject(updateReqVO.getQuerySql()); |
| | | SQLFilter.sqlInject2(updateReqVO.getQuerySql()); |
| | | indDataSetService.update(updateReqVO); |
| | | return success(true); |
| | | } |