示例#1
0
        public bool SaveEarning(Earning earning)
        {
            var earnings = _database.GetCollection<Item>(EARNING_COLLECTION);

            try
            {
                earnings.Save(earning);
            }
            catch
            {
                return false;
            }

            return true;
        }
示例#2
0
 public Earning Edit(Earning earning)
 {
     return _mongoContext.GetEarning(earning.Date);
 }
示例#3
0
 public bool Save(Earning earning)
 {
     return _mongoContext.SaveEarning(earning);
 }
示例#4
0
 public Earning Create(Earning earning)
 {
     earning.Onuses = _helper.GetOnusesPerEarning(earning.Date, earning.Next);
     return earning;
 }