mirror of
https://github.com/certd/certd.git
synced 2026-05-16 21:27:34 +08:00
chore:
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import { Controller, Get, Inject, MidwayEnvironmentService, Provide } from '@midwayjs/core';
|
||||
import { logger } from '@certd/basic';
|
||||
import { Constants } from '@certd/lib-server';
|
||||
|
||||
@Provide()
|
||||
@Controller('/home')
|
||||
export class HomeController {
|
||||
@Inject()
|
||||
environmentService: MidwayEnvironmentService;
|
||||
@Get('/', { summary: Constants.per.guest })
|
||||
async home(): Promise<string> {
|
||||
logger.info('当前环境:', this.environmentService.getCurrentEnvironment()); // prod
|
||||
return 'Hello Midwayjs!';
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user