No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 
 
 
 

189 líneas
5.4 KiB

  1. using Learun.Util;
  2. using System.Data;
  3. using Learun.Application.TwoDevelopment.EducationalAdministration;
  4. using System.Web.Mvc;
  5. using System.Collections.Generic;
  6. namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
  7. {
  8. /// <summary>
  9. /// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
  10. /// Copyright (c) 2013-2018 北京泉江科技有限公司
  11. /// 创 建:超级管理员
  12. /// 日 期:2019-10-22 16:58
  13. /// 描 述:文件接收
  14. /// </summary>
  15. public class SYS_ReceiveDocumentController : MvcControllerBase
  16. {
  17. private SYS_ReceiveDocumentIBLL sYS_ReceiveDocumentIBLL = new SYS_ReceiveDocumentBLL();
  18. #region 视图功能
  19. /// <summary>
  20. /// 主页面
  21. /// <summary>
  22. /// <returns></returns>
  23. [HttpGet]
  24. public ActionResult Index()
  25. {
  26. return View();
  27. }
  28. /// <summary>
  29. /// 表单页
  30. /// <summary>
  31. /// <returns></returns>
  32. [HttpGet]
  33. public ActionResult Form()
  34. {
  35. return View();
  36. }
  37. /// <summary>
  38. /// 表单页
  39. /// <summary>
  40. /// <returns></returns>
  41. [HttpGet]
  42. public ActionResult FormView()
  43. {
  44. return View();
  45. }
  46. /// <summary>
  47. /// 指派人列表
  48. /// <summary>
  49. /// <returns></returns>
  50. [HttpGet]
  51. public ActionResult IssueForm()
  52. {
  53. return View();
  54. }
  55. /// <summary>
  56. /// 阅读详情
  57. /// <summary>
  58. /// <returns></returns>
  59. [HttpGet]
  60. public ActionResult ReadList()
  61. {
  62. return View();
  63. }
  64. #endregion
  65. #region 获取数据
  66. /// <summary>
  67. /// 获取页面显示列表数据
  68. /// <summary>
  69. /// <param name="queryJson">查询参数</param>
  70. /// <returns></returns>
  71. [HttpGet]
  72. [AjaxOnly]
  73. public ActionResult GetPageList(string pagination, string queryJson)
  74. {
  75. Pagination paginationobj = pagination.ToObject<Pagination>();
  76. var data = sYS_ReceiveDocumentIBLL.GetPageList(paginationobj, queryJson);
  77. var jsonData = new
  78. {
  79. rows = data,
  80. total = paginationobj.total,
  81. page = paginationobj.page,
  82. records = paginationobj.records
  83. };
  84. return Success(jsonData);
  85. }
  86. /// <summary>
  87. /// 获取表单数据
  88. /// <summary>
  89. /// <returns></returns>
  90. [HttpGet]
  91. [AjaxOnly]
  92. public ActionResult GetFormData(string keyValue)
  93. {
  94. var Sys_ReceiveDocumentData = sYS_ReceiveDocumentIBLL.GetSys_ReceiveDocumentEntity(keyValue);
  95. var jsonData = new
  96. {
  97. Sys_ReceiveDocument = Sys_ReceiveDocumentData,
  98. };
  99. return Success(jsonData);
  100. }
  101. /// <summary>
  102. /// 获取表单数据
  103. /// <summary>
  104. /// <returns></returns>
  105. [HttpGet]
  106. [AjaxOnly]
  107. public ActionResult GetFormDataByProcessId(string processId)
  108. {
  109. var Sys_ReceiveDocumentData = sYS_ReceiveDocumentIBLL.GetEntityByProcessId(processId);
  110. var jsonData = new
  111. {
  112. Sys_ReceiveDocument = Sys_ReceiveDocumentData,
  113. };
  114. return Success(jsonData);
  115. }
  116. #endregion
  117. #region 提交数据
  118. /// <summary>
  119. /// 删除实体数据
  120. /// <param name="keyValue">主键</param>
  121. /// <summary>
  122. /// <returns></returns>
  123. [HttpPost]
  124. [AjaxOnly]
  125. public ActionResult DeleteForm(string keyValue)
  126. {
  127. sYS_ReceiveDocumentIBLL.DeleteEntity(keyValue);
  128. return Success("删除成功!");
  129. }
  130. /// <summary>
  131. /// 结束下发
  132. /// <param name="keyValue">主键</param>
  133. /// <summary>
  134. /// <returns></returns>
  135. [HttpPost]
  136. [AjaxOnly]
  137. public ActionResult OverIssue(string keyValue)
  138. {
  139. var entity = sYS_ReceiveDocumentIBLL.GetSys_ReceiveDocumentEntity(keyValue);
  140. if (null != entity)
  141. {
  142. entity.RSendFlag = "4";
  143. sYS_ReceiveDocumentIBLL.SaveEntity(keyValue, entity);
  144. }
  145. return Success("操作成功!");
  146. }
  147. /// <summary>
  148. /// 保存实体数据(新增、修改)
  149. /// <param name="keyValue">主键</param>
  150. /// <summary>
  151. /// <returns></returns>
  152. [HttpPost]
  153. [ValidateAntiForgeryToken]
  154. [AjaxOnly]
  155. [ValidateInput(false)]
  156. public ActionResult SaveForm(string keyValue, string strEntity)
  157. {
  158. Sys_ReceiveDocumentEntity entity = strEntity.ToObject<Sys_ReceiveDocumentEntity>();
  159. sYS_ReceiveDocumentIBLL.SaveEntity(keyValue, entity);
  160. return Success("保存成功!");
  161. }
  162. /// <summary>
  163. /// 提交申请
  164. /// </summary>
  165. /// <param name="keyValue"></param>
  166. /// <returns></returns>
  167. [HttpPost]
  168. [AjaxOnly]
  169. public ActionResult ChangeStatusById(string keyValue, string processId)
  170. {
  171. sYS_ReceiveDocumentIBLL.ChangeStatusById(keyValue, 1, processId);
  172. return Success("操作成功!");
  173. }
  174. #endregion
  175. }
  176. }