Browse Source

refactor(types): 用户类型

qinlaiqiao 4 years ago
parent
commit
704e0ac9b6
1 changed files with 1 additions and 53 deletions
  1. 1 53
      types/src/interface/user.ts

+ 1 - 53
types/src/interface/user.ts

@@ -49,52 +49,6 @@ export interface ISpecifyCptItem {
   cptID: string;
 }
 
-// user 表原始字段
-export interface IRawUser {
-  _id?: string;
-  qq?: string;
-  real_name?: string;
-  avatar?: string;
-  // 指定的编办
-  specifyCpt?: string;
-  latest_login?: number;
-  user_type?: string;
-  contacts?: IContact[];
-  isSmsLogin?: number;
-  isLoginValid?: number;
-  ssoId?: string;
-  email?: string;
-  mobile?: string;
-  create_time?: string;
-  upgrade_list?: IUpgradeItemInfo[];
-  used_list?: IUsed[];
-  latest_used?: string;
-  defaultEnterprise?: string;
-}
-
-// 返回给前端的字段
-export interface IUser {
-  ID?: string;
-  qq?: string;
-  realName?: string;
-  avatar?: string;
-  // 指定的编办
-  specifyCpt?: string;
-  latestLogin?: number;
-  userType?: string;
-  contacts?: IContact[];
-  isSmsLogin?: number;
-  isLoginValid?: number;
-  ssoID?: string;
-  email?: string;
-  mobile?: string;
-  createTime?: string;
-  upgradeList?: IUpgradeItemInfo[];
-  usedList?: IUsed[];
-  latestUsed?: string;
-  defaultEnterprise?: string;
-}
-
 interface IProCptItem {
   // 编办 ID
   compilationID: string;
@@ -144,8 +98,7 @@ interface ISummary {
   everydayOnlineTime: IEverydayOnlineTimeItem[];
 }
 
-// todo 临时的,用于替代 IUser
-export interface IUserTmp {
+export interface IUser {
   ID: string;
   ssoID: string;
   mobile: string;
@@ -165,15 +118,10 @@ export interface IUserTmp {
 }
 
 // 最近联系人
-// todo 待删
 export interface IRecentUser extends IUser {
   recentDate: number;
 }
 
-export interface IContactUser extends IUserTmp {
-  recentDate: number;
-}
-
 export interface ILoginResult {
   userID: string;
 }