123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- class Album {
- String rEQ;
- String rEQDT;
- String rESDT;
- int status;
- List<Result> result;
- Album({this.rEQ, this.rEQDT, this.rESDT, this.status, this.result});
- Album.fromJson(Map<String, dynamic> json) {
- rEQ = json['REQ'];
- rEQDT = json['REQ_DT'];
- rESDT = json['RES_DT'];
- status = json['status'];
- if (json['result'] != null) {
- result = new List<Result>();
- json['result'].forEach((v) {
- result.add(new Result.fromJson(v));
- });
- }
- }
- Map<String, dynamic> toJson() {
- final Map<String, dynamic> data = new Map<String, dynamic>();
- data['REQ'] = this.rEQ;
- data['REQ_DT'] = this.rEQDT;
- data['RES_DT'] = this.rESDT;
- data['status'] = this.status;
- if (this.result != null) {
- data['result'] = this.result.map((v) => v.toJson()).toList();
- }
- return data;
- }
- }
- class Result {
- String sId;
- String title;
- String section;
- String type;
- String content;
- String charge;
- String recommand;
- String createdAt;
- Poster poster;
- double narationDuration;
- Poster naration;
- Result(
- {this.sId,
- this.title,
- this.section,
- this.type,
- this.content,
- this.charge,
- this.recommand,
- this.createdAt,
- this.poster,
- this.narationDuration,
- this.naration});
- Result.fromJson(Map<String, dynamic> json) {
- sId = json['_id'];
- title = json['title'];
- section = json['section'];
- type = json['type'];
- content = json['content'];
- charge = json['charge'];
- recommand = json['recommand'];
- createdAt = json['createdAt'];
- poster = json['poster'] != null ? new Poster.fromJson(json['poster']) : null;
- narationDuration = json['naration_duration'];
- naration = json['naration'] != null ? new Poster.fromJson(json['naration']) : null;
- }
- Map<String, dynamic> toJson() {
- final Map<String, dynamic> data = new Map<String, dynamic>();
- data['_id'] = this.sId;
- data['title'] = this.title;
- data['section'] = this.section;
- data['type'] = this.type;
- data['content'] = this.content;
- data['charge'] = this.charge;
- data['recommand'] = this.recommand;
- data['createdAt'] = this.createdAt;
- if (this.poster != null) {
- data['poster'] = this.poster.toJson();
- }
- data['naration_duration'] = this.narationDuration;
- if (this.naration != null) {
- data['naration'] = this.naration.toJson();
- }
- return data;
- }
- }
- class Poster {
- String name;
- String filename;
- int length;
- String type;
- Poster({this.name, this.filename, this.length, this.type});
- Poster.fromJson(Map<String, dynamic> json) {
- name = json['name'];
- filename = json['filename'];
- length = json['length'];
- type = json['type'];
- }
- Map<String, dynamic> toJson() {
- final Map<String, dynamic> data = new Map<String, dynamic>();
- data['name'] = this.name;
- data['filename'] = this.filename;
- data['length'] = this.length;
- data['type'] = this.type;
- return data;
- }
- }
|