43 lines
1.0 KiB
Dart
43 lines
1.0 KiB
Dart
|
// To parse this JSON data, do
|
||
|
//
|
||
|
// final signatories = signatoriesFromJson(jsonString);
|
||
|
|
||
|
import 'dart:convert';
|
||
|
|
||
|
Signatories signatoriesFromJson(String str) =>
|
||
|
Signatories.fromJson(json.decode(str));
|
||
|
|
||
|
String signatoriesToJson(Signatories data) => json.encode(data.toJson());
|
||
|
|
||
|
class Signatories {
|
||
|
final int? id;
|
||
|
final int signatoryId;
|
||
|
final String firstname;
|
||
|
final String middlename;
|
||
|
final String lastname;
|
||
|
|
||
|
Signatories({
|
||
|
this.id,
|
||
|
required this.signatoryId,
|
||
|
required this.firstname,
|
||
|
required this.middlename,
|
||
|
required this.lastname,
|
||
|
});
|
||
|
|
||
|
factory Signatories.fromJson(Map<String, dynamic> json) => Signatories(
|
||
|
id: json["id"],
|
||
|
signatoryId: json["signatory_id"],
|
||
|
firstname: json["firstname"],
|
||
|
middlename: json["middlename"],
|
||
|
lastname: json["lastname"],
|
||
|
);
|
||
|
|
||
|
Map<String, dynamic> toJson() => {
|
||
|
"id": id,
|
||
|
"signatory_id": signatoryId,
|
||
|
"firstname": firstname,
|
||
|
"middlename": middlename,
|
||
|
"lastname": lastname,
|
||
|
};
|
||
|
}
|