import 'package:equatable/equatable.dart';

class TeamDataModel extends Equatable {
  String all_fans;
  String direct_fans_count;
  String indirect_fans_count;
  String referrer_invite_code;
  String referrer_phone;
  String referrer_username;
  String referrer_wechat;
  String today_add;
  String yesterday_add;
  String referrerAvatar;

  TeamDataModel({
    this.all_fans,
    this.direct_fans_count,
    this.indirect_fans_count,
    this.referrer_invite_code,
    this.referrer_phone,
    this.referrer_username,
    this.referrer_wechat,
    this.today_add,
    this.yesterday_add,
    this.referrerAvatar,
  });

  factory TeamDataModel.fromJson(Map<String, dynamic> json) {
    return TeamDataModel(
      all_fans: json['all_fans'],
      direct_fans_count: json['direct_fans_count'],
      indirect_fans_count: json['indirect_fans_count'],
      referrer_invite_code: json['referrer_invite_code'],
      referrer_phone: json['referrer_phone'],
      referrer_username: json['referrer_username'],
      referrer_wechat: json['referrer_wechat'],
      today_add: json['today_add'],
      yesterday_add: json['yesterday_add'],
      referrerAvatar: json['referrer_avatar'],
    );
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['all_fans'] = this.all_fans;
    data['direct_fans_count'] = this.direct_fans_count;
    data['indirect_fans_count'] = this.indirect_fans_count;
    data['referrer_invite_code'] = this.referrer_invite_code;
    data['referrer_phone'] = this.referrer_phone;
    data['referrer_username'] = this.referrer_username;
    data['referrer_wechat'] = this.referrer_wechat;
    data['today_add'] = this.today_add;
    data['yesterday_add'] = this.yesterday_add;
    data['referrer_avatar'] = this.referrerAvatar;
    return data;
  }




  @override
  List<Object> get props => [this.all_fans, this.direct_fans_count, this.indirect_fans_count, this.referrer_invite_code, this.referrer_phone, this.referrer_username, this.referrer_wechat,
    this.today_add, this.yesterday_add, this.referrerAvatar];
}
