Пример #1
0
 public void SendSms(SmsToSend sms)
 {
     // connect to gate
     // prepare sms
     // send
 }
        private void QueueSms(User user, string message)
        {
            var smsToSend = new SmsToSend
            {
                UserId = user.Id,
                PhoneNumber = user.MobilePhone,
                Message = message,
                CreationTime = DomainTime.Current.Now
            };

            _currentSmsesToSend[user.Id] = smsToSend;
            _notificationQueue.QueueSms(smsToSend);
        }
 public void QueueSms(SmsToSend smsToSend)
 {
     _context.SmsesToSend.Add(smsToSend);
 }