2024-04-10 12:56:06 +05:30
|
|
|
class ContentBytesModel {
|
|
|
|
|
String? status;
|
|
|
|
|
int? statusCode;
|
|
|
|
|
String? message;
|
|
|
|
|
Data? data;
|
|
|
|
|
|
|
|
|
|
ContentBytesModel({this.status, this.statusCode, this.message, this.data});
|
|
|
|
|
|
|
|
|
|
ContentBytesModel.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
status = json['status'];
|
|
|
|
|
statusCode = json['status_code'];
|
|
|
|
|
message = json['message'];
|
|
|
|
|
data = json['data'] != null ? Data.fromJson(json['data']) : null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['status'] = status;
|
|
|
|
|
data['status_code'] = statusCode;
|
|
|
|
|
data['message'] = message;
|
|
|
|
|
if (this.data != null) {
|
|
|
|
|
data['data'] = this.data!.toJson();
|
|
|
|
|
}
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Data {
|
|
|
|
|
List<Video>? video;
|
|
|
|
|
List<Audio>? audio;
|
|
|
|
|
List<Read>? read;
|
2024-05-07 19:27:23 +05:30
|
|
|
List<NewReleaseAudio>? newReleaseAudio;
|
|
|
|
|
List<MostReads>? mostReads;
|
2024-04-10 12:56:06 +05:30
|
|
|
|
2024-05-07 19:27:23 +05:30
|
|
|
Data({
|
|
|
|
|
this.video,
|
|
|
|
|
this.audio,
|
|
|
|
|
this.read,
|
|
|
|
|
this.newReleaseAudio,
|
|
|
|
|
this.mostReads,
|
|
|
|
|
});
|
2024-04-10 12:56:06 +05:30
|
|
|
|
|
|
|
|
Data.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
if (json['video'] != null) {
|
|
|
|
|
video = <Video>[];
|
|
|
|
|
json['video'].forEach((v) {
|
|
|
|
|
video!.add(Video.fromJson(v));
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (json['audio'] != null) {
|
|
|
|
|
audio = <Audio>[];
|
|
|
|
|
json['audio'].forEach((v) {
|
|
|
|
|
audio!.add(Audio.fromJson(v));
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (json['read'] != null) {
|
|
|
|
|
read = <Read>[];
|
|
|
|
|
json['read'].forEach((v) {
|
|
|
|
|
read!.add(Read.fromJson(v));
|
|
|
|
|
});
|
|
|
|
|
}
|
2024-05-07 19:27:23 +05:30
|
|
|
if (json['new_release_audio'] != null) {
|
|
|
|
|
newReleaseAudio = <NewReleaseAudio>[];
|
|
|
|
|
json['new_release_audio'].forEach((v) {
|
|
|
|
|
newReleaseAudio!.add(NewReleaseAudio.fromJson(v));
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (json['most_reads'] != null) {
|
|
|
|
|
mostReads = <MostReads>[];
|
|
|
|
|
json['most_reads'].forEach((v) {
|
|
|
|
|
mostReads!.add(MostReads.fromJson(v));
|
|
|
|
|
});
|
|
|
|
|
}
|
2024-04-10 12:56:06 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
if (video != null) {
|
|
|
|
|
data['video'] = video!.map((v) => v.toJson()).toList();
|
|
|
|
|
}
|
|
|
|
|
if (audio != null) {
|
|
|
|
|
data['audio'] = audio!.map((v) => v.toJson()).toList();
|
|
|
|
|
}
|
|
|
|
|
if (read != null) {
|
|
|
|
|
data['read'] = read!.map((v) => v.toJson()).toList();
|
|
|
|
|
}
|
2024-05-07 19:27:23 +05:30
|
|
|
if (newReleaseAudio != null) {
|
|
|
|
|
data['new_release_audio'] =
|
|
|
|
|
newReleaseAudio!.map((v) => v.toJson()).toList();
|
|
|
|
|
}
|
|
|
|
|
if (mostReads != null) {
|
|
|
|
|
data['most_reads'] = mostReads!.map((v) => v.toJson()).toList();
|
|
|
|
|
}
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class MostReads {
|
|
|
|
|
int? id;
|
|
|
|
|
int? contentByteReadXid;
|
|
|
|
|
int? clickCount;
|
|
|
|
|
int? isActive;
|
|
|
|
|
String? createdAt;
|
|
|
|
|
ContentByteData? contentByteData;
|
|
|
|
|
|
|
|
|
|
MostReads(
|
|
|
|
|
{this.id,
|
|
|
|
|
this.contentByteReadXid,
|
|
|
|
|
this.clickCount,
|
|
|
|
|
this.isActive,
|
|
|
|
|
this.createdAt,
|
|
|
|
|
this.contentByteData});
|
|
|
|
|
|
|
|
|
|
MostReads.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
id = json['id'];
|
|
|
|
|
contentByteReadXid = json['content_byte_read_xid'];
|
|
|
|
|
clickCount = json['click_count'];
|
|
|
|
|
isActive = json['is_active'];
|
|
|
|
|
createdAt = json['created_at'];
|
|
|
|
|
contentByteData = json['content_byte_data'] != null
|
|
|
|
|
? ContentByteData.fromJson(json['content_byte_data'])
|
|
|
|
|
: null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['id'] = id;
|
|
|
|
|
data['content_byte_read_xid'] = contentByteReadXid;
|
|
|
|
|
data['click_count'] = clickCount;
|
|
|
|
|
data['is_active'] = isActive;
|
|
|
|
|
data['created_at'] = createdAt;
|
|
|
|
|
if (contentByteData != null) {
|
|
|
|
|
data['content_byte_data'] = contentByteData!.toJson();
|
|
|
|
|
}
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class ContentByteData {
|
|
|
|
|
int? id;
|
|
|
|
|
String? title;
|
|
|
|
|
String? file;
|
|
|
|
|
int? categoryId;
|
|
|
|
|
String? image;
|
|
|
|
|
String? isActive;
|
|
|
|
|
String? createdAt;
|
|
|
|
|
|
|
|
|
|
ContentByteData(
|
|
|
|
|
{this.id,
|
|
|
|
|
this.title,
|
|
|
|
|
this.file,
|
|
|
|
|
this.categoryId,
|
|
|
|
|
this.image,
|
|
|
|
|
this.isActive,
|
|
|
|
|
this.createdAt});
|
|
|
|
|
|
|
|
|
|
ContentByteData.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
id = json['id'];
|
|
|
|
|
title = json['title'];
|
|
|
|
|
file = json['file'];
|
|
|
|
|
categoryId = json['category_id'];
|
|
|
|
|
image = json['image'];
|
|
|
|
|
isActive = json['is_active'];
|
|
|
|
|
createdAt = json['created_at'];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['id'] = id;
|
|
|
|
|
data['title'] = title;
|
|
|
|
|
data['file'] = file;
|
|
|
|
|
data['category_id'] = categoryId;
|
|
|
|
|
data['image'] = image;
|
|
|
|
|
data['is_active'] = isActive;
|
|
|
|
|
data['created_at'] = createdAt;
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class NewReleaseAudio {
|
|
|
|
|
int? id;
|
|
|
|
|
String? title;
|
|
|
|
|
String? file;
|
|
|
|
|
int? categoryId;
|
|
|
|
|
String? image;
|
|
|
|
|
String? isActive;
|
|
|
|
|
String? createdAt;
|
|
|
|
|
String? formattedCreatedAt;
|
|
|
|
|
String? fullCreatedAt;
|
|
|
|
|
|
|
|
|
|
NewReleaseAudio(
|
|
|
|
|
{this.id,
|
|
|
|
|
this.title,
|
|
|
|
|
this.file,
|
|
|
|
|
this.categoryId,
|
|
|
|
|
this.image,
|
|
|
|
|
this.isActive,
|
|
|
|
|
this.createdAt,
|
|
|
|
|
this.formattedCreatedAt,
|
|
|
|
|
this.fullCreatedAt});
|
|
|
|
|
|
|
|
|
|
NewReleaseAudio.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
id = json['id'];
|
|
|
|
|
title = json['title'];
|
|
|
|
|
file = json['file'];
|
|
|
|
|
categoryId = json['category_id'];
|
|
|
|
|
image = json['image'];
|
|
|
|
|
isActive = json['is_active'];
|
|
|
|
|
createdAt = json['created_at'];
|
|
|
|
|
formattedCreatedAt = json['formatted_created_at'];
|
|
|
|
|
fullCreatedAt = json['full_created_at'];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['id'] = id;
|
|
|
|
|
data['title'] = title;
|
|
|
|
|
data['file'] = file;
|
|
|
|
|
data['category_id'] = categoryId;
|
|
|
|
|
data['image'] = image;
|
|
|
|
|
data['is_active'] = isActive;
|
|
|
|
|
data['created_at'] = createdAt;
|
|
|
|
|
data['formatted_created_at'] = formattedCreatedAt;
|
|
|
|
|
data['full_created_at'] = fullCreatedAt;
|
2024-04-10 12:56:06 +05:30
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Video {
|
|
|
|
|
int? id;
|
|
|
|
|
String? contentType;
|
|
|
|
|
String? title;
|
|
|
|
|
String? description;
|
|
|
|
|
String? tags;
|
|
|
|
|
String? file;
|
|
|
|
|
int? categoryId;
|
|
|
|
|
String? image;
|
2024-05-07 19:27:23 +05:30
|
|
|
String? createdAt;
|
|
|
|
|
String? link;
|
2024-04-10 12:56:06 +05:30
|
|
|
String? isActive;
|
|
|
|
|
|
|
|
|
|
Video({
|
|
|
|
|
this.id,
|
|
|
|
|
this.contentType,
|
|
|
|
|
this.title,
|
|
|
|
|
this.description,
|
|
|
|
|
this.tags,
|
|
|
|
|
this.file,
|
2024-05-07 19:27:23 +05:30
|
|
|
this.createdAt,
|
|
|
|
|
this.link,
|
2024-04-10 12:56:06 +05:30
|
|
|
this.categoryId,
|
|
|
|
|
this.image,
|
|
|
|
|
this.isActive,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Video.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
id = json['id'];
|
|
|
|
|
contentType = json['content_type'];
|
|
|
|
|
title = json['title'];
|
2024-05-07 19:27:23 +05:30
|
|
|
link = json["link"];
|
2024-04-10 12:56:06 +05:30
|
|
|
description = json['description'];
|
2024-05-07 19:27:23 +05:30
|
|
|
createdAt = json['created_at'];
|
2024-04-10 12:56:06 +05:30
|
|
|
tags = json['tags'];
|
|
|
|
|
file = json['file'];
|
|
|
|
|
categoryId = json['category_id'];
|
|
|
|
|
image = json['image'];
|
|
|
|
|
isActive = json['is_active'];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['id'] = id;
|
|
|
|
|
data['content_type'] = contentType;
|
|
|
|
|
data['title'] = title;
|
|
|
|
|
data['description'] = description;
|
|
|
|
|
data['tags'] = tags;
|
|
|
|
|
data['file'] = file;
|
|
|
|
|
data['category_id'] = categoryId;
|
|
|
|
|
data['image'] = image;
|
|
|
|
|
data['is_active'] = isActive;
|
|
|
|
|
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Audio {
|
|
|
|
|
int? id;
|
|
|
|
|
String? contentType;
|
|
|
|
|
String? title;
|
|
|
|
|
String? description;
|
|
|
|
|
String? tags;
|
|
|
|
|
String? file;
|
2024-05-07 19:27:23 +05:30
|
|
|
String? link;
|
2024-04-10 12:56:06 +05:30
|
|
|
int? categoryId;
|
|
|
|
|
String? image;
|
|
|
|
|
String? isActive;
|
|
|
|
|
|
|
|
|
|
Audio({
|
|
|
|
|
this.id,
|
|
|
|
|
this.contentType,
|
|
|
|
|
this.title,
|
|
|
|
|
this.description,
|
|
|
|
|
this.tags,
|
|
|
|
|
this.file,
|
|
|
|
|
this.categoryId,
|
2024-05-07 19:27:23 +05:30
|
|
|
this.link,
|
2024-04-10 12:56:06 +05:30
|
|
|
this.image,
|
|
|
|
|
this.isActive,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Audio.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
id = json['id'];
|
|
|
|
|
contentType = json['content_type'];
|
|
|
|
|
title = json['title'];
|
|
|
|
|
description = json['description'];
|
|
|
|
|
tags = json['tags'];
|
2024-05-07 19:27:23 +05:30
|
|
|
link = json['link'];
|
2024-04-10 12:56:06 +05:30
|
|
|
file = json['file'];
|
|
|
|
|
categoryId = json['category_id'];
|
|
|
|
|
image = json['image'];
|
|
|
|
|
isActive = json['is_active'];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['id'] = id;
|
|
|
|
|
data['content_type'] = contentType;
|
|
|
|
|
data['title'] = title;
|
|
|
|
|
data['description'] = description;
|
|
|
|
|
data['tags'] = tags;
|
|
|
|
|
data['file'] = file;
|
|
|
|
|
data['category_id'] = categoryId;
|
|
|
|
|
data['image'] = image;
|
|
|
|
|
data['is_active'] = isActive;
|
|
|
|
|
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Read {
|
|
|
|
|
int? id;
|
|
|
|
|
String? contentType;
|
|
|
|
|
String? title;
|
|
|
|
|
String? description;
|
|
|
|
|
String? tags;
|
|
|
|
|
String? file;
|
|
|
|
|
int? categoryId;
|
|
|
|
|
String? image;
|
|
|
|
|
String? isActive;
|
|
|
|
|
|
|
|
|
|
Read({
|
|
|
|
|
this.id,
|
|
|
|
|
this.contentType,
|
|
|
|
|
this.title,
|
|
|
|
|
this.description,
|
|
|
|
|
this.tags,
|
|
|
|
|
this.file,
|
|
|
|
|
this.categoryId,
|
|
|
|
|
this.image,
|
|
|
|
|
this.isActive,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Read.fromJson(Map<String, dynamic> json) {
|
|
|
|
|
id = json['id'];
|
|
|
|
|
contentType = json['content_type'];
|
|
|
|
|
title = json['title'];
|
|
|
|
|
description = json['description'];
|
|
|
|
|
tags = json['tags'];
|
|
|
|
|
file = json['file'];
|
|
|
|
|
categoryId = json['category_id'];
|
|
|
|
|
image = json['image'];
|
|
|
|
|
isActive = json['is_active'];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
|
|
|
data['id'] = id;
|
|
|
|
|
data['content_type'] = contentType;
|
|
|
|
|
data['title'] = title;
|
|
|
|
|
data['description'] = description;
|
|
|
|
|
data['tags'] = tags;
|
|
|
|
|
data['file'] = file;
|
|
|
|
|
data['category_id'] = categoryId;
|
|
|
|
|
data['image'] = image;
|
|
|
|
|
data['is_active'] = isActive;
|
|
|
|
|
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
|
}
|