Ejemplo n.º 1
0
        private void btnUpdate_Click(object sender, EventArgs e)
        {
            if (textGroupId.Text == "")
            {
                MessageBox.Show("Please Select The Group");
            }
            else
            {
                GroupBLL.Group_ID    = int.Parse(textGroupId.Text);
                GroupBLL.Group_Name  = textGroupName.Text;
                GroupBLL.Description = textDescription.Text;

                bool success = GroupDAL.Update(GroupBLL);
                if (success == true)
                {
                    MessageBox.Show("Cetegory Updated Succesfully ...");
                    clear();
                    DataTable dt = GroupDAL.Select();
                    dgvGroup.DataSource = dt;
                }
                else
                {
                    MessageBox.Show("Update Failed :/  ");
                }
            }
        }
Ejemplo n.º 2
0
        public static Group EditGroup(int id, string name, DateTime startDate, DateTime endDate, int tourId)
        {
            ValidateGroup(name, startDate, endDate);
            var group = new Group(name, startDate, endDate, tourId)
            {
                Id = id
            };

            GroupDAL.Update(group);
            return(group);
        }
Ejemplo n.º 3
0
 public override bool Update(OGroups group)
 {
     return(gr.Update(group));
 }
Ejemplo n.º 4
0
 ///<summary>
 ///更新
 ///</summary>
 /// <param name="model"></param>
 /// <returns></returns>
 public bool Update(GroupEntity model)
 {
     return(dal.Update(model));
 }