dengzedong
2024-10-14 3e18d4bfbf2c657b08b21512c2d884cc9d59df7b
iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/kio/controller/admin/ChannelKioTagController.java
@@ -8,6 +8,7 @@
import com.iailab.module.data.channel.kio.vo.KioTagPageReqVO;
import com.iailab.module.data.channel.kio.vo.KioTagRespVO;
import io.swagger.v3.oas.annotations.Operation;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
@@ -18,9 +19,7 @@
import static com.iailab.framework.common.pojo.CommonResult.success;
/**
 * @author lirm
 * @Description
 * @createTime 2024年08月26日
 */
@RestController
@RequestMapping("/data/channel/kio/tag")
@@ -31,12 +30,14 @@
    /**
     * 分页查询tag
     * */
    @PreAuthorize("@ss.hasPermission('data:channel-kio:query')")
    @GetMapping("page")
    public CommonResult<PageResult<KioTagRespVO>> page(@Valid KioTagPageReqVO reqVO){
        PageResult<ChannelKioTagEntity> page = channelKioTagService.queryPage(reqVO);
        return success(BeanUtils.toBean(page, KioTagRespVO.class));
    }
    @PreAuthorize("@ss.hasPermission('data:channel-kio:query')")
    @GetMapping("/info/{id}")
    @Operation(summary = "信息")
    public CommonResult<ChannelKioTagEntity> info(@PathVariable("id") String id) {
@@ -44,8 +45,9 @@
        return success(info);
    }
    @PostMapping("/add")
    public CommonResult<Boolean> add(@RequestBody ChannelKioTagEntity channelKioTagEntity) {
    @PreAuthorize("@ss.hasPermission('data:channel-kio:create')")
    @PostMapping("/create")
    public CommonResult<Boolean> create(@RequestBody ChannelKioTagEntity channelKioTagEntity) {
        String id = UUID.randomUUID().toString();
        channelKioTagEntity.setId(id);
        channelKioTagEntity.setCreateTime(new Date());
@@ -53,6 +55,7 @@
        return success(true);
    }
    @PreAuthorize("@ss.hasPermission('data:channel-kio:update')")
    @PutMapping("/update")
    public CommonResult<Boolean> update(@RequestBody ChannelKioTagEntity channelKioTagEntity) {
        channelKioTagEntity.setUpdateTime(new Date());
@@ -60,6 +63,7 @@
        return success(true);
    }
    @PreAuthorize("@ss.hasPermission('data:channel-kio:delete')")
    @DeleteMapping("/delete")
    public CommonResult<Boolean> delete(@RequestParam("id") String id) {
        channelKioTagService.delete(id);