コード例 #1
0
 public static void LogError(ENT.ErrorLog errorlog)
 {
     using (BAL.ErrorLog objError = new Web.Framework.BusinessLayer.ErrorLog())
     {
         objError.Insert(errorlog);
     }
 }
コード例 #2
0
        // this function for just referance for partial update field user have to create seperate function learn from this function.
        public bool UpdatePartial(ENT.ErrorLog objEntity)
        {
            bool blnResult = false;

            try
            {
                //Create Fields List in dictionary
                Dictionary <string, bool> dctFields = new Dictionary <string, bool>();
                dctFields.Add(COM.HelperMethod.PropertyName <ENT.ErrorLog>(x => x.errorid), true);
                dctFields.Add(COM.HelperMethod.PropertyName <ENT.ErrorLog>(x => x.errocode), false);
                dctFields.Add(COM.HelperMethod.PropertyName <ENT.ErrorLog>(x => x.errortext), false);
                dctFields.Add(COM.HelperMethod.PropertyName <ENT.ErrorLog>(x => x.errorfileurl), false);
                dctFields.Add(COM.HelperMethod.PropertyName <ENT.ErrorLog>(x => x.UpdatedBy), false);
                dctFields.Add(COM.HelperMethod.PropertyName <ENT.ErrorLog>(x => x.UpdatedDateTime), false);
                objEntity.FieldCollection = dctFields;
                if (objDAL.SaveChanges(objEntity.FieldCollection, objEntity))
                {
                    blnResult = true;
                }
            }
            catch (Exception)
            {
                throw;
            }
            return(blnResult);
        }
コード例 #3
0
        public object GetByPrimaryKey(ENT.ErrorLog Entity)
        {
            object objResult = null;

            try
            {
                DAL.CRUDOperation tt = new DAL.CRUDOperation();
                objResult = tt.GetEntityByPrimartKey(Entity);
            }
            catch (Exception)
            {
                throw;
            }
            return(objResult);
        }
コード例 #4
0
        private bool disposedValue = false; // To detect redundant calls

        protected virtual void Dispose(bool disposing)
        {
            if (!disposedValue)
            {
                if (disposing)
                {
                    // TODO: dispose managed state (managed objects).
                }
                objDAL    = null;
                clsDAL    = null;
                Entity    = null;
                lstEntity = null;
                // TODO: free unmanaged resources (unmanaged objects) and override a finalizer below.
                // TODO: set large fields to null.

                disposedValue = true;
            }
        }