PalVideoTrigger.fromMap constructor

PalVideoTrigger.fromMap(
  1. Map<String, dynamic> map
)

Implementation

factory PalVideoTrigger.fromMap(Map<String, dynamic> map) {
  return PalVideoTrigger(
    eventLogId: map['eventLogId'] ?? '',
    videoId: map['videoId'] ?? '',
    creationDate: DateTime.parse(map['creationDate']),
    videoUrl: map['videoUrl'] ?? '',
    videoThumbUrl: map['videoThumbUrl'] ?? '',
    imgThumbUrl: map['imgThumbUrl'] ?? '',
    // type: parseType(map['type']),
    author: Author(
      userName: map['videoSpeakerName'] ?? '',
      companyTitle: map['videoSpeakerRole'] ?? '',
    ),
    survey: map['survey'] != null ? Survey.fromMap(map['survey']) : null,
  );
}