public EnquiryTypeViewModel() { var Scope = Startup.Instance.provider.CreateScope(); _currentEnquiryType = new EnquiryType(); _repositoryEnquiryType = Scope.ServiceProvider.GetRequiredService <IEnquiryTypeService>(); EnquiryTypes = _repositoryEnquiryType.GetAllEnquiryType(); WireCommands(); }
public EnquiriesController(IPersonService personService, IMailerService mailerService, IMappingEngine mappingEngine, IAddressService addressService, IEnquiryTypeService enquiryTypeService, IEnquiryService enquiryService, ISerializer serializer, IEnquiryRecipientService enquiryRecipientService) { if (mailerService == null) { throw new ArgumentNullException("mailerService"); } if (personService == null) { throw new ArgumentNullException("personService"); } if (mappingEngine == null) { throw new ArgumentNullException("mappingEngine"); } if (addressService == null) { throw new ArgumentNullException("addressService"); } if (enquiryTypeService == null) { throw new ArgumentNullException("enquiryTypeService"); } if (enquiryService == null) { throw new ArgumentNullException("enquiryService"); } if (serializer == null) { throw new ArgumentNullException("serializer"); } if (enquiryRecipientService == null) { throw new ArgumentNullException("enquiryRecipientService"); } _mailerService = mailerService; _mappingEngine = mappingEngine; _personService = personService; _addressService = addressService; _enquiryService = enquiryService; _enquiryTypeService = enquiryTypeService; _serializer = serializer; _enquiryRecipientService = enquiryRecipientService; }
public EnquiryTypeController(IEnquiryTypeService enquirytypeService) { _enquirytypeService = enquirytypeService; }