Beispiel #1
0
        protected void grid_RowUpdating(object sender, DevExpress.Web.Data.ASPxDataUpdatingEventArgs e)
        {
            ASPxTextBox     txtLuongCB     = grid.FindEditFormTemplateControl("txtLuongCB") as ASPxTextBox;
            ASPxDateEdit    txtThoiDiem    = grid.FindEditFormTemplateControl("txtThoiDiem") as ASPxDateEdit;
            ASPxHiddenField HiddentfileKem = grid.FindEditFormTemplateControl("HiddentfileKem") as ASPxHiddenField;
            ASPxTextBox     txtfilekem     = grid.FindEditFormTemplateControl("txtfilekem") as ASPxTextBox;
            ASPxTextBox     txtQuyetDinh   = grid.FindEditFormTemplateControl("txtQuyetDinh") as ASPxTextBox;

            this.luongcb = objBaoHiem.GetLuongCBId(Int32.Parse(e.Keys[grid.KeyFieldName].ToString()));
            if (this.luongcb != null)
            {
                this.luongcb.luongcb  = Convert.ToDecimal(txtLuongCB.Text.Trim());
                this.luongcb.thoidiem = txtThoiDiem.Date;
                this.luongcb.soqd     = txtQuyetDinh.Text.Trim();
                if (HiddentfileKem.Count > 0)
                {
                    this.luongcb.fileKem = "LCB" + DateTime.Now.ToShortDateString().Replace("/", "_") + "_" + HiddentfileKem.Get("filekem").ToString();
                }
                else
                {
                    this.luongcb.fileKem = "LCB" + DateTime.Now.ToShortDateString().Replace("/", "_") + "_" + txtfilekem.Text.Trim();
                }
                this.objBaoHiem.UpdateLuongCB(luongcb);
            }
            grid.CancelEdit();
            e.Cancel             = true;
            this.grid.DataSource = objBaoHiem.GetLuongCBs();
            this.grid.DataBind();
        }
Beispiel #2
0
 protected void grid_RowDeleting(object sender, DevExpress.Web.Data.ASPxDataDeletingEventArgs e)
 {
     this.luongcb = objBaoHiem.GetLuongCBId(Int32.Parse(e.Keys[grid.KeyFieldName].ToString()));
     if (this.luongcb != null)
     {
         this.objBaoHiem.DeleteLuongCB(luongcb);
     }
     grid.CancelEdit();
     e.Cancel             = true;
     this.grid.DataSource = objBaoHiem.GetLuongCBs();
     this.grid.DataBind();
 }
Beispiel #3
0
 public void DeleteLuongCB(LuongCBInfo objLuongCB)
 {
     DataProvider.Instance().DeleteLuongCB(objLuongCB);
 }
Beispiel #4
0
 // Luong CB
 public void AddLuongCB(LuongCBInfo objLuongCB)
 {
     DataProvider.Instance().AddLuongCB(objLuongCB);
 }
Beispiel #5
0
 public void UpdateLuongCB(LuongCBInfo objLuongCB)
 {
     DataProvider.Instance().UpdateLuongCB(objLuongCB);
 }
 public override void UpdateLuongCB(LuongCBInfo objLuongCB)
 {
     SqlHelper.ExecuteNonQuery(ConnectionString, GetFullyQualifiedName("HRM_LuongCB"), objLuongCB.id, objLuongCB.luongcb, objLuongCB.thoidiem, objLuongCB.soqd, objLuongCB.fileKem, 1);
 }
Beispiel #7
0
 public abstract void DeleteLuongCB(LuongCBInfo objLuongCB);
Beispiel #8
0
 public abstract void UpdateLuongCB(LuongCBInfo objLuongCB);
Beispiel #9
0
 public abstract void AddLuongCB(LuongCBInfo objLuongCB);