Ejemplo n.º 1
0
        protected void RadGridThamGiaCTXH_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(RadGridThamGiaCTXH, e, "LabelSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item   = e.Item as GridDataItem;
                HyperLink    hplTen = item["TGCTXHTCTen"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplTen.Enabled = false;
                }

                string tooltip = "- Tổ chức chính trị - xã hội: ";
                tooltip += (hplTen.Text);
                tooltip += ("\n- Vị trí phụ trách: " + item["TGCTXHChucVu"].Text);
                tooltip += ("\n- Từ ngày: " + item["TGCTXHTuNgay"].Text);
                if (!item["TGCTXHDenNgay"].Text.Equals(" "))
                {
                    tooltip += ("\n- Đến ngày: " + item["TGCTXHDenNgay"].Text);
                }
                if (!item["TGCTXHNoiDung"].Text.Equals(" "))
                {
                    tooltip += ("\n- Nội dung: " + item["TGCTXHNoiDung"].Text);
                }

                hplTen.ToolTip = tooltip;
            }
        }
Ejemplo n.º 2
0
        protected void RadGridQuaTrinhDaoTao_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(RadGridQuaTrinhDaoTao, e, "LabelSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item      = e.Item as GridDataItem;
                HyperLink    hplTruong = item["QTDTTruong"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplTruong.Enabled = false;
                }

                string tooltip = "- Trường hoặc cơ sở đào tạo, bồi dưỡng: ";
                tooltip += (hplTruong.Text);
                tooltip += ("\n- Chuyên ngành đào tạo, bồi dưỡng: " + item["QTDTChuyenNganh"].Text);
                tooltip += ("\n- Từ ngày: " + item["QTDTTuNgay"].Text);
                if (!item["QTDTDenNgay"].Text.Equals(" "))
                {
                    tooltip += ("\n- Đến ngày: " + item["QTDTDenNgay"].Text);
                }
                tooltip += ("\n- Hình thức đào tạo, bồi dưỡng: " + item["QTDTHinhThuc"].Text);
                tooltip += ("\n- Văn bằng, chứng chỉ: " + item["QTDTVanBang"].Text);

                hplTruong.ToolTip = tooltip;
            }
        }
Ejemplo n.º 3
0
 protected void btUpdate_Click(object sender, EventArgs e)
 {
     if (this.Page.IsValid)
     {
         try
         {
             int    nhanvienID       = Convert.ToInt32(ddtNhanVien.SelectedValue);
             string email            = txtEmail.Text;
             string password         = txtPassword.Text;
             int    chucnang         = Convert.ToInt32(rblChucNang.SelectedValue);
             bool   trangthai        = Convert.ToBoolean(rblTrangThai.SelectedValue);
             bool   upThongTinCaNhan = cbThongTinCaNhan.Checked;
             bool   upLyLich         = cbLyLich.Checked;
             bool   inLyLich         = cbInLyLich.Checked;
             bool   inKeKhai         = cbInKeKhai.Checked;
             bool   upKeKhai         = cbUpKeKhai.Checked;
             bool   inDanhGia        = cbInDanhGia.Checked;
             bool   upDanhGia        = cbUpDanhGia.Checked;
             _accEntity.Update(nhanvienID, _accountID, chucnang, trangthai, upThongTinCaNhan, upLyLich, inLyLich, inKeKhai, upKeKhai, inDanhGia, upDanhGia);
             this.RedirectToIndex();
         }
         catch
         {
             Helper.PageHelper pageHelper = new Helper.PageHelper();
             pageHelper.AlertMessage(this.Page, "Chọn nhân viên thích hợp");
         }
     }
 }
