fromMapArticleUncountable static method
Implementation
static CalibreWeebi<ArticleUncountable> fromMapArticleUncountable(
Map<String, dynamic> map) {
return CalibreWeebi<ArticleUncountable>(
id: map['id'],
title: map['title'] ?? '',
kind: ArticleKind.uncountable,
creationDate: map['creationDate'] == null
? DatesWeebi.defaultDate
: DateTime.tryParse(map['creationDate']) ?? DatesWeebi.defaultDate,
updateDate: DateTime.tryParse(map['updateDate'] ?? ''),
status: map['status'],
statusUpdateDate: DateTime.tryParse(map['statusUpdateDate'] ?? ''),
articles: map['articles'] == null || map['articles'] == []
? <ArticleUncountable>[]
: List<ArticleUncountable>.from(
map['articles'].map((x) => ArticleUncountable.fromMap(x))),
);
}