private void ShowInfo(int _id) { BLL.norules_classbll bll = new BLL.norules_classbll(); Model.norules_classinfo model = bll.GetModel(_id); txtNRules_Code.Text = model.NRules_Code; txtNRules_Name.Text = model.NRules_Name; }
private bool DoEdit(int _id) { bool result = true; BLL.norules_classbll bll = new BLL.norules_classbll(); Model.norules_classinfo model = bll.GetModel(_id); model.NRules_Code = txtNRules_Code.Text.Trim(); model.NRules_Name = txtNRules_Name.Text; if (!bll.Update(model)) { result = false; } return(result); }