userModel.ts 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /**
  2. * @description: Login interface parameters
  3. */
  4. export interface LoginParams {
  5. username: string;
  6. password: string;
  7. }
  8. export interface AutoLoginParams {
  9. /** 工号 */
  10. workNo: string;
  11. username: string;
  12. }
  13. export interface ThirdLoginParams {
  14. token: string;
  15. thirdType: string;
  16. }
  17. export interface RoleInfo {
  18. roleName: string;
  19. value: string;
  20. }
  21. /**
  22. * @description: Login interface return value
  23. */
  24. export interface LoginResultModel {
  25. userId: string | number;
  26. token: string;
  27. role: RoleInfo;
  28. userInfo?: any;
  29. }
  30. /**
  31. * @description: Get user information return value
  32. */
  33. export interface GetUserInfoModel {
  34. roles: RoleInfo[];
  35. // 用户id
  36. userId: string | number;
  37. // 用户名
  38. username: string;
  39. // 真实名字
  40. realname: string;
  41. // 头像
  42. avatar: string;
  43. // 介绍
  44. desc?: string;
  45. // 用户信息
  46. userInfo?: any;
  47. // 缓存字典项
  48. sysAllDictItems?: any;
  49. }
  50. /**
  51. * @description: Get user information return value
  52. */
  53. export interface GetResultModel {
  54. code: number;
  55. message: string;
  56. result: object;
  57. success: Boolean;
  58. }