public void Save(Data.TreasuryDetail entity)
 {
     try
     {
         if (entity.ID == Guid.Empty)
         {
             this.Insert(entity);
         }
         else
         {
             this.SubmitChanges();
         }
     }
     catch
     {
         throw;
     }
 }
        public void Delete(Data.TreasuryDetail entity)
        {
            try
            {
                if (entity == null)
                {
                    return;
                }

                this.Delete(new List <Data.TreasuryDetail>()
                {
                    entity
                });
            }
            catch
            {
                throw;
            }
        }