Customer.fromMap constructor
Implementation
factory Customer.fromMap(Map<String, dynamic> map) {
return Customer(
id: map['id'] ?? '',
email: map['email'] ?? '',
name: map['name'] ?? '',
instruments: map['instruments'] != null
? List<Instrument>.from(
map['instruments'].map((x) => Instrument.fromMap(x)))
: [],
);
}