LoginUser.cs 858 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using Newtonsoft.Json;
  7. namespace PTMedicalInsurance.Entity
  8. {
  9. class LoginUser
  10. {
  11. public string userName { get; set; }
  12. public string passWord { get; set; }
  13. [JsonIgnore]
  14. public UserInfo user { get; set; }
  15. public RoleInfo[] roles { set; get; }
  16. [JsonIgnore]
  17. public InterfaceInfo interfaceInfo { set; get; }
  18. [JsonIgnore]
  19. public bool hasLogin { get; set; }
  20. private static LoginUser _loginUser = null;
  21. public static LoginUser Current {
  22. get
  23. {
  24. if (_loginUser == null) {
  25. _loginUser = new LoginUser();
  26. }
  27. return _loginUser;
  28. }
  29. }
  30. }
  31. }