Exemplo n.º 1
0
 void uscTuyenDung_HoSoUngVien1_AfterUpdate(object sender, EventArgs e)
 {
     GridPanel1.Reload();
     RowSelectionModel3.ClearSelections();
     btnDelete.Disabled = true;
     btnEdit.Disabled   = true;
     btnNext.Disabled   = true;
     btnPrint.Disabled  = true;
 }
Exemplo n.º 2
0
 public void btnDelete_Click(object sender, DirectEventArgs e)
 {
     try
     {
         foreach (var item in RowSelectionModel3.SelectedRows)
         {
             new HoSoUngVienController().Delete(int.Parse("0" + item.RecordID));
         }
         GridPanel1.Reload();
         RowSelectionModel3.ClearSelections();
         btnDelete.Disabled = true;
         btnEdit.Disabled   = true;
         btnNext.Disabled   = true;
         btnPrint.Disabled  = true;
     }
     catch (Exception ex)
     {
         Dialog.ShowError(ex.Message);
     }
 }
Exemplo n.º 3
0
    public void btn_ChuyenLichHenPV_Click(object sender, DirectEventArgs e)
    {
        try
        {
            LichPhongVanController lichphongvan = new LichPhongVanController();
            DAL.LichHenPhongVan    lpv          = new DAL.LichHenPhongVan();
            HoSoUngVienController  hosoungvien  = new HoSoUngVienController();
            DAL.HoSoUngVien        hsuv         = new DAL.HoSoUngVien();
            foreach (var item in RowSelectionModel3.SelectedRows)
            {
                lpv.FR_KEY      = decimal.Parse("0" + item.RecordID);
                lpv.CreatedBy   = CurrentUser.ID;
                lpv.CreatedDate = DateTime.Now;
                if (!df_NgayPhongVan.SelectedDate.ToString().Contains("0001"))
                {
                    lpv.LichHen = Convert.ToDateTime(df_NgayPhongVan.SelectedDate);
                }
                lpv.ThoiGian      = tf_GioPhongVan.Text;
                lpv.ThuTuPhongVan = int.Parse("0" + txt_ThuTuPhongVan.Text);
                lpv.VongPhongVan  = int.Parse("0" + txt_VongPhongVan.Text);
                lpv.GhiChu        = txt_ghichu.Text;
                lichphongvan.InsertByHoSoUngVien(lpv);
                hsuv.MaUngVien        = decimal.Parse("0" + item.RecordID);
                hsuv.BlackListOrStore = "";
                hosoungvien.ChuyenDanhSach(hsuv, false);
            }

            wdChuyenLichHenPV.Hide();
            GridPanel1.Reload();
            RowSelectionModel3.ClearSelections();
            btnDelete.Disabled = true;
            btnEdit.Disabled   = true;
            btnNext.Disabled   = true;
            btnPrint.Disabled  = true;
            Dialog.ShowNotification("Chuyển thành công!");
        }
        catch (Exception ex)
        {
            Dialog.ShowError("Thông báo", "Có lỗi xảy ra: " + ex.Message);
        }
    }
Exemplo n.º 4
0
    public void btnChuyenTiep_Click(object sender, DirectEventArgs e)
    {
        string type         = "";
        bool   datrungtuyen = false;
        HoSoUngVienController hosoungvien = new HoSoUngVienController();

        DAL.HoSoUngVien hsuv = new DAL.HoSoUngVien();
        if (e.ExtraParams["type"] == "toList")
        {
            type         = "";
            datrungtuyen = true;
        }
        else
        {
            if (e.ExtraParams["type"] == "toDaTrungTuyen")
            {
                type = "DaTrungTuyen";
                hsuv.DaTrungTuyen = true;
                datrungtuyen      = true;
            }
            else
            {
                if (Equals(hdfType.Text, "store"))
                {
                    type = "black";
                }
                else
                {
                    if (Equals(hdfType.Text, "black"))
                    {
                        type = "store";
                    }
                }
            }
        }
        try
        {
            foreach (var item in RowSelectionModel3.SelectedRows)
            {
                hsuv.MaUngVien        = decimal.Parse("0" + item.RecordID);
                hsuv.BlackListOrStore = type;
                if (datrungtuyen == false)
                {
                    hsuv.MaLyDo = int.Parse("0" + hdfChuyen_LyDo.Text);
                    hsuv.GhiChu = txt_Chuyen_GhiChu.Text;
                }
                hsuv.XacNhanDiLam = null;
                hosoungvien.ChuyenDanhSach(hsuv, datrungtuyen);
            }
            wdChuyenLyDo.Hide();
            GridPanel1.Reload();
            RowSelectionModel3.ClearSelections();
            btnDelete.Disabled = true;
            btnEdit.Disabled   = true;
            btnNext.Disabled   = true;
            btnPrint.Disabled  = true;
            Dialog.ShowNotification("Chuyển thành công!");
        }
        catch (Exception ex)
        {
            Dialog.ShowError("Thông báo", "Có lỗi xảy ra: " + ex.Message);
        }
    }