package com.foreverwin.mesnac.equip.mapper;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.foreverwin.mesnac.equip.model.EdcDataResource;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author pavel.liu
 * @since 2021-07-13
 */
@Repository
public interface EdcDataResourceMapper extends BaseMapper<EdcDataResource> {

    /**
     * 设备HANDLE，获取维护好的数据收集组
     * @param resourceBo
     * @return
     */
    String getDcGroupBoByResourceBo(@Param("resourceBo")String resourceBo);

    String getDcGroupBoByResourceBo2(@Param("resourceBo")String resourceBo);

    /**
     * 数据插入
     * @param
     */
    void insertOneResourceParam(@Param("tableName")String tableName,EdcDataResource edcDataResource);
//    void insertOneResourceParam(@Param("entity")EdcDataResource entity);

    /**
     * 执行新增SQL
     *
     * @param sqlStr
     * @return
     */
    int insertBySql(@Param(value="sqlStr") String sqlStr);

}