Organisation.fromJson constructor
Organisation.fromJson(- Map json
)
Implementation
Organisation.fromJson(Map json) {
id = json['id'];
name = json['name'];
description = json['description'];
logoLink = json['logo_link'];
organisationType = json['organisation_type'];
//linkedCampaigns = json['linked_campaigns'].cast<int>();
email = json['email'];
website = json['website'];
geographicReach = json['geographic_reach'];
instagram = json['IG_link'];
facebook = json['FB_link'];
twitter = json['twitter_link'];
campaigns = json['campaigns'] == null
? <Campaign>[]
: json['campaigns']
.map((e) => Campaign.fromJson(e))
.toList()
.cast<Campaign>();
extraText1 = json['extra_text_1'];
extraLink1 = json['extra_link_1'];
extraText2 = json['extra_text_2'];
extraLink2 = json['extra_link_2'];
extraText3 = json['extra_text_3'];
extraLink3 = json['extra_link_3'];
}