private void SetThongTin(DM_KHU_VUC obj)
 {
     try
     {
         idKhuVuc             = obj.ID;
         tthaiNVu             = obj.TTHAI_NVU;
         lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(tthaiNVu);
         txtMaKhuVuc.Text     = obj.MA_KVUC;
         txtNguoiDuyet.Text   = obj.NGUOI_CNHAT;
         if (!obj.NGAY_CNHAT.IsNullOrEmptyOrSpace())
         {
             txtNgayDuyet.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, ApplicationConstant.defaultDateTimeFormat);
         }
         txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
         action = DatabaseConstant.Action.XEM;
         CommonFunction.RefreshButton(Toolbar, action, tthaiNVu, mnuMain, DatabaseConstant.Function.DC_DM_KHU_VUC);
         SetEnabledAllControls(false);
     }
     catch (System.Exception ex)
     {
         LMessage.ShowMessage("M.DungChung.LoiChung", LMessage.MessageBoxType.Error);
         LLogging.WriteLog(ex.TargetSite.Name, LLogging.LogType.ERR, ex);
     }
     finally
     {
     }
 }
        public void AfterAddNew(bool ret, NS_DM_DVI_TGIAN obj, List <ClientResponseDetail> listClientResponseDetail)
        {
            try
            {
                if (ret)
                {
                    LMessage.ShowMessage("M.DungChung.ThemThanhCong", LMessage.MessageBoxType.Information);

                    if (chkThemNhieuLan.IsChecked == true)
                    {
                        BeforeAddNew();
                    }
                    else
                    {
                        id                      = obj.ID;
                        trangThaiNVu            = obj.TTHAI_NVU;
                        lblTrangThai.Content    = BusinessConstant.layNgonNguNghiepVu(trangThaiNVu);
                        txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);

                        BeforeViewFromDetail();
                    }
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
        }
Example #3
0
        public void AfterAddNew(bool ret, List <DC_HAN_MUC> lstObjHM, List <ClientResponseDetail> listClientResponseDetail)
        {
            try
            {
                if (ret == true)
                {
                    LMessage.ShowMessage("M.DungChung.ThemThanhCong", LMessage.MessageBoxType.Information);
                    SetEnabledAllControls(false);

                    tthaiNvu = lstObjHM.FirstOrDefault().TTHAI_NVU;
                    CommonFunction.RefreshButton(Toolbar, DatabaseConstant.Action.XEM, tthaiNvu, mnuMain, _function);

                    lblTrangThai.Content = BusinessConstant.layNgonNguSuDung(lstObjHM.FirstOrDefault().TTHAI_BGHI);
                    txtTrangThai.Text    = BusinessConstant.layNgonNguSuDung(lstObjHM.FirstOrDefault().TTHAI_BGHI);
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
        }
        private void SetFormData()
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                NhanSuProcess processNhanSu = new NhanSuProcess();
                List <ClientResponseDetail> listClientResponseDetail = new List <ClientResponseDetail>();
                bool ret = false;

                obj    = new NS_DM_PHUONG_XA();
                obj.ID = id;

                ret = processNhanSu.PhuongXa(DatabaseConstant.Action.LOAD_DATA, ref obj, ref listClientResponseDetail);
                if (ret == true)
                {
                    id = obj.ID;

                    #region Thông tin chung
                    lblTrangThai.Content       = BusinessConstant.layNgonNguNghiepVu(obj.TTHAI_NVU);
                    cmbQuocGia.SelectedIndex   = lstSourceQuocGia.IndexOf(lstSourceQuocGia.FirstOrDefault(i => i.KeywordStrings[1].Equals(obj.FN003)));
                    cmbTinhTP.SelectedIndex    = lstSourceTinhTP.IndexOf(lstSourceTinhTP.FirstOrDefault(i => i.KeywordStrings[1].Equals(obj.FN002)));
                    cmbQuanHuyen.SelectedIndex = lstSourceQuanHuyen.IndexOf(lstSourceQuanHuyen.FirstOrDefault(i => i.KeywordStrings[1].Equals(obj.FN001)));
                    txtMa.Text   = obj.MA;
                    txtTen.Text  = obj.TEN;
                    txtMoTa.Text = obj.MO_TA;

                    #endregion

                    #region Thông tin kiểm soát
                    txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayLap.Value      = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                    txtNguoiLap.Text        = obj.NGUOI_NHAP;
                    if (LDateTime.IsDate(obj.NGAY_CNHAT, "yyyyMMdd") == true)
                    {
                        raddtNgayCapNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                    }
                    else
                    {
                        raddtNgayCapNhat.Value = null;
                    }
                    txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                    #endregion
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }
        private void SetFormData()
        {
            Mouse.OverrideCursor = Cursors.Wait;
            //lstTSDB = new List<TDTD_TAI_SAN_DAM_BAO>();
            try
            {
                DataTable dt = null;
                LDatatable.MakeParameterTable(ref dt);
                LDatatable.AddParameter(ref dt, "@INP_IDHDTC", "string", idHDTC.ToString());
                DataSet ds = new TaiSanDamBaoProcess().GetHopDongTheChapTDTD(dt);
                if (!ds.IsNullOrEmpty() && ds.Tables.Count > 1)
                {
                    dt = ds.Tables[0];

                    idHDTC               = Convert.ToInt32(dt.Rows[0]["ID"]);
                    txtSoHopDong.Text    = dt.Rows[0]["MA_HDTC"].ToString();
                    txtMaKH.Text         = dt.Rows[0]["MA_KHANG"].ToString();
                    lblTTinKHang.Content = dt.Rows[0]["TEN_KHANG"].ToString();
                    teldtNgayCNhat.Value = LDateTime.StringToDate(dt.Rows[0]["NGAY_HDTC"].ToString(), ApplicationConstant.defaultDateTimeFormat);
                    txtDienGiai.Text     = dt.Rows[0]["DIEN_GIAI"].ToString();
                    tThai_NVu            = dt.Rows[0]["TTHAI_NVU"].ToString();
                    lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(tThai_NVu);
                    maDviQLy             = dt.Rows[0]["MA_DVI_QLY"].ToString();
                    maDViTao             = dt.Rows[0]["MA_DVI_TAO"].ToString();
                    txtNguoiLap.Text     = dt.Rows[0]["NGUOI_NHAP"].ToString();
                    if (dt.Rows[0]["NGUOI_CNHAT"] != DBNull.Value)
                    {
                        txtNguoiCapNhat.Text = dt.Rows[0]["NGUOI_CNHAT"].ToString();
                    }
                    teldtNgayNhap.Value = LDateTime.StringToDate(dt.Rows[0]["NGAY_NHAP"].ToString(), ApplicationConstant.defaultDateTimeFormat);
                    if (dt.Rows[0]["NGAY_CNHAT"] != DBNull.Value)
                    {
                        teldtNgayCNhat.Value = LDateTime.StringToDate(dt.Rows[0]["NGAY_CNHAT"].ToString(), ApplicationConstant.defaultDateTimeFormat);
                    }
                    txtTrangThai.Text = BusinessConstant.layNgonNguSuDung(dt.Rows[0]["TTHAI_BGHI"].ToString());
                    dt = ds.Tables[1];

                    lstTSDB = dt.Rows.OfType <DataRow>().ToList();

                    raddgrDSachTSDB.ItemsSource = null;
                    raddgrDSachTSDB.ItemsSource = lstTSDB;

                    SetGtriTong(lstTSDB);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }
        private void SetFormData()
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                NhanSuProcess processNhanSu = new NhanSuProcess();
                List <ClientResponseDetail> listClientResponseDetail = new List <ClientResponseDetail>();
                bool ret = false;

                obj    = new NS_DM_DVI_TGIAN();
                obj.ID = id;

                ret = processNhanSu.DonViThoiGian(DatabaseConstant.Action.LOAD_DATA, ref obj, ref listClientResponseDetail);
                if (ret == true)
                {
                    id = obj.ID;

                    #region Thông tin chung
                    lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(obj.TTHAI_NVU);
                    txtMa.Text           = obj.MA;
                    txtTen.Text          = obj.TEN;
                    txtMoTa.Text         = obj.MO_TA;
                    #endregion

                    #region Thông tin kiểm soát
                    txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayLap.Value      = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                    txtNguoiLap.Text        = obj.NGUOI_NHAP;
                    if (LDateTime.IsDate(obj.NGAY_CNHAT, "yyyyMMdd") == true)
                    {
                        raddtNgayCapNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                    }
                    else
                    {
                        raddtNgayCapNhat.Value = null;
                    }
                    txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                    #endregion
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }
Example #7
0
        private void SetFormData()
        {
            DanhMucProcess processDanhMuc = new DanhMucProcess();

            List <ClientResponseDetail> listClientResponseDetail = new List <ClientResponseDetail>();

            obj = new DM_KHU_VUC();
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                bool ret = false;
                obj.ID = id;
                ret    = processDanhMuc.KhuVuc02(DatabaseConstant.Action.LOAD, ref obj, ref listClientResponseDetail);
                if (ret == true)
                {
                    sTrangThaiNVu        = obj.TTHAI_NVU;
                    lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(sTrangThaiNVu);

                    #region Thông tin chung
                    cmbChiNhanh.SelectedIndex      = lstSourceChiNhanh.IndexOf(lstSourceChiNhanh.FirstOrDefault(e => e.KeywordStrings.First().Equals(obj.MA_DVI_QLY)));
                    cmbPhongGiaoDich.SelectedIndex = lstSourcePhongGiaoDich.IndexOf(lstSourcePhongGiaoDich.FirstOrDefault(e => e.KeywordStrings.First().Equals(obj.MA_DVI)));
                    txtMaKhuVuc.Text      = obj.MA_KVUC;
                    txtTenKhuVuc.Text     = obj.TEN_KVUC;
                    txtTenTat.Text        = obj.TEN_TAT;
                    cmbCBQL.SelectedIndex = lstSourceCBQL.IndexOf(lstSourceCBQL.FirstOrDefault(e => e.KeywordStrings.First().Equals(obj.MA_CBO_QLY)));
                    #endregion

                    #region Thông tin kiểm soát
                    txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayLap.Value      = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                    txtNguoiLap.Text        = obj.NGUOI_NHAP;
                    if (LDateTime.IsDate(obj.NGAY_CNHAT, "yyyyMMdd") == true)
                    {
                        raddtNgayCapNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                    }
                    txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                    #endregion
                }
                else
                {
                    LMessage.ShowMessage("M_ResponseMessage_HanhDong_LayDuLieuKhongThanhCong", LMessage.MessageBoxType.Warning);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                LMessage.ShowMessage("M_ResponseMessage_HanhDong_LayDuLieuKhongThanhCong", LMessage.MessageBoxType.Warning);
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }
Example #8
0
        void LoadTabKiemSoat(DataSet ds)
        {
            DataTable dt = ds.Tables["TTIN_CTIET"];

            if (dt != null && dt.Rows.Count > 0)
            {
                txtNguoiLap.Text     = dt.Rows[0]["NGUOI_NHAP"].ToString();
                txtNguoiCapNhat.Text = dt.Rows[0]["NGUOI_CNHAT"].ToString();
                teldtNgayNhap.Value  = LDateTime.StringToDate(dt.Rows[0]["NGAY_NHAP"].ToString(), ApplicationConstant.defaultDateTimeFormat);
                if (!dt.Rows[0]["NGAY_CNHAT"].ToString().IsNullOrEmptyOrSpace())
                {
                    teldtNgayCNhat.Value = LDateTime.StringToDate(dt.Rows[0]["NGAY_CNHAT"].ToString(), ApplicationConstant.defaultDateTimeFormat);
                }
                txtTrangThai.Text = BusinessConstant.layNgonNguSuDung(dt.Rows[0]["TTHAI_BGHI"].ToString());
            }
        }
Example #9
0
        public void AfterModify(bool ret, BC_MATK obj, List <ClientResponseDetail> listClientResponseDetail)
        {
            try
            {
                if (ret)
                {
                    LMessage.ShowMessage("M.DungChung.CapNhatThanhCong", LMessage.MessageBoxType.Information);

                    trangThaiNVu            = obj.TTHAI_NVU;
                    TTHAI_NVU               = obj.TTHAI_NVU;
                    TTHAI_BGHI              = obj.TTHAI_BGHI;
                    MA_DVI_QLY              = obj.MA_DVI_QLY;
                    MA_DVI_TAO              = obj.MA_DVI_TAO;
                    NGAY_NHAP               = obj.NGAY_NHAP;
                    NGUOI_NHAP              = obj.NGUOI_NHAP;
                    LOAI_BCTK               = obj.LOAI_BCTK;
                    MA_TK                   = obj.MATK;
                    ID                      = obj.ID;
                    lblTrangThai.Content    = BusinessConstant.layNgonNguNghiepVu(trangThaiNVu);
                    txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayCapNhat.Value  = LDateTime.StringToDate(ClientInformation.NgayLamViecHienTai, "yyyyMMdd");
                    txtNguoiCapNhat.Text    = ClientInformation.TenDangNhap;

                    BeforeViewFromDetail();
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }

                // Yêu cầu Unlock bản ghi cần sửa
                UtilitiesProcess process    = new UtilitiesProcess();
                List <int>       listLockId = new List <int>();
                listLockId.Add(id);

                bool retUnlockData = process.UnlockData(DatabaseConstant.Module.DMDC,
                                                        DatabaseConstant.Function.KTDL_MAPPING_MATK_CT,
                                                        DatabaseConstant.Table.BC_MATK,
                                                        DatabaseConstant.Action.SUA,
                                                        listLockId);
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
        }
 private void LoadDuLieu()
 {
     lblTrangThai.Content       = BusinessConstant.layNgonNguNghiepVu(objHeThong.HTTKTHCT.TTHAI_NVU);
     txtTrangThai.Text          = BusinessConstant.layNgonNguSuDung(objHeThong.HTTKTHCT.TTHAI_BGHI);
     txtMaHeThongTaiKhoan.Text  = objHeThong.HTTKTHCT.MA_HT_TKTH;
     txtTenHeThongTaiKhoan.Text = objHeThong.HTTKTHCT.TEN_HT_TKTH;
     dtNgayHieuLuc.Value        = LDateTime.StringToDate(objHeThong.HTTKTHCT.NGAY_ADUNG, ApplicationConstant.defaultDateTimeFormat);
     if (!objHeThong.HTTKTHCT.NGAY_HET_HLUC.IsNullOrEmptyOrSpace())
     {
         dtNgayHetHieuLuc.Value = LDateTime.StringToDate(objHeThong.HTTKTHCT.NGAY_HET_HLUC, ApplicationConstant.defaultDateTimeFormat);
     }
     txtNguoiLap.Text     = objHeThong.HTTKTHCT.NGUOI_NHAP;
     txtNguoiCapNhat.Text = objHeThong.HTTKTHCT.NGUOI_CNHAT;
     raddtNgayNhap.Value  = LDateTime.StringToDate(objHeThong.HTTKTHCT.NGAY_NHAP, ApplicationConstant.defaultDateTimeFormat);
     if (!objHeThong.HTTKTHCT.NGAY_CNHAT.IsNullOrEmptyOrSpace())
     {
         raddtNgayCNhat.Value = LDateTime.StringToDate(objHeThong.HTTKTHCT.NGAY_CNHAT, ApplicationConstant.defaultDateTimeFormat);
     }
 }
Example #11
0
        public void AfterModify(bool ret, List <DC_HAN_MUC> lstObjHM, List <ClientResponseDetail> listClientResponseDetail)
        {
            if (ret == true)
            {
                LMessage.ShowMessage("M.DungChung.SuaThanhCong", LMessage.MessageBoxType.Information);
                SetEnabledAllControls(false);

                tthaiNvu = lstObjHM.FirstOrDefault().TTHAI_NVU;
                CommonFunction.RefreshButton(Toolbar, DatabaseConstant.Action.XEM, tthaiNvu, mnuMain, _function);

                lblTrangThai.Content = BusinessConstant.layNgonNguSuDung(lstObjHM.FirstOrDefault().TTHAI_BGHI);
                txtTrangThai.Text    = BusinessConstant.layNgonNguSuDung(lstObjHM.FirstOrDefault().TTHAI_BGHI);
                teldtNgayCNhat.Value = LDateTime.StringToDate(ClientInformation.NgayLamViecHienTai, "yyyyMMdd");
                txtNguoiCapNhat.Text = ClientInformation.TenDangNhap;
            }
            else
            {
                CommonFunction.ThongBaoKetQua(listClientResponseDetail);
            }
        }
 public void SetDataForm(int id)
 {
     try
     {
         idKhuVuc = id;
         DM_KHU_VUC obj = new DanhMucProcess().getKhuVucById(idKhuVuc);
         if (!LObject.IsNullOrEmpty(obj))
         {
             tthaiNVu               = obj.TTHAI_NVU;
             txtMaKhuVuc.Text       = obj.MA_KVUC;
             txtTenKhuVuc.Text      = obj.TEN_KVUC;
             txtTenTat.Text         = obj.TEN_TAT;
             lblTrangThai.Content   = BusinessConstant.layNgonNguNghiepVu(tthaiNVu);
             cmbDonVi.SelectedIndex = lstSourcePGD.IndexOf(lstSourcePGD.FirstOrDefault(e => e.KeywordStrings.First().Equals(obj.MA_DVI)));
             txtNguoiLap.Text       = obj.NGUOI_NHAP;
             txtNgayLap.Value       = LDateTime.StringToDate(obj.NGAY_NHAP, ApplicationConstant.defaultDateTimeFormat);
             txtNguoiDuyet.Text     = obj.NGUOI_CNHAT;
             if (!obj.NGAY_CNHAT.IsNullOrEmptyOrSpace())
             {
                 txtNgayDuyet.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, ApplicationConstant.defaultDateTimeFormat);
             }
             txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
             if (action.Equals(DatabaseConstant.Action.SUA))
             {
                 SetEnabledAllControls(true);
             }
             else
             {
                 SetEnabledAllControls(false);
             }
             CommonFunction.RefreshButton(Toolbar, action, tthaiNVu, mnuMain, DatabaseConstant.Function.DC_DM_KHU_VUC);
         }
     }
     catch (System.Exception ex)
     {
         LMessage.ShowMessage("M.DungChung.LoiChung", LMessage.MessageBoxType.Error);
         LLogging.WriteLog(ex.TargetSite.Name, LLogging.LogType.ERR, ex);
     }
 }
        /// <summary>
        /// Sau khi sửa
        /// </summary>
        /// <param name="ret"></param>
        private void afterModify(ApplicationConstant.ResponseStatus ret, HT_NHNSD obj, string responseMessage)
        {
            if (ret == ApplicationConstant.ResponseStatus.THANH_CONG)
            {
                LMessage.ShowMessage("M.DungChung.CapNhatThanhCong", LMessage.MessageBoxType.Information);

                id       = obj.ID;
                TthaiNvu = obj.TTHAI_NVU;

                lblTrangThai.Content = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                txtTrangThai.Text    = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                raddtNgayNhap.Value  = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                txtNguoiLap.Text     = obj.NGUOI_NHAP;
                raddtNgayCNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                CommonFunction.RefreshButton(Toolbar, DatabaseConstant.Action.XEM, tthaiNvu, mnuMain, DatabaseConstant.Function.HT_NHNSD);

                formCase = "XEM";
                HideControl();
            }
            else
            {
                LMessage.ShowMessage(responseMessage, LMessage.MessageBoxType.Error);
            }

            // Yêu cầu Unlock bản ghi cần sửa
            UtilitiesProcess process    = new UtilitiesProcess();
            List <int>       listLockId = new List <int>();

            listLockId.Add(id);

            bool retUnlockData = process.UnlockData(DatabaseConstant.Module.QTHT,
                                                    DatabaseConstant.Function.HT_NHNSD,
                                                    DatabaseConstant.Table.HT_NHNSD,
                                                    DatabaseConstant.Action.SUA,
                                                    listLockId);
        }
        /// <summary>
        /// Sau khi thêm mới
        /// </summary>
        /// <param name="ret"></param>
        private void afterAddNew(ApplicationConstant.ResponseStatus ret, HT_NHNSD obj, string responseMessage)
        {
            if (ret == ApplicationConstant.ResponseStatus.THANH_CONG)
            {
                LMessage.ShowMessage("M.DungChung.ThemThanhCong", LMessage.MessageBoxType.Information);

                if (cbMultiAdd.IsChecked == true)
                {
                    ResetForm();
                }
                else if (!DatabaseConstant.CLOSE_DETAIL_FORM)
                {
                    id       = obj.ID;
                    TthaiNvu = obj.TTHAI_NVU;

                    lblLabelTrangThai.Content = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    txtTrangThai.Text         = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayNhap.Value       = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                    txtNguoiLap.Text          = obj.NGUOI_NHAP;
                    raddtNgayCNhat.Value      = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                    txtNguoiCapNhat.Text      = obj.NGUOI_CNHAT;
                    CommonFunction.RefreshButton(Toolbar, DatabaseConstant.Action.XEM, tthaiNvu, mnuMain, DatabaseConstant.Function.HT_NHNSD);

                    formCase = "XEM";
                    HideControl();
                }
                else
                {
                    onClose();
                }
            }
            else
            {
                LMessage.ShowMessage(responseMessage, LMessage.MessageBoxType.Error);
            }
        }
Example #15
0
 private void UserControl_Loaded(object sender, RoutedEventArgs e)
 {
     Mouse.OverrideCursor = Cursors.Wait;
     try
     {
         if (!isLoaded)
         {
             if (luuAction == DatabaseConstant.Action.XEM)
             {
                 formCase = "XEM";
             }
             if (luuAction == DatabaseConstant.Action.SUA || luuAction == DatabaseConstant.Action.THEM)
             {
                 formCase = "MANAGE";
             }
             if (formCase == null)
             {
                 formCase = ClientInformation.FormCase;
             }
             string strTrangThai = string.Empty;
             if (obj != null)
             {
                 txtMaLoaiThamSo.Text         = obj.MA_TSO_LOAI;
                 txtMaThamSo.Text             = obj.MA_TSO;
                 txtTenThamSo.Text            = obj.TEN_TSO;
                 txtMoTaThamSo.Text           = obj.MO_TA;
                 txtGiaTriMacDinh.Text        = obj.HTHI_GTRI_MDINH;
                 cmbKieuDuLieu.SelectedIndex  = lstSourceKieuDL.IndexOf(lstSourceKieuDL.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.KIEU_DU_LIEU)));
                 cmbHienThiTren.SelectedIndex = lstSourceLoaiControl.IndexOf(lstSourceLoaiControl.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.HTHI_DIEU_KHIEN)));
                 txtCauLenhHienThi.Text       = obj.HTHI_SQL;
                 txtGiaTri.Text = obj.GIA_TRI;
                 cmbThuocPhanHe.SelectedIndex  = lstSourcePhanHe.IndexOf(lstSourcePhanHe.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.MA_PHAN_HE)));
                 cmbPhamViAHuong.SelectedIndex = lstSourcePhamVi.IndexOf(lstSourcePhamVi.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.PVI_AHUONG)));
                 strTrangThai = obj.TTHAI_NVU;
                 //cmbHanhDong.SelectedIndex = lstSource.IndexOf(lstSourceKieuDL.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.KIEU_DU_LIEU)));
             }
             else
             {
                 lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(BusinessConstant.TrangThaiNghiepVu.CHO_DUYET.layGiaTri());
                 txtTrangThai.Text    = BusinessConstant.layNgonNguSuDung(BusinessConstant.TrangThaiSuDung.SU_DUNG.layGiaTri());
                 raddtNgayNhap.Value  = DateTime.Today;
                 txtNguoiLap.Text     = ClientInformation.TenDangNhap;
                 strTrangThai         = string.Empty;
             }
             CommonFunction.RefreshButton(Toolbar, luuAction, strTrangThai, mnuMain, DatabaseConstant.Function.HT_THAM_SO);
             if (luuAction != DatabaseConstant.Action.THEM)
             {
                 cbMultiAdd.Visibility = Visibility.Collapsed;
             }
             HideControl();
             if (ClientInformation.LoaiNguoiSuDung.Equals(BusinessConstant.LoaiNguoiSuDung.CAP_SA.layGiaTri()) ||
                 ClientInformation.LoaiNguoiSuDung.Equals(BusinessConstant.LoaiNguoiSuDung.CAP_QTTW.layGiaTri()))
             {
                 formCase = "SETVALUE";
                 HideControl();
             }
         }
     }
     catch (System.Exception ex)
     {
         CommonFunction.ThongBaoLoi(ex);
         LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
     }
     Mouse.OverrideCursor = Cursors.Arrow;
 }
        private void UserControl_Loaded(object sender, RoutedEventArgs e)
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                if (!isLoaded)
                {
                    if (luuAction == DatabaseConstant.Action.XEM)
                    {
                        formCase = "XEM";
                    }
                    else if (luuAction == DatabaseConstant.Action.SUA)
                    {
                        formCase = "SUA";
                    }
                    else if (luuAction == DatabaseConstant.Action.THEM)
                    {
                        formCase = "MANAGE";
                    }

                    if (formCase == null)
                    {
                        formCase = ClientInformation.FormCase;
                    }
                    string strTrangThai = string.Empty;
                    if (obj != null)
                    {
                        id       = obj.ID;
                        tthaiNvu = obj.TTHAI_NVU;

                        // khởi tạo combobox
                        AutoComboBox auto = new AutoComboBox();
                        auto = new AutoComboBox();
                        List <string> lstDieuKien = new List <string>();

                        //auto.GenAutoComboBox(ref lstSourceDonVi, ref cmbDonVi, DatabaseConstant.DanhSachTruyVan.COMBOBOX_DONVI.getValue(), null, obj.MA_DVI_QLY);
                        lstDieuKien = new List <string>();
                        lstDieuKien.Add("'" + DatabaseConstant.ToChucDonVi.HSO.getValue() + "', '" + DatabaseConstant.ToChucDonVi.CNH.getValue() + "'");
                        auto.GenAutoComboBox(ref lstSourceDonVi, ref cmbDonVi, DatabaseConstant.DanhSachTruyVan.COMBOBOX_DONVITHEOLOAI.getValue(), lstDieuKien, obj.MA_DVI_QLY);

                        //lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(obj.TTHAI_NVU);
                        lblTrangThai.Content = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);

                        txtMaNhom.Text  = obj.MA_NHNSD;
                        txtTenNhom.Text = obj.TEN_NHNSD;
                        txtMoTa.Text    = obj.MO_TA;

                        if (obj.HAN_CHE_TRUY_CAP.Equals(BusinessConstant.CoKhong.CO.layGiaTri()))
                        {
                            chkHoatDong.IsChecked = true;
                        }
                        else
                        {
                            chkHoatDong.IsChecked = false;
                        }

                        txtTrangThai.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                        if (!string.IsNullOrEmpty(obj.NGAY_NHAP) && obj.NGAY_NHAP != "")
                        {
                            raddtNgayNhap.Value = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                        }
                        else
                        {
                            raddtNgayNhap.Value = null;
                        }
                        txtNguoiLap.Text     = obj.NGUOI_NHAP;
                        txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                        if (!string.IsNullOrEmpty(obj.NGAY_CNHAT) && obj.NGAY_CNHAT != "")
                        {
                            raddtNgayCNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                        }
                        else
                        {
                            raddtNgayCNhat.Value = null;
                        }

                        BuildGridDoiTuong();
                        loadWidthColumnDoiTuong();
                        strTrangThai = obj.TTHAI_NVU;
                    }
                    else
                    {
                        // khởi tạo combobox
                        AutoComboBox auto = new AutoComboBox();
                        auto = new AutoComboBox();
                        List <string> lstDieuKien = new List <string>();

                        //auto.GenAutoComboBox(ref lstSourceDonVi, ref cmbDonVi, DatabaseConstant.DanhSachTruyVan.COMBOBOX_DONVI.getValue(), null, ClientInformation.MaDonVi);
                        lstDieuKien = new List <string>();
                        lstDieuKien.Add("'" + DatabaseConstant.ToChucDonVi.HSO.getValue() + "', '" + DatabaseConstant.ToChucDonVi.CNH.getValue() + "'");
                        auto.GenAutoComboBox(ref lstSourceDonVi, ref cmbDonVi, DatabaseConstant.DanhSachTruyVan.COMBOBOX_DONVITHEOLOAI.getValue(), lstDieuKien, ClientInformation.MaDonVi);

                        lblTrangThai.Content = string.Empty;
                        txtTrangThai.Text    = string.Empty;
                        raddtNgayNhap.Value  = null;
                        txtNguoiLap.Text     = string.Empty;
                        raddtNgayCNhat.Value = null;
                        txtNguoiCapNhat.Text = string.Empty;
                        strTrangThai         = string.Empty;
                    }

                    CommonFunction.RefreshButton(Toolbar, luuAction, strTrangThai, mnuMain, DatabaseConstant.Function.HT_NHNSD);

                    if (luuAction != DatabaseConstant.Action.THEM)
                    {
                        cbMultiAdd.Visibility = Visibility.Collapsed;
                    }

                    ((RadTabItem)tabNSDCT.Items[0]).IsSelected = true;
                    tabNSDCT.SelectionChanged += tabNSDCT_SelectionChanged;
                    LoadGridTruyCap();
                    cmbDonVi.Focus();
                    isLoaded = true;
                }
                HideControl();
                if (ClientInformation.LoaiNguoiSuDung.Equals(BusinessConstant.LoaiNguoiSuDung.CAP_QTDV.layGiaTri()) ||
                    ClientInformation.LoaiNguoiSuDung.Equals(BusinessConstant.LoaiNguoiSuDung.CAP_NVDV.layGiaTri()))
                {
                    cmbDonVi.IsEnabled = false;
                }
                else
                {
                    cmbDonVi.IsEnabled = true;
                }
            }
            catch (System.Exception ex)
            {
                CommonFunction.ThongBaoLoi(ex);
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
            }
            Mouse.OverrideCursor = Cursors.Arrow;
        }
        private void UserControl_Loaded(object sender, RoutedEventArgs e)
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                if (!isLoaded)
                {
                    if (luuAction == DatabaseConstant.Action.XEM)
                    {
                        formCase = "XEM";
                    }
                    if (luuAction == DatabaseConstant.Action.SUA)
                    {
                        formCase = "SUA";
                    }
                    if (formCase == null)
                    {
                        formCase = ClientInformation.FormCase;
                    }
                    string strTrangThai = string.Empty;
                    if (obj != null)
                    {
                        id                = obj.ID;
                        tthaiNvu          = obj.TTHAI_NVU;
                        loaiThamSo        = obj.MA_TSO_LOAI;
                        donViQuanLyThamSo = obj.MA_DVI_QLY;

                        cmbMaLoaiThamSo.SelectedIndex = lstSourceLoaiThamSo.IndexOf(lstSourceLoaiThamSo.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.MA_TSO_LOAI)));
                        txtMaThamSo.Text             = obj.MA_TSO;
                        txtTenThamSo.Text            = obj.TEN_TSO;
                        txtMoTaThamSo.Text           = obj.MO_TA;
                        txtGiaTriMacDinh.Text        = obj.HTHI_GTRI_MDINH;
                        cmbKieuDuLieu.SelectedIndex  = lstSourceKieuDL.IndexOf(lstSourceKieuDL.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.KIEU_DU_LIEU)));
                        cmbHienThiTren.SelectedIndex = lstSourceLoaiControl.IndexOf(lstSourceLoaiControl.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.HTHI_DIEU_KHIEN)));
                        txtCauLenhHienThi.Text       = obj.HTHI_SQL;
                        txtGiaTri.Text = obj.GIA_TRI;
                        cmbThuocPhanHe.SelectedIndex  = lstSourcePhanHe.IndexOf(lstSourcePhanHe.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.MA_PHAN_HE)));
                        cmbPhamViAHuong.SelectedIndex = lstSourcePhamVi.IndexOf(lstSourcePhamVi.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.PVI_AHUONG)));
                        strTrangThai = obj.TTHAI_NVU;
                        //cmbHanhDong.SelectedIndex = lstSource.IndexOf(lstSourceKieuDL.FirstOrDefault(d => d.KeywordStrings.First().Equals(obj.KIEU_DU_LIEU)));

                        lblTrangThai.Content = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                        txtTrangThai.Text    = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                        if (!string.IsNullOrEmpty(obj.NGAY_NHAP) && obj.NGAY_NHAP != "")
                        {
                            raddtNgayNhap.Value = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                        }
                        else
                        {
                            raddtNgayNhap.Value = null;
                        }
                        txtNguoiLap.Text     = obj.NGUOI_NHAP;
                        txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                        if (!string.IsNullOrEmpty(obj.NGAY_CNHAT) && obj.NGAY_CNHAT != "")
                        {
                            raddtNgayCNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                        }
                        else
                        {
                            raddtNgayCNhat.Value = null;
                        }
                    }
                    else
                    {
                        lblTrangThai.Content = string.Empty;
                        txtTrangThai.Text    = string.Empty;
                        raddtNgayNhap.Value  = null;
                        txtNguoiLap.Text     = string.Empty;
                        raddtNgayCNhat.Value = null;
                        txtNguoiCapNhat.Text = string.Empty;
                        strTrangThai         = string.Empty;
                    }
                    CommonFunction.RefreshButton(Toolbar, luuAction, strTrangThai, mnuMain, DatabaseConstant.Function.HT_THAM_SO);
                    if (luuAction != DatabaseConstant.Action.THEM)
                    {
                        cbMultiAdd.Visibility = Visibility.Collapsed;
                    }
                    HideControl();
                }
            }
            catch (System.Exception ex)
            {
                CommonFunction.ThongBaoLoi(ex);
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
            }
            Mouse.OverrideCursor = Cursors.Arrow;
        }
Example #18
0
        private void SetFormData()
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                DanhMucProcess processDanhMuc = new DanhMucProcess();
                List <ClientResponseDetail> listClientResponseDetail = new List <ClientResponseDetail>();
                bool ret = false;

                obj    = new DM_DTUONG();
                obj.ID = id;

                ret = processDanhMuc.getDoiTuongById(id, ref obj, ref listClientResponseDetail);
                if (ret == true)
                {
                    id = obj.ID;

                    #region Thông tin chung
                    lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(obj.TTHAI_NVU);

                    cmbLoaiDoiTuong.SelectedIndex = lstSourceDoiTuongLoai.IndexOf(lstSourceDoiTuongLoai.FirstOrDefault(i => i.KeywordStrings[1].ToString().Equals(obj.ID_LOAI_DTUONG.ToString())));

                    txtMaDoiTuong.Text       = obj.MA_DTUONG;
                    cmbMaDonVi.SelectedIndex = lstSourceDonVi.IndexOf(lstSourceDonVi.FirstOrDefault(i => i.KeywordStrings[0].ToString().Equals(obj.MA_DVI.ToString())));
                    txtMaLoaiThamChieu.Text  = obj.MA_LOAI_TCHIEU;
                    txtMaThamChieu.Text      = obj.MA_TCHIEU;
                    txtMota.Text             = obj.MO_TA;
                    txtTenDoiTuong.Text      = obj.TEN_DTUONG;
                    #endregion

                    #region Thông tin kiểm soát
                    txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayLap.Value      = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                    txtNguoiLap.Text        = obj.NGUOI_NHAP;
                    if (LDateTime.IsDate(obj.NGAY_CNHAT, "yyyyMMdd") == true)
                    {
                        raddtNgayCapNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                    }
                    else
                    {
                        raddtNgayCapNhat.Value = null;
                    }
                    txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                    #endregion

                    #region Lưu thông tin chung
                    TTHAI_BGHI = obj.TTHAI_BGHI;
                    TTHAI_NVU  = obj.TTHAI_NVU;
                    MA_DVI_QLY = obj.MA_DVI_QLY;
                    MA_DVI_TAO = obj.MA_DVI_TAO;
                    NGAY_NHAP  = obj.NGAY_NHAP;
                    NGUOI_NHAP = obj.NGUOI_NHAP;
                    #endregion
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }
Example #19
0
        private void SetFormData()
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                #region Get data từ server
                HanMucProcess process = new HanMucProcess();
                List <ClientResponseDetail> listClientResponseDetail = new List <ClientResponseDetail>();
                bool ret = false;

                ret = process.HanMucChung(DatabaseConstant.Action.LOAD, ref _lstObjHM, ref listClientResponseDetail);
                #endregion

                if (ret == true)
                {
                    tthaiNvu = _lstObjHM.FirstOrDefault().TTHAI_NVU;

                    cmbLoaiDoiTuong.SelectedIndex = lstLoaiDoiTuong.IndexOf(lstLoaiDoiTuong.FirstOrDefault(e => e.KeywordStrings.First().Equals(_lstObjHM.FirstOrDefault().MA_DTUONG_LOAI)));
                    txtMaDoiTuong.Tag             = _lstObjHM.FirstOrDefault().ID_DTUONG;
                    txtMaDoiTuong.Text            = _lstObjHM.FirstOrDefault().MA_DTUONG;

                    if (_lstObjHM.Where(e => e.MA_TNANG == "ADD").FirstOrDefault().MAX != null)
                    {
                        chkHMGiaoDichToiDa.IsChecked = false;
                        numHMGiaoDich.Value          = (double?)_lstObjHM.Where(e => e.MA_TNANG == "ADD").FirstOrDefault().MAX;
                    }
                    else
                    {
                        chkHMGiaoDichToiDa.IsChecked = true;
                    }

                    if (_lstObjHM.Where(e => e.MA_TNANG == "APPROVE").FirstOrDefault().MAX != null)
                    {
                        chkHMPheDuyetToiDa.IsChecked = false;
                        numHMPheDuyet.Value          = (double?)_lstObjHM.Where(e => e.MA_TNANG == "APPROVE").FirstOrDefault().MAX;
                    }
                    else
                    {
                        chkHMPheDuyetToiDa.IsChecked = true;
                    }

                    teldtNgayHieuLuc.Value = LDateTime.StringToDate(_lstObjHM.FirstOrDefault().NGAY_ADUNG, "yyyyMMdd");
                    if (_lstObjHM.FirstOrDefault().NGAY_HHAN != null)
                    {
                        teldtNgayHetHieuLuc.Value = LDateTime.StringToDate(_lstObjHM.FirstOrDefault().NGAY_HHAN, "yyyyMMdd");
                    }
                    else
                    {
                        teldtNgayHetHieuLuc.Value = null;
                    }

                    lblTrangThai.Content = BusinessConstant.layNgonNguSuDung(_lstObjHM.FirstOrDefault().TTHAI_BGHI);
                    txtTrangThai.Text    = BusinessConstant.layNgonNguSuDung(_lstObjHM.FirstOrDefault().TTHAI_BGHI);

                    txtNguoiLap.Text    = _lstObjHM.FirstOrDefault().NGUOI_NHAP;
                    teldtNgayNhap.Value = LDateTime.StringToDate(_lstObjHM.FirstOrDefault().NGAY_NHAP, "yyyyMMdd");

                    if (_lstObjHM.FirstOrDefault().NGUOI_CNHAT != null)
                    {
                        txtNguoiCapNhat.Text = _lstObjHM.FirstOrDefault().NGUOI_CNHAT;
                    }
                    else
                    {
                        txtNguoiCapNhat.Text = "";
                    }
                    if (_lstObjHM.FirstOrDefault().NGAY_CNHAT != null)
                    {
                        teldtNgayCNhat.Value = LDateTime.StringToDate(_lstObjHM.FirstOrDefault().NGAY_CNHAT, "yyyyMMdd");
                    }
                    else
                    {
                        teldtNgayCNhat.Value = null;
                    }
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                CommonFunction.ThongBaoLoi(ex);
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }
Example #20
0
        private void SetFormData()
        {
            Mouse.OverrideCursor = Cursors.Wait;
            try
            {
                KhaiThacDuLieuProcess       processKTDL = new KhaiThacDuLieuProcess();
                List <ClientResponseDetail> listClientResponseDetail = new List <ClientResponseDetail>();
                bool ret = false;

                obj    = new BC_MATK();
                obj.ID = ID;

                ret = processKTDL.MaTK(DatabaseConstant.Action.LOAD, ref obj, ref listClientResponseDetail);
                if (ret == true)
                {
                    ID = obj.ID;

                    #region Thông tin chung
                    lblTrangThai.Content = BusinessConstant.layNgonNguNghiepVu(obj.TTHAI_NVU);

                    cmbLoaiTK.SelectedIndex = lstSourceLoaiTK.IndexOf(lstSourceLoaiTK.FirstOrDefault(i => i.KeywordStrings[0].ToString().Equals(obj.MA_LOAITK.ToString())));

                    txtMaTK.Text  = obj.MA_LOAITK;
                    txtTenTK.Text = obj.TEN_MATK;
                    #endregion

                    #region Thông tin kiểm soát
                    txtTrangThaiBanGhi.Text = BusinessConstant.layNgonNguSuDung(obj.TTHAI_BGHI);
                    raddtNgayLap.Value      = LDateTime.StringToDate(obj.NGAY_NHAP, "yyyyMMdd");
                    txtNguoiLap.Text        = obj.NGUOI_NHAP;
                    if (LDateTime.IsDate(obj.NGAY_CNHAT, "yyyyMMdd") == true)
                    {
                        raddtNgayCapNhat.Value = LDateTime.StringToDate(obj.NGAY_CNHAT, "yyyyMMdd");
                    }
                    else
                    {
                        raddtNgayCapNhat.Value = null;
                    }
                    txtNguoiCapNhat.Text = obj.NGUOI_CNHAT;
                    #endregion

                    #region Lưu thông tin chung
                    TTHAI_BGHI = obj.TTHAI_BGHI;
                    TTHAI_NVU  = obj.TTHAI_NVU;
                    MA_DVI_QLY = obj.MA_DVI_QLY;
                    MA_DVI_TAO = obj.MA_DVI_TAO;
                    NGAY_NHAP  = obj.NGAY_NHAP;
                    NGUOI_NHAP = obj.NGUOI_NHAP;
                    #endregion
                }
                else
                {
                    CommonFunction.ThongBaoKetQua(listClientResponseDetail);
                }
            }
            catch (Exception ex)
            {
                LLogging.WriteLog(System.Reflection.MethodInfo.GetCurrentMethod().ToString(), LLogging.LogType.ERR, ex);
                throw ex;
            }
            finally
            {
                Mouse.OverrideCursor = Cursors.Arrow;
            }
        }