Beispiel #1
0
 private void ShowInfo(int MID)
 {
     CHSS.BLL.CMedicalEquipment   bll   = new CHSS.BLL.CMedicalEquipment();
     CHSS.Model.CMedicalEquipment model = bll.GetModel(MID);
     this.txtMID.Text             = model.MID.ToString();
     this.txtMediDescription.Text = model.MediDescription;
     this.txtMediAddDate.Text     = model.MediAddDate;
     this.txtMediName.Text        = model.MediName;
 }
Beispiel #2
0
        protected void btnSave_Click(object sender, EventArgs e)
        {
            string MediDescription = this.txtMediDescription.Text;
            string MediAddDate     = this.txtMediAddDate.Text;
            string MediName        = this.txtMediName.Text;
            int    UID             = int.Parse(Session["UID"].ToString());

            CHSS.Model.CMedicalEquipment model = new CHSS.Model.CMedicalEquipment();
            model.MediDescription = MediDescription;
            model.MediAddDate     = MediAddDate;
            model.MediName        = MediName;
            model.UID             = UID;

            CHSS.BLL.CMedicalEquipment bll = new CHSS.BLL.CMedicalEquipment();
            bll.Add(model);
            Response.Redirect("Show.aspx?id=" + (bll.GetMaxId() - 1));
        }
Beispiel #3
0
        public void btnSave_Click(object sender, EventArgs e)
        {
            int    MID             = int.Parse(this.txtMID.Text);
            string MediDescription = this.txtMediDescription.Text;
            string MediAddDate     = this.txtMediAddDate.Text;
            string MediName        = this.txtMediName.Text;
            int    UID             = int.Parse(Session["UID"].ToString());


            CHSS.Model.CMedicalEquipment model = new CHSS.Model.CMedicalEquipment();
            model.MID             = MID;
            model.MediDescription = MediDescription;
            model.MediAddDate     = MediAddDate;
            model.MediName        = MediName;
            model.UID             = UID;

            CHSS.BLL.CMedicalEquipment bll = new CHSS.BLL.CMedicalEquipment();
            bll.Update(model);
            Response.Redirect("Show.aspx?id=" + MID);
        }