From 747b4b5744b0cb1a1d921a3e30103e18a31026ec Mon Sep 17 00:00:00 2001 From: zhangli <1109134334@qq.com> Date: Mon, 30 Aug 2021 16:31:26 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E5=85=AC=E6=96=87=E6=8E=A5=E6=94=B6?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E3=80=90=E8=A7=92=E8=89=B2=E7=AD=BE=E5=AD=97?= =?UTF-8?q?=E5=8A=9E=E7=90=86=E3=80=91=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Role/RoleBLL.cs | 21 ++++++ .../Role/RoleIBLL.cs | 1 + .../Role/RoleService.cs | 26 +++++++ .../Sys_ReceiveDocumentController.cs | 30 +++++++- .../Controllers/Sys_ReceiveFileController.cs | 25 +++++++ .../Views/Sys_ReceiveDocument/Index.cshtml | 3 +- .../Views/Sys_ReceiveDocument/Index.js | 25 +++++++ .../Views/Sys_ReceiveDocument/RoleForm.cshtml | 11 +++ .../Views/Sys_ReceiveDocument/RoleForm.js | 70 +++++++++++++++++++ .../Learun.Application.Web.csproj | 2 + 10 files changed, 212 insertions(+), 2 deletions(-) create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.js diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleBLL.cs b/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleBLL.cs index e2729f7d1..2233752dd 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleBLL.cs @@ -125,6 +125,27 @@ namespace Learun.Application.Organization } } } + /// 获取分页数据 + /// + public List GetListForSelect() + { + try + { + return (List)roleService.GetListForSelect(); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + /// /// 根据角色名获取角色 /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleIBLL.cs index 2f42e6380..8100f64b5 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleIBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleIBLL.cs @@ -23,6 +23,7 @@ namespace Learun.Application.Organization /// 关键字 /// List GetList(string keyword); + List GetListForSelect(); /// /// 获取分页数据 /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleService.cs b/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleService.cs index 3fc54ab3f..11f5a7489 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Organization/Role/RoleService.cs @@ -65,6 +65,32 @@ namespace Learun.Application.Organization } } } + /// + /// 获取角色数据列表 + /// + /// + public IEnumerable GetListForSelect() + { + try + { + var strSql = new StringBuilder(); + strSql.Append("SELECT t.F_RoleId,t.F_FullName,t.F_EnCode"); + strSql.Append(" FROM LR_Base_Role t WHERE t.F_EnabledMark = 1 AND t.F_DeleteMark = 0 ORDER BY t.F_EnCode "); + return this.BaseRepository().FindList(strSql.ToString()); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + public IEnumerable GetPageList(Pagination pagination, string keyword) { try diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveDocumentController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveDocumentController.cs index 891c892ed..33f60a743 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveDocumentController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveDocumentController.cs @@ -4,6 +4,7 @@ using Learun.Application.TwoDevelopment.EducationalAdministration; using System.Web.Mvc; using System.Collections.Generic; using System.Linq; +using Learun.Application.Organization; namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { @@ -18,6 +19,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { private SYS_ReceiveDocumentIBLL sYS_ReceiveDocumentIBLL = new SYS_ReceiveDocumentBLL(); private Sys_ReceiveFileIBLL receiveFileIbll=new Sys_ReceiveFileBLL(); + private RoleIBLL roleIBLL = new RoleBLL(); #region 视图功能 @@ -30,7 +32,16 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { return View(); } - + /// + /// 主页面 + /// + /// + [HttpGet] + public ActionResult RoleForm() + { + return View(); + } + /// /// 公文接收归档 /// @@ -129,6 +140,23 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers /// [HttpGet] [AjaxOnly] + public ActionResult GetRoleData() + { + var data = roleIBLL.GetListForSelect(); + + //var jsonData = new + //{ + // data = data + //}; + + return Success(data); + } + /// + /// 获取表单数据 + /// + /// + [HttpGet] + [AjaxOnly] public ActionResult GetFormData(string keyValue) { var Sys_ReceiveDocumentData = sYS_ReceiveDocumentIBLL.GetSys_ReceiveDocumentEntity(keyValue); diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveFileController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveFileController.cs index 3b7c27e01..73c1a7e6f 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveFileController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Sys_ReceiveFileController.cs @@ -6,6 +6,7 @@ using System.Collections.Generic; using System.Linq; using System.Web; using Learun.Application.Base.SystemModule; +using Learun.Application.Base.AuthorizeModule; namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { @@ -20,6 +21,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { private Sys_ReceiveFileIBLL sys_ReceiveFileIBLL = new Sys_ReceiveFileBLL(); private AnnexesFileIBLL annexesFileIbll = new AnnexesFileBLL(); + private UserRelationIBLL userRelationIBLL = new UserRelationBLL(); #region 视图功能 @@ -300,6 +302,29 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers sys_ReceiveFileIBLL.ReceiveDocumentIssue(entity); return Success("发送成功"); } + /// + /// 根据角色批示 + /// + /// + [HttpPost] + [AjaxOnly] + public ActionResult RoleReceive(string strEntity) + { + Sys_IssueEntity entity = strEntity.ToObject(); + var data = userRelationIBLL.GetUserIdList(entity.SpecifyReceiver); + string userIds = ""; + foreach (var item in data) + { + if (userIds != "") + { + userIds += ","; + } + userIds += item.F_UserId; + } + entity.SpecifyReceiver = userIds; + sys_ReceiveFileIBLL.ReceiveDocumentIssue(entity); + return Success("发送成功"); + } /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml index 8567a5652..952e590d0 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml @@ -39,11 +39,12 @@  删除 @* 提交*@ -
+
 查看  校办主任阅签  校长书记批办  部门签字办理 +  角色签字办理  结束下发  查阅情况  打印 diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.js index b6e4a8249..287a16f0a 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.js @@ -228,6 +228,31 @@ var bootstrap = function ($, learun) { }); } }); + // 下发审批指定角色 + $('#lr_IssueSpecifyRole').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('RID'); + if (learun.checkrow(keyValue)) { + learun.layerForm({ + id: 'form', + title: '下发审批指定接收人', + url: top.$.rootUrl + '/EducationalAdministration/Sys_ReceiveDocument/RoleForm?keyValue=' + keyValue, + width: 600, + height: 400, + callBack: function (id) { + var res = false; + // 验证数据 + res = top[id].validForm(); + // 保存数据 + if (res) { + res = top[id].save('', function () { + page.search(); + }); + } + return res; + } + }); + } + }); // 结束下发 $('#lr_OverIssue').on('click', function () { var keyValue = $('#gridtable').jfGridValue('RID'); diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.cshtml new file mode 100644 index 000000000..b35cc0803 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.cshtml @@ -0,0 +1,11 @@ +@{ + ViewBag.Title = "公文发送"; + Layout = "~/Views/Shared/_Form.cshtml"; +} +
+
+
接收角色*
+
+
+
+@Html.AppendJsFile("/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.js new file mode 100644 index 000000000..e7e0ab873 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/RoleForm.js @@ -0,0 +1,70 @@ +/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn) + * Copyright (c) 2013-2018 北京泉江科技有限公司 + * 创建人:超级管理员 + * 日 期:2019-04-11 10:31 + * 描 述:公文发送 + */ +var acceptClick; +var keyValue = request('keyValue'); +var rFileId = request('rFileId'); +var specifyReceiver = request('specifyReceiver'); +// 设置权限 +var setAuthorize; +// 设置表单数据 +var setFormData; +// 验证数据是否填写完整 +var validForm; +// 保存数据 +var save; +var bootstrap = function ($, learun) { + "use strict"; + // 设置权限 + setAuthorize = function (data) { + }; + var page = { + init: function () { + $('.lr-form-wrap').lrscroll(); + page.bind(); + page.initData(); + }, + bind: function () { + //$('#SpecifyReceiver').lrUserSelect({ type: '1' }); + $('#SpecifyReceiver').lrselect({ + allowSearch: true, + url: top.$.rootUrl + '/EducationalAdministration/Sys_ReceiveDocument/GetRoleData', + value: 'F_RoleId', + text: 'F_FullName', + maxHeight: 200 + }); + + }, + initData: function () { + if (rFileId) { + $('#SpecifyReceiver').lrformselectSet(specifyReceiver); + } + } + }; + // 验证数据是否填写完整 + validForm = function () { + if (!$('#form').lrValidform()) { + return false; + } + return true; + }; + // 保存数据 + save = function (processId, callBack, i) { + var formData = $('body').lrGetFormData(); + formData.RFileId = rFileId; + formData.SFileId = keyValue; + var postData = { + strEntity: JSON.stringify(formData) + }; + $.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/Sys_ReceiveFile/RoleReceive', postData, function (res) { + // 保存成功后才回调 + if (!!callBack) { + callBack(res, formData, i); + } + }); + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index f6ddba674..3c4192dc4 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -1058,6 +1058,7 @@ + @@ -7402,6 +7403,7 @@ + From ed295caa9e7fd98c0b434dc72e178ac3f53c3c9f Mon Sep 17 00:00:00 2001 From: zhangli <1109134334@qq.com> Date: Mon, 30 Aug 2021 16:37:11 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E6=94=B9=E6=8C=89=E9=92=AE=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Views/Sys_ReceiveDocument/Index.cshtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml index 952e590d0..31793429b 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Sys_ReceiveDocument/Index.cshtml @@ -44,7 +44,7 @@  校办主任阅签  校长书记批办  部门签字办理 -  角色签字办理 +  按角色办理  结束下发  查阅情况  打印 From 3a81fa280e9ca091e1372d894c5df73aa6f5b2c7 Mon Sep 17 00:00:00 2001 From: zhangli <1109134334@qq.com> Date: Wed, 1 Sep 2021 10:17:40 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=9C=A8=E5=86=8C?= =?UTF-8?q?=E7=99=BB=E8=AE=B0=E6=98=8E=E7=BB=86=E7=BC=96=E8=BE=91=E9=83=A8?= =?UTF-8?q?=E5=88=86=E5=AD=97=E6=AE=B5=E6=97=A0=E6=B3=95=E4=BF=9D=E5=AD=98?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Views/Ass_AssetsInfoItem/Form.cshtml | 4 ++-- .../AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.js | 3 +++ .../Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs | 1 + 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml index 79854304e..2351a51a3 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml @@ -5,8 +5,8 @@
@*
序号
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.js index 6923ff564..d907f3764 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.js @@ -87,6 +87,9 @@ var bootstrap = function ($, learun) { $('[data-table="' + id + '"]').lrSetFormData(data[id]); } } + if (!data["Ass_AssetsInfoItem"].AICode) { + $('#AICode').val(newCode); + } }); } else { $('#AICode').val(newCode); diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs index a98657418..ff8e0ac2c 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_AssetsInfoItem/Ass_AssetsInfoItemService.cs @@ -653,6 +653,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem Ass_AssetsInfoItemEntity.AISpecificationtype = entity.AISpecificationtype; Ass_AssetsInfoItemEntity.AIUnits = entity.AIUnits; Ass_AssetsInfoItemEntity.AIAssValue = entity.AIAssValue; + Ass_AssetsInfoItemEntity.AIPlace = entity.AIPlace; Ass_AssetsInfoItemEntity.AIASSClass = entity.AIASSClass; Ass_AssetsInfoItemEntity.AIASSState = entity.AIASSState; Ass_AssetsInfoItemEntity.AIAddType = entity.AIAddType; From f57a42a3a600a4fc8d455fdbbf1967508619ffae Mon Sep 17 00:00:00 2001 From: zhangli <1109134334@qq.com> Date: Wed, 1 Sep 2021 10:32:13 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E8=B5=84=E4=BA=A7=E8=B0=83=E6=8B=A8?= =?UTF-8?q?=E3=80=90=E6=96=B0=E5=A2=9E=E6=98=8E=E7=BB=86=E3=80=91=E9=87=91?= =?UTF-8?q?=E9=9A=85=E7=BC=96=E5=8F=B7=E6=94=B9=E4=B8=BA=E8=B5=84=E4=BA=A7?= =?UTF-8?q?=E7=BC=96=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Views/Ass_AssetsOutApply/IndexTwo.cshtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutApply/IndexTwo.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutApply/IndexTwo.cshtml index 553e8603b..dd25ac784 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutApply/IndexTwo.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsOutApply/IndexTwo.cshtml @@ -30,7 +30,7 @@
-
金隅编号
+
资产编号