2024-03-20 18:31:37 +08:00
|
|
|
class DictItemModel {
|
|
|
|
DictItemModel({
|
2024-03-25 14:16:00 +08:00
|
|
|
this.id,
|
|
|
|
this.createdAt,
|
|
|
|
this.updatedAt,
|
|
|
|
this.creator,
|
|
|
|
this.updater,
|
2024-03-20 18:31:37 +08:00
|
|
|
required this.label,
|
2024-03-25 14:16:00 +08:00
|
|
|
this.value,
|
|
|
|
this.orderNo,
|
|
|
|
this.status,
|
|
|
|
this.remark,
|
2024-03-20 18:31:37 +08:00
|
|
|
});
|
|
|
|
|
|
|
|
final int? id;
|
|
|
|
final DateTime? createdAt;
|
|
|
|
final DateTime? updatedAt;
|
|
|
|
final String? creator;
|
|
|
|
final String? updater;
|
2024-03-25 14:16:00 +08:00
|
|
|
final String label;
|
2024-03-20 18:31:37 +08:00
|
|
|
final String? value;
|
|
|
|
final int? orderNo;
|
|
|
|
final int? status;
|
|
|
|
final String? remark;
|
|
|
|
|
|
|
|
factory DictItemModel.fromJson(Map<String, dynamic> json) {
|
|
|
|
return DictItemModel(
|
|
|
|
id: json["id"],
|
|
|
|
createdAt: DateTime.tryParse(json["createdAt"] ?? ""),
|
|
|
|
updatedAt: DateTime.tryParse(json["updatedAt"] ?? ""),
|
|
|
|
creator: json["creator"],
|
|
|
|
updater: json["updater"],
|
|
|
|
label: json["label"],
|
|
|
|
value: json["value"],
|
|
|
|
orderNo: json["orderNo"],
|
|
|
|
status: json["status"],
|
|
|
|
remark: json["remark"],
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() => {
|
|
|
|
"id": id,
|
|
|
|
"createdAt": createdAt?.toIso8601String(),
|
|
|
|
"updatedAt": updatedAt?.toIso8601String(),
|
|
|
|
"creator": creator,
|
|
|
|
"updater": updater,
|
|
|
|
"label": label,
|
|
|
|
"value": value,
|
|
|
|
"orderNo": orderNo,
|
|
|
|
"status": status,
|
|
|
|
"remark": remark,
|
|
|
|
};
|
|
|
|
}
|