protected void btnDelete_Click(object sender, EventArgs e) { TechnicianDAO dao = new TechnicianDAO(); String id = dropDownTechID.SelectedValue; dao.deleteTechnician(id); Response.Redirect("~/Staff/AdminHome.aspx"); }
protected void btnInsert_Click(object sender, EventArgs e) { TechnicianDTO dto = (TechnicianDTO)Session["TechnicianDTO"]; ModelFacade facade = new ModelFacade(); Technician technician = facade.createTechnician(dto); TechnicianDAO dao = new TechnicianDAO(); dao.saveTechnician(technician); Session.Abandon(); Response.Redirect("~/Staff/AdminHome.aspx"); }
protected void btnSubmit_Click(object sender, EventArgs e) { Technician tech = new Technician(); tech.technicianID = lblIDNew.Text; tech.technicianName = txtNewName.Text; tech.technicianType = dropDownNewType.SelectedValue.ToString(); TechnicianDAO dao = new TechnicianDAO(); dao.updateTechnician(tech); Session.Abandon(); Response.Redirect("~/Staff/AdminHome.aspx"); }
public TechnicianRN() { dao = new TechnicianDAO(); }