25 lines
486 B
TypeScript
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,
|
|
};
|
|
};
|