| 123456789101112131415161718192021222324252627282930 |
- import 'package:cloud_firestore/cloud_firestore.dart';
- class LoggedInUser {
- final String name;
- final num totalPoints;
- dynamic weeklyPlace;
- final String sharedId;
- final Timestamp lastChallengeDate;
- final GeoPoint address;
- LoggedInUser({
- required this.name,
- required this.totalPoints,
- required this.weeklyPlace,
- required this.sharedId,
- required this.lastChallengeDate,
- required this.address,
- });
- factory LoggedInUser.fromMap(Map<String, dynamic> map) {
- return LoggedInUser(
- name: map["name"],
- totalPoints: map["total_points"],
- weeklyPlace: map["weekly_place"],
- sharedId: map["shared_id"],
- lastChallengeDate: map["last_challenge_date"],
- address: map["address"],
- );
- }
- }
|