예제 #1
0
        private ConceptoEntityObject GetConceptoObject(DataRow row)
        {
            ConceptoEntityObject _ConceptoInfo = null;

            if (row != null)
            {
                _ConceptoInfo             = new ConceptoEntityObject();
                _ConceptoInfo.Clave       = row["CLAVE_CONCEPTO"].ToString();
                _ConceptoInfo.Descripcion = row["descripcion"].ToString();
                //_ConceptoInfo.Activo = (row["activo"] != DBNull.Value && row["activo"].ToString().ToUpper().Trim() == "SI") ? true : false;
            }

            return(_ConceptoInfo);
        }
        protected void ASPxGridViewNomina_CustomDataCallback(object sender, ASPxGridViewCustomDataCallbackEventArgs e)
        {
            DevExpress.Web.ASPxGridView grid = (DevExpress.Web.ASPxGridView)sender;
            object conceptoID = e.Parameters;
            string clave      = conceptoID.ToString().Trim();

            //se obtiene el empleado mediante el ID
            ConceptoBusinessObject _ConceptoBAL  = new ConceptoBusinessObject();
            ConceptoEntityObject   _ConceptoInfo = _ConceptoBAL.GetConcepto(clave);

            if (_ConceptoInfo != null)
            {
                e.Result = new string[] { _ConceptoInfo.Clave, _ConceptoInfo.Descripcion };
            }
        }
예제 #3
0
        public ConceptoEntityObject GetConcepto(string ClaveConcepto)
        {
            DataTable dt;

            DataRow[]            rows;
            ConceptoEntityObject _ConceptoInfo = null;

            try
            {
                dt   = GetConceptosTable();
                rows = dt.Select(string.Format(@"CLAVE_CONCEPTO='{0}'", ClaveConcepto.Trim()));

                if (rows != null && rows.Length > 0)
                {
                    _ConceptoInfo = GetConceptoObject(rows[0]);
                }

                return(_ConceptoInfo);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
예제 #4
0
 public int Delete(ConceptoEntityObject ConceptoInfo)
 {
     throw new NotImplementedException();
 }