Add categories and suppliers with CRUD routes
- category table with hierarchical parent_id, sort ordering, soft-delete - supplier table with contact info, account number, payment terms - CRUD routes for both with search on suppliers - Zod validation schemas in @forte/shared - Products will link to suppliers via join table (many-to-many) - 26 tests passing
This commit is contained in:
@@ -8,6 +8,7 @@ import { devAuthPlugin } from './plugins/dev-auth.js'
|
||||
import { healthRoutes } from './routes/v1/health.js'
|
||||
import { authRoutes } from './routes/v1/auth.js'
|
||||
import { accountRoutes } from './routes/v1/accounts.js'
|
||||
import { inventoryRoutes } from './routes/v1/inventory.js'
|
||||
|
||||
export async function buildApp() {
|
||||
const app = Fastify({
|
||||
@@ -35,6 +36,7 @@ export async function buildApp() {
|
||||
await app.register(healthRoutes, { prefix: '/v1' })
|
||||
await app.register(authRoutes, { prefix: '/v1' })
|
||||
await app.register(accountRoutes, { prefix: '/v1' })
|
||||
await app.register(inventoryRoutes, { prefix: '/v1' })
|
||||
|
||||
return app
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user