Exemplo n.º 1
0
        public ActionResult Edit(ContactRec p)
        {
            ContactBAL CB = new ContactBAL();

            CB.Update(p);

            return(RedirectToAction("Index"));
        }
Exemplo n.º 2
0
        public ActionResult Create(ContactRec p)
        {
            ContactBAL CB = new ContactBAL();

            CB.Add(p);

            return(RedirectToAction("Index"));
        }
Exemplo n.º 3
0
        public ActionResult Edit(ContactRec c)
        {
            DBManager db = new DBManager();

            db.Update(c);

            return(RedirectToAction("Index"));
        }
Exemplo n.º 4
0
        public ActionResult Create(ContactRec c)
        {
            DBManager db = new DBManager();

            db.Add(c);

            return(RedirectToAction("Index"));
        }
Exemplo n.º 5
0
        //Update

        public void Update(ContactRec c)
        {
            var tempRec = ContactDAL.contactList.Where(x => x.ID == c.ID).Single();

            tempRec.ID          = c.ID;
            tempRec.firstName   = c.firstName;
            tempRec.lastName    = c.lastName;
            tempRec.phoneNum    = c.phoneNum;
            tempRec.homeNum     = c.homeNum;
            tempRec.businessNum = c.businessNum;
            tempRec.address     = c.address;
            tempRec.notes       = c.notes;

            tempRec.active = c.active;
        }
Exemplo n.º 6
0
        //Add

        public void Add(ContactRec c)
        {
            c.ID = ContactDAL.LastId++;

            ContactDAL.contactList.Add(c);
        }
Exemplo n.º 7
0
 public void Update(ContactRec rc)
 {
     ContactDAL.recordList.Where(x => x.id == rc.id).Single().setContactRec(rc);
 }
Exemplo n.º 8
0
        public void Add(ContactRec cr)
        {
            cr.id = ContactDAL.LastId++;

            ContactDAL.recordList.Add(cr);
        }
Exemplo n.º 9
0
 public void Update(ContactRec c)
 {
     bll.Update(c);
 }
Exemplo n.º 10
0
 /// <summary>
 /// Adds a new password record.
 /// </summary>
 /// <param name="p">The password object.</param>
 public void Add(ContactRec c)
 {
     bll.Add(c);
 }