public ActionResult SectionIndex()
        {
            @ViewBag.Main = "List";
            @ViewBag.Sub  = "Sections";
            BasicContants.StoredProcedure = "GetSections";
            IEnumerable <SectionsModel> model = _sectionRep.Get();

            return(View(model));
        }
Ejemplo n.º 2
0
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            var section = _sectionsRepository.Get((int)id);

            if (section == null)
            {
                return(HttpNotFound());
            }


            return(View(section));
        }
Ejemplo n.º 3
0
        public void FillData()
        {
            BasicRepository _basic = new BasicRepository();

            BasicContants.StoredProcedure = "GetGender";
            Genders    = _basic.Get();
            GenderList = Genders.ToGenderSelectListItems(GenderID);

            BasicContants.StoredProcedure = "GetStudentType";
            Students    = _basic.Get();
            StudentList = Students.ToStudentTypeSelectListItems(StudentTypeID);

            SectionsRepository _section = new SectionsRepository();

            BasicContants.StoredProcedure = "GetFullSectionName";
            Sections    = _section.Get();
            SectionList = Sections.ToSectionSelectListItems(SectionID);

            ParentRepository _parent = new ParentRepository();

            Parents    = _parent.Get();
            ParentList = Parents.ToParentSelectListItems(ParentID);

            TransportRepository _transport = new TransportRepository();

            Transports    = _transport.Get();
            TransportList = Transports.ToTransportSelectListItems(TransportID);
        }
Ejemplo n.º 4
0
 public virtual Section Get(int id)
 {
     return(_sectionsRangeRepository.Get(id));
 }