• This project
    • Loading...
  • Sign in

2021-1-capstone-design1 / RIT_Project1

%ea%b7%b8%eb%a6%bc1
Go to a project
Toggle navigation Toggle navigation pinning
  • Projects
  • Groups
  • Snippets
  • Help
  • Project
  • Activity
  • Repository
  • Pipelines
  • Graphs
  • Issues 1
  • Merge Requests 0
  • Wiki
  • Snippets
  • Network
  • Create a new issue
  • Builds
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Network
  • Compare
  • Branches
  • Tags
Switch branch/tag
  • RIT_Project1
  • ..
  • models
  • User.dart
  • 고원빈's avatar
    [frontend] login authorization 문제 해결 · ba1656c2
    ba1656c2
    고원빈 authored 2021-05-25 12:55:59 +0900
User.dart 350 Bytes
Raw Blame History Permalink
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
class User {
  final String userId;
  final String token;

  User({this.userId, this.token});

  factory User.fromJson(Map<String, dynamic> parsedJson) {
    return User(
      userId: parsedJson['userId'],
      token: parsedJson['token'],
    );
  }
  Map<String, dynamic> toJson() => {
        "userId": userId,
        "token": token,
      };
}