/// <summary> /// Initializes a new instance of the class. /// </summary> public RegistrationApiController() { _context = new AllTheSameDbContext(); _vendorCredentialService = new VendorCredentialService(new UnitOfWork(_context), new VendorCredentialRepository(_context)); _industryService = new IndustryService(new UnitOfWork(_context), new IndustryRepository(_context)); _organizationService = new OrganizationService(new UnitOfWork(_context), new OrganizationRepository(_context)); _orgTypeService = new OrgTypeService(new UnitOfWork(_context), new OrgTypeRepository(_context)); _vendorService = new VendorService(new UnitOfWork(_context), new VendorRepository(_context)); _vendorTypeService = new VendorTypeService(new UnitOfWork(_context), new VendorTypeRepository(_context)); _vendorAdminService = new VendorAdminService(new UnitOfWork(_context), new VendorAdminRepository(_context)); _vendorWorkerService = new VendorWorkerService(new UnitOfWork(_context), new VendorWorkerRepository(_context)); _vendorCredDocumentService = new VendorCredDocumentService(new UnitOfWork(_context), new VendorCredDocumentRepository(_context)); _addressService = new AddressService(new UnitOfWork(_context), new AddressRepository(_context)); //var vendorCredentialList = _context.VendorCredentials; //var industryList = _context.Industries; //var organizationList = _context.Organizations; //var orgTypeList = _context.OrgTypes; //var vendorList = _context.Vendors; //var vendorTypeList = _context.VendorTypes; //var vendorAdminList = _context.VendorAdmins; //var vendorWorkerList = _context.VendorWorkers; //var vendorCredDocumentList = _context.VendorCredDocuments; //var addressList = _context.Addresses; //var c = Repository<Person>.Instance.Count; //var c2 = Repository<Person>.Instance.Count; //var s = new ServiceProxy<Person,IPersonRepository>().Count; }
public VendorController() { _vendorService = new VendorService(); _vendortypeService = new VendorTypeService(); }