public void Add(YellowstonePathology.Business.Domain.OrderCommentEnum orderCommentEnum, YellowstonePathology.Business.User.SystemUser eventUser, string masterAccessionNo, int clientId, string clientOrderId, string comment) { string objectId = MongoDB.Bson.ObjectId.GenerateNewId().ToString(); YellowstonePathology.Business.Domain.OrderCommentLog orderCommentLog = new Business.Domain.OrderCommentLog(objectId); YellowstonePathology.Business.Interface.IOrderComment orderComment = YellowstonePathology.Business.Domain.OrderCommentFactory.GetOrderComment(orderCommentEnum); orderCommentLog.SetDefaultValues(eventUser); orderCommentLog.FromEvent(orderComment); orderCommentLog.MasterAccessionNo = masterAccessionNo; orderCommentLog.ClientId = clientId; orderCommentLog.Description = orderComment.Description; orderCommentLog.ClientOrderId = clientOrderId; this.Add(orderCommentLog); }
public static void LogEvent(string clientOrderId, string comment, YellowstonePathology.Business.User.SystemUser systemUser, YellowstonePathology.Business.Domain.OrderCommentEnum eventEnum) { OrderCommentLogCollection orderCommentLogCollection = new OrderCommentLogCollection(); YellowstonePathology.Business.Interface.IOrderComment eventInfo = YellowstonePathology.Business.Domain.OrderCommentFactory.GetOrderComment(eventEnum); string objectId = MongoDB.Bson.ObjectId.GenerateNewId().ToString(); OrderCommentLog eventLog = new OrderCommentLog(objectId); eventLog.FromEvent(eventInfo); eventLog.ClientOrderId = clientOrderId; eventLog.Comment = comment; eventLog.LoggedById = systemUser.UserId; eventLog.LoggedBy = systemUser.DisplayName; eventLog.LogDate = DateTime.Now; orderCommentLogCollection.Add(eventLog); }
public static YellowstonePathology.Business.Interface.IOrderComment GetOrderComment(YellowstonePathology.Business.Domain.OrderCommentEnum orderCommentEnum) { YellowstonePathology.Business.Interface.IOrderComment result = null; switch (orderCommentEnum) { case OrderCommentEnum.CytologyLogFaxSentRequestingInformation: //5000 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(5000); break; case OrderCommentEnum.CytologyLogFaxSentRequestingABN: //5001 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(5001); break; case OrderCommentEnum.CytologyLogClientCall: //5002 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(5002); break; case OrderCommentEnum.SpecimenReceivedFromHistology: //5005 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(5005); break; case OrderCommentEnum.CancelOrder: //7000 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(7000); break; case OrderCommentEnum.ClientOrderAccessioned: //1010 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(1010); break; case OrderCommentEnum.ClientOrderSpecimenAccessioned: //1011 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(1011); break; case OrderCommentEnum.PatientVerified: //6010 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(6010); break; case OrderCommentEnum.PatientVerificationError: //6020 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(6020); break; case OrderCommentEnum.SpecimenVerified: //6011 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(6011); break; case OrderCommentEnum.SpecimenVerificationError: //6021 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(6021); break; case OrderCommentEnum.OrderIron: //6030 result = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetLabEventByEventId(6030); break; default: break; } return(result); }