mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-20 00:56:31 +08:00
42 lines
997 B
Dart
42 lines
997 B
Dart
import 'package:PiliPlus/models/video/note_list/author.dart';
|
|
|
|
class NoteListItemModel {
|
|
int? cvid;
|
|
String? title;
|
|
String? summary;
|
|
String? pubtime;
|
|
String? webUrl;
|
|
String? message;
|
|
Author? author;
|
|
int? likes;
|
|
bool? hasLike;
|
|
|
|
NoteListItemModel({
|
|
this.cvid,
|
|
this.title,
|
|
this.summary,
|
|
this.pubtime,
|
|
this.webUrl,
|
|
this.message,
|
|
this.author,
|
|
this.likes,
|
|
this.hasLike,
|
|
});
|
|
|
|
factory NoteListItemModel.fromJson(Map<String, dynamic> json) =>
|
|
NoteListItemModel(
|
|
cvid: json['cvid'] as int?,
|
|
title: json['title'] as String?,
|
|
summary: json['summary'] as String?,
|
|
pubtime: json['pubtime'] as String?,
|
|
webUrl: json['web_url'] as String?,
|
|
message: json['message'] as String?,
|
|
author: json['author'] == null
|
|
? null
|
|
: Author.fromJson(json['author'] as Map<String, dynamic>),
|
|
likes: json['likes'] as int?,
|
|
hasLike: json['has_like'] as bool?,
|
|
);
|
|
|
|
}
|