Ejemplo n.º 4
0
 protected void ButtonDelete_Click(object sender, EventArgs e)
 {
     Models.NhanVien nhanvien = _nhanvienEntity.Find_NhanVien(_nhanvienID);
     if (nhanvien.Accounts.Where(x => x.ACCChucNang == 0).Count() > 0)
     {
         Helper.PageHelper pageHelper = new Helper.PageHelper();
         pageHelper.AlertMessage(this.Page, "Nhân viên " + nhanvien.NVTen + " phụ trách chức năng quản trị nên không thể xóa!");
     }
     else
     {
         _nhanvienEntity.Delete(_nhanvienID);
         Response.Redirect("~/NhanSu");
     }
 }
Ejemplo n.º 5
0
        protected void rgDGDV_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgDGDV, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item   = e.Item as GridDataItem;
                HyperLink    hplNam = item["DGDVNam"].Controls[0] as HyperLink;
                if (!_quanly && !_loginACC.ACCUpDanhGia)
                {
                    hplNam.Enabled = false;
                }
            }
        }
Ejemplo n.º 6
0
        protected void btUpdate_Click(object sender, EventArgs e)
        {
            string password = txtPassword.Text;

            Helper.PageHelper pageHelper = new Helper.PageHelper();
            if (password.Equals(""))
            {
                pageHelper.AlertMessage(this.Page, "Nhập mật khẩu !...");
            }
            else
            {
                _accEntity.UpdateOwnAccount(_email, password);
                pageHelper.AlertMessage(this.Page, "Đã cập nhật thành công");
            }
        }
Ejemplo n.º 7
0
        protected void rgDanhGia_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgDanhGia, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item       = e.Item as GridDataItem;
                HyperLink    hplNoiDung = item["DGNoiDung"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplNoiDung.Enabled = false;
                }

                string tooltip = "- Nội dung đánh giá: " + hplNoiDung.Text;
                tooltip += ("\n- Ngày tháng đánh giá: " + item["DGNgay"].Text);

                hplNoiDung.ToolTip = tooltip;
            }
        }
Ejemplo n.º 8
0
        protected void rgChinhSach_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgChinhSach, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item   = e.Item as GridDataItem;
                HyperLink    hplTen = item["CSTen"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplTen.Enabled = false;
                }

                string tooltip = "- Diện chính sách: " + hplTen.Text;
                tooltip += ("\n- Ngày xét: " + item["CSNgay"].Text);

                hplTen.ToolTip = tooltip;
            }
        }
Ejemplo n.º 9
0
        protected void rgTrinhDoTinHoc_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgTrinhDoTinHoc, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item = e.Item as GridDataItem;

                HyperLink hplTen = item["TDTHTen"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplTen.Enabled = false;
                }

                string tooltip = ("- Trình độ tin học: " + hplTen.Text);
                tooltip += ("\n- Bằng cấp: " + item["TDTHChungChi"].Text);

                hplTen.ToolTip = tooltip;
            }
        }
Ejemplo n.º 10
0
        protected void rgDanhHieu_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgDanhHieu, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item = e.Item as GridDataItem;

                HyperLink hplTen = item["PTDHTen"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplTen.Enabled = false;
                }

                string tooltip = "- Danh hiệu: " + hplTen.Text;
                tooltip += ("\n- Hội đồng xét phong tặng: " + item["PTDHHoiDong"].Text);
                tooltip += ("\n- Ngày xét phong tặng: " + item["PTDHNgay"].Text);

                hplTen.ToolTip = tooltip;
            }
        }
Ejemplo n.º 11
0
        protected void rgKhenThuong_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgKhenThuong, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item = e.Item as GridDataItem;

                HyperLink hplNoiDung = item["KTNoiDung"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplNoiDung.Enabled = false;
                }

                string tooltip = "- Nội dung khen thưởng: " + hplNoiDung.Text;
                tooltip += ("\n- Cấp quyết định: " + item["KTCapQuyetDinh"].Text);
                tooltip += ("\n- Ngày ký quyết định: " + item["KTNgay"].Text);

                hplNoiDung.ToolTip = tooltip;
            }
        }
Ejemplo n.º 12
0
        protected void rgLamViec_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(rgLamViec, e, "lblSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item     = e.Item as GridDataItem;
                HyperLink    hplDVTen = item["DVTen"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplDVTen.Enabled = false;
                }

                string tooltip = "- Đơn vị công tác: ";
                tooltip += (hplDVTen.Text);
                tooltip += ("\n- Chức vụ: " + item["CVTen"].Text);
                tooltip += ("\n- Từ ngày: " + item["LVTuNgay"].Text);
                tooltip += ("\n- Đến ngày: " + item["LVDenNgay"].Text);
                tooltip += ("\n- Nhóm ngạch: " + item["NGTen"].Text);
                tooltip += ("\n- Bậc lương: " + item["BLTen"].Text);
                tooltip += ("\n- Hệ số lương: " + item["LVHeSoLuong"].Text);
                tooltip += ("\n- Lương cơ bản: " + item["LVLuongCoBan"].Text);
                tooltip += ("\n- Nhiệm vụ được phân công: " + item["LVNhiemVu"].Text);
                tooltip += ("\n- Phụ cấp chức vụ: " + item["LVPhuCapChucVu"].Text);
                tooltip += ("\n- Phụ cấp công vụ: " + item["LVPhuCapCongVu"].Text);
                tooltip += ("\n- Phụ cấp kiêm nhiệm: " + item["LVPhuCapKiemNhiem"].Text);
                tooltip += ("\n- Phụ cấp nghề: " + item["LVPhuCapNghe"].Text);
                tooltip += ("\n- Phụ cấp thâm niên nghề: " + item["LVPhuCapThamNienNghe"].Text);
                tooltip += ("\n- Phụ cấp vượt khung: " + item["LVPhuCapVuotKhung"].Text);
                tooltip += ("\n- Phụ cấp độc hại: " + item["LVPhuCapDocHai"].Text);
                tooltip += ("\n- Tỷ lệ hưởng lương: " + item["LVTyLe"].Text + "%");

                hplDVTen.ToolTip = tooltip;
            }
        }
Ejemplo n.º 13
0
        protected void RadGridQuanHe_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
        {
            Helper.PageHelper pageHelper = new Helper.PageHelper();
            pageHelper.SetSequenceNumberColumn(RadGridQuanHe, e, "LabelSTT");

            if (e.Item is GridDataItem)
            {
                GridDataItem item   = e.Item as GridDataItem;
                HyperLink    hplTen = item["QHTen"].Controls[0] as HyperLink;

                if (!_quanly && !_loginACC.ACCUpLyLich)
                {
                    hplTen.Enabled = false;
                }

                CheckBox chbBenVo = item["chbQHBenVo"].Controls[0] as CheckBox;

                string tooltip = ("- Quan hệ gia đình: ");
                if (!chbBenVo.Checked)
                {
                    tooltip += ("Họ hàng ruột");
                }
                else
                {
                    tooltip += ("Họ hàng bên vợ/chồng");
                }
                tooltip += ("\n- Họ và tên: " + hplTen.Text);
                tooltip += ("\n- Giới tính: " + item["QHGioiTinh"].Text);
                tooltip += ("\n- Mối quan hệ: " + item["LQHTen"].Text);
                tooltip += ("\n- Ngày tháng năm sinh: " + item["QHNgaySinh"].Text);
                tooltip += ("\n- Hộ khẩu: " + item["QHHoKhau"].Text);
                tooltip += ("\n- Nơi ở: " + item["QHNoiO"].Text);

                hplTen.ToolTip = tooltip;
            }
        }
Ejemplo n.º 14
0
 protected void rgGiaiTrinh_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
 {
     Helper.PageHelper pageHelper = new Helper.PageHelper();
     pageHelper.SetSequenceNumberColumn(rgGiaiTrinh, e, "lblSTT");
 }
Ejemplo n.º 15
0
 protected void RadGridChucVu_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e)
 {
     Helper.PageHelper pageHelper = new Helper.PageHelper();
     pageHelper.SetSequenceNumberColumn(RadGridChucVu, e, "LabelSTT");
 }