public void SaveMinutesOfSession(vw_MinutesOfSession MinutesOfSession) { Cases_CaseSessions session = GetByID(MinutesOfSession.SessionID); session.MunitesOfSession = MinutesOfSession.Text; Update(session); Save(); }
public ActionResult Create(MinutesOfSessionCreateViewModel MinutesOfSessionViewModel) { if (CurrentUser != null) { ViewData["SessionEnded"] = false; vw_MinutesOfSession vw_Minutes = new vw_MinutesOfSession() { SessionID = MinutesOfSessionViewModel.MinutesOfSession.SessionID, Text = MinutesOfSessionViewModel.MinutesOfSession.Text, }; if (MinutesOfSessionViewModel.MinutesOfSession.Text == null) { return(CPartialView(PrepareViewModel(MinutesOfSessionViewModel.MinutesOfSession)).WithErrorMessages("برجاء كتابة المحضر")); } var result = SessionService.SaveMinutesOfSession(vw_Minutes); if (result == Base.SaveMinutesOfSessionStatus.Succeeded) { ViewBag.Saved = true; return(CPartialView(PrepareViewModel(MinutesOfSessionViewModel.MinutesOfSession)).WithSuccessMessages(JIC.Base.Resources.Messages.OperationCompletedSuccessfully)); } else if (result == SaveMinutesOfSessionStatus.SessionSentToJudge) { return(CPartialView(PrepareViewModel(MinutesOfSessionViewModel.MinutesOfSession)).WithErrorMessages("لا يمكن تعديل المحضر بعد إرساله للقاضى للتصديق")); } else if (result == SaveMinutesOfSessionStatus.SessionApprovedByJudge) { return(CPartialView(PrepareViewModel(MinutesOfSessionViewModel.MinutesOfSession)).WithErrorMessages("لايمكن الحفظ تم التصديق من القاضى")); } else { return(CPartialView(PrepareViewModel(MinutesOfSessionViewModel.MinutesOfSession)).WithErrorMessages(JIC.Base.Resources.Messages.OperationNotCompleted)); } } else { ViewData["SessionEnded"] = true; return(CPartialView()); } }
public SaveMinutesOfSessionStatus SaveMinutesOfSession(vw_MinutesOfSession MinutesOfSession) { if (SessionsComp.IsAppprovedByJudge(MinutesOfSession.SessionID)) { return(SaveMinutesOfSessionStatus.SessionApprovedByJudge); } if (SessionsComp.IsSentToJudge(MinutesOfSession.SessionID)) { return(SaveMinutesOfSessionStatus.SessionSentToJudge); } else { try { SessionsComp.SaveMinutesOfSession(MinutesOfSession); return(SaveMinutesOfSessionStatus.Succeeded); } catch (Exception ex) { HandleException(ex); return(SaveMinutesOfSessionStatus.Failed); } } }
public void SaveMinutesOfSession(vw_MinutesOfSession MinutesOfSession) { sessionsRepository.SaveMinutesOfSession(MinutesOfSession); }
public SaveMinutesOfSessionStatus SaveMinutesOfSession(vw_MinutesOfSession MinutesOfSession) { throw new NotImplementedException(); }