From 7024bc9666e62cc33f651e7a060235d17bd51f25 Mon Sep 17 00:00:00 2001 From: crupest Date: Thu, 14 Feb 2019 23:05:04 +0800 Subject: Develop user token interface. --- Timeline/Entities/User.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'Timeline/Entities') diff --git a/Timeline/Entities/User.cs b/Timeline/Entities/User.cs index 3f7e9ac6..50463b57 100644 --- a/Timeline/Entities/User.cs +++ b/Timeline/Entities/User.cs @@ -11,5 +11,20 @@ namespace Timeline.Entities public string Username { get; set; } public string Password { get; set; } public string[] Roles { get; set; } + + public UserInfo GetUserInfo() + { + return new UserInfo + { + Username = this.Username, + Roles = this.Roles + }; + } + } + + public class UserInfo + { + public string Username { get; set; } + public string[] Roles { get; set; } } } -- cgit v1.2.3