示例#1
0
        protected void cmdOK_Click(object sender, EventArgs e)
        {
            UDS.Components.DocumentFlow df = new UDS.Components.DocumentFlow();

            try
            {
                if (DeptID == 0)
                {
                   // DeptID = df.AddDept(txtDeptName.Text, txtRemark.Text);

                    Dept dept = new Dept();
                    dept.Dept_Name = txtDeptName.Text;
                    dept.Dept_Remark = txtRemark.Text;
                    dept.Save();

                }
                else
                {
                    df.UpdateDept(DeptID, txtDeptName.Text, txtRemark.Text);
                }
            }
            finally
            {
                if (df != null)
                    df = null;
            }
            Server.Transfer("DepartmentManagement.aspx");
        }