Nessuna descrizione

T_Cus_CustomerExpand.cs 8.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Data;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. namespace CallCenterApi.BLL
  8. {
  9. /// <summary>
  10. /// T_Cus_CustomerExpand
  11. /// </summary>
  12. public partial class T_Cus_CustomerExpand
  13. {
  14. private readonly CallCenterApi.DAL.T_Cus_CustomerExpand dal = new CallCenterApi.DAL.T_Cus_CustomerExpand();
  15. public T_Cus_CustomerExpand()
  16. { }
  17. #region BasicMethod
  18. /// <summary>
  19. /// 是否存在该记录
  20. /// </summary>
  21. public bool Exists(Guid F_ExpandId)
  22. {
  23. return dal.Exists(F_ExpandId);
  24. }
  25. /// <summary>
  26. /// 增加一条数据
  27. /// </summary>
  28. public bool Add(CallCenterApi.Model.T_Cus_CustomerExpand model)
  29. {
  30. return dal.Add(model);
  31. }
  32. /// <summary>
  33. /// 更新一条数据
  34. /// </summary>
  35. public bool Update(CallCenterApi.Model.T_Cus_CustomerExpand model)
  36. {
  37. return dal.Update(model);
  38. }
  39. /// <summary>
  40. /// 删除一条数据
  41. /// </summary>
  42. public bool Delete(Guid F_ExpandId)
  43. {
  44. return dal.Delete(F_ExpandId);
  45. }
  46. /// <summary>
  47. /// 删除一条数据
  48. /// </summary>
  49. public bool DeleteList(string F_ExpandIdlist)
  50. {
  51. return dal.DeleteList(F_ExpandIdlist);
  52. }
  53. /// <summary>
  54. /// 得到一个对象实体
  55. /// </summary>
  56. public CallCenterApi.Model.T_Cus_CustomerExpand GetModel(Guid F_ExpandId)
  57. {
  58. return dal.GetModel(F_ExpandId);
  59. }
  60. /// <summary>
  61. /// 得到一个对象实体
  62. /// </summary>
  63. public CallCenterApi.Model.T_Cus_CustomerExpand GetModelByCustomerId(string customerId)
  64. {
  65. return dal.GetModelByCustomerId(customerId);
  66. }
  67. /// <summary>
  68. /// 获得数据列表
  69. /// </summary>
  70. public DataSet GetList(string strWhere)
  71. {
  72. return dal.GetList(strWhere);
  73. }
  74. /// <summary>
  75. /// 获得前几行数据
  76. /// </summary>
  77. public DataSet GetList(int Top, string strWhere, string filedOrder)
  78. {
  79. return dal.GetList(Top, strWhere, filedOrder);
  80. }
  81. /// <summary>
  82. /// 获得数据列表
  83. /// </summary>
  84. public List<CallCenterApi.Model.T_Cus_CustomerExpand> GetModelList(string strWhere)
  85. {
  86. DataSet ds = dal.GetList(strWhere);
  87. return DataTableToList(ds.Tables[0]);
  88. }
  89. /// <summary>
  90. /// 获得数据列表
  91. /// </summary>
  92. public List<CallCenterApi.Model.T_Cus_CustomerExpand> DataTableToList(DataTable dt)
  93. {
  94. List<CallCenterApi.Model.T_Cus_CustomerExpand> modelList = new List<CallCenterApi.Model.T_Cus_CustomerExpand>();
  95. int rowsCount = dt.Rows.Count;
  96. if (rowsCount > 0)
  97. {
  98. CallCenterApi.Model.T_Cus_CustomerExpand model;
  99. for (int n = 0; n < rowsCount; n++)
  100. {
  101. model = dal.DataRowToModel(dt.Rows[n]);
  102. if (model != null)
  103. {
  104. modelList.Add(model);
  105. }
  106. }
  107. }
  108. return modelList;
  109. }
  110. /// <summary>
  111. /// 获得数据列表
  112. /// </summary>
  113. public DataSet GetAllList()
  114. {
  115. return GetList("");
  116. }
  117. /// <summary>
  118. /// 分页获取数据列表
  119. /// </summary>
  120. public int GetRecordCount(string strWhere)
  121. {
  122. return dal.GetRecordCount(strWhere);
  123. }
  124. /// <summary>
  125. /// 分页获取数据列表
  126. /// </summary>
  127. public DataSet GetListByPage(string strWhere, string orderby, int startIndex, int endIndex)
  128. {
  129. return dal.GetListByPage(strWhere, orderby, startIndex, endIndex);
  130. }
  131. /// <summary>
  132. /// 分页获取数据列表
  133. /// </summary>
  134. //public DataSet GetList(int PageSize,int PageIndex,string strWhere)
  135. //{
  136. //return dal.GetList(PageSize,PageIndex,strWhere);
  137. //}
  138. #endregion BasicMethod
  139. #region ExtensionMethod
  140. #endregion ExtensionMethod
  141. //private readonly CallCenterApi.DAL.T_Cus_CustomerExpand dal = new CallCenterApi.DAL.T_Cus_CustomerExpand();
  142. //public T_Cus_CustomerExpand()
  143. //{ }
  144. //#region BasicMethod
  145. ///// <summary>
  146. ///// 是否存在该记录
  147. ///// </summary>
  148. //public bool Exists(Guid F_ExpandId)
  149. //{
  150. // return dal.Exists(F_ExpandId);
  151. //}
  152. ///// <summary>
  153. ///// 增加一条数据
  154. ///// </summary>
  155. //public bool Add(CallCenterApi.Model.T_Cus_CustomerExpand model)
  156. //{
  157. // return dal.Add(model);
  158. //}
  159. ///// <summary>
  160. ///// 更新一条数据
  161. ///// </summary>
  162. //public bool Update(CallCenterApi.Model.T_Cus_CustomerExpand model)
  163. //{
  164. // return dal.Update(model);
  165. //}
  166. ///// <summary>
  167. ///// 删除一条数据
  168. ///// </summary>
  169. //public bool Delete(Guid F_ExpandId)
  170. //{
  171. // return dal.Delete(F_ExpandId);
  172. //}
  173. ///// <summary>
  174. ///// 删除一条数据
  175. ///// </summary>
  176. //public bool DeleteList(string F_ExpandIdlist)
  177. //{
  178. // return dal.DeleteList(F_ExpandIdlist);
  179. //}
  180. ///// <summary>
  181. ///// 得到一个对象实体
  182. ///// </summary>
  183. //public CallCenterApi.Model.T_Cus_CustomerExpand GetModel(Guid F_ExpandId)
  184. //{
  185. // return dal.GetModel(F_ExpandId);
  186. //}
  187. ///// <summary>
  188. ///// 获得数据列表
  189. ///// </summary>
  190. //public DataSet GetList(string strWhere)
  191. //{
  192. // return dal.GetList(strWhere);
  193. //}
  194. ///// <summary>
  195. ///// 获得前几行数据
  196. ///// </summary>
  197. //public DataSet GetList(int Top, string strWhere, string filedOrder)
  198. //{
  199. // return dal.GetList(Top, strWhere, filedOrder);
  200. //}
  201. ///// <summary>
  202. ///// 获得数据列表
  203. ///// </summary>
  204. //public List<CallCenterApi.Model.T_Cus_CustomerExpand> GetModelList(string strWhere)
  205. //{
  206. // DataSet ds = dal.GetList(strWhere);
  207. // return DataTableToList(ds.Tables[0]);
  208. //}
  209. ///// <summary>
  210. ///// 获得数据列表
  211. ///// </summary>
  212. //public List<CallCenterApi.Model.T_Cus_CustomerExpand> DataTableToList(DataTable dt)
  213. //{
  214. // List<CallCenterApi.Model.T_Cus_CustomerExpand> modelList = new List<CallCenterApi.Model.T_Cus_CustomerExpand>();
  215. // int rowsCount = dt.Rows.Count;
  216. // if (rowsCount > 0)
  217. // {
  218. // CallCenterApi.Model.T_Cus_CustomerExpand model;
  219. // for (int n = 0; n < rowsCount; n++)
  220. // {
  221. // model = dal.DataRowToModel(dt.Rows[n]);
  222. // if (model != null)
  223. // {
  224. // modelList.Add(model);
  225. // }
  226. // }
  227. // }
  228. // return modelList;
  229. //}
  230. ///// <summary>
  231. ///// 获得数据列表
  232. ///// </summary>
  233. //public DataSet GetAllList()
  234. //{
  235. // return GetList("");
  236. //}
  237. ///// <summary>
  238. ///// 分页获取数据列表
  239. ///// </summary>
  240. //public int GetRecordCount(string strWhere)
  241. //{
  242. // return dal.GetRecordCount(strWhere);
  243. //}
  244. ///// <summary>
  245. ///// 分页获取数据列表
  246. ///// </summary>
  247. //public DataSet GetListByPage(string strWhere, string orderby, int startIndex, int endIndex)
  248. //{
  249. // return dal.GetListByPage(strWhere, orderby, startIndex, endIndex);
  250. //}
  251. ///// <summary>
  252. ///// 分页获取数据列表
  253. ///// </summary>
  254. ////public DataSet GetList(int PageSize,int PageIndex,string strWhere)
  255. ////{
  256. ////return dal.GetList(PageSize,PageIndex,strWhere);
  257. ////}
  258. //#endregion BasicMethod
  259. //#region ExtensionMethod
  260. //#endregion ExtensionMethod
  261. }
  262. }