Ejemplo n.º 1
0
        public ActionResult EditNGO(int id)
        {
            NGODAO ngoDAO = new NGODAO();
            NGOAcc ngo    = ngoDAO.FetchOne(id);

            return(View("NGOForm", ngo));
        }
Ejemplo n.º 2
0
        public ActionResult NGODetails(int id)
        {
            NGODAO ngoDAO = new NGODAO();
            NGOAcc ngo    = ngoDAO.FetchOne(id);

            return(View("NGODetails", ngo));
        }
Ejemplo n.º 3
0
        public ActionResult SearchForName(string searchPhrase)
        {
            // get a list of search resultss from the database.
            NGODAO        ngoDAO        = new NGODAO();
            List <NGOAcc> searchResults = ngoDAO.SearchForName(searchPhrase);

            return(View("NGO", searchResults));
        }
Ejemplo n.º 4
0
        public ActionResult ProcessNGO(NGOAcc ngoAcc)
        {
            //save to the db.
            NGODAO ngoDAO = new NGODAO();

            ngoDAO.CreateOrUpdate(ngoAcc);

            return(View("NGODetails", ngoAcc));
        }
Ejemplo n.º 5
0
        public ActionResult DeleteNGO(int id)
        {
            NGODAO ngoDAO = new NGODAO();

            ngoDAO.Delete(id);

            List <NGOAcc> ngo = ngoDAO.FetchAll();

            return(View("NGO", ngo));
        }
Ejemplo n.º 6
0
        public ActionResult NGO()
        {
            List <NGOAcc> ngo = new List <NGOAcc>();

            //ngo.Add(new NGOAcc(111, "asda", "adas", "dasdsa", "dasdasd", "dasdasd", "dasdsa", "dqawewq", "dqawedwq", "1/1/2001", "dqwewq"));

            NGODAO ngoDAO = new NGODAO();

            ngo = ngoDAO.FetchAll();

            return(View("NGO", ngo));
        }