public void Update(LoyaltyCard entity) { LoyaltyCardType CardType = entity.LoyaltyCardType; var TotalSpent = entity.TotalSpent; var SpentThreshold = CardType.SpentThreshold; //so tien tich diem vuot qua nguong cua the CardType = _loyaltyCardTypeService.GetBySpent(TotalSpent); if (entity.LoyaltyCardTypeId != CardType.Id) { entity.LoyaltyCardTypeId = CardType.Id; } _repository.Update(entity); }
public void Insert(LoyaltyCardType entity) { _repository.Insert(entity); }
public void Update(LoyaltyCardType entity) { _repository.Update(entity); }
public void Delete(LoyaltyCardType entity) { _repository.Delete(entity); }