IEmailContentService.cs 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. using LeaRun.Application.Entity.PublicInfoManage;
  2. using LeaRun.Util.WebControl;
  3. using System.Collections.Generic;
  4. namespace LeaRun.Application.IService.PublicInfoManage
  5. {
  6. /// <summary>
  7. /// 版 本 6.1
  8. /// Copyright (c) 2013-2016 上海力软信息技术有限公司
  9. /// 创建人:佘赐雄
  10. /// 日 期:2015.12.8 11:31
  11. /// 描 述:邮件内容
  12. /// </summary>
  13. public interface IEmailContentService
  14. {
  15. #region 获取数据
  16. /// <summary>
  17. /// 未读邮件
  18. /// </summary>
  19. /// <param name="pagination">分页参数</param>
  20. /// <param name="userId">用户Id</param>
  21. /// <param name="keyword">关键字</param>
  22. /// <returns></returns>
  23. IEnumerable<EmailContentEntity> GetUnreadMail(Pagination pagination, string userId, string keyword);
  24. /// <summary>
  25. /// 未读邮件数量
  26. /// </summary>
  27. /// <param name="userId">用户Id</param>
  28. /// <returns></returns>
  29. int GetUnreadMailCount(string userId);
  30. /// <summary>
  31. /// 星标邮件
  32. /// </summary>
  33. /// <param name="pagination">分页参数</param>
  34. /// <param name="userId">用户Id</param>
  35. /// <param name="keyword">关键字</param>
  36. /// <returns></returns>
  37. IEnumerable<EmailContentEntity> GetAsteriskMail(Pagination pagination, string userId, string keyword);
  38. /// <summary>
  39. /// 星标邮件数量
  40. /// </summary>
  41. /// <param name="userId">用户Id</param>
  42. /// <returns></returns>
  43. int GetAsteriskMailCount(string userId);
  44. /// <summary>
  45. /// 草稿箱
  46. /// </summary>
  47. /// <param name="pagination">分页参数</param>
  48. /// <param name="userId">用户Id</param>
  49. /// <param name="keyword">关键字</param>
  50. /// <returns></returns>
  51. IEnumerable<EmailContentEntity> GetDraftMail(Pagination pagination, string userId, string keyword);
  52. /// <summary>
  53. /// 草稿箱数量
  54. /// </summary>
  55. /// <param name="userId">用户Id</param>
  56. /// <returns></returns>
  57. int GetDraftMailCount(string userId);
  58. /// <summary>
  59. /// 回收箱
  60. /// </summary>
  61. /// <param name="pagination">分页参数</param>
  62. /// <param name="userId">用户Id</param>
  63. /// <param name="keyword">关键字</param>
  64. /// <returns></returns>
  65. IEnumerable<EmailContentEntity> GetRecycleMail(Pagination pagination, string userId, string keyword);
  66. /// <summary>
  67. /// 回收箱数量
  68. /// </summary>
  69. /// <param name="userId">用户Id</param>
  70. /// <returns></returns>
  71. int GetRecycleMailCount(string userId);
  72. /// <summary>
  73. /// 收件箱
  74. /// </summary>
  75. /// <param name="pagination">分页参数</param>
  76. /// <param name="userId">用户Id</param>
  77. /// <param name="keyword">关键字</param>
  78. /// <returns></returns>
  79. IEnumerable<EmailContentEntity> GetAddresseeMail(Pagination pagination, string userId, string keyword);
  80. /// <summary>
  81. /// 收件箱数量
  82. /// </summary>
  83. /// <param name="userId">用户Id</param>
  84. /// <returns></returns>
  85. int GetAddresseeMailCount(string userId);
  86. /// <summary>
  87. /// 已发送
  88. /// </summary>
  89. /// <param name="pagination">分页参数</param>
  90. /// <param name="userId">用户Id</param>
  91. /// <param name="keyword">关键字</param>
  92. /// <returns></returns>
  93. IEnumerable<EmailContentEntity> GetSentMail(Pagination pagination, string userId, string keyword);
  94. /// <summary>
  95. /// 已发送数量
  96. /// </summary>
  97. /// <param name="userId">用户Id</param>
  98. /// <returns></returns>
  99. int GetSentMailCount(string userId);
  100. /// <summary>
  101. /// 邮件实体
  102. /// </summary>
  103. /// <param name="keyValue">主键值</param>
  104. /// <returns></returns>
  105. EmailContentEntity GetEntity(string keyValue);
  106. /// <summary>
  107. /// 收件邮件实体
  108. /// </summary>
  109. /// <param name="keyValue">主键值</param>
  110. /// <returns></returns>
  111. EmailAddresseeEntity GetAddresseeEntity(string keyValue);
  112. #endregion
  113. #region 提交数据
  114. /// <summary>
  115. /// 删除草稿
  116. /// </summary>
  117. /// <param name="keyValue">主键</param>
  118. void RemoveDraftForm(string keyValue);
  119. /// <summary>
  120. /// 删除未读、星标、收件
  121. /// </summary>
  122. /// <param name="keyValue">主键</param>
  123. void RemoveAddresseeForm(string keyValue);
  124. /// <summary>
  125. /// 彻底删除未读、星标、收件
  126. /// </summary>
  127. /// <param name="keyValue">主键</param>
  128. void ThoroughRemoveAddresseeForm(string keyValue);
  129. /// <summary>
  130. /// 删除回收
  131. /// </summary>
  132. /// <param name="keyValue">主键</param>
  133. /// <param name="Type">类型</param>
  134. void RemoveRecycleForm(string keyValue, int Type);
  135. /// <summary>
  136. /// 删除已发
  137. /// </summary>
  138. /// <param name="keyValue">主键</param>
  139. void RemoveSentForm(string keyValue);
  140. /// <summary>
  141. /// 彻底删除已发
  142. /// </summary>
  143. /// <param name="keyValue">主键</param>
  144. void ThoroughRemoveSentForm(string keyValue);
  145. /// <summary>
  146. /// 保存邮件表单(发送、存入草稿、草稿编辑)
  147. /// </summary>
  148. /// <param name="keyValue">主键值</param>
  149. /// <param name="emailContentEntity">邮件实体</param>
  150. /// <param name="addresssIds">收件人</param>
  151. /// <param name="copysendIds">抄送人</param>
  152. /// <param name="bccsendIds">密送人</param>
  153. /// <returns></returns>
  154. void SaveForm(string keyValue, EmailContentEntity emailContentEntity, string[] addresssIds, string[] copysendIds, string[] bccsendIds);
  155. /// <summary>
  156. /// 设置邮件已读/未读
  157. /// </summary>
  158. /// <param name="keyValue">主键</param>
  159. /// <param name="IsRead">是否已读:0-未读1-已读</param>
  160. void ReadEmail(string keyValue, int IsRead = 1);
  161. /// <summary>
  162. /// 设置邮件星标/取消星标
  163. /// </summary>
  164. /// <param name="keyValue">主键</param>
  165. /// <param name="asterisk">星标:0-取消星标1-星标</param>
  166. void SteriskEmail(string keyValue, int sterisk = 1);
  167. #endregion
  168. }
  169. }