修改结束时间
This commit is contained in:
		
							parent
							
								
									aaa7f288ff
								
							
						
					
					
						commit
						1b685f297c
					
				@ -244,7 +244,13 @@ namespace APT.BaseData.Domain.IServices.FM
 | 
				
			|||||||
        /// <returns></returns>
 | 
					        /// <returns></returns>
 | 
				
			||||||
        List<T_FM_NOTIFICATION_TASK> InsertUserNoticeTaskModels(List<string> Name, List<Guid> DataId, Guid? OrgId, List<Guid> UserId, List<string> userName,
 | 
					        List<T_FM_NOTIFICATION_TASK> InsertUserNoticeTaskModels(List<string> Name, List<Guid> DataId, Guid? OrgId, List<Guid> UserId, List<string> userName,
 | 
				
			||||||
  DateTime startTime, DateTime endTime, int noticeType, List<string> formCode);
 | 
					  DateTime startTime, DateTime endTime, int noticeType, List<string> formCode);
 | 
				
			||||||
 | 
					        /// <summary>
 | 
				
			||||||
 | 
					        /// 发送新消息集合返回实体集合
 | 
				
			||||||
 | 
					        /// </summary>
 | 
				
			||||||
 | 
					        /// <param name="id">消息ID</param>
 | 
				
			||||||
 | 
					        /// <returns></returns>
 | 
				
			||||||
 | 
					        List<T_FM_NOTIFICATION_TASK> InsertUserNoticeTaskModels(List<string> Name, List<Guid> DataId, Guid? OrgId, List<Guid> UserId, List<string> userName,
 | 
				
			||||||
 | 
					  DateTime startTime, List<DateTime> endTime, int noticeType, List<string> formCode);
 | 
				
			||||||
        /// <summary>
 | 
					        /// <summary>
 | 
				
			||||||
        /// 发送新消息集合返回实体集合
 | 
					        /// 发送新消息集合返回实体集合
 | 
				
			||||||
        /// </summary>
 | 
					        /// </summary>
 | 
				
			||||||
 | 
				
			|||||||
@ -581,7 +581,40 @@ namespace APT.BaseData.Services.Services.FM
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
            return notices;
 | 
					            return notices;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					        /// <summary>
 | 
				
			||||||
 | 
					        /// 插入新消息集合返回实体集合(wjn240705)
 | 
				
			||||||
 | 
					        /// </summary>
 | 
				
			||||||
 | 
					        /// <param name="id">消息ID</param>
 | 
				
			||||||
 | 
					        /// <returns></returns>
 | 
				
			||||||
 | 
					        public List<T_FM_NOTIFICATION_TASK> InsertUserNoticeTaskModels(List<string> Names, List<Guid> DataIds, Guid? OrgId, List<Guid> UserIds, List<string> UserNames,
 | 
				
			||||||
 | 
					  DateTime startTime, List<DateTime> endTimes, int noticeType, List<string> formCode)
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            List<T_FM_NOTIFICATION_TASK> notices = new List<T_FM_NOTIFICATION_TASK>();
 | 
				
			||||||
 | 
					            if (UserIds.Count > 0)
 | 
				
			||||||
 | 
					            {
 | 
				
			||||||
 | 
					                var index = 0;
 | 
				
			||||||
 | 
					                UserIds.ForEach(t =>
 | 
				
			||||||
 | 
					                {
 | 
				
			||||||
 | 
					                    T_FM_NOTIFICATION_TASK notice = new T_FM_NOTIFICATION_TASK();
 | 
				
			||||||
 | 
					                    notice.CODE = DateTime.Now.ToString("yyyyMMddHHmmss");
 | 
				
			||||||
 | 
					                    notice.NOTICE_TITLE = Names[index];
 | 
				
			||||||
 | 
					                    notice.SOURCE_DATA_ID = DataIds[index];
 | 
				
			||||||
 | 
					                    notice.ORG_ID = OrgId;
 | 
				
			||||||
 | 
					                    notice.ID = Guid.NewGuid();
 | 
				
			||||||
 | 
					                    notice.TASK_STARTDT = startTime;
 | 
				
			||||||
 | 
					                    notice.TASK_ENDDT = endTimes[index];
 | 
				
			||||||
 | 
					                    notice.NOTICE_TYPE = noticeType;
 | 
				
			||||||
 | 
					                    notice.NOTICE_STATUS = (int)FMNoticeStatusEnum.未处理;
 | 
				
			||||||
 | 
					                    notice.USER_ID = t;
 | 
				
			||||||
 | 
					                    notice.USER_NAME = UserNames[index];
 | 
				
			||||||
 | 
					                    notice.SOURCE_FORMCODE = formCode[index];
 | 
				
			||||||
 | 
					                    notices.Add(notice);
 | 
				
			||||||
 | 
					                    index++;
 | 
				
			||||||
 | 
					                });
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            return notices;
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
        /// <summary>
 | 
					        /// <summary>
 | 
				
			||||||
        /// 插入新消息集合返回实体集合(wjn0513)
 | 
					        /// 插入新消息集合返回实体集合(wjn0513)
 | 
				
			||||||
        /// </summary>
 | 
					        /// </summary>
 | 
				
			||||||
 | 
				
			|||||||
@ -5406,6 +5406,7 @@ namespace APT.BaseData.Services.DomainServices
 | 
				
			|||||||
                var noticeUserNames = new List<string>();
 | 
					                var noticeUserNames = new List<string>();
 | 
				
			||||||
                var noticeDataIds = new List<Guid>();
 | 
					                var noticeDataIds = new List<Guid>();
 | 
				
			||||||
                var noticeFormCodes = new List<string>();
 | 
					                var noticeFormCodes = new List<string>();
 | 
				
			||||||
 | 
					                var noticeEndTime = new List<DateTime>();
 | 
				
			||||||
                SystemCodeFilter riskCode = new SystemCodeFilter
 | 
					                SystemCodeFilter riskCode = new SystemCodeFilter
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
                    CodeType = (int)PFCodeRuleType.风险辨识任务编号,
 | 
					                    CodeType = (int)PFCodeRuleType.风险辨识任务编号,
 | 
				
			||||||
@ -5510,6 +5511,7 @@ namespace APT.BaseData.Services.DomainServices
 | 
				
			|||||||
                    noticeUserIds.Add((Guid)riskDetail.CHARGE_USER_ID);
 | 
					                    noticeUserIds.Add((Guid)riskDetail.CHARGE_USER_ID);
 | 
				
			||||||
                    noticeUserNames.Add(user.NAME);
 | 
					                    noticeUserNames.Add(user.NAME);
 | 
				
			||||||
                    noticeFormCodes.Add("HM062");
 | 
					                    noticeFormCodes.Add("HM062");
 | 
				
			||||||
 | 
					                    noticeEndTime.Add(DateTime.Parse(riskTask.END_TIME.ToShortDateString() + " 23:59:59"));
 | 
				
			||||||
                    risks.Add(riskTask);
 | 
					                    risks.Add(riskTask);
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
                int hazardIndex = 0;
 | 
					                int hazardIndex = 0;
 | 
				
			||||||
@ -5571,9 +5573,10 @@ namespace APT.BaseData.Services.DomainServices
 | 
				
			|||||||
                    noticeUserIds.Add((Guid)hazardDetail.CHARGE_USER_ID);
 | 
					                    noticeUserIds.Add((Guid)hazardDetail.CHARGE_USER_ID);
 | 
				
			||||||
                    noticeUserNames.Add(user.NAME);
 | 
					                    noticeUserNames.Add(user.NAME);
 | 
				
			||||||
                    noticeFormCodes.Add("HM102");
 | 
					                    noticeFormCodes.Add("HM102");
 | 
				
			||||||
 | 
					                    noticeEndTime.Add(DateTime.Parse(hazardTask.END_TIME.ToShortDateString() + " 23:59:59"));
 | 
				
			||||||
                    hazards.Add(hazardTask);
 | 
					                    hazards.Add(hazardTask);
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
                sendNoticeList = NotificationTaskService.InsertUserNoticeTaskModels(noticeTitles, noticeDataIds, entity.ORG_ID, noticeUserIds, noticeUserNames, DateTime.Now, DateTime.Parse(DateTime.Now.AddDays(1).ToShortDateString() + " 23:59:59"), (int)FMNoticeTypeEnum.消息, noticeFormCodes);
 | 
					                sendNoticeList = NotificationTaskService.InsertUserNoticeTaskModels( noticeTitles, noticeDataIds, entity.ORG_ID, noticeUserIds, noticeUserNames, DateTime.Now, noticeEndTime, (int)FMNoticeTypeEnum.消息, noticeFormCodes);
 | 
				
			||||||
                this.UnifiedCommit(() =>
 | 
					                this.UnifiedCommit(() =>
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
                    if (entity != null)
 | 
					                    if (entity != null)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user