代码提交测试
This commit is contained in:
parent
591be7e1d2
commit
5e11201784
@ -105,10 +105,16 @@ namespace APT.BaseData.Domain.Enums
|
|||||||
public enum NOTICETYPE
|
public enum NOTICETYPE
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 会议
|
/// 会议 行洛坑
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Description("1747261")]
|
[Description("2054208")]
|
||||||
Meeting = 5
|
Meeting = 5,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 会议 金鼎
|
||||||
|
/// </summary>
|
||||||
|
[Description("2163620")]
|
||||||
|
MeetingJD = 50
|
||||||
}
|
}
|
||||||
|
|
||||||
public enum FMDepartmentType
|
public enum FMDepartmentType
|
||||||
|
|||||||
@ -52,7 +52,7 @@ namespace APT.BaseData.Domain.IServices.FM
|
|||||||
/// <param name="dicApproveDepartMentID">自定义审批流程人员部门信息</param>
|
/// <param name="dicApproveDepartMentID">自定义审批流程人员部门信息</param>
|
||||||
/// <param name="approveTaskName">审批流名称</param>
|
/// <param name="approveTaskName">审批流名称</param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
void InsertApprove(string serialCode, string fromCode, string param, Guid id, string approveCode, Guid? finishNoticeId, bool sendMessage, Action action, Guid? approveId = null, Guid? approveUserId = null, Dictionary<int, T_FM_USER> dicApproveUser = null, Dictionary<int, Guid> dicApproveDepartMentID = null, string NoticeCode = "", string taskSourceFormCode = "", Guid? operaterID = null, string approveTaskName = "", Enums.FMTASKTYPE? TASK_TYPE = null, int? FREQUENCYE = null, DateTime? DateTimeLastest = null, int? BSOperateEnum = null, Guid? DATA_ID_LOG = null, Guid? DATA_ID_SUB = null);
|
void InsertApprove(string serialCode, string fromCode, string param, Guid id, string approveCode, Guid? finishNoticeId, bool sendMessage, Action action, Guid? approveId = null, Guid? approveUserId = null, Dictionary<int, T_FM_USER> dicApproveUser = null, Dictionary<int, Guid> dicApproveDepartMentID = null, string NoticeCode = "", string taskSourceFormCode = "", Guid? operaterID = null, string approveTaskName = "", Enums.FMTASKTYPE? TASK_TYPE = null, int? FREQUENCYE = null, DateTime? DateTimeLastest = null, int? BSOperateEnum = null, Guid? DATA_ID_LOG = null, Guid? DATA_ID_SUB = null, DateTime? dtTaskEnd = null, List<Guid> listDataIdSub = null);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 发布审批流
|
/// 发布审批流
|
||||||
|
|||||||
@ -16,6 +16,13 @@ namespace APT.BaseData.Domain.IServices.FM
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="noticeType"></param>
|
/// <param name="noticeType"></param>
|
||||||
/// <param name="DATA_ID"></param>
|
/// <param name="DATA_ID"></param>
|
||||||
void SendMsg(Enums.NOTICETYPE? noticeType, Guid? DATA_ID, Guid? KEY = null, T_FM_SYNC_TASK task = null);
|
void SendMsg(Enums.NOTICETYPE noticeType, Guid? DATA_ID, Guid? KEY = null, T_FM_SYNC_TASK task = null);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取会议模板ID
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="ORG_ID"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
string GetTEMPLATE_ID(Guid ORG_ID);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -316,7 +316,7 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
/// <param name="operaterID"></param>
|
/// <param name="operaterID"></param>
|
||||||
/// <param name="approveTaskName">审批流名称</param>
|
/// <param name="approveTaskName">审批流名称</param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public void InsertApprove(string serialCode, string fromCode, string param, Guid id, string approveCode, Guid? finishNoticeId, bool sendMessage, Action action, Guid? approveId = null, Guid? approveUserId = null, Dictionary<int, T_FM_USER> dicApproveUser = null, Dictionary<int, Guid> dicApproveDepartMentID = null, string NoticeCode = "", string taskSourceFormCode = "", Guid? operaterID = null, string approveTaskName = "", FMTASKTYPE? TASK_TYPE = null, int? FREQUENCYE = null, DateTime? DateTimeLastest = null, int? iBSOperateEnum = null, Guid? DATA_ID_LOG = null, Guid? DATA_ID_SUB = null)
|
public void InsertApprove(string serialCode, string fromCode, string param, Guid id, string approveCode, Guid? finishNoticeId, bool sendMessage, Action action, Guid? approveId = null, Guid? approveUserId = null, Dictionary<int, T_FM_USER> dicApproveUser = null, Dictionary<int, Guid> dicApproveDepartMentID = null, string NoticeCode = "", string taskSourceFormCode = "", Guid? operaterID = null, string approveTaskName = "", FMTASKTYPE? TASK_TYPE = null, int? FREQUENCYE = null, DateTime? DateTimeLastest = null, int? iBSOperateEnum = null, Guid? DATA_ID_LOG = null, Guid? DATA_ID_SUB = null, DateTime? dtTaskEnd = null, List<Guid> listDataIdSub = null)
|
||||||
{
|
{
|
||||||
T_PF_APPROVE approve = null;
|
T_PF_APPROVE approve = null;
|
||||||
//上个消息
|
//上个消息
|
||||||
@ -563,9 +563,17 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
e.DEFAULT_APPROVE_USER_ID = null;
|
e.DEFAULT_APPROVE_USER_ID = null;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
if (finishNotice == null && dtTaskEnd != null)
|
||||||
if (iBSOperateEnum == 200 || iBSOperateEnum == 20 || iBSOperateEnum == 60)
|
|
||||||
{
|
{
|
||||||
|
finishNotice = new T_FM_NOTIFICATION_TASK();
|
||||||
|
finishNotice.ID = Guid.Empty;
|
||||||
|
finishNotice.TASK_ENDDT = dtTaskEnd.Value;
|
||||||
|
}
|
||||||
|
if (iBSOperateEnum == 200 || iBSOperateEnum == 20 || iBSOperateEnum == 60 || iBSOperateEnum == 165)
|
||||||
|
{
|
||||||
|
if (listDataIdSub != null && listDataIdSub.Any())
|
||||||
|
listBSLog = GetOperateLogInfo(DATA_ID_LOG, approve.ORG_ID, appdetails, iBSOperateEnum, finishNotice, listDataIdSub);
|
||||||
|
else
|
||||||
listBSLog = GetOperateLogInfo(DATA_ID_LOG, approve.ORG_ID, appdetails, iBSOperateEnum, finishNotice, DATA_ID_SUB);//验收人确认整改
|
listBSLog = GetOperateLogInfo(DATA_ID_LOG, approve.ORG_ID, appdetails, iBSOperateEnum, finishNotice, DATA_ID_SUB);//验收人确认整改
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -582,7 +590,7 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
AddEntityNoCommit(approve);
|
AddEntityNoCommit(approve);
|
||||||
if (appdetails != null && appdetails.Any())
|
if (appdetails != null && appdetails.Any())
|
||||||
BantchAddEntityNoCommit(appdetails);
|
BantchAddEntityNoCommit(appdetails);
|
||||||
if (finishNotice != null)
|
if (finishNotice != null && finishNotice.ID != Guid.Empty)
|
||||||
UpdateEntityNoCommit(finishNotice, "NOTICE_STATUS", "TASK_DT", "MODIFIER_ID");
|
UpdateEntityNoCommit(finishNotice, "NOTICE_STATUS", "TASK_DT", "MODIFIER_ID");
|
||||||
if (notice != null)
|
if (notice != null)
|
||||||
AddEntityNoCommit(notice);
|
AddEntityNoCommit(notice);
|
||||||
@ -2091,7 +2099,20 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
if (finishNotice != null)
|
if (finishNotice != null)
|
||||||
taskEnd = finishNotice.TASK_ENDDT;
|
taskEnd = finishNotice.TASK_ENDDT;
|
||||||
listOperateLog = new List<T_BS_OPERATE_LOG>();
|
listOperateLog = new List<T_BS_OPERATE_LOG>();
|
||||||
|
if (OPERATEPOINT == OPERATEPOINT_Enums.RiskDelayApply)
|
||||||
|
{
|
||||||
|
//手动隐患上报
|
||||||
|
//添加当前操作者的 处理信息
|
||||||
|
//给所有人 添加 带操作记录
|
||||||
|
foreach (var item in ListDATA_ID_SUB)
|
||||||
|
{
|
||||||
|
listOperateLog.Add(AddModel(OPERATEPOINT_Enums.RiskDelayApply, dataId.Value, LoginID, APT.Infrastructure.Api.AppContext.CurrentSession.UserName, ORG_ID, 0, true, item));
|
||||||
|
for (int i = 0; i < ListUserID.Count; i++)
|
||||||
|
listOperateLog.Add(AddModel(OPERATEPOINT_Enums.RiskDelayApplyAudit, dataId.Value, ListUserID[i], ListUserName[i], ORG_ID, i, false, item));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
//OPERATEPOINT_Enums.CheckResultAudit => //(int)OPERATEPOINT_Enums.RiskGet
|
//OPERATEPOINT_Enums.CheckResultAudit => //(int)OPERATEPOINT_Enums.RiskGet
|
||||||
if (OPERATEPOINT == OPERATEPOINT_Enums.RiskInfoCompleteSD)
|
if (OPERATEPOINT == OPERATEPOINT_Enums.RiskInfoCompleteSD)
|
||||||
{
|
{
|
||||||
@ -2113,6 +2134,7 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
listOperateLog.Add(AddModel(OPERATEPOINT_Enums.RiskSendAudit, dataId.Value, ListUserID[i], ListUserName[i], ORG_ID, i, false, item));
|
listOperateLog.Add(AddModel(OPERATEPOINT_Enums.RiskSendAudit, dataId.Value, ListUserID[i], ListUserName[i], ORG_ID, i, false, item));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
catch { }
|
catch { }
|
||||||
}
|
}
|
||||||
return listOperateLog;
|
return listOperateLog;
|
||||||
@ -2292,6 +2314,7 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
if (isAddLog || (APT.Infrastructure.Api.AppContext.CurrentSession.UserID.HasValue && APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value == UserID))
|
if (isAddLog || (APT.Infrastructure.Api.AppContext.CurrentSession.UserID.HasValue && APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value == UserID))
|
||||||
{
|
{
|
||||||
ModelAdd.OPERTETIME = DateTime.Now;//默认通过
|
ModelAdd.OPERTETIME = DateTime.Now;//默认通过
|
||||||
|
ModelAdd.ISINTTIME = true;
|
||||||
}
|
}
|
||||||
return ModelAdd;
|
return ModelAdd;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -15,6 +15,7 @@ using APT.MS.Domain.Entities.PF;
|
|||||||
using APT.BaseData.Domain.Dtos;
|
using APT.BaseData.Domain.Dtos;
|
||||||
using Castle.Core.Internal;
|
using Castle.Core.Internal;
|
||||||
using APT.MS.Domain.Entities.SC;
|
using APT.MS.Domain.Entities.SC;
|
||||||
|
using TencentCloud.Sms.V20210111.Models;
|
||||||
|
|
||||||
namespace APT.BaseData.Services.Services.FM
|
namespace APT.BaseData.Services.Services.FM
|
||||||
{
|
{
|
||||||
@ -30,7 +31,7 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="noticeType">现在只支持会议</param>
|
/// <param name="noticeType">现在只支持会议</param>
|
||||||
/// <param name="DATA_ID"></param>
|
/// <param name="DATA_ID"></param>
|
||||||
public void SendMsg(NOTICETYPE? noticeType, Guid? DATA_ID, Guid? KEY = null, T_FM_SYNC_TASK task = null)
|
public void SendMsg(NOTICETYPE noticeType, Guid? DATA_ID, Guid? KEY = null, T_FM_SYNC_TASK task = null)
|
||||||
{
|
{
|
||||||
var mtConfig = GetEntity<T_SC_MT_CONFIG>(e => e.IS_SENDMSG);
|
var mtConfig = GetEntity<T_SC_MT_CONFIG>(e => e.IS_SENDMSG);
|
||||||
if (mtConfig == null)
|
if (mtConfig == null)
|
||||||
@ -39,10 +40,11 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
}
|
}
|
||||||
|
|
||||||
Expression<Func<T_FM_NOTICE, bool>> expression = e => e.NOTICE_STATUS == FMNoticeStatus.等待发送;
|
Expression<Func<T_FM_NOTICE, bool>> expression = e => e.NOTICE_STATUS == FMNoticeStatus.等待发送;
|
||||||
if (noticeType != null && noticeType.HasValue)
|
//if (noticeType != null && noticeType.HasValue)
|
||||||
{
|
//{
|
||||||
expression = expression.And(e => e.NOTICETYPE == noticeType.Value);
|
// expression = expression.And(e => e.NOTICETYPE == noticeType.Value);
|
||||||
}
|
//}
|
||||||
|
expression = expression.And(e => e.NOTICETYPE == noticeType);
|
||||||
if (DATA_ID != null && DATA_ID.HasValue)
|
if (DATA_ID != null && DATA_ID.HasValue)
|
||||||
{
|
{
|
||||||
expression = expression.And(e => e.DATA_ID == DATA_ID.Value);
|
expression = expression.And(e => e.DATA_ID == DATA_ID.Value);
|
||||||
@ -145,18 +147,46 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
{
|
{
|
||||||
var listTemp = listNoticeSend.Where(e => e.KEY == item && e.NOTICE_STATUS == FMNoticeStatus.等待发送);
|
var listTemp = listNoticeSend.Where(e => e.KEY == item && e.NOTICE_STATUS == FMNoticeStatus.等待发送);
|
||||||
phoneNumbers = listTemp.Select(e => e.TEL).ToArray();
|
phoneNumbers = listTemp.Select(e => e.TEL).ToArray();
|
||||||
|
switch (noticeType)
|
||||||
|
{
|
||||||
|
case NOTICETYPE.Meeting:
|
||||||
//2个参数
|
//2个参数
|
||||||
foreach (var itemS in listTemp)
|
foreach (var itemS in listTemp)
|
||||||
{
|
{
|
||||||
if (templates == null)
|
if (templates == null)
|
||||||
{
|
{
|
||||||
templates = new List<string>();
|
templates = new List<string>();
|
||||||
|
TEMPLATE_ID = itemS.TEMPLATE_ID;
|
||||||
templates.Add(itemS.TITLE);
|
templates.Add(itemS.TITLE);
|
||||||
templates.Add(itemS.ENDDT.Value.ToString("yyyy-MM-dd HH:mm"));
|
templates.Add(itemS.ENDDT.Value.ToString("yyyy-MM-dd HH:mm"));
|
||||||
TEMPLATE_ID = itemS.TEMPLATE_ID;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
|
case NOTICETYPE.MeetingJD:
|
||||||
|
//2个参数
|
||||||
|
foreach (var itemS in listTemp)
|
||||||
|
{
|
||||||
|
if (templates == null)
|
||||||
|
{
|
||||||
|
templates = new List<string>();
|
||||||
|
|
||||||
|
TEMPLATE_ID = itemS.TEMPLATE_ID;
|
||||||
|
templates.AddRange(GetSplit(itemS.TITLE.Split('[')[0]));
|
||||||
|
templates.Add(itemS.ENDDT.Value.Year.ToString());
|
||||||
|
templates.Add(itemS.ENDDT.Value.Month.ToString("00"));
|
||||||
|
templates.Add(itemS.ENDDT.Value.Day.ToString("00"));
|
||||||
|
templates.Add(itemS.ENDDT.Value.Hour.ToString("00"));
|
||||||
|
templates.Add(itemS.ENDDT.Value.Minute.ToString("00"));
|
||||||
|
templates.Add(itemS.ENDDT.Value.Second.ToString("00"));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
if (string.IsNullOrEmpty(TEMPLATE_ID) || phoneNumbers.Length < 1 || !templates.Any())
|
if (string.IsNullOrEmpty(TEMPLATE_ID) || phoneNumbers.Length < 1 || !templates.Any())
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
@ -164,7 +194,17 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var result = tencentSendSMS.sendSMS(TEMPLATE_ID, phoneNumbers, templates.ToArray());
|
SendSmsResponse result = null;
|
||||||
|
if (noticeType == NOTICETYPE.Meeting)
|
||||||
|
{
|
||||||
|
result = tencentSendSMS.sendSMS(TEMPLATE_ID, phoneNumbers, templates.ToArray());
|
||||||
|
}
|
||||||
|
else if (noticeType == NOTICETYPE.MeetingJD)
|
||||||
|
{
|
||||||
|
//result = tencentSendSMS.sendSMSDCJD(TEMPLATE_ID, phoneNumbers, templates.ToArray());
|
||||||
|
}
|
||||||
|
if (result != null)
|
||||||
|
{
|
||||||
foreach (var itemResult in result.SendStatusSet)
|
foreach (var itemResult in result.SendStatusSet)
|
||||||
{
|
{
|
||||||
foreach (var itemRN in listNoticeSend)
|
foreach (var itemRN in listNoticeSend)
|
||||||
@ -192,6 +232,7 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
//发送信息报错 例:腾讯云 服务器挂了
|
//发送信息报错 例:腾讯云 服务器挂了
|
||||||
@ -231,5 +272,86 @@ namespace APT.BaseData.Services.Services.FM
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取会议模板ID
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="ORG_ID"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public string GetTEMPLATE_ID(Guid ORG_ID)
|
||||||
|
{
|
||||||
|
if (ORG_ID == new Guid("B043B28B-BBC3-C452-6052-4FBA1457ABFA"))
|
||||||
|
{
|
||||||
|
return NOTICETYPE.Meeting.GetDescription();
|
||||||
|
}
|
||||||
|
else if (ORG_ID == new Guid("8B3C41AA-51B1-7CE9-1879-248A038C1B5C"))
|
||||||
|
{
|
||||||
|
return NOTICETYPE.MeetingJD.GetDescription();
|
||||||
|
}
|
||||||
|
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 文本分块(发送信息时用)
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="title"></param>
|
||||||
|
/// <param name="piece"></param>
|
||||||
|
/// <param name="splitMax"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
private List<string> GetSplit(string title, int piece = 3, int splitMax = 6)
|
||||||
|
{
|
||||||
|
int titleLength = title.Length;
|
||||||
|
List<string> listResult = new List<string>();
|
||||||
|
if (titleLength == piece)
|
||||||
|
{
|
||||||
|
//每个字一份
|
||||||
|
for (int i = 0; i < piece; i++)
|
||||||
|
{
|
||||||
|
listResult.Add(title.Substring(i, 1));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
else if (titleLength >= splitMax * piece)
|
||||||
|
{
|
||||||
|
//按最长给 多的也不给
|
||||||
|
for (int i = 0; i < piece; i++)
|
||||||
|
{
|
||||||
|
listResult.Add(title.Substring(i * splitMax, splitMax));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
int remain = titleLength % piece;
|
||||||
|
int Per = titleLength / piece;
|
||||||
|
|
||||||
|
//分割长度
|
||||||
|
List<int> listLength = new List<int>();
|
||||||
|
if (remain == 0)
|
||||||
|
{
|
||||||
|
for (int i = 0; i < piece; i++)
|
||||||
|
listLength.Add(Per);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
for (int i = 0; i < piece; i++)
|
||||||
|
{
|
||||||
|
remain--;
|
||||||
|
if (remain < 0)
|
||||||
|
listLength.Add(Per);
|
||||||
|
else
|
||||||
|
listLength.Add(Per + 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for (int i = 0; i < piece; i++)
|
||||||
|
{
|
||||||
|
listResult.Add(title.Substring(0, listLength[i]));
|
||||||
|
title = title.Substring(listLength[i]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return listResult;
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5658,6 +5658,31 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
|
|
||||||
if (!isLast && isApprovel)
|
if (!isLast && isApprovel)
|
||||||
{
|
{
|
||||||
|
IEnumerable<T_BS_OPERATE_LOG> listLog = null;
|
||||||
|
|
||||||
|
switch (CALLBACK_INTERFACE)
|
||||||
|
{
|
||||||
|
case "BS/BSRiskSubmitDelayApply/DealEndNew":
|
||||||
|
var listApplyDetail = GetEntities<T_BS_RISK_SUBMIT_DELAY_APPLY_DETAIL>(e => e.RISK_SUBMIT_DELAY_APPLY_ID == modelApp.DATA_ID);
|
||||||
|
if (listApplyDetail != null && listApplyDetail.Any())
|
||||||
|
{
|
||||||
|
var listContentID = listApplyDetail.Select(e => e.RISK_SUBMIT_CONTENT_ID).ToList();
|
||||||
|
listLog = GetUpdateDeal(OPERATEPOINT_Enums.RiskDelayApplyAudit, Guid.Empty, APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value, listContentID, taskFinish.TASK_ENDDT);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case "BS/BSRiskSubmit/NoticeNew":
|
||||||
|
var listContents = GetEntities<T_BS_RISK_SUBMIT_CONTENT>(e => e.RISK_SUBMIT_NOTICE_ID == modelApp.DATA_ID);
|
||||||
|
if (listContents != null && listContents.Any())
|
||||||
|
{
|
||||||
|
var listContentID = listContents.Select(e => e.ID);
|
||||||
|
var RISK_SUBMIT_ID = listContents.ToList()[0].RISK_SUBMIT_ID;
|
||||||
|
listLog = GetUpdateDeal(OPERATEPOINT_Enums.RiskSendAudit, RISK_SUBMIT_ID.Value, APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value, listContentID, taskFinish.TASK_ENDDT);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
//如果感觉taskID会乱 taskFinish 做case 判断
|
//如果感觉taskID会乱 taskFinish 做case 判断
|
||||||
this.UnifiedCommit(() =>
|
this.UnifiedCommit(() =>
|
||||||
{
|
{
|
||||||
@ -8070,6 +8095,7 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
List<Guid> listCheckUserID = new List<Guid>();
|
List<Guid> listCheckUserID = new List<Guid>();
|
||||||
List<T_FM_NOTIFICATION_TASK> listTaskBS044 = new List<T_FM_NOTIFICATION_TASK>();
|
List<T_FM_NOTIFICATION_TASK> listTaskBS044 = new List<T_FM_NOTIFICATION_TASK>();
|
||||||
|
|
||||||
|
List<T_BS_OPERATE_LOG> listLog = new List<T_BS_OPERATE_LOG>();
|
||||||
Dictionary<Guid, DateTime> dicContentIDDtEnd = new Dictionary<Guid, DateTime>();
|
Dictionary<Guid, DateTime> dicContentIDDtEnd = new Dictionary<Guid, DateTime>();
|
||||||
foreach (var item in listContent)
|
foreach (var item in listContent)
|
||||||
{
|
{
|
||||||
@ -8111,6 +8137,7 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
listNotice.Add(notice);
|
listNotice.Add(notice);
|
||||||
}
|
}
|
||||||
dicContentIDDtEnd.Add(item.RISK_SUBMIT_CONTENT_ID, item.LastDateApply.Value);
|
dicContentIDDtEnd.Add(item.RISK_SUBMIT_CONTENT_ID, item.LastDateApply.Value);
|
||||||
|
listLog.Add(AddModel(OPERATEPOINT_Enums.RiskDelayApplyCheck, entity.RISK_SUBMIT_ID, subContent.CHECK_USER_ID.Value, subContent.Nav_UserCheck.NAME, subContent.ORG_ID, 0, false, subContent.ID));//每个明细都要添加操作记录(最终查看是整改单)
|
||||||
}
|
}
|
||||||
|
|
||||||
#region 隐患整改单待办结束时间修改
|
#region 隐患整改单待办结束时间修改
|
||||||
@ -8140,6 +8167,13 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
|
if (listContent != null && listContent.Any())
|
||||||
|
{
|
||||||
|
var listContentID = listContent.Select(e => e.RISK_SUBMIT_CONTENT_ID).ToList();
|
||||||
|
listLog.AddRange(GetUpdateDeal(OPERATEPOINT_Enums.RiskDelayApplyAudit, entity.RISK_SUBMIT_ID, APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value, listContentID, taskFinish.TASK_ENDDT));
|
||||||
|
}
|
||||||
|
|
||||||
//修改 model
|
//修改 model
|
||||||
UnifiedCommit(() =>
|
UnifiedCommit(() =>
|
||||||
{
|
{
|
||||||
@ -8166,6 +8200,8 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
}
|
}
|
||||||
if (listTaskBS044 != null && listTaskBS044.Any())//隐患整改单修改 待办结束时间
|
if (listTaskBS044 != null && listTaskBS044.Any())//隐患整改单修改 待办结束时间
|
||||||
BantchUpdateEntityNoCommit(listTaskBS044);
|
BantchUpdateEntityNoCommit(listTaskBS044);
|
||||||
|
if (listLog != null && listLog.Any())//下个审批节点
|
||||||
|
BantchSaveEntityNoCommit(listLog);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
@ -8505,6 +8541,7 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
if (isAddLog || (APT.Infrastructure.Api.AppContext.CurrentSession.UserID.HasValue && APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value == UserID))
|
if (isAddLog || (APT.Infrastructure.Api.AppContext.CurrentSession.UserID.HasValue && APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value == UserID))
|
||||||
{
|
{
|
||||||
ModelAdd.OPERTETIME = DateTime.Now;//默认通过
|
ModelAdd.OPERTETIME = DateTime.Now;//默认通过
|
||||||
|
ModelAdd.ISINTTIME = true;
|
||||||
}
|
}
|
||||||
return ModelAdd;
|
return ModelAdd;
|
||||||
}
|
}
|
||||||
@ -8536,6 +8573,31 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
}
|
}
|
||||||
return model;
|
return model;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private IEnumerable<T_BS_OPERATE_LOG> GetUpdateDeal(OPERATEPOINT_Enums OPERATEPOINT, Guid DATA_ID, Guid UserID, IEnumerable<Guid> listDataIdSub, DateTime TASK_ENDDT)
|
||||||
|
{
|
||||||
|
if (UserID == Guid.Empty)
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
Expression<Func<T_BS_OPERATE_LOG, bool>> expression = e => e.OPERATEPOINT == OPERATEPOINT && e.USER_ID == UserID;
|
||||||
|
if (DATA_ID != Guid.Empty && listDataIdSub != null && listDataIdSub.Any())
|
||||||
|
expression = expression.And(e => e.DATA_ID == DATA_ID);
|
||||||
|
|
||||||
|
if (listDataIdSub != null && listDataIdSub.Any())
|
||||||
|
expression = expression.And(e => e.DATA_ID_SUB.HasValue && listDataIdSub.Contains(e.DATA_ID_SUB.Value));
|
||||||
|
var listModel = GetEntities(expression);
|
||||||
|
if (listModel != null && listModel.Any())
|
||||||
|
{
|
||||||
|
foreach (var item in listModel)
|
||||||
|
{
|
||||||
|
item.OPERTETIME = DateTime.Now;
|
||||||
|
if (TASK_ENDDT != null)
|
||||||
|
item.ISINTTIME = (item.OPERTETIME > TASK_ENDDT ? false : true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return listModel;
|
||||||
|
}
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1508,7 +1508,23 @@ namespace APT.MS.Domain.Enums
|
|||||||
[Description("整改落实人确认")]
|
[Description("整改落实人确认")]
|
||||||
RiskNoticeActureCheck = 160,
|
RiskNoticeActureCheck = 160,
|
||||||
|
|
||||||
//延期申请
|
/// <summary>
|
||||||
|
/// 延期申请 165
|
||||||
|
/// </summary>
|
||||||
|
[Description("延期申请")]
|
||||||
|
RiskDelayApply = 165,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 延期申请审批 170
|
||||||
|
/// </summary>
|
||||||
|
[Description("延期申请审批")]
|
||||||
|
RiskDelayApplyAudit = 170,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 验收人确认 175
|
||||||
|
/// </summary>
|
||||||
|
[Description("验收人确认")]
|
||||||
|
RiskDelayApplyCheck = 175,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 整改落实人确认 180
|
/// 整改落实人确认 180
|
||||||
|
|||||||
@ -180,6 +180,11 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
for (int i = 0; i < ListUserID.Count; i++)
|
for (int i = 0; i < ListUserID.Count; i++)
|
||||||
listResult.Add(AddModel(OPERATEPOINT_Enums.RiskDeal, DATA_ID, ListUserID[i], ListUserName[i], ORG_ID, i, false, DATA_ID_SUB));
|
listResult.Add(AddModel(OPERATEPOINT_Enums.RiskDeal, DATA_ID, ListUserID[i], ListUserName[i], ORG_ID, i, false, DATA_ID_SUB));
|
||||||
break;
|
break;
|
||||||
|
case OPERATEPOINT_Enums.RiskDelayApplyCheck:
|
||||||
|
modelLogUpdate = GetUpdateDeal(OPERATEPOINT, DATA_ID, UserIDLogin, DATA_ID_SUB, TASK_ENDDT);//处理自己的
|
||||||
|
if (modelLogUpdate != null)
|
||||||
|
listResult.Add(modelLogUpdate);
|
||||||
|
break;
|
||||||
case OPERATEPOINT_Enums.RiskDeal:
|
case OPERATEPOINT_Enums.RiskDeal:
|
||||||
modelLogUpdate = GetUpdateDeal(OPERATEPOINT, DATA_ID, UserIDLogin, DATA_ID_SUB, TASK_ENDDT);//处理自己的
|
modelLogUpdate = GetUpdateDeal(OPERATEPOINT, DATA_ID, UserIDLogin, DATA_ID_SUB, TASK_ENDDT);//处理自己的
|
||||||
if (modelLogUpdate != null)
|
if (modelLogUpdate != null)
|
||||||
@ -267,6 +272,7 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
if (isAddLog || (APT.Infrastructure.Api.AppContext.CurrentSession.UserID.HasValue && APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value == UserID))
|
if (isAddLog || (APT.Infrastructure.Api.AppContext.CurrentSession.UserID.HasValue && APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value == UserID))
|
||||||
{
|
{
|
||||||
ModelAdd.OPERTETIME = DateTime.Now;//默认通过
|
ModelAdd.OPERTETIME = DateTime.Now;//默认通过
|
||||||
|
ModelAdd.ISINTTIME = true;
|
||||||
}
|
}
|
||||||
return ModelAdd;
|
return ModelAdd;
|
||||||
}
|
}
|
||||||
@ -285,7 +291,10 @@ namespace APT.BaseData.Services.DomainServices
|
|||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
Expression<Func<T_BS_OPERATE_LOG, bool>> expression = e => e.DATA_ID == DATA_ID && e.OPERATEPOINT == OPERATEPOINT && e.USER_ID == UserID;
|
Expression<Func<T_BS_OPERATE_LOG, bool>> expression = e => e.OPERATEPOINT == OPERATEPOINT && e.USER_ID == UserID;
|
||||||
|
if (DATA_ID != Guid.Empty)
|
||||||
|
expression = expression.And(e => e.DATA_ID == DATA_ID);
|
||||||
|
|
||||||
if (DATA_ID_SUB.HasValue)
|
if (DATA_ID_SUB.HasValue)
|
||||||
expression = expression.And(e => e.DATA_ID_SUB.HasValue && e.DATA_ID_SUB == DATA_ID_SUB);
|
expression = expression.And(e => e.DATA_ID_SUB.HasValue && e.DATA_ID_SUB == DATA_ID_SUB);
|
||||||
var model = GetEntity(expression);
|
var model = GetEntity(expression);
|
||||||
|
|||||||
@ -26,13 +26,15 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
IPFCodeRuleService CodeRuleService { get; set; }
|
IPFCodeRuleService CodeRuleService { get; set; }
|
||||||
IPFApproveCallBackService ApproveCallBackService { get; set; }
|
IPFApproveCallBackService ApproveCallBackService { get; set; }
|
||||||
IFMDepartmentService DepartmentService { get; set; }
|
IFMDepartmentService DepartmentService { get; set; }
|
||||||
public BSRiskSubmitDelayApplyController(IFMNotificationTaskService notificationTaskService, IFMFlowPermitService mFlowPermitService, IPFCodeRuleService codeRuleService, IPFApproveCallBackService approveCallBackService, IFMDepartmentService departmentService)
|
IBSOperateLogService OperateLogService { get; set; }
|
||||||
|
public BSRiskSubmitDelayApplyController(IFMNotificationTaskService notificationTaskService, IFMFlowPermitService mFlowPermitService, IPFCodeRuleService codeRuleService, IPFApproveCallBackService approveCallBackService, IFMDepartmentService departmentService, IBSOperateLogService operateLogService)
|
||||||
{
|
{
|
||||||
NotificationTaskService = notificationTaskService;
|
NotificationTaskService = notificationTaskService;
|
||||||
MFlowPermitService = mFlowPermitService;
|
MFlowPermitService = mFlowPermitService;
|
||||||
CodeRuleService = codeRuleService;
|
CodeRuleService = codeRuleService;
|
||||||
ApproveCallBackService = approveCallBackService;
|
ApproveCallBackService = approveCallBackService;
|
||||||
DepartmentService = departmentService;
|
DepartmentService = departmentService;
|
||||||
|
OperateLogService = operateLogService;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -137,7 +139,6 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
Guid NoticePersonID = new Guid(filter.Keyword);
|
Guid NoticePersonID = new Guid(filter.Keyword);
|
||||||
DateTime dtNowDate = DateTime.Now.Date;
|
DateTime dtNowDate = DateTime.Now.Date;
|
||||||
Guid LoginID = APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value;
|
Guid LoginID = APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value;
|
||||||
|
|
||||||
var info = GetEntities<T_BS_RISK_SUBMIT_CONTENT>(e => e.RISK_SUBMIT_NOTICE_PERSON_ID == NoticePersonID && e.ACTUAL_DEAL_USER_ID.HasValue && e.ACTUAL_DEAL_USER_ID.Value == LoginID && !e.IS_DELETED && e.LastDateUser.HasValue && e.LastDateUser.Value >= dtNowDate && (e.RiskContentState == (int)RiskContentState.ActualDealCheck || e.RiskContentState == (int)RiskContentState.OKNotBack), null, null).ToList();
|
var info = GetEntities<T_BS_RISK_SUBMIT_CONTENT>(e => e.RISK_SUBMIT_NOTICE_PERSON_ID == NoticePersonID && e.ACTUAL_DEAL_USER_ID.HasValue && e.ACTUAL_DEAL_USER_ID.Value == LoginID && !e.IS_DELETED && e.LastDateUser.HasValue && e.LastDateUser.Value >= dtNowDate && (e.RiskContentState == (int)RiskContentState.ActualDealCheck || e.RiskContentState == (int)RiskContentState.OKNotBack), null, null).ToList();
|
||||||
var listContID = info.Select(e => e.ID);
|
var listContID = info.Select(e => e.ID);
|
||||||
|
|
||||||
@ -395,6 +396,7 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
|
|
||||||
entity.APPROVE_ID = Guid.NewGuid();
|
entity.APPROVE_ID = Guid.NewGuid();
|
||||||
|
|
||||||
|
var listDataIdSub = listContent.Select(e => e.ID).ToList();
|
||||||
MFlowPermitService.InsertApprove(serialCode, "BS046", parms, entity.ID, "BS046_SHOWPRINT", entity.TaskID, true, () =>
|
MFlowPermitService.InsertApprove(serialCode, "BS046", parms, entity.ID, "BS046_SHOWPRINT", entity.TaskID, true, () =>
|
||||||
{
|
{
|
||||||
if (entity != null)
|
if (entity != null)
|
||||||
@ -402,7 +404,7 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
//UpdateEntityNoCommit(content); //延期申请提交
|
//UpdateEntityNoCommit(content); //延期申请提交
|
||||||
BantchSaveEntityNoCommit(listApplyDetail);//延期申请明细
|
BantchSaveEntityNoCommit(listApplyDetail);//延期申请明细
|
||||||
BantchSaveEntityNoCommit(listContent);//延期申请提交
|
BantchSaveEntityNoCommit(listContent);//延期申请提交
|
||||||
}, entity.APPROVE_ID, null, dicApproveUser, dicApproveDepartMent, null, null, null, null, FMTASKTYPE.BS_RiskUp_DealApply);
|
}, entity.APPROVE_ID, null, dicApproveUser, dicApproveDepartMent, null, null, null, null, FMTASKTYPE.BS_RiskUp_DealApply, null, null, (int)OPERATEPOINT_Enums.RiskDelayApply, entity.RISK_SUBMIT_ID, null, null, listDataIdSub);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@ -556,10 +558,6 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
Guid LoginID = APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value;
|
Guid LoginID = APT.Infrastructure.Api.AppContext.CurrentSession.UserID.Value;
|
||||||
//var details = GetEntities<T_BS_RISK_SUBMIT_DELAY_APPLY_DETAIL>(e => e.RISK_SUBMIT_DELAY_APPLY_ID == DataID && !e.IS_DELETED && e.CHCEKUSERID == LoginID, null, null).ToList();
|
//var details = GetEntities<T_BS_RISK_SUBMIT_DELAY_APPLY_DETAIL>(e => e.RISK_SUBMIT_DELAY_APPLY_ID == DataID && !e.IS_DELETED && e.CHCEKUSERID == LoginID, null, null).ToList();
|
||||||
var details = GetEntities<T_BS_RISK_SUBMIT_DELAY_APPLY_DETAIL>(e => listDetailGuid.Contains(e.ID) && e.CHCEKTIME == null, null, null).ToList();
|
var details = GetEntities<T_BS_RISK_SUBMIT_DELAY_APPLY_DETAIL>(e => listDetailGuid.Contains(e.ID) && e.CHCEKTIME == null, null, null).ToList();
|
||||||
for (int i = 0; i < details.Count; i++)
|
|
||||||
{
|
|
||||||
details[i].CHCEKTIME = DateTime.Now; //设置审批时间
|
|
||||||
}
|
|
||||||
|
|
||||||
T_FM_NOTIFICATION_TASK task = this.GetEntity<T_FM_NOTIFICATION_TASK>(TaskID);
|
T_FM_NOTIFICATION_TASK task = this.GetEntity<T_FM_NOTIFICATION_TASK>(TaskID);
|
||||||
task.TASK_DT = DateTime.Now;
|
task.TASK_DT = DateTime.Now;
|
||||||
@ -567,12 +565,20 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
task.NOTICE_STATUS = FMNoticeStatusEnum.正常已办.GetInt();
|
task.NOTICE_STATUS = FMNoticeStatusEnum.正常已办.GetInt();
|
||||||
else
|
else
|
||||||
task.NOTICE_STATUS = FMNoticeStatusEnum.超期办理.GetInt();
|
task.NOTICE_STATUS = FMNoticeStatusEnum.超期办理.GetInt();
|
||||||
|
List<T_BS_OPERATE_LOG> listOperateLog = new List<T_BS_OPERATE_LOG>();
|
||||||
|
for (int i = 0; i < details.Count; i++)
|
||||||
|
{
|
||||||
|
details[i].CHCEKTIME = DateTime.Now; //设置审批时间
|
||||||
|
listOperateLog.AddRange(OperateLogService.GetListOperateLog(OPERATEPOINT_Enums.RiskDelayApplyCheck, Guid.Empty, LoginID, null, null, null, filter.OrgId, details[i].RISK_SUBMIT_CONTENT_ID, null, false, task.TASK_ENDDT));//修改操作日志
|
||||||
|
}
|
||||||
|
|
||||||
this.UnifiedCommit(() =>
|
this.UnifiedCommit(() =>
|
||||||
{
|
{
|
||||||
BantchUpdateEntityNoCommit(details);
|
BantchUpdateEntityNoCommit(details);
|
||||||
if (task != null)//代办消息 清除
|
if (task != null)//代办消息 清除
|
||||||
UpdateEntityNoCommit(task, "NOTICE_STATUS", "TASK_DT", "MODIFIER_ID");
|
UpdateEntityNoCommit(task, "NOTICE_STATUS", "TASK_DT", "MODIFIER_ID");
|
||||||
|
if (listOperateLog != null && listOperateLog.Any())
|
||||||
|
BantchSaveEntityNoCommit(listOperateLog);
|
||||||
|
|
||||||
});
|
});
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@ -121,7 +121,15 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
}
|
}
|
||||||
filter.Include = listInclude;
|
filter.Include = listInclude;
|
||||||
|
|
||||||
var safecheck = GetEntity<T_BS_SAFE_CHECK>(null, filter);
|
T_BS_SAFE_CHECK safecheck = new T_BS_SAFE_CHECK();
|
||||||
|
try
|
||||||
|
{
|
||||||
|
safecheck = GetEntity<T_BS_SAFE_CHECK>(null, filter);
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
return safecheck;
|
||||||
|
}
|
||||||
|
|
||||||
#region 主体的很多属性只需要显示名称 例:区域 项目等
|
#region 主体的很多属性只需要显示名称 例:区域 项目等
|
||||||
|
|
||||||
@ -2063,14 +2071,15 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
appOperaterID = userOper.ID;
|
appOperaterID = userOper.ID;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
DateTime? dtTaskEnd = null;
|
||||||
T_FM_NOTIFICATION_TASK task = null;
|
T_FM_NOTIFICATION_TASK task = null;
|
||||||
if (entity.TaskID != Guid.Empty)
|
if (entity.TaskID != Guid.Empty)
|
||||||
{
|
{
|
||||||
task = NotificationTaskService.GetEntityTask(entity.TaskID, "BS032_SHOWPRINT");
|
task = NotificationTaskService.GetEntityTask(entity.TaskID, "BS032_SHOWPRINT");
|
||||||
|
dtTaskEnd = task.TASK_ENDDT;
|
||||||
if (!task.SOURCE_DATA_ID.HasValue)
|
if (!task.SOURCE_DATA_ID.HasValue)
|
||||||
task.SOURCE_DATA_ID = entity.ID;
|
task.SOURCE_DATA_ID = entity.ID;
|
||||||
}
|
}
|
||||||
|
|
||||||
MFlowPermitService.InsertApprove(serialCode, "BS032", param, entity.ID, "BS032_SHOWPRINT", null, true, () =>
|
MFlowPermitService.InsertApprove(serialCode, "BS032", param, entity.ID, "BS032_SHOWPRINT", null, true, () =>
|
||||||
{
|
{
|
||||||
if (entity != null)
|
if (entity != null)
|
||||||
@ -2101,7 +2110,7 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
BantchDeleteEntityNoCommit<T_BS_SAFE_CHECK_PROJECT_CATEGORY>(listDelCategoryID);
|
BantchDeleteEntityNoCommit<T_BS_SAFE_CHECK_PROJECT_CATEGORY>(listDelCategoryID);
|
||||||
if (listDelUserIDs != null)
|
if (listDelUserIDs != null)
|
||||||
BantchDeleteEntityNoCommit<T_BS_SAFE_CHECK_DETAIL_USER>(listDelUserIDs);
|
BantchDeleteEntityNoCommit<T_BS_SAFE_CHECK_DETAIL_USER>(listDelUserIDs);
|
||||||
}, entity.APPROVE_ID, null, null, null, null, "BS032_SHOWPRINT", appOperaterID, approveTaskName, FMTASKTYPE.BS_SafeCheck_Make_Audit, null, entity.CHECKTIME, (int)OPERATEPOINT_Enums.CheckForm, entity.ID);//, entity.LIMITDATETIME
|
}, entity.APPROVE_ID, null, null, null, null, "BS032_SHOWPRINT", appOperaterID, approveTaskName, FMTASKTYPE.BS_SafeCheck_Make_Audit, null, entity.CHECKTIME, (int)OPERATEPOINT_Enums.CheckForm, entity.ID, null, dtTaskEnd);//, entity.LIMITDATETIME
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
@ -4812,8 +4821,10 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
//{
|
//{
|
||||||
// param = entity.Nav_CheckType.CODE + "_" + param;
|
// param = entity.Nav_CheckType.CODE + "_" + param;
|
||||||
//}
|
//}
|
||||||
|
DateTime? dtTaskEnd = null;
|
||||||
|
if (task != null)
|
||||||
|
dtTaskEnd = task.TASK_ENDDT;
|
||||||
|
|
||||||
//entity.TaskID
|
|
||||||
MFlowPermitService.InsertApprove(serialCode, FORM_CODE, param, entity.ID, "BS034_SHOWPRINT", null, true, () =>
|
MFlowPermitService.InsertApprove(serialCode, FORM_CODE, param, entity.ID, "BS034_SHOWPRINT", null, true, () =>
|
||||||
{
|
{
|
||||||
if (entity != null)
|
if (entity != null)
|
||||||
@ -4842,7 +4853,7 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
UpdateEntityNoCommit(Record);
|
UpdateEntityNoCommit(Record);
|
||||||
if (listOpLog != null && listOpLog.Count > 0)
|
if (listOpLog != null && listOpLog.Count > 0)
|
||||||
BantchSaveEntityNoCommit(listOpLog);//日志
|
BantchSaveEntityNoCommit(listOpLog);//日志
|
||||||
}, entity.APPROVE_CHECKAUDIT_ID, entity.USERID_DOPLAN, null, null, null, "BS034_VIEW", null, entity.NAME.Replace("任务表", "记录表") + "-审批", FMTASKTYPE.BS_SafeCheck_Audit, null, entity.LIMITDATETIME, ((int)OPERATEPOINT_Enums.CheckAgree), entity.ID);
|
}, entity.APPROVE_CHECKAUDIT_ID, entity.USERID_DOPLAN, null, null, null, "BS034_VIEW", null, entity.NAME.Replace("任务表", "记录表") + "-审批", FMTASKTYPE.BS_SafeCheck_Audit, null, entity.LIMITDATETIME, ((int)OPERATEPOINT_Enums.CheckAgree), entity.ID, null, dtTaskEnd);
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
@ -8272,6 +8283,27 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
{
|
{
|
||||||
throw new Exception("获取检查人员信息失败!");
|
throw new Exception("获取检查人员信息失败!");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Nav_ListCheckDetail ID 修改防止页面数据未清理直接修改 ID保持不变带来的影响
|
||||||
|
foreach (var item in entity.Nav_ListCheckDetail)
|
||||||
|
{
|
||||||
|
item.ID = Guid.NewGuid();
|
||||||
|
if (item.Nav_Files != null && item.Nav_Files.Any())
|
||||||
|
{
|
||||||
|
foreach (var itemF in item.Nav_Files)
|
||||||
|
{
|
||||||
|
itemF.SAFE_CHECK_DETAIL_ID = item.ID;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (item.Nav_ListCheckDetailReason != null && item.Nav_ListCheckDetailReason.Any())
|
||||||
|
{
|
||||||
|
foreach (var itemR in item.Nav_ListCheckDetailReason)
|
||||||
|
{
|
||||||
|
itemR.CHECK_DETAIL_ID = item.ID;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
var loginId = APT.Infrastructure.Api.AppContext.CurrentSession.UserID;
|
var loginId = APT.Infrastructure.Api.AppContext.CurrentSession.UserID;
|
||||||
DateTime dtNow = DateTime.Now;
|
DateTime dtNow = DateTime.Now;
|
||||||
List<T_BS_CHECK_MAIN> listMain = new List<T_BS_CHECK_MAIN>();
|
List<T_BS_CHECK_MAIN> listMain = new List<T_BS_CHECK_MAIN>();
|
||||||
|
|||||||
@ -317,9 +317,7 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
{
|
{
|
||||||
//相同
|
//相同
|
||||||
var UserReject = GetEntity<T_FM_USER>(entity.USERID_REJECT.Value);
|
var UserReject = GetEntity<T_FM_USER>(entity.USERID_REJECT.Value);
|
||||||
|
|
||||||
listTaskToday.Add(NotificationTaskService.InsertUserNoticeTaskModel("检查退回结果保持不变【编号:" + safeCheck.CODE + ",序号:" + entity.ROW_NO + "】", entity.ID, entity.ORG_ID, UserReject.ID, UserReject.NAME, DateTime.Now, 2, "", FMTASKTYPE.Default));
|
listTaskToday.Add(NotificationTaskService.InsertUserNoticeTaskModel("检查退回结果保持不变【编号:" + safeCheck.CODE + ",序号:" + entity.ROW_NO + "】", entity.ID, entity.ORG_ID, UserReject.ID, UserReject.NAME, DateTime.Now, 2, "", FMTASKTYPE.Default));
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -353,6 +351,11 @@ namespace APT.BS.WebApi.Controllers.Api
|
|||||||
|
|
||||||
var TaskEnd = NotificationTaskService.GetEntityTask(entity.TaskID, "BS069_SHOWPRINT");
|
var TaskEnd = NotificationTaskService.GetEntityTask(entity.TaskID, "BS069_SHOWPRINT");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
////保存草稿 只保存页面数据
|
////保存草稿 只保存页面数据
|
||||||
this.UnifiedCommit(() =>
|
this.UnifiedCommit(() =>
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user