public string GetCurrentSy() { SchoolYearService sys = new SchoolYearService(); SchoolYear sy = sys.GetCurrentSY(); return(sy.SY); }
public void LoadSY() { gvSY.DataSource = null; ISchoolYearService syService = new SchoolYearService(); string message = String.Empty; try { var sy = syService.GetAllSY(); SYList = new List<SchoolYear>(sy); gvSY.DataSource = SYList; gvSY.Refresh(); if (gvSY.RowCount != 0) gvSY.Rows[0].IsSelected = true; SYcurrent = SYList.Find(x => x.CurrentSY == true); } catch (Exception ex) { message = "Error Loading List of School Years"; MessageBox.Show(ex.ToString()); } }
public List<GradeSection> GetAllGradeSections() { SchoolYearService sys = new SchoolYearService(); string currentSY = String.Empty; currentSY = sys.GetCurrentSY().SY; return ToGradeSectionList(gsLogic.GetAllGradeSections(currentSY)); }
public List <GradeSection> GetAllGradeSections() { SchoolYearService sys = new SchoolYearService(); string currentSY = String.Empty; currentSY = sys.GetCurrentSY().SY; return(ToGradeSectionList(gsLogic.GetAllGradeSections(currentSY))); }
private void btnDelete_Click(object sender, EventArgs e) { if (SYSelected != null) { ISchoolYearService syService = new SchoolYearService(); string message = String.Empty; if (!syService.DeleteSY(SYSelected.SY, ref message)) { message = "Deletion of School Year Failed"; } else { Log("D", "SchoolYear", SYSelected); MessageBox.Show("Deleted succesfully!"); } } }
public List <SchoolYear> GetAllSY() { SchoolYearService sys = new SchoolYearService(); return(sys.GetAllSY()); }
public string GetCurrentSY() { SchoolYearService ss = new SchoolYearService(); return(ss.GetCurrentSY().SY); }
public string GetCurrentSy() { SchoolYearService sys = new SchoolYearService(); SchoolYear sy = sys.GetCurrentSY(); return sy.SY; }
private void UpdateCurrentSY(string szSY, bool bSY) { try { Boolean ret = false; string message = String.Empty; ISchoolYearService syService = new SchoolYearService(); SchoolYear schoolyear = new SchoolYear() { SY = szSY, CurrentSY = bSY }; ret = syService.UpdateSY(ref schoolyear, ref message); schoolyear.CurrentSY = true; Log("U", "SchoolYear", schoolyear); } catch (Exception ex) { MessageBox.Show("Error: " + ex.ToString()); } }
private void SaveSY() { try { Boolean ret = false; string message = String.Empty; int SYto = 0; SYto = int.Parse(txtSY.Text) + 1; ISchoolYearService syService = new SchoolYearService(); SchoolYear schoolyear = new SchoolYear() { SY = txtSY.Text + "-" + SYto.ToString(), CurrentSY = false }; ret = syService.CreateSY(ref schoolyear, ref message); Log("C", "SchoolYear", schoolyear); MessageBox.Show("Saved Successfully!"); LoadSY(); } catch (Exception ex) { MessageBox.Show("Error: " + ex.ToString()); } }
public List<SchoolYear> GetLastFiveSY() { SchoolYearService sy = new SchoolYearService(); return sy.GetAllSY(); }
public List<SchoolYear> GetAllSchoolYears() { SchoolYearService s = new SchoolYearService(); return s.GetAllSY(); }
public List <SchoolYear> GetLastFiveSY() { SchoolYearService sy = new SchoolYearService(); return(sy.GetAllSY()); }
public SchoolYear GetCurrentSY() { SchoolYearService sy = new SchoolYearService(); return(sy.GetCurrentSY()); }
public string GetCurrentSY() { SchoolYearService ss = new SchoolYearService(); return ss.GetCurrentSY().SY; }
public SchoolYear GetCurrentSY() { SchoolYearService sy = new SchoolYearService(); return sy.GetCurrentSY(); }