-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2.资源文件合并至20211117 3.重新提交1.1.3
- Loading branch information
jay
committed
Jan 4, 2022
1 parent
8b19169
commit 485df74
Showing
16 changed files
with
618 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"todo-tree.tree.showBadges": true, | ||
"todo-tree.tree.showCountsInTree": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
enum UpdateResult { | ||
error, | ||
unnecessary, | ||
hasNewAppVersion, | ||
hasNewDataVersion, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
// To parse this JSON data, do | ||
// | ||
// final updateInfo = updateInfoFromJson(jsonString); | ||
|
||
import 'dart:convert'; | ||
|
||
UpdateResp updateInfoFromJson(String str) => | ||
UpdateResp.fromJson(json.decode(str)); | ||
|
||
String updateInfoToJson(UpdateResp data) => json.encode(data.toJson()); | ||
|
||
class UpdateResp { | ||
UpdateResp({ | ||
this.results = const [], | ||
}); | ||
|
||
List<UpdateInfo> results; | ||
|
||
factory UpdateResp.fromJson(Map<String, dynamic> json) => UpdateResp( | ||
results: json["results"] == null | ||
? const [] | ||
: List<UpdateInfo>.from( | ||
json["results"].map((x) => UpdateInfo.fromJson(x))), | ||
); | ||
|
||
Map<String, dynamic> toJson() => { | ||
"results": List<dynamic>.from(results.map((x) => x.toJson())), | ||
}; | ||
} | ||
|
||
class UpdateInfo { | ||
UpdateInfo({ | ||
this.alias, | ||
this.checksum, | ||
this.createdAt, | ||
required this.id, | ||
this.info, | ||
required this.minimalVersion, | ||
this.objectId, | ||
required this.serverVersion, | ||
required this.type, | ||
this.updatedAt, | ||
this.url, | ||
}); | ||
String? alias; | ||
String? checksum; | ||
DateTime? createdAt; | ||
int id; | ||
String? info; | ||
int minimalVersion; | ||
String? objectId; | ||
int serverVersion; | ||
int type; | ||
DateTime? updatedAt; | ||
String? url; | ||
|
||
factory UpdateInfo.fromJson(Map<String, dynamic> json) => UpdateInfo( | ||
alias: json["alias"], | ||
checksum: json["checksum"], | ||
createdAt: json["createdAt"] == null | ||
? null | ||
: DateTime.parse(json["createdAt"]), | ||
id: json["id"], | ||
info: json["info"], | ||
minimalVersion: json["minimal_version"], | ||
objectId: json["objectId"], | ||
serverVersion: json["server_version"], | ||
type: json["type"], | ||
updatedAt: json["updatedAt"] == null | ||
? null | ||
: DateTime.parse(json["updatedAt"]), | ||
url: json["url"], | ||
); | ||
|
||
Map<String, dynamic> toJson() => { | ||
"alias": alias, | ||
"checksum": checksum, | ||
"createdAt": createdAt == null ? null : createdAt!.toIso8601String(), | ||
"id": id, | ||
"info": info, | ||
"objectId": objectId, | ||
"minimal_version": minimalVersion, | ||
"server_version": serverVersion, | ||
"type": type, | ||
"updatedAt": updatedAt == null ? null : updatedAt!.toIso8601String(), | ||
"url": url, | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.