app/@overflow/model/meta/MetaMemberStatus.ts
crusader aaf3e23966 ing
2018-08-27 00:15:10 +09:00

25 lines
486 B
TypeScript

export interface MetaMemberStatus {
id?: number;
key?: string;
name?: string;
createDate?: Date;
}
export enum MetaMemberStatusEnum {
NOAUTH = 'NOAUTH',
NORMAL = 'NORMAL',
DORMANCY = 'DORMANCY',
WITHDRAWAL = 'WITHDRAWAL',
}
export const toMetaMemberStatusEnum = (v: MetaMemberStatus): MetaMemberStatusEnum => {
return MetaMemberStatusEnum[v.key];
};
export const toMetaMemberStatus = (v: MetaMemberStatusEnum): MetaMemberStatus => {
return {
key: v,
};
};