/// <summary> /// 获取未使用链接列表 /// </summary> /// <param name="host"></param> /// <param name="depth"></param> /// <returns></returns> public static List <UrlEntity> GetList(string host) { string where = "isUser=0"; if (!string.IsNullOrEmpty(host)) { where += string.Format(" and [Host]='{0}' ", host); } return(UrlDAL.Search(where, "Id", 0)); }
/// <summary> /// 获取链接列表 /// </summary> /// <param name="host"></param> /// <param name="depth"></param> /// <returns></returns> public static List <UrlEntity> GetList(string host, int depth) { string where = string.Empty; if (!string.IsNullOrEmpty(host)) { where += string.Format("[Host]='{0}' and ", host); } if (depth > 0) { where += string.Format("[Depth]={0} and ", depth); } if (!string.IsNullOrEmpty(where)) { where = where.Remove(where.Length - 4, 4); } return(UrlDAL.Search(where, "Id", 0)); }