2020-09-17 06:02:48 +06:30
|
|
|
import 'package:cloud_firestore/cloud_firestore.dart';
|
|
|
|
|
|
2020-09-15 07:13:41 +06:30
|
|
|
class ShipmentStatus {
|
|
|
|
|
String status;
|
|
|
|
|
DateTime date;
|
|
|
|
|
bool done;
|
2020-12-10 20:06:15 +06:30
|
|
|
String staffId;
|
|
|
|
|
String staffName;
|
|
|
|
|
ShipmentStatus(
|
|
|
|
|
{this.status, this.date, this.done, this.staffId, this.staffName});
|
2020-09-17 06:02:48 +06:30
|
|
|
|
|
|
|
|
factory ShipmentStatus.fromMap(Map<String, dynamic> map) {
|
|
|
|
|
var _date = (map['date'] as Timestamp);
|
|
|
|
|
return ShipmentStatus(
|
2020-12-10 20:06:15 +06:30
|
|
|
status: map['status'],
|
|
|
|
|
date: _date == null ? null : _date.toDate(),
|
|
|
|
|
done: map['done'],
|
|
|
|
|
staffId: map['staff_id'],
|
|
|
|
|
staffName: map['staff_name']);
|
2020-09-17 06:02:48 +06:30
|
|
|
}
|
2020-09-15 07:13:41 +06:30
|
|
|
}
|