@@ -199,6 +199,7 @@ | |||
<a id="lr_node_auditor" class="btn btn-warning"><i class="fa fa-user"></i> 添加节点执行人</a> | |||
<a id="lr_form_auditor" class="btn btn-success"><i class="fa fa-user"></i> 添加表字段</a> | |||
<a id="lr_form_schoolmaster" class="btn btn-success"><i class="fa fa-user"></i> 添加分管校长</a> | |||
<a id="lr_form_deptmaster" class="btn btn-warning"><i class="fa fa-user"></i> 添加部门负责人</a> | |||
<a id="lr_delete_auditor" class="btn btn-danger"><i class="fa fa-trash-o"></i> 移除</a> | |||
</div> | |||
</div> | |||
@@ -185,6 +185,9 @@ var bootstrap = function ($, learun) { | |||
case '7': | |||
return '分管校长'; | |||
break; | |||
case '8': | |||
return '部门负责人'; | |||
break; | |||
} | |||
} | |||
}, | |||
@@ -350,6 +353,19 @@ var bootstrap = function ($, learun) { | |||
} | |||
}); | |||
}); | |||
//添加部门负责人 | |||
$('#lr_form_deptmaster').on('click', function () { | |||
learun.layerConfirm('是否确认增加部门负责人?', function (res) { | |||
if (res) { | |||
var data = { auditorId: 'bmfzrid', type: '8', auditorName: '部门负责人' }; | |||
if (!isRepeat(data.auditorId)) { | |||
data.id = learun.newGuid(); | |||
auditors.push(data); | |||
$('#auditor_girdtable').jfGridSet('refreshdata', auditors); | |||
} | |||
} | |||
}); | |||
}); | |||
/*表单添加*/ | |||
$('#workform_girdtable').jfGrid({ | |||
@@ -47,7 +47,25 @@ namespace Learun.Application.Web.Areas.LogisticsManagement.Controllers | |||
{ | |||
return View(); | |||
} | |||
/// <summary> | |||
/// 项目资料查看 | |||
/// <summary> | |||
/// <returns></returns> | |||
[HttpGet] | |||
public ActionResult IndexView() | |||
{ | |||
return View(); | |||
} | |||
/// <summary> | |||
/// 项目资料查看 | |||
/// <summary> | |||
/// <returns></returns> | |||
[HttpGet] | |||
public ActionResult FormView() | |||
{ | |||
return View(); | |||
} | |||
#endregion | |||
#region 获取数据 | |||
@@ -0,0 +1,140 @@ | |||
using Learun.Util; | |||
using System.Data; | |||
using Learun.Application.TwoDevelopment.LogisticsManagement; | |||
using System.Web.Mvc; | |||
using System.Collections.Generic; | |||
namespace Learun.Application.Web.Areas.LogisticsManagement.Controllers | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-07-05 15:56 | |||
/// 描 述:项目进展情况 | |||
/// </summary> | |||
public class ProjectProcessManageController : MvcControllerBase | |||
{ | |||
private ProjectProcessManageIBLL projectProcessManageIBLL = new ProjectProcessManageBLL(); | |||
#region 视图功能 | |||
/// <summary> | |||
/// 主页面 | |||
/// <summary> | |||
/// <returns></returns> | |||
[HttpGet] | |||
public ActionResult Index() | |||
{ | |||
return View(); | |||
} | |||
/// <summary> | |||
/// 表单页 | |||
/// <summary> | |||
/// <returns></returns> | |||
[HttpGet] | |||
public ActionResult Form() | |||
{ | |||
return View(); | |||
} | |||
/// <summary> | |||
/// 表单页 | |||
/// <summary> | |||
/// <returns></returns> | |||
[HttpGet] | |||
public ActionResult IndexData() | |||
{ | |||
return View(); | |||
} | |||
#endregion | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="pagination">分页参数</param> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
[HttpGet] | |||
[AjaxOnly] | |||
public ActionResult GetPageList(string pagination, string queryJson) | |||
{ | |||
Pagination paginationobj = pagination.ToObject<Pagination>(); | |||
var data = projectProcessManageIBLL.GetPageList(paginationobj, queryJson); | |||
var jsonData = new | |||
{ | |||
rows = data, | |||
total = paginationobj.total, | |||
page = paginationobj.page, | |||
records = paginationobj.records | |||
}; | |||
return Success(jsonData); | |||
} | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
[HttpGet] | |||
[AjaxOnly] | |||
public ActionResult GetList(string queryJson) | |||
{ | |||
var data = projectProcessManageIBLL.GetList(queryJson); | |||
return Success(data); | |||
} | |||
/// <summary> | |||
/// 获取表单数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
[HttpGet] | |||
[AjaxOnly] | |||
public ActionResult GetFormData(string keyValue) | |||
{ | |||
var ProjectProcessManageData = projectProcessManageIBLL.GetProjectProcessManageEntity( keyValue ); | |||
var jsonData = new { | |||
ProjectProcessManage = ProjectProcessManageData, | |||
}; | |||
return Success(jsonData); | |||
} | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
[HttpPost] | |||
[AjaxOnly] | |||
public ActionResult DeleteForm(string keyValue) | |||
{ | |||
projectProcessManageIBLL.DeleteEntity(keyValue); | |||
return Success("删除成功!"); | |||
} | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="strEntity">实体</param> | |||
/// <returns></returns> | |||
[HttpPost] | |||
[ValidateAntiForgeryToken] | |||
[AjaxOnly] | |||
public ActionResult SaveForm(string keyValue, string strEntity) | |||
{ | |||
ProjectProcessManageEntity entity = strEntity.ToObject<ProjectProcessManageEntity>(); | |||
projectProcessManageIBLL.SaveEntity(keyValue,entity); | |||
if (string.IsNullOrEmpty(keyValue)) | |||
{ | |||
} | |||
return Success("保存成功!"); | |||
} | |||
#endregion | |||
} | |||
} |
@@ -0,0 +1,35 @@ | |||
@{ | |||
ViewBag.Title = "项目资料管理"; | |||
Layout = "~/Views/Shared/_Form.cshtml"; | |||
} | |||
<div class="lr-form-wrap" id="form"> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">项目<font face="宋体">*</font></div> | |||
<div id="PId" readonly="readonly" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">项目阶段<font face="宋体">*</font></div> | |||
<div id="PPId" readonly="readonly" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">项目资料名称<font face="宋体">*</font></div> | |||
<input id="Name" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" readonly="readonly"/> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage" id="FilesDiv"> | |||
<div class="lr-form-item-title">资料文件</div> | |||
<div id="Files" readonly="readonly"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">负责部门</div> | |||
<div id="DepartmentId" readonly="readonly"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">负责人</div> | |||
<div id="ManagerId" readonly="readonly"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">备注</div> | |||
<textarea id="Remark" class="form-control" style="height:100px;" readonly="readonly"></textarea> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/ProjectDataManage/FormView.js") |
@@ -0,0 +1,119 @@ | |||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2021-06-21 15:49 | |||
* 描 述:项目资料管理 | |||
*/ | |||
var acceptClick; | |||
var keyValue = request('keyValue'); | |||
var PPId = request("PPId");//项目阶段id | |||
var PId = request("PId");//项目Id | |||
var type = request("type");//项目Id | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var page = { | |||
init: function () { | |||
$('.lr-form-wrap').lrscroll(); | |||
page.bind(); | |||
page.initData(); | |||
}, | |||
bind: function () { | |||
$('#PId').lrselect({ | |||
// 展开最大高度 | |||
maxHeight: 200, | |||
// 是否允许搜索 | |||
allowSearch: true, | |||
// 访问数据接口地址 | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectManage/GetList', | |||
value: "Id", | |||
text: "Name", | |||
}); | |||
if (!!PId) { | |||
$('#PId').lrselectSet(PId); | |||
} | |||
$('#PPId').lrselect({ | |||
type: 'tree', | |||
// 展开最大高度 | |||
maxHeight: 200, | |||
// 是否允许搜索 | |||
allowSearch: true, | |||
// 访问数据接口地址 | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectPhaseManage/GetTree', | |||
select: function (item) { | |||
if (item != null && item != undefined) { | |||
} | |||
} | |||
}); | |||
if (!!PPId) { | |||
$('#PPId').lrselectSet(PPId); | |||
} | |||
$('#Files').lrUploader(); | |||
$('#DepartmentId').lrDataSourceSelect({ | |||
code: 'classdata', | |||
value: 'id', | |||
text: 'name', | |||
select: function (item) { | |||
var DeptCode = $('#DepartmentId').lrselectGet(); | |||
if (DeptCode != null && DeptCode != "" && DeptCode != undefined) { | |||
$('#ManagerId').lrselectRefresh({ | |||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=BaseUser', | |||
value: 'f_userid', | |||
text: 'f_realname', | |||
param: { strWhere: " 1=1 and f_departmentid in ('" + DeptCode + "')" }, | |||
maxHeight: 200, | |||
}); | |||
} | |||
} | |||
}); | |||
$('#ManagerId').lrselect({ | |||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=BaseUser', | |||
value: 'f_userid', | |||
text: 'f_realname', | |||
param: { strWhere: " 1=2 " }, | |||
maxHeight: 200, | |||
}); | |||
}, | |||
initData: function () { | |||
if (!!keyValue) { | |||
$.lrSetForm(top.$.rootUrl + '/LogisticsManagement/ProjectDataManage/GetFormData?keyValue=' + keyValue, function (data) { | |||
for (var id in data) { | |||
if (!!data[id].length && data[id].length > 0) { | |||
$('#' + id).jfGridSet('refreshdata', data[id]); | |||
} | |||
else { | |||
$('[data-table="' + id + '"]').lrSetFormData(data[id]); | |||
} | |||
} | |||
}); | |||
} | |||
} | |||
}; | |||
//// 保存数据 | |||
//acceptClick = function (callBack) { | |||
// if (!$('body').lrValidform()) { | |||
// return false; | |||
// } | |||
// var postData = { | |||
// strEntity: JSON.stringify($('body').lrGetFormData()) | |||
// }; | |||
// if (type == 2) { | |||
// $.lrSaveForm(top.$.rootUrl + '/LogisticsManagement/ProjectDataManage/SaveData?keyValue=' + keyValue, postData, function (res) { | |||
// // 保存成功后才回调 | |||
// if (!!callBack) { | |||
// callBack(); | |||
// } | |||
// }); | |||
// } else { | |||
// $.lrSaveForm(top.$.rootUrl + '/LogisticsManagement/ProjectDataManage/SaveForm?keyValue=' + keyValue, postData, function (res) { | |||
// // 保存成功后才回调 | |||
// if (!!callBack) { | |||
// callBack(); | |||
// } | |||
// }); | |||
// } | |||
//}; | |||
page.init(); | |||
} |
@@ -43,6 +43,7 @@ | |||
</div> | |||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||
<a id="lr_data" class="btn btn-default"><i class="fa fa-plus"></i> 上传项目资料</a> | |||
<a id="lr_dataview" class="btn btn-default"><i class="fa fa-plus"></i> 查看项目资料</a> | |||
</div> | |||
</div> | |||
</div> | |||
@@ -29,6 +29,10 @@ var bootstrap = function ($, learun) { | |||
$('#lr_data').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != 1) { | |||
return learun.alert.warning('只有进行中状态才可以上传!'); | |||
} | |||
learun.layerForm({ | |||
id: 'ProjectDataManageIndex', | |||
title: '项目资料管理', | |||
@@ -42,6 +46,21 @@ var bootstrap = function ($, learun) { | |||
}); | |||
} | |||
}); | |||
//查看项目资料 | |||
$('#lr_dataview').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
learun.layerForm({ | |||
id: 'ProjectDataManageIndex', | |||
title: '项目资料查看', | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectDataManage/IndexView?PId=' + keyValue, | |||
width: 1000, | |||
height: 800, | |||
btn: null | |||
}); | |||
} | |||
}); | |||
}, | |||
inittree: function () { | |||
// 初始化左侧树形数据 | |||
@@ -175,7 +194,7 @@ var bootstrap = function ($, learun) { | |||
search: function (param) { | |||
param = param || {}; | |||
param.PTId = PTId; | |||
param.SqlParameter = " and [Status]=1"; | |||
//param.SqlParameter = " and [Status]=1"; | |||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}; | |||
@@ -0,0 +1,53 @@ | |||
@{ | |||
/**/ | |||
ViewBag.Title = "项目资料管理"; | |||
Layout = "~/Views/Shared/_Index.cshtml"; | |||
} | |||
<div class="lr-layout lr-layout-left-center" id="lr_layout"> | |||
<div class="lr-layout-left"> | |||
<div class="lr-layout-wrap"> | |||
<div class="lr-layout-title lrlt ">阶段</div> | |||
<div id="dataTree" class="lr-layout-body"></div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-center"> | |||
<div class="lr-layout-wrap "> | |||
<div class="lr-layout-title"> | |||
<span id="titleinfo" class="lrlt">未选择阶段</span> - <span class="lrlt">列表信息</span> | |||
</div> | |||
<div class="lr-layout-tool"> | |||
<div class="lr-layout-tool-left"> | |||
<div class="lr-layout-tool-item"> | |||
<div id="multiple_condition_query"> | |||
<div class="lr-query-formcontent"> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">资料名称</div> | |||
<input id="Name" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">负责部门</div> | |||
<div id="DepartmentId"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">负责人</div> | |||
<div id="ManagerId"></div> | |||
</div> | |||
</div> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-tool-right"> | |||
<div class=" btn-group btn-group-sm"> | |||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||
<a id="lr_view" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 查看</a> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-body" id="gridtable"></div> | |||
</div> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/ProjectDataManage/IndexView.js") |
@@ -0,0 +1,121 @@ | |||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2021-06-21 15:49 | |||
* 描 述:项目资料管理 | |||
*/ | |||
var refreshGirdData; | |||
var acceptClick; | |||
var PPId; | |||
var PId = request("PId");//项目Id | |||
var type = request("type");//type==2,上传项目资料 | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var page = { | |||
init: function () { | |||
page.inittree(); | |||
page.initGird(); | |||
page.bind(); | |||
}, | |||
bind: function () { | |||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||
page.search(queryJson); | |||
}, 220, 400); | |||
$('#DepartmentId').lrDepartmentSelect(); | |||
$('#ManagerId').lrUserSelect(0); | |||
// 刷新 | |||
$('#lr_refresh').on('click', function () { | |||
location.reload(); | |||
}); | |||
// 编辑 | |||
$('#lr_view').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
learun.layerForm({ | |||
id: 'ProjectDataManageform', | |||
title: '查看', | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectDataManage/FormView?keyValue=' + keyValue, | |||
width: 800, | |||
height: 600, | |||
btn: null | |||
}); | |||
} | |||
}); | |||
}, | |||
inittree: function () { | |||
// 初始化左侧树形数据 | |||
$('#dataTree').lrtree({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectPhaseManage/GetTree', | |||
nodeClick: page.treeNodeClick | |||
}); | |||
}, | |||
treeNodeClick: function (item) { | |||
PPId = item.id; | |||
$('#titleinfo').text(item.text); | |||
page.search(); | |||
}, | |||
// 初始化列表 | |||
initGird: function () { | |||
$('#gridtable').jfGrid({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectDataManage/GetPageList', | |||
headData: [ | |||
{ label: "项目资料名称", name: "Name", width: 200, align: "left" }, | |||
{ | |||
label: "负责部门", name: "DepartmentId", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'classdata', | |||
key: value, | |||
keyId: 'id', | |||
callback: function (_data) { | |||
callback(_data['name']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "负责人", name: "ManagerId", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('user', { | |||
key: value, | |||
callback: function (_data) { | |||
callback(_data.name); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "是否上传", name: "FileStatus", width: 130, align: "left", | |||
formatter: function (value) { | |||
return value == '1' ? '<span class=\"label label-success\">是</span>' : '<span class=\"label label-warning\">否</span>'; | |||
} | |||
}, | |||
{ label: "上传时间", name: "FileTime", width: 130, align: "left" }, | |||
{ label: "备注", name: "Remark", width: 100, align: "left" }, | |||
], | |||
mainId: 'Id', | |||
isPage: true, | |||
sidx: 'CreateTime desc' | |||
}); | |||
page.search(); | |||
}, | |||
search: function (param) { | |||
param = param || {}; | |||
param.PPId = PPId; | |||
param.PId = PId; | |||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}; | |||
refreshGirdData = function () { | |||
$('#gridtable').jfGridSet('reload'); | |||
}; | |||
// 保存数据 | |||
acceptClick = function (callBack) { | |||
if (!!callBack) { | |||
callBack(); | |||
} | |||
learun.layerClose(window.name); | |||
}; | |||
page.init(); | |||
} |
@@ -50,6 +50,7 @@ | |||
<a id="lr_data" class="btn btn-default"><i class="fa fa-plus"></i> 设置上传项目资料</a> | |||
<a id="lr_submit" class="btn btn-default"><i class="fa fa-plus"></i> 审核</a> | |||
<a id="lr_nosubmit" class="btn btn-default"><i class="fa fa-plus"></i> 去审</a> | |||
<a id="lr_file" class="btn btn-default"><i class="fa fa-plus"></i> 归档</a> | |||
</div> | |||
</div> | |||
</div> | |||
@@ -104,6 +104,19 @@ var bootstrap = function ($, learun) { | |||
}); | |||
} | |||
}); | |||
// 归档,将状态改为2 | |||
$('#lr_file').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
learun.layerConfirm('是否确认归档该项!', function (res) { | |||
if (res) { | |||
learun.postForm(top.$.rootUrl + '/LogisticsManagement/ProjectManage/UpdateStatus', { keyValue: keyValue, Status: 2 }, function () { | |||
refreshGirdData(); | |||
}); | |||
} | |||
}); | |||
} | |||
}); | |||
//设置上传项目资料 | |||
$('#lr_data').on('click', function () { | |||
@@ -175,7 +188,7 @@ var bootstrap = function ($, learun) { | |||
} else if (value == 1) { | |||
return '<span class=\"label label-warning\">进行中</span>'; | |||
} else if (value == 2) { | |||
return '<span class=\"label label-success\">完成</span>'; | |||
return '<span class=\"label label-success\">已完成</span>'; | |||
} | |||
} | |||
}, | |||
@@ -0,0 +1,23 @@ | |||
@{ | |||
ViewBag.Title = "项目进展情况"; | |||
Layout = "~/Views/Shared/_Form.cshtml"; | |||
} | |||
<div class="lr-form-wrap" id="form"> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">项目<font face="宋体">*</font></div> | |||
<div id="PId" readonly="readonly" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectDataManage"> | |||
<div class="lr-form-item-title">项目阶段<font face="宋体">*</font></div> | |||
<div id="PPId" readonly="readonly" isvalid="yes" checkexpession="NotNull"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectProcessManage"> | |||
<div class="lr-form-item-title">项目进展情况<font face="宋体">*</font></div> | |||
<textarea id="Progress" class="form-control" style="height: 100px;" isvalid="yes" checkexpession="NotNull" ></textarea> | |||
</div> | |||
<div class="col-xs-12 lr-form-item" data-table="ProjectProcessManage"> | |||
<div class="lr-form-item-title">时间<font face="宋体">*</font></div> | |||
<input id="ProcessTime" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt: 'yyyy-MM-dd', onpicked: function() { $('#ProcessTime').trigger('change'); } })" isvalid="yes" checkexpession="NotNull"/> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/ProjectProcessManage/Form.js") |
@@ -0,0 +1,86 @@ | |||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2021-07-05 15:56 | |||
* 描 述:项目进展情况 | |||
*/ | |||
var acceptClick; | |||
var keyValue = request('keyValue'); | |||
var PPId = request("PPId");//项目阶段id | |||
var PId = request("PId");//项目Id | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var page = { | |||
init: function () { | |||
$('.lr-form-wrap').lrscroll(); | |||
page.bind(); | |||
page.initData(); | |||
}, | |||
bind: function () { | |||
$('#PId').lrselect({ | |||
// 展开最大高度 | |||
maxHeight: 200, | |||
// 是否允许搜索 | |||
allowSearch: true, | |||
// 访问数据接口地址 | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectManage/GetList', | |||
value: "Id", | |||
text: "Name", | |||
}); | |||
if (!!PId) { | |||
$('#PId').lrselectSet(PId); | |||
} | |||
$('#PPId').lrselect({ | |||
type: 'tree', | |||
// 展开最大高度 | |||
maxHeight: 200, | |||
// 是否允许搜索 | |||
allowSearch: true, | |||
// 访问数据接口地址 | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectPhaseManage/GetTree', | |||
select: function (item) { | |||
if (item != null && item != undefined) { | |||
} | |||
} | |||
}); | |||
if (!!PPId) { | |||
$('#PPId').lrselectSet(PPId); | |||
} | |||
}, | |||
initData: function () { | |||
if (!!keyValue) { | |||
$.lrSetForm(top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/GetFormData?keyValue=' + keyValue, function (data) { | |||
for (var id in data) { | |||
if (!!data[id].length && data[id].length > 0) { | |||
$('#' + id ).jfGridSet('refreshdata', data[id]); | |||
} | |||
else { | |||
$('[data-table="' + id + '"]').lrSetFormData(data[id]); | |||
} | |||
} | |||
if (data && data.ProjectProcessManage) { | |||
$('#PId').lrselectSet(data.ProjectProcessManage.PId); | |||
$('#PPId').lrselectSet(data.ProjectProcessManage.PPId); | |||
} | |||
}); | |||
} | |||
} | |||
}; | |||
// 保存数据 | |||
acceptClick = function (callBack) { | |||
if (!$('body').lrValidform()) { | |||
return false; | |||
} | |||
var postData = { | |||
strEntity: JSON.stringify($('body').lrGetFormData()) | |||
}; | |||
$.lrSaveForm(top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/SaveForm?keyValue=' + keyValue, postData, function (res) { | |||
// 保存成功后才回调 | |||
if (!!callBack) { | |||
callBack(); | |||
} | |||
}); | |||
}; | |||
page.init(); | |||
} |
@@ -0,0 +1,36 @@ | |||
@{ | |||
ViewBag.Title = "项目进展情况"; | |||
Layout = "~/Views/Shared/_Index.cshtml"; | |||
} | |||
<div class="lr-layout lr-layout-left-center" id="lr_layout"> | |||
<div class="lr-layout-left"> | |||
<div class="lr-layout-wrap"> | |||
<div class="lr-layout-title lrlg ">树形列表</div> | |||
<div id="dataTree" class="lr-layout-body"></div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-center"> | |||
<div class="lr-layout-wrap "> | |||
<div class="lr-layout-title"> | |||
<span id="titleinfo" class="lrlg">列表信息</span> | |||
</div> | |||
<div class="lr-layout-tool"> | |||
<div class="lr-layout-tool-left"> | |||
</div> | |||
<div class="lr-layout-tool-right"> | |||
<div class=" btn-group btn-group-sm"> | |||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i> 新增</a> | |||
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 编辑</a> | |||
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i> 删除</a> | |||
@*<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i> 打印</a>*@ | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-body" id="gridtable"></div> | |||
</div> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/ProjectProcessManage/Index.js") |
@@ -0,0 +1,117 @@ | |||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2021-07-05 15:56 | |||
* 描 述:项目进展情况 | |||
*/ | |||
var refreshGirdData; | |||
var acceptClick; | |||
var PPId; | |||
var PId = request("PId");//项目Id | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var page = { | |||
init: function () { | |||
page.inittree(); | |||
page.initGird(); | |||
page.bind(); | |||
}, | |||
bind: function () { | |||
// 刷新 | |||
$('#lr_refresh').on('click', function () { | |||
location.reload(); | |||
}); | |||
// 新增 | |||
$('#lr_add').on('click', function () { | |||
if (!PPId) { | |||
learun.alert.warning('请选择阶段!'); | |||
return false; | |||
} | |||
learun.layerForm({ | |||
id: 'form', | |||
title: '新增', | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/Form?PPId=' + PPId + '&PId=' + PId, | |||
width: 600, | |||
height: 400, | |||
callBack: function (id) { | |||
return top[id].acceptClick(refreshGirdData); | |||
} | |||
}); | |||
}); | |||
// 编辑 | |||
$('#lr_edit').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
learun.layerForm({ | |||
id: 'form', | |||
title: '编辑', | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/Form?keyValue=' + keyValue, | |||
width: 600, | |||
height: 400, | |||
callBack: function (id) { | |||
return top[id].acceptClick(refreshGirdData); | |||
} | |||
}); | |||
} | |||
}); | |||
// 删除 | |||
$('#lr_delete').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||
if (res) { | |||
learun.deleteForm(top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/DeleteForm', { keyValue: keyValue}, function () { | |||
refreshGirdData(); | |||
}); | |||
} | |||
}); | |||
} | |||
}); | |||
// 打印 | |||
$('#lr_print').on('click', function () { | |||
$('#gridtable').jqprintTable(); | |||
}); | |||
}, | |||
// 初始化列表 | |||
initGird: function () { | |||
$('#gridtable').jfGrid({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/GetPageList', | |||
headData: [ | |||
{ label: "项目进展情况", name: "Progress", width: 100, align: "left"}, | |||
{ label: "时间", name: "ProcessTime", width: 100, align: "left"}, | |||
], | |||
mainId:'Id', | |||
isPage: true | |||
}); | |||
page.search(); | |||
}, | |||
inittree: function () { | |||
// 初始化左侧树形数据 | |||
$('#dataTree').lrtree({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectPhaseManage/GetTree', | |||
nodeClick: page.treeNodeClick | |||
}); | |||
}, | |||
treeNodeClick: function (item) { | |||
PPId = item.id; | |||
$('#titleinfo').text(item.text); | |||
page.search(); | |||
}, | |||
search: function (param) { | |||
param = param || {}; | |||
param.PPId = PPId; | |||
param.PId = PId; | |||
$('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) }); | |||
} | |||
}; | |||
refreshGirdData = function () { | |||
$('#gridtable').jfGridSet('reload'); | |||
}; | |||
acceptClick = function (callBack) { | |||
if (!!callBack) { | |||
callBack(); | |||
} | |||
learun.layerClose(window.name); | |||
}; | |||
page.init(); | |||
} |
@@ -0,0 +1,53 @@ | |||
@{ | |||
/**/ | |||
ViewBag.Title = "项目进展情况管理"; | |||
Layout = "~/Views/Shared/_Index.cshtml"; | |||
} | |||
<div class="lr-layout lr-layout-left-center" id="lr_layout"> | |||
<div class="lr-layout-left"> | |||
<div class="lr-layout-wrap"> | |||
<div class="lr-layout-title lrlt ">类型</div> | |||
<div id="dataTree" class="lr-layout-body"></div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-center"> | |||
<div class="lr-layout-wrap "> | |||
<div class="lr-layout-title"> | |||
<span id="titleinfo" class="lrlt">未选择类型</span> - <span class="lrlt">列表信息</span> | |||
</div> | |||
<div class="lr-layout-tool"> | |||
@*<div class="lr-layout-tool-left"> | |||
<div class="lr-layout-tool-item"> | |||
<div id="multiple_condition_query"> | |||
<div class="lr-query-formcontent"> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">项目名称</div> | |||
<input id="Name" type="text" class="form-control" /> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">负责部门</div> | |||
<div id="DepartmentId"></div> | |||
</div> | |||
<div class="col-xs-12 lr-form-item"> | |||
<div class="lr-form-item-title">负责人</div> | |||
<div id="ManagerId"></div> | |||
</div> | |||
</div> | |||
</div> | |||
</div> | |||
</div>*@ | |||
<div class="lr-layout-tool-right"> | |||
<div class=" btn-group btn-group-sm"> | |||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||
</div> | |||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||
<a id="lr_data" class="btn btn-default"><i class="fa fa-plus"></i> 填写项目进展情况</a> | |||
</div> | |||
</div> | |||
</div> | |||
<div class="lr-layout-body" id="gridtable"></div> | |||
</div> | |||
</div> | |||
</div> | |||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/ProjectProcessManage/IndexData.js") |
@@ -0,0 +1,164 @@ | |||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
* 创建人:超级管理员 | |||
* 日 期:2021-06-21 15:49 | |||
* 描 述:项目管理 | |||
*/ | |||
var refreshGirdData; | |||
var PTId; | |||
var bootstrap = function ($, learun) { | |||
"use strict"; | |||
var page = { | |||
init: function () { | |||
page.inittree(); | |||
page.initGird(); | |||
page.bind(); | |||
}, | |||
bind: function () { | |||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||
page.search(queryJson); | |||
}, 220, 400); | |||
$('#DepartmentId').lrDepartmentSelect(); | |||
$('#ManagerId').lrUserSelect(0); | |||
// 刷新 | |||
$('#lr_refresh').on('click', function () { | |||
location.reload(); | |||
}); | |||
//填写项目进展情况 | |||
$('#lr_data').on('click', function () { | |||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||
if (learun.checkrow(keyValue)) { | |||
var Status = $('#gridtable').jfGridValue('Status'); | |||
if (Status != 1) { | |||
return learun.alert.warning('只有进行中状态才可填写!'); | |||
} | |||
learun.layerForm({ | |||
id: 'ProjectDataManageIndex', | |||
title: '项目进展情况管理', | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/Index?PId=' + keyValue, | |||
width: 1000, | |||
height: 800, | |||
btn: ['确定'], | |||
callBack: function (id) { | |||
return top[id].acceptClick(refreshGirdData); | |||
} | |||
}); | |||
} | |||
}); | |||
}, | |||
inittree: function () { | |||
// 初始化左侧树形数据 | |||
$('#dataTree').lrtree({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectTypeManage/GetTree', | |||
nodeClick: page.treeNodeClick | |||
}); | |||
}, | |||
treeNodeClick: function (item) { | |||
PTId = item.id; | |||
$('#titleinfo').text(item.text); | |||
page.search(); | |||
}, | |||
// 初始化列表 | |||
initGird: function () { | |||
$('#gridtable').jfGrid({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectManage/GetPageList', | |||
headData: [ | |||
{ label: "项目名称", name: "Name", width: 200, align: "left" }, | |||
{ label: "项目周期", name: "Period", width: 100, align: "left" }, | |||
{ | |||
label: "负责部门", name: "DepartmentId", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('custmerData', { | |||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'classdata', | |||
key: value, | |||
keyId: 'id', | |||
callback: function (_data) { | |||
callback(_data['name']); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "负责人", name: "ManagerId", width: 100, align: "left", | |||
formatterAsync: function (callback, value, row, op, $cell) { | |||
learun.clientdata.getAsync('user', { | |||
key: value, | |||
callback: function (_data) { | |||
callback(_data.name); | |||
} | |||
}); | |||
} | |||
}, | |||
{ | |||
label: "项目状态", name: "Status", width: 100, align: "left", | |||
formatter: function (value) { | |||
if (value == 0) { | |||
return '<span class=\"label label-default\">草稿</span>'; | |||
} else if (value == 1) { | |||
return '<span class=\"label label-warning\">进行中</span>'; | |||
} else if (value == 2) { | |||
return '<span class=\"label label-success\">完成</span>'; | |||
} | |||
} | |||
}, | |||
{ label: "备注", name: "Remark", width: 100, align: "left" }, | |||
], | |||
mainId: 'Id', | |||
isPage: true, | |||
sidx: 'CreateTime desc', | |||
isSubGrid: true, // 是否有子表单 | |||
subGridExpanded: function (subContentId, rowItem) { | |||
var PId = rowItem.Id; | |||
$('#' + subContentId).jfGrid({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectPhaseManage/GetList', | |||
headData: [ | |||
{ name: "Name", width: 150, align: "left" } | |||
], | |||
mainId: 'Id', | |||
isPage: false, | |||
sidx: 'Sort', | |||
sord: 'ASC', | |||
isSubGrid: true, // 是否有子表单 | |||
subGridExpanded: function (subContentId, rowItem) { | |||
$('#' + subContentId).jfGrid({ | |||
url: top.$.rootUrl + '/LogisticsManagement/ProjectProcessManage/GetList', | |||
headData: [ | |||
{ label: "项目进展情况", name: "Progress", width: 200, align: "left" }, | |||
{ | |||
label: "时间", name: "ProcessTime", width: 100, align: "left", | |||
formatter: function (value) { | |||
return learun.formatDate(value, 'yyyy-MM-dd'); | |||
} | |||
} | |||
], | |||
mainId: 'Id', | |||
isPage: false, | |||
}); | |||
var param; | |||
param = param || {}; | |||
param.PPId = rowItem.Id; | |||
param.PId = PId; | |||
$('#' + subContentId).jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}); | |||
var param; | |||
param = param || {}; | |||
//param.BId = rowItem.Id; | |||
$('#' + subContentId).jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}); | |||
page.search(); | |||
}, | |||
search: function (param) { | |||
param = param || {}; | |||
param.PTId = PTId; | |||
//param.SqlParameter = " and [Status]=1"; | |||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||
} | |||
}; | |||
refreshGirdData = function () { | |||
$('#gridtable').jfGridSet('reload'); | |||
}; | |||
page.init(); | |||
} |
@@ -818,6 +818,7 @@ | |||
<Compile Include="Areas\LR_Desktop\Controllers\CalculateProjectController.cs" /> | |||
<Compile Include="Areas\LR_Desktop\Controllers\FormulaMainController.cs" /> | |||
<Compile Include="Areas\LR_Desktop\Controllers\FormulaChildController.cs" /> | |||
<Compile Include="Areas\LogisticsManagement\Controllers\ProjectProcessManageController.cs" /> | |||
</ItemGroup> | |||
<ItemGroup> | |||
<Content Include="Areas\AdmissionsPlatform\Views\AP_OnlineUserInfo\DropOutIndex.js" /> | |||
@@ -1206,11 +1207,14 @@ | |||
<Content Include="Areas\LogisticsManagement\Views\APAppointmentPsychologist\Index.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\CompanyNews\Form.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\CompanyNews\Index.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\FormView.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\Form.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\IndexView.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\Index.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\IndexData.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectPhaseManage\Form.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectPhaseManage\Index.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectProcessManage\IndexData.js" /> | |||
<Content Include="Areas\LR_AuthorizeModule\Views\Authorize\AppForm.js" /> | |||
<Content Include="Areas\LR_AuthorizeModule\Views\Authorize\Form.css" /> | |||
<Content Include="Areas\LR_AuthorizeModule\Views\Authorize\Form.js" /> | |||
@@ -6514,6 +6518,10 @@ | |||
<Content Include="Areas\LR_Desktop\Views\FormulaChild\Index.js" /> | |||
<Content Include="Areas\LR_Desktop\Views\FormulaChild\Form.cshtml" /> | |||
<Content Include="Areas\LR_Desktop\Views\FormulaChild\Form.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectProcessManage\Index.cshtml" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectProcessManage\Index.js" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectProcessManage\Form.cshtml" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectProcessManage\Form.js" /> | |||
</ItemGroup> | |||
<ItemGroup> | |||
<Folder Include="Areas\EducationalAdministration\Views\OpenLessonPlanOfElectivePre\" /> | |||
@@ -7359,6 +7367,9 @@ | |||
<Content Include="Areas\LR_Desktop\Views\QualityReport\IndexReport.cshtml" /> | |||
<Content Include="Areas\LR_Desktop\Views\QualityReport\FormView.cshtml" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\IndexData.cshtml" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectProcessManage\IndexData.cshtml" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\IndexView.cshtml" /> | |||
<Content Include="Areas\LogisticsManagement\Views\ProjectDataManage\FormView.cshtml" /> | |||
<None Include="Properties\PublishProfiles\FolderProfile.pubxml" /> | |||
<Content Include="Views\Login\Default-beifen.cshtml" /> | |||
<None Include="Properties\PublishProfiles\FolderProfile1.pubxml" /> | |||
@@ -574,6 +574,7 @@ | |||
<Compile Include="LogisticsManagement\ProjectTypeManageMap.cs" /> | |||
<Compile Include="LogisticsManagement\ProjectManageMap.cs" /> | |||
<Compile Include="EducationalAdministration\FillinFromMap.cs" /> | |||
<Compile Include="LogisticsManagement\ProjectProcessManageMap.cs" /> | |||
</ItemGroup> | |||
<ItemGroup> | |||
<ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj"> | |||
@@ -0,0 +1,29 @@ | |||
using Learun.Application.TwoDevelopment.LogisticsManagement; | |||
using System.Data.Entity.ModelConfiguration; | |||
namespace Learun.Application.Mapping | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-07-05 15:56 | |||
/// 描 述:项目进展情况 | |||
/// </summary> | |||
public class ProjectProcessManageMap : EntityTypeConfiguration<ProjectProcessManageEntity> | |||
{ | |||
public ProjectProcessManageMap() | |||
{ | |||
#region 表、主键 | |||
//表 | |||
this.ToTable("PROJECTPROCESSMANAGE"); | |||
//主键 | |||
this.HasKey(t => t.Id); | |||
#endregion | |||
#region 配置关系 | |||
#endregion | |||
} | |||
} | |||
} | |||
@@ -1713,6 +1713,10 @@ | |||
<Compile Include="LR_Desktop\FormulaChild\FormulaChildService.cs" /> | |||
<Compile Include="LR_Desktop\FormulaChild\FormulaChildBLL.cs" /> | |||
<Compile Include="LR_Desktop\FormulaChild\FormulaChildIBLL.cs" /> | |||
<Compile Include="LogisticsManagement\ProjectProcessManage\ProjectProcessManageEntity.cs" /> | |||
<Compile Include="LogisticsManagement\ProjectProcessManage\ProjectProcessManageService.cs" /> | |||
<Compile Include="LogisticsManagement\ProjectProcessManage\ProjectProcessManageBLL.cs" /> | |||
<Compile Include="LogisticsManagement\ProjectProcessManage\ProjectProcessManageIBLL.cs" /> | |||
</ItemGroup> | |||
<ItemGroup> | |||
<ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj"> | |||
@@ -197,18 +197,18 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||
{ | |||
entity.Modify(keyValue); | |||
db.Update(entity); | |||
if (!string.IsNullOrEmpty(entity.Files)) | |||
{ | |||
//判断当前项目各阶段是否已全部上传 | |||
var list = db.FindList<ProjectDataManageEntity>(x => x.PId == entity.PId && !string.IsNullOrEmpty(x.Files) && x.Id != keyValue); | |||
if (list.Count() <= 0) | |||
{ | |||
//如果全部已上传,将项目状态改为已完成 | |||
var projectManageEntity = db.FindEntity<ProjectManageEntity>(x => x.Id == entity.PId); | |||
projectManageEntity.Status = "2"; | |||
db.Update(projectManageEntity); | |||
} | |||
} | |||
//if (!string.IsNullOrEmpty(entity.Files)) | |||
//{ | |||
// //判断当前项目各阶段是否已全部上传 | |||
// var list = db.FindList<ProjectDataManageEntity>(x => x.PId == entity.PId && !string.IsNullOrEmpty(x.Files) && x.Id != keyValue); | |||
// if (list.Count() <= 0) | |||
// { | |||
// //如果全部已上传,将项目状态改为已完成 | |||
// var projectManageEntity = db.FindEntity<ProjectManageEntity>(x => x.Id == entity.PId); | |||
// projectManageEntity.Status = "2"; | |||
// db.Update(projectManageEntity); | |||
// } | |||
//} | |||
} | |||
else | |||
@@ -0,0 +1,150 @@ | |||
using Learun.Util; | |||
using System; | |||
using System.Data; | |||
using System.Collections.Generic; | |||
namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-07-05 15:56 | |||
/// 描 述:项目进展情况 | |||
/// </summary> | |||
public class ProjectProcessManageBLL : ProjectProcessManageIBLL | |||
{ | |||
private ProjectProcessManageService projectProcessManageService = new ProjectProcessManageService(); | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="pagination">分页参数</param> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ProjectProcessManageEntity> GetPageList(Pagination pagination, string queryJson) | |||
{ | |||
try | |||
{ | |||
return projectProcessManageService.GetPageList(pagination, queryJson); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="pagination">分页参数</param> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ProjectProcessManageEntity> GetList(string queryJson) | |||
{ | |||
try | |||
{ | |||
return projectProcessManageService.GetList(queryJson); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取ProjectProcessManage表实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
public ProjectProcessManageEntity GetProjectProcessManageEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
return projectProcessManageService.GetProjectProcessManageEntity(keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DeleteEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
projectProcessManageService.DeleteEntity(keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
/// <returns></returns> | |||
public void SaveEntity(string keyValue, ProjectProcessManageEntity entity) | |||
{ | |||
try | |||
{ | |||
projectProcessManageService.SaveEntity(keyValue, entity); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
} | |||
} |
@@ -0,0 +1,77 @@ | |||
using Learun.Util; | |||
using System; | |||
using System.ComponentModel.DataAnnotations.Schema; | |||
namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-07-05 15:56 | |||
/// 描 述:项目进展情况 | |||
/// </summary> | |||
public class ProjectProcessManageEntity | |||
{ | |||
#region 实体成员 | |||
/// <summary> | |||
/// Id | |||
/// </summary> | |||
[Column("ID")] | |||
public string Id { get; set; } | |||
/// <summary> | |||
/// 项目Id | |||
/// </summary> | |||
[Column("PID")] | |||
public string PId { get; set; } | |||
/// <summary> | |||
/// 项目阶段Id | |||
/// </summary> | |||
[Column("PPID")] | |||
public string PPId { get; set; } | |||
/// <summary> | |||
/// 项目进展情况描述 | |||
/// </summary> | |||
[Column("PROGRESS")] | |||
public string Progress { get; set; } | |||
/// <summary> | |||
/// 时间 | |||
/// </summary> | |||
[Column("PROCESSTIME")] | |||
public string ProcessTime { get; set; } | |||
/// <summary> | |||
/// 创建时间 | |||
/// </summary> | |||
[Column("CREATETIME")] | |||
public DateTime? CreateTime { get; set; } | |||
/// <summary> | |||
/// 创建人 | |||
/// </summary> | |||
[Column("CREATEUSERID")] | |||
public string CreateUserId { get; set; } | |||
#endregion | |||
#region 扩展操作 | |||
/// <summary> | |||
/// 新增调用 | |||
/// </summary> | |||
public void Create() | |||
{ | |||
this.Id = Guid.NewGuid().ToString(); | |||
this.CreateTime = DateTime.Now; | |||
this.CreateUserId = LoginUserInfo.Get().userId; | |||
} | |||
/// <summary> | |||
/// 编辑调用 | |||
/// </summary> | |||
/// <param name="keyValue"></param> | |||
public void Modify(string keyValue) | |||
{ | |||
this.Id = keyValue; | |||
} | |||
#endregion | |||
#region 扩展字段 | |||
#endregion | |||
} | |||
} | |||
@@ -0,0 +1,49 @@ | |||
using Learun.Util; | |||
using System.Data; | |||
using System.Collections.Generic; | |||
namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-07-05 15:56 | |||
/// 描 述:项目进展情况 | |||
/// </summary> | |||
public interface ProjectProcessManageIBLL | |||
{ | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
IEnumerable<ProjectProcessManageEntity> GetPageList(Pagination pagination, string queryJson); | |||
IEnumerable<ProjectProcessManageEntity> GetList(string queryJson); | |||
/// <summary> | |||
/// 获取ProjectProcessManage表实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
ProjectProcessManageEntity GetProjectProcessManageEntity(string keyValue); | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
void DeleteEntity(string keyValue); | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
void SaveEntity(string keyValue, ProjectProcessManageEntity entity); | |||
#endregion | |||
} | |||
} |
@@ -0,0 +1,215 @@ | |||
using Dapper; | |||
using Learun.DataBase.Repository; | |||
using Learun.Util; | |||
using System; | |||
using System.Collections.Generic; | |||
using System.Data; | |||
using System.Text; | |||
namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-07-05 15:56 | |||
/// 描 述:项目进展情况 | |||
/// </summary> | |||
public class ProjectProcessManageService : RepositoryFactory | |||
{ | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="pagination">查询参数</param> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ProjectProcessManageEntity> GetPageList(Pagination pagination, string queryJson) | |||
{ | |||
try | |||
{ | |||
var strSql = new StringBuilder(); | |||
strSql.Append("SELECT "); | |||
strSql.Append(@" | |||
t.Id, | |||
t.Progress, | |||
t.ProcessTime | |||
"); | |||
strSql.Append(" FROM ProjectProcessManage t "); | |||
strSql.Append(" WHERE 1=1 "); | |||
var queryParam = queryJson.ToJObject(); | |||
// 虚拟参数 | |||
var dp = new DynamicParameters(new { }); | |||
if (!queryParam["Progress"].IsEmpty()) | |||
{ | |||
dp.Add("Progress", queryParam["Progress"].ToString(), DbType.String); | |||
strSql.Append(" AND t.Progress = @Progress "); | |||
} | |||
if (!queryParam["PId"].IsEmpty()) | |||
{ | |||
dp.Add("PId", queryParam["PId"].ToString(), DbType.String); | |||
strSql.Append(" AND t.PId = @PId "); | |||
} | |||
if (!queryParam["PPId"].IsEmpty()) | |||
{ | |||
dp.Add("PPId", queryParam["PPId"].ToString(), DbType.String); | |||
strSql.Append(" AND t.PPId = @PPId "); | |||
} | |||
return this.BaseRepository("CollegeMIS").FindList<ProjectProcessManageEntity>(strSql.ToString(), dp, pagination); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取页面显示列表数据 | |||
/// </summary> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ProjectProcessManageEntity> GetList(string queryJson) | |||
{ | |||
try | |||
{ | |||
var strSql = new StringBuilder(); | |||
strSql.Append("SELECT "); | |||
strSql.Append(@" | |||
t.Id, | |||
t.Progress, | |||
t.ProcessTime | |||
"); | |||
strSql.Append(" FROM ProjectProcessManage t "); | |||
strSql.Append(" WHERE 1=1 "); | |||
var queryParam = queryJson.ToJObject(); | |||
// 虚拟参数 | |||
var dp = new DynamicParameters(new { }); | |||
if (!queryParam["PId"].IsEmpty()) | |||
{ | |||
dp.Add("PId", queryParam["PId"].ToString(), DbType.String); | |||
strSql.Append(" AND t.PId = @PId "); | |||
} | |||
if (!queryParam["PPId"].IsEmpty()) | |||
{ | |||
dp.Add("PPId", queryParam["PPId"].ToString(), DbType.String); | |||
strSql.Append(" AND t.PPId = @PPId "); | |||
} | |||
if (!queryParam["Progress"].IsEmpty()) | |||
{ | |||
dp.Add("Progress", queryParam["Progress"].ToString(), DbType.String); | |||
strSql.Append(" AND t.Progress = @Progress "); | |||
} | |||
strSql.Append(" order by t.ProcessTime desc"); | |||
return this.BaseRepository("CollegeMIS").FindList<ProjectProcessManageEntity>(strSql.ToString(), dp); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取ProjectProcessManage表实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
public ProjectProcessManageEntity GetProjectProcessManageEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
return this.BaseRepository("CollegeMIS").FindEntity<ProjectProcessManageEntity>(keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DeleteEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
this.BaseRepository("CollegeMIS").Delete<ProjectProcessManageEntity>(t => t.Id == keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
public void SaveEntity(string keyValue, ProjectProcessManageEntity entity) | |||
{ | |||
try | |||
{ | |||
if (!string.IsNullOrEmpty(keyValue)) | |||
{ | |||
entity.Modify(keyValue); | |||
this.BaseRepository("CollegeMIS").Update(entity); | |||
} | |||
else | |||
{ | |||
entity.Create(); | |||
this.BaseRepository("CollegeMIS").Insert(entity); | |||
} | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
} | |||
} |
@@ -534,7 +534,7 @@ namespace Learun.Application.WorkFlow | |||
foreach (var item in nodeAuditorList) | |||
{ | |||
switch (item.type)//1.岗位2.角色3.用户4.上下级5.表单指定字段6.某一个节点执行人 | |||
//liang 20200813 新增type=7 分管校长 | |||
//liang 20200813 新增type=7 分管校长 20210706增加部门负责人type=8 | |||
{ | |||
case 1:// 岗位 | |||
var userRelationList = userRelationIBLL.GetUserIdList(item.auditorId); | |||
@@ -547,17 +547,35 @@ namespace Learun.Application.WorkFlow | |||
{ | |||
if (userEntity.F_DepartmentId == paramConfig.CreateUser.DepartmentId) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
else if (item.condition == 2) | |||
{ | |||
if (userEntity.F_CompanyId == paramConfig.CreateUser.CompanyId) | |||
{ | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
else | |||
{ | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
@@ -567,15 +585,6 @@ namespace Learun.Application.WorkFlow | |||
}); | |||
} | |||
} | |||
else | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
break; | |||
@@ -591,24 +600,30 @@ namespace Learun.Application.WorkFlow | |||
{ | |||
if (userEntity.F_DepartmentId == paramConfig.CreateUser.DepartmentId) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
else if (item.condition == 2) | |||
{ | |||
if (userEntity.F_CompanyId == paramConfig.CreateUser.CompanyId) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
else if (item.condition == 3) // 需要存在上级关系 | |||
@@ -619,12 +634,15 @@ namespace Learun.Application.WorkFlow | |||
if (postIBLL.IsUp(postList1, postList2)) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
else if (item.condition == 4) // 需要存在下级关系 | |||
@@ -634,6 +652,21 @@ namespace Learun.Application.WorkFlow | |||
var postList2 = userRelationIBLL.GetObjectIds(userEntity.F_UserId, 2);// 节点审核人岗位 | |||
if (postIBLL.IsDown(postList1, postList2)) | |||
{ | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
else | |||
{ | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
@@ -643,15 +676,6 @@ namespace Learun.Application.WorkFlow | |||
}); | |||
} | |||
} | |||
else | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
break; | |||
@@ -664,12 +688,15 @@ namespace Learun.Application.WorkFlow | |||
var userEntity3 = userIBLL.GetEntityByUserId(userItem); | |||
if (userEntity3 != null) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity3.F_UserId)) | |||
{ | |||
Id = userEntity3.F_UserId, | |||
Account = userEntity3.F_Account, | |||
Name = userEntity3.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity3.F_UserId, | |||
Account = userEntity3.F_Account, | |||
Name = userEntity3.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
} | |||
@@ -695,12 +722,15 @@ namespace Learun.Application.WorkFlow | |||
var userEntity = userIBLL.GetEntityByUserId(userRelationItem.F_UserId); | |||
if (userEntity != null) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity.F_UserId)) | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity.F_UserId, | |||
Account = userEntity.F_Account, | |||
Name = userEntity.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
break; | |||
@@ -723,12 +753,15 @@ namespace Learun.Application.WorkFlow | |||
var userEntity5 = userIBLL.GetEntityByUserId(row[0].ToString()); | |||
if (userEntity5 != null) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity5.F_UserId)) | |||
{ | |||
Id = userEntity5.F_UserId, | |||
Account = userEntity5.F_Account, | |||
Name = userEntity5.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity5.F_UserId, | |||
Account = userEntity5.F_Account, | |||
Name = userEntity5.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
} | |||
@@ -741,12 +774,15 @@ namespace Learun.Application.WorkFlow | |||
var userEntity6 = userIBLL.GetEntityByUserId(task.F_CreateUserId); | |||
if (userEntity6 != null) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity6.F_UserId)) | |||
{ | |||
Id = userEntity6.F_UserId, | |||
Account = userEntity6.F_Account, | |||
Name = userEntity6.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity6.F_UserId, | |||
Account = userEntity6.F_Account, | |||
Name = userEntity6.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
break; | |||
@@ -782,12 +818,60 @@ namespace Learun.Application.WorkFlow | |||
if (null != userEntity7) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
if (!list.Exists(m => m.Id == userEntity7.F_UserId)) | |||
{ | |||
Id = userEntity7.F_UserId, | |||
Account = userEntity7.F_Account, | |||
Name = userEntity7.F_RealName | |||
}); | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity7.F_UserId, | |||
Account = userEntity7.F_Account, | |||
Name = userEntity7.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||
break; | |||
case 8://liang 20210706新增部门负责人判断 | |||
//获取流程创建用户的分管领导 | |||
//判断用户所在部门是否有上级部门:如果有,找到上级部门的负责人;如果没有,找本部门的分管校长; | |||
string deptMasterId = ""; | |||
var selfDepart2 = departmentIBLL.GetEntity(paramConfig.CreateUser.DepartmentId); | |||
if (selfDepart2 != null) | |||
{ | |||
//本部门存在部门负责人 | |||
if (!string.IsNullOrEmpty(selfDepart2.F_Manager)) | |||
{ | |||
deptMasterId = selfDepart2.F_Manager; | |||
} | |||
else | |||
{ | |||
//本部门不存在就找上级部门 | |||
var parentDepart = departmentIBLL.GetEntity(selfDepart2.F_ParentId); | |||
if (parentDepart != null) | |||
{ | |||
if (!string.IsNullOrEmpty(selfDepart2.F_Manager)) | |||
{ | |||
deptMasterId = parentDepart.F_Manager; | |||
} | |||
} | |||
} | |||
} | |||
//找到部门负责人就增加审批人 | |||
if (!string.IsNullOrEmpty(deptMasterId)) | |||
{ | |||
var userEntity7 = userIBLL.GetEntityByUserId(deptMasterId); | |||
if (null != userEntity7) | |||
{ | |||
if (!list.Exists(m => m.Id == userEntity7.F_UserId)) | |||
{ | |||
list.Add(new NWFUserInfo() | |||
{ | |||
Id = userEntity7.F_UserId, | |||
Account = userEntity7.F_Account, | |||
Name = userEntity7.F_RealName | |||
}); | |||
} | |||
} | |||
} | |||