internal List<string> historyContentMethod(SupportRequirementModel model, List<string> strList, SupportProcessStatus status, string target) { if (!String.IsNullOrEmpty(model.SupportRequirementId)) { SupportRequirementModel parentModel = _service.Requirements.Where(x => x.Id == model.SupportRequirementId).FirstOrDefault(); strList = historyContentMethod(parentModel, strList, status, target); } foreach (var item in model.SupportProcesses) { SupportHistoryModel m = new SupportHistoryModel() { Status = item.Status, }; switch (item.Status) { case SupportProcessStatus.Solution: m.Message = PublicMethod.JsonSerialize<SupportSolutionOptionModel>(item.SupportSolutions.SupportSolutionOptions.Where(x => x.selected == true).FirstOrDefault()); break; case SupportProcessStatus.CustomerReply: m.Name = model.MemberId; m.Message = item.Message; break; case SupportProcessStatus.HandlerReply: m.Name = model.Handler; m.Message = item.Message; break; } string historyStr = PublicMethod.JsonSerialize<SupportHistoryModel>(m); strList = _service.SendContentMethod(strList, target, CustomerCommand.History, historyStr); } return strList; }