package cn.cslg.pas.mapper;
import cn.cslg.pas.common.model.QueryPatentVO;
import cn.cslg.pas.common.model.dto.PatentQueryFieldSourceDTO;
import cn.cslg.pas.common.model.vo.PatentQueryFieldSourceVO;
import cn.cslg.pas.common.model.vo.PatentVO;
import cn.cslg.pas.domain.Patent;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import java.util.List;
import java.util.Map;
/**
*
* 专利信息表 Mapper 接口
*
*
* @author 王岩
* @since 2021-12-26
*/
public interface PatentMapper extends BaseMapper {
Integer getDateTime(String ids, String column, String type);
Integer getDateTime2(String ids, Integer field, String type);
List getCustomFieldCount(@Param("ids") List ids, @Param("field") Integer field, @Param("mino") String mino, @Param("maxo") String maxo, @Param("minv") Integer minv, @Param("maxv") Integer maxv);
List getCustomFieldTime(@Param("ids") List ids, @Param("field") Integer field, @Param("startDate") Long startDate, @Param("endDate") Long endDate);
@MapKey("id")
Map getPatentListByIdAndColumn(Integer id, String column);
IPage getPageList(Page page, @Param("params") PatentVO params);
IPage getPageListForRMS2(Page page, @Param("params") QueryPatentVO params);
List getListForRMS( @Param("params")QueryPatentVO params);
List getPageList(@Param("params") PatentVO params);
IPage getPatentQuerySourcePageList(Page page, @Param("params") PatentQueryFieldSourceVO params, @Param("ids") List patentIds);
List getPatentQuerySourcePageList(@Param("params") PatentQueryFieldSourceVO params, @Param("ids") List patentIds);
@Select(" SELECT count(status) as count, status as label" +
" FROM os_patent_affair A\n" +
" where A.pid IN (SELECT op.id\n" +
" FROM os_patent op\n" +
" LEFT JOIN os_thematic_pid c on c.pid = op.id\n" +
" where c.zid = #{projectId})\n" +
" group by status ")
List getCountStatus(@Param("projectId") Integer projectId);
List getPatent(@Param("patentNo")List patentNo,@Param("n")int n,@Param("p")int p);
int getPatentNumber(@Param("patentNo")List patentNo);
List getConPantentNos(@Param("params") QueryPatentVO params);
List getConPantents(@Param("params") QueryPatentVO params);
Integer getConPantentsCount(@Param("params") QueryPatentVO params);
}