package com.yh.saas.plugin.news.mapper;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.yh.saas.plugin.news.entity.ParameterCompany;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author Chenly
 * @since 2019-10-10
 */
public interface NewsParameterCompanyMapper extends BaseMapper<ParameterCompany> {

    @Select("<script>"
            + "SELECT "
            + " MAX(parameter_key) "
            + " FROM"
            + " news_parameter_company "
            + " WHERE"
            + " comp_id = #{compId} and"
            + " const_code = #{constCode}"
            + "</script>")
    Integer selectMaxkey(@Param("compId")String compId, @Param("constCode")String constCode);


}
