예제 #1
0
        protected override string uc_Update()
        {
            string str;

            if (MyRule.Get(MyLogin.RoleId, "bbiDepartment") != "OK")
            {
                str = "";
            }
            else if (MyRule.AllowEdit)
            {
                //  SYS_LOG.Insert("Danh Sách Phòng Ban", "Cập Nhật", this.txtID.Text);
                base.SetWaitDialogCaption("Đang cập nhật dữ liệu...");
                HRM_DEPARTMENT hRMDEPARTMENT = this.InitClass();
                string         str1          = hRMDEPARTMENT.Update();
                if (str1 == "OK")
                {
                    this.RaiseSuccessEventHander(hRMDEPARTMENT);
                }
                if (str1 != "OK")
                {
                    XtraMessageBox.Show(str1, "Cảnh Báo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                }
                this.DoHide();
                str = str1;
            }
            else
            {
                MyRule.Notify();
                str = "";
            }
            return(str);
        }