33 lines
826 B
TypeScript
33 lines
826 B
TypeScript
import { ApiProperty } from '@midwayjs/swagger';
|
|
import { Rule, RuleType } from '@midwayjs/validate';
|
|
|
|
export class SiteConfig {
|
|
@ApiProperty({ example: '1', description: '站点 ID' })
|
|
@Rule(RuleType.string())
|
|
id: string;
|
|
|
|
@ApiProperty({ description: '站点 URL' })
|
|
@Rule(RuleType.string())
|
|
wpApiUrl: string;
|
|
|
|
@ApiProperty({ description: '站点 rest key' })
|
|
@Rule(RuleType.string())
|
|
consumerKey: string;
|
|
|
|
@ApiProperty({ description: '站点 rest 秘钥' })
|
|
@Rule(RuleType.string())
|
|
consumerSecret: string;
|
|
|
|
@ApiProperty({ description: '站点名' })
|
|
@Rule(RuleType.string())
|
|
siteName: string;
|
|
|
|
@ApiProperty({ description: '站点邮箱' })
|
|
@Rule(RuleType.string())
|
|
email?: string;
|
|
|
|
@ApiProperty({ description: '站点邮箱密码' })
|
|
@Rule(RuleType.string())
|
|
emailPswd?: string;
|
|
}
|