using System;
using System.Data;
using System.Collections.Generic;

namespace DTcms.BLL
{
	/// <summary>
	/// ÄÚÈÝÆÀÂÛ
	/// </summary>
	public partial class article_comment
	{
        private readonly Model.siteconfig siteConfig = new BLL.siteconfig().loadConfig(); //»ñµÃÕ¾µãÅäÖÃÐÅÏ¢
        private readonly DAL.article_comment dal;
		public article_comment()
		{
            dal = new DAL.article_comment(siteConfig.sysdatabaseprefix);
        }

        #region »ù±¾·½·¨===========================
        /// <summary>
		/// ÊÇ·ñ´æÔÚ¸Ã¼ÇÂ¼
		/// </summary>
		public bool Exists(int id)
		{
			return dal.Exists(id);
		}

        /// <summary>
        /// ·µ»ØÊý¾Ý×ÜÊý(AJAX·ÖÒ³ÓÃµ½)
        /// </summary>
        public int GetCount(string strWhere)
        {
            return dal.GetCount(strWhere);
        }

		/// <summary>
		/// Ôö¼ÓÒ»ÌõÊý¾Ý
		/// </summary>
		public int  Add(Model.article_comment model)
		{
			return dal.Add(model);
		}

        /// <summary>
        /// ÐÞ¸ÄÒ»ÁÐÊý¾Ý
        /// </summary>
        public void UpdateField(int id, string strValue)
        {
            dal.UpdateField(id, strValue);
        }

		/// <summary>
		/// ¸üÐÂÒ»ÌõÊý¾Ý
		/// </summary>
		public bool Update(Model.article_comment model)
		{
			return dal.Update(model);
		}

		/// <summary>
		/// É¾³ýÒ»ÌõÊý¾Ý
		/// </summary>
		public bool Delete(int id)
		{
			return dal.Delete(id);
		}

		/// <summary>
		/// µÃµ½Ò»¸ö¶ÔÏóÊµÌå
		/// </summary>
		public Model.article_comment GetModel(int id)
		{
			return dal.GetModel(id);
		}

		/// <summary>
		/// »ñµÃÇ°¼¸ÐÐÊý¾Ý
		/// </summary>
		public DataSet GetList(int Top,string strWhere,string filedOrder)
		{
			return dal.GetList(Top,strWhere,filedOrder);
		}

        /// <summary>
        /// »ñµÃ²éÑ¯·ÖÒ³Êý¾Ý
        /// </summary>
        public DataSet GetList(int pageSize, int pageIndex, string strWhere, string filedOrder, out int recordCount)
        {
            return dal.GetList(pageSize, pageIndex, strWhere, filedOrder, out recordCount);
        }

		#endregion
	}
}

