mirror of
https://github.com/certd/certd.git
synced 2026-04-15 21:40:53 +08:00
chore: 1
This commit is contained in:
@@ -1,16 +0,0 @@
|
||||
import { MidwayEnvironmentService } from '@midwayjs/core';
|
||||
import { Controller, Get, Inject, Provide } from '@midwayjs/core';
|
||||
import { logger } from '../utils/logger.js';
|
||||
import { Constants } from '../basic/constants.js';
|
||||
|
||||
@Provide()
|
||||
@Controller('/hello')
|
||||
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