feat: add public seller directory
This commit is contained in:
@@ -28,6 +28,8 @@ import { createProductRepository } from '../modules/products/repositories/produc
|
||||
import { createProductService } from '../modules/products/services/product-service.js';
|
||||
import { createPublicProductService } from '../modules/products/services/public-product-service.js';
|
||||
import { createSearchService } from '../modules/search/services/search-service.js';
|
||||
import { createSellerRepository } from '../modules/sellers/repositories/seller-repository.js';
|
||||
import { createPublicSellerService } from '../modules/sellers/services/public-seller-service.js';
|
||||
|
||||
function parsePort(value) {
|
||||
const port = Number.parseInt(value ?? '3000', 10);
|
||||
@@ -46,6 +48,7 @@ async function startServer() {
|
||||
const inventoryItemRepository = createInventoryItemRepository(database.db);
|
||||
const inventoryImageRepository = createInventoryImageRepository(database.db);
|
||||
const listingRepository = createListingRepository(database.db);
|
||||
const sellerRepository = createSellerRepository(database.db);
|
||||
const conditionRepository = createConditionRepository(database.db);
|
||||
const userRepository = createUserRepository(database.db);
|
||||
const sessionRepository = createSessionRepository(database.db);
|
||||
@@ -93,6 +96,7 @@ async function startServer() {
|
||||
productService: createProductService({ productRepository }),
|
||||
publicProductService: createPublicProductService({ productRepository }),
|
||||
searchService: createSearchService({ listingRepository }),
|
||||
publicSellerService: createPublicSellerService({ sellerRepository }),
|
||||
});
|
||||
|
||||
app.addHook('onClose', async () => {
|
||||
|
||||
Reference in New Issue
Block a user