Esempio n. 1
0
 public bool Insert(ChequeBank chequeBank)
 {
     try
     {
         _chequeBanks.Add(chequeBank);
         return(true);
     }
     catch (Exception)
     {
         return(false);
     }
 }
Esempio n. 2
0
        public bool Delete(ChequeBank chequeBank)
        {
            try
            {
                _chequeBanks.Attach(chequeBank);
                _chequeBanks.Remove(chequeBank);

                return(true);
            }
            catch (Exception)
            {
                return(false);
            }
        }
Esempio n. 3
0
        public bool Update(ChequeBank chequeBank)
        {
            try
            {
                _chequeBanks.Attach(chequeBank);

                _uow.Entry(chequeBank).State = EntityState.Modified;
                //_uow.Entry(chequeBank).Property(p => p.CreatedOn).IsModified = false;
                //_uow.Entry(chequeBank).Property(p => p.CreatedBy).IsModified = false;
                return(true);
            }
            catch (Exception)
            {
                return(false);
            }
        }