package cn.cslg.report.controller;

import cn.cslg.report.common.core.base.Constants;
import cn.cslg.report.common.model.dto.PatentQueryFieldSourceDTO;
import cn.cslg.report.common.model.vo.CompareFileVO;
import cn.cslg.report.common.model.vo.PatentIndexSettingVO;
import cn.cslg.report.common.model.vo.PatentQueryFieldSourceVO;
import cn.cslg.report.common.utils.Response;
import cn.cslg.report.entity.CompareFiles;
import cn.cslg.report.service.business.CompareFilesService;

import com.baomidou.mybatisplus.core.metadata.IPage;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor;
import org.springframework.context.annotation.Lazy;
import org.springframework.web.bind.annotation.*;

import java.io.IOException;
import java.util.List;


@Tag(name = "初选")
@RestController
@RequestMapping(Constants.REPORT_API + "/CompareFiles")
@RequiredArgsConstructor(onConstructor_ = {@Lazy})
public class CompareFilesController {
    private final CompareFilesService compareFilesService;

    @GetMapping("/index/setting/all")
    @Operation(summary ="获取当前所有的,传过来报告（int）id，和（String）专利号")
    public String settingAll(Integer reportId, String patentNos)throws IOException{
         return Response.success(compareFilesService.setAll(reportId,patentNos));
    }
    @PostMapping("/index/setting")
    @Operation(summary = "获取专利标引情况")
    public String getPatentIndexSetting(@RequestBody PatentIndexSettingVO params) throws IOException {
         compareFilesService.getPatentIndexSetting(params);
       return Response.success();
    }






}
