//package com.backendsys.controller.Ai;
//
//import com.backendsys.entity.Ai.Aizn.AiznGood.AiznGoodCompoundTask.AiznGoodCompoundTaskDTO;
//import com.backendsys.entity.Ai.Aizn.AiznGood.AiznGoodReplaceTask.AiznGoodReplaceTaskDTO;
//import com.backendsys.service.Ai.Aizn.AiznGoodService;
//import com.backendsys.service.Ai.Aizn.AiznImageTaskService;
//import com.backendsys.utils.response.Result;
//import jakarta.validation.constraints.NotEmpty;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.security.access.prepost.PreAuthorize;
//import org.springframework.validation.annotation.Validated;
//import org.springframework.web.bind.annotation.GetMapping;
//import org.springframework.web.bind.annotation.PostMapping;
//import org.springframework.web.bind.annotation.RequestBody;
//import org.springframework.web.bind.annotation.RestController;
//
//import java.io.IOException;
//
//@RestController
//public class AiznGoodController {
//
//    @Autowired
//    private AiznImageTaskService aiznImageTaskService;
//
//    @Autowired
//    private AiznGoodService aiznGoodService;
//
//    /**
//     * [紫鸟] AI模特 - 商品合成 (发起任务)
//     */
//    @PreAuthorize("@sr.hasPermission('32')")
//    @PostMapping("/api/ai/zn/makeGoodCompoundTask")
//    public Result makeGoodCompoundTask(@Validated @RequestBody AiznGoodCompoundTaskDTO aiznGoodCompoundTaskDTO) {
//        return Result.success(aiznGoodService.makeGoodCompoundTask(aiznGoodCompoundTaskDTO));
//    }
//
//    /**
//     * [紫鸟] AI模特 - 商品合成 (查询任务)
//     */
//    @PreAuthorize("@sr.hasPermission('32')")
//    @GetMapping("/api/ai/zn/getProgressOfGoodCompoundTask")
//    public Result getProgressOfGoodCompoundTask(@NotEmpty(message = "任务ID 不能为空") String id) throws IOException {
//        return Result.success(aiznImageTaskService.getProgressOfTask(id, 11));
//    }
//
//    /**
//     * [紫鸟] AI模特 - 商品替换(发起任务)
//     */
//    @PreAuthorize("@sr.hasPermission('32')")
//    @PostMapping("/api/ai/zn/makeGoodReplaceTask")
//    public Result makeGoodReplaceTask(@Validated @RequestBody AiznGoodReplaceTaskDTO aiznGoodReplaceTaskDTO) {
//        return Result.success(aiznGoodService.makeGoodReplaceTask(aiznGoodReplaceTaskDTO));
//    }
//
//    /**
//     * [紫鸟] AI模特 - 商品合成 (查询任务)
//     */
//    @PreAuthorize("@sr.hasPermission('32')")
//    @GetMapping("/api/ai/zn/getProgressOfGoodReplaceTask")
//    public Result getProgressOfGoodReplaceTask(@NotEmpty(message = "任务ID 不能为空") String id) throws IOException {
//        return Result.success(aiznImageTaskService.getProgressOfTask(id, 12));
//    }
//
//}
