package com.chenyang.nse.bussiness.dao.table.core.subset;

import com.chenyang.nse.bussiness.dao.BaseDao;
import com.chenyang.nse.bussiness.entity.orm.table.core.subset.TCoreSubsetTable;
import com.chenyang.nse.bussiness.entity.vo.ComboboxVO;
import java.util.List;
import org.hibernate.transform.Transformers;
import org.springframework.stereotype.Repository;

@Repository
public class TCoreSubsetTableDao extends BaseDao<TCoreSubsetTable, String> {
   public List<ComboboxVO> getTableNames(String subsetnameid) {
      String sql = "select id as value, tablename as text  from t_core_subset_table where subsetid='" + subsetnameid + "'";
      List<ComboboxVO> vo = this.getSession().createNativeQuery(sql).setResultTransformer(Transformers.ALIAS_TO_ENTITY_MAP).getResultList();
      return vo;
   }
}
