public static int Execute(string query, object param = null) { using (var conn = DataBaseConfig.GetSqlConnection()) { return(conn.Execute(query, param)); } }
public static List <T> Query <T>(string query, object param = null) { using (var conn = DataBaseConfig.GetSqlConnection()) { return(conn.Query <T>(query, param)?.ToList()); } }