UGoldReadUserTxnsParams.fromMap constructor
UGoldReadUserTxnsParams.fromMap(
- Map<String, dynamic> json
)
Implementation
factory UGoldReadUserTxnsParams.fromMap(Map<String, dynamic> json) => UGoldReadUserTxnsParams(
userId: json["userId"],
tags: json["tags"] == null ? null : List<TagGoldTxn>.from(json["tags"]!.map((dynamic x) => TagGoldTxn.values.firstWhereOrNull((TagGoldTxn e) => e.number == x)).whereType<TagGoldTxn>()),
pageSize: json["pageSize"] ?? 20,
pageNumber: json["pageNumber"] ?? 1,
orderBy: json["orderBy"],
selectorArgs: json["selectorArgs"] == null ? null : UGoldTxnSelectorArgs.fromMap(json["selectorArgs"]),
fromCreatedAt: json["fromCreatedAt"] == null ? null : DateTime.parse(json["fromCreatedAt"]),
toCreatedAt: json["toCreatedAt"] == null ? null : DateTime.parse(json["toCreatedAt"]),
ids: json["ids"] == null ? null : List<String>.from(json["ids"]!.map((dynamic x) => x)),
creatorId: json["creatorId"],
);