public PharmacyController( ILocationService locationService, IPharmacyService pharmacyService) { _locationService = locationService ?? throw new ArgumentNullException(nameof(locationService)); _pharmacyService = pharmacyService ?? throw new ArgumentNullException(nameof(pharmacyService)); }
public PharmacyServiceTests() { sut = new Services.Services.PharmacyService(pharmacyRepositoryMock.Object); var pharmacies = PharmacyFactory.GetPharmacies(); pharmacyRepositoryMock.Setup(x => x.GetAll()).Returns(pharmacies); }
public UserProfilePageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; isEdit = false; Mode = "Редактировать"; Initial(); }
public SaleController(ISaleService saleService, IMapper mapper, IPharmacyService pharmacyService, IHttpClientFactory httpClientFactory) { _saleService = saleService; _mapper = mapper; _pharmacyService = pharmacyService; _httpClientFactory = httpClientFactory; }
private void OnConsumerReceived(object sender, BasicDeliverEventArgs e) { Byte[] body = null; string messageJson = null; ActionBenefitMessage message = null; string exchangeName = null; try { exchangeName = e.Exchange; body = e.Body.ToArray(); messageJson = Encoding.UTF8.GetString(body); message = JsonConvert.DeserializeObject <ActionBenefitMessage>(messageJson); HandleMessage(message, exchangeName); _channel.BasicAck(e.DeliveryTag, false); } catch (Exception ex) { Console.WriteLine(ex.Message); _channel.BasicReject(e.DeliveryTag, false); using (var scope = _service.CreateScope()) { IPharmacyService pharmacyService = scope.ServiceProvider.GetRequiredService <IPharmacyService>(); PharmacySystem pharmacySystem = pharmacyService.GetPharmacyByExchangeName(exchangeName); if (pharmacySystem != null) { SendEmail(ex.Message, pharmacySystem.Email); } } } }
public PrescriptionController(IClinicianService clinicianService, UserManager <ApplicationUser> userManager, IProfileService profileService, IPrescriptionService prescriptionService, IEmailSender emailSender, IPharmacyService pharmacyService) { _clinicianService = clinicianService; _userManager = userManager; _profileService = profileService; _prescriptionService = prescriptionService; _emailSender = emailSender; _pharmacyService = pharmacyService; }
private void InitializeRabbitMqListener() { if (_channel == null) { return; } _channel.QueueDeclare(queue: _queueName, durable: true, exclusive: false, autoDelete: false, arguments: null); _channel.BasicConsume(queue: _queueName, autoAck: false, consumer: _consumer); using (var scope = _service.CreateScope()) { IPharmacyService pharmacyService = scope.ServiceProvider.GetRequiredService <IPharmacyService>(); foreach (PharmacySystem p in pharmacyService.GetPharmaciesBySubscribed(true)) { _channel.ExchangeDeclare(exchange: p.ActionsBenefitsExchangeName, type: ExchangeType.Fanout); _channel.QueueBind(queue: _queueName, exchange: p.ActionsBenefitsExchangeName, routingKey: ""); } } }
public LoginPageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; }
public RegisterPageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; }
public PharmacyController(IPharmacyService pharmacyService, IMapper mapper) { _pharmacyService = pharmacyService; _mapper = mapper; }
public PharmacyServiceTests() { pharmacyService = new PharmacyService(pharmacyRepository); }
public MedicineService(LekarnaDbContext data, IPharmacyService pharmacyService) { this.data = data; this.pharmacyService = pharmacyService; }
public RegisterPageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; Registration(user); }
public PharmacyController(IPharmacyService service) { this._pharmacyService = service; }
public ProcurementController(IUrgentMedicationProcurementService service, IMailService mailService, IPharmacyService pharmacyService) { _service = service; _mailService = mailService; _pharmacyService = pharmacyService; }
public ProductPageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; }
public PharmacyController(IPharmacyService pharmacyService) { this.pharmacyService = pharmacyService; }
public PharmacyController(IApiValidationService validationService, IPharmacyService pharmacyService, ILogger <PharmacyController> logger) { _validationService = validationService; _pharmacyService = pharmacyService; _logger = logger; }
public PharmacyController([FromServices] IPharmacyService pharmacyService) { this._pharmacyService = pharmacyService; }
/// <summary> /// Initializes a new instance of the <see cref="PharmacyController"/> class. /// </summary> /// <param name="svc">The injected pharmacy data service.</param> /// <param name="httpAccessor">The injected http context accessor provider.</param> public PharmacyController(IPharmacyService svc, IHttpContextAccessor httpAccessor) { this.service = svc; this.httpContextAccessor = httpAccessor; }
public ProductListPageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; Products = new ObservableCollection <ProductPair>(); }
public PrescriptionController(IPrescriptionSearchService prescriptionSearchService, IMailService mailService, IPharmacyService pharmacyService) { this.prescriptionSearchService = prescriptionSearchService; this.mailService = mailService; this.pharmacyService = pharmacyService; }
public OrderController(IOrderService orderService, IMapper mapper, IPharmacyService pharmacyService) { _orderService = orderService; _mapper = mapper; _pharmacyService = pharmacyService; }
public OrderPageModel(IPharmacyService pharmacyService) { _pharmacyService = pharmacyService; Init(); }
public PharmacySystemServiceController(IPharmacyService pharmacySystemService, IActionBenefitService actionBenefitService) { _pharmacySystemService = pharmacySystemService; _actionBenefitService = actionBenefitService; }
public MedicineController(IPharmacyService pharmacyService, IMedicineService medicineService) { this.pharmacyService = pharmacyService; this.medicineService = medicineService; }