feat(M05-C): 完成团购验券与第三方直订
This commit is contained in:
@@ -38,6 +38,9 @@ import {
|
||||
} from './routes/order-management.js';
|
||||
import { registerOrderShareRoutes, type OrderShareRouteOptions } from './routes/order-share.js';
|
||||
import { registerPaymentRoutes, type PaymentRouteOptions } from './routes/payments.js';
|
||||
import {
|
||||
registerThirdPartyRoutes, type ThirdPartyRouteOptions
|
||||
} from './routes/third-party.js';
|
||||
|
||||
export interface BuildAppOptions {
|
||||
config?: AppConfig;
|
||||
@@ -53,6 +56,7 @@ export interface BuildAppOptions {
|
||||
orderManagement?: OrderManagementRouteOptions;
|
||||
orderShare?: OrderShareRouteOptions;
|
||||
payment?: PaymentRouteOptions;
|
||||
thirdParty?: ThirdPartyRouteOptions;
|
||||
}
|
||||
|
||||
declare module 'fastify' {
|
||||
@@ -133,6 +137,9 @@ export async function buildApp(options: BuildAppOptions = {}): Promise<FastifyIn
|
||||
if (options.payment) {
|
||||
await registerPaymentRoutes(app, options.payment);
|
||||
}
|
||||
if (options.thirdParty) {
|
||||
await registerThirdPartyRoutes(app, options.thirdParty);
|
||||
}
|
||||
|
||||
return app;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user