Beispiel #1
0
 public bool Insert(FinanYear finanYear)
 {
     try
     {
         _finanYears.Add(finanYear);
         return(true);
     }
     catch (Exception)
     {
         return(false);
     }
 }
Beispiel #2
0
        public bool Delete(FinanYear finanYear)
        {
            try
            {
                _finanYears.Attach(finanYear);
                _finanYears.Remove(finanYear);

                return(true);
            }
            catch (Exception)
            {
                return(false);
            }
        }
Beispiel #3
0
        public bool Update(FinanYear finanYear)
        {
            try
            {
                _finanYears.Attach(finanYear);

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