Skip to content

Commit

Permalink
修复bug,主要是反序列化的字段
Browse files Browse the repository at this point in the history
  • Loading branch information
hupo376787 committed Oct 14, 2024
1 parent 2961b87 commit 76d0dd8
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 65 deletions.
3 changes: 1 addition & 2 deletions WeiboAlbumDownloader/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
using System.Threading;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Interop;
using System.Windows.Media.Imaging;
using TimeCrontab;
using WeiboAlbumDownloader.Enums;
Expand Down Expand Up @@ -892,7 +891,7 @@ await Task.Run(async () =>


//单个用户结束下载
string info = $"<a href=\"//weibo.com/u/{userId}\">{userId}{nickName}</a>于{DateTime.Now.ToString("HH:mm:ss")}结束下载,程序版本V{currentVersion}<img src=\"{headUrl}\">";
string info = $"{nickName} <a href=\"//weibo.com/u/{userId}\">{userId}{nickName}</a>于{DateTime.Now.ToString("HH:mm:ss")}结束下载,程序版本V{currentVersion}<img src=\"{headUrl}\">";
await PushPlusHelper.SendMessage(settings?.PushPlusToken!, "微博相册下载", info);
SentrySdk.CaptureMessage(info);

Expand Down
126 changes: 63 additions & 63 deletions WeiboAlbumDownloader/Models/WeiboCnMobileModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace WeiboAlbumDownloader.Models
public partial class WeiboCnMobileModel
{
[JsonProperty("ok")]
public long Ok { get; set; }
public long? Ok { get; set; }

[JsonProperty("data")]
public Data? Data { get; set; }
Expand All @@ -26,7 +26,7 @@ public partial class Data
public string? Scheme { get; set; }

[JsonProperty("showAppTips")]
public long ShowAppTips { get; set; }
public long? ShowAppTips { get; set; }
}

public partial class CardlistInfo
Expand All @@ -35,25 +35,25 @@ public partial class CardlistInfo
public string? Containerid { get; set; }

[JsonProperty("v_p")]
public long VP { get; set; }
public long? VP { get; set; }

[JsonProperty("show_style")]
public long ShowStyle { get; set; }
public long? ShowStyle { get; set; }

[JsonProperty("total")]
public long Total { get; set; }
public long? Total { get; set; }

[JsonProperty("autoLoadMoreIndex")]
public long AutoLoadMoreIndex { get; set; }
public long? AutoLoadMoreIndex { get; set; }

[JsonProperty("since_id")]
public long SinceId { get; set; }
public long? SinceId { get; set; }
}

public partial class Card
{
[JsonProperty("card_type")]
public long CardType { get; set; }
public long? CardType { get; set; }

[JsonProperty("profile_type_id")]
public string? ProfileTypeId { get; set; }
Expand Down Expand Up @@ -83,19 +83,19 @@ public partial class Mblog
public string? Mid { get; set; }

[JsonProperty("can_edit")]
public bool CanEdit { get; set; }
public bool? CanEdit { get; set; }

[JsonProperty("text")]
public string? Text { get; set; }

[JsonProperty("textLength")]
public long TextLength { get; set; }
public long? TextLength { get; set; }

[JsonProperty("source")]
public string? Source { get; set; }

[JsonProperty("favorited")]
public bool Favorited { get; set; }
public bool? Favorited { get; set; }

[JsonProperty("pic_ids")]
public List<string>? PicIds { get; set; }
Expand All @@ -110,10 +110,10 @@ public partial class Mblog
public string? OriginalPic { get; set; }

[JsonProperty("is_paid")]
public bool IsPaid { get; set; }
public bool? IsPaid { get; set; }

[JsonProperty("mblog_vip_type")]
public long MblogVipType { get; set; }
public long? MblogVipType { get; set; }

[JsonProperty("user")]
public User? User { get; set; }
Expand All @@ -122,37 +122,37 @@ public partial class Mblog
public RetweetedStatus? RetweetedStatus { get; set; }

[JsonProperty("reposts_count")]
public long RepostsCount { get; set; }
public long? RepostsCount { get; set; }

[JsonProperty("comments_count")]
public long CommentsCount { get; set; }
public long? CommentsCount { get; set; }

[JsonProperty("reprint_cmt_count")]
public long ReprintCmtCount { get; set; }
public long? ReprintCmtCount { get; set; }

[JsonProperty("attitudes_count")]
public long AttitudesCount { get; set; }
public long? AttitudesCount { get; set; }

[JsonProperty("mixed_count")]
public long MixedCount { get; set; }
public long? MixedCount { get; set; }

[JsonProperty("pending_approval_count")]
public long PendingApprovalCount { get; set; }
public long? PendingApprovalCount { get; set; }

[JsonProperty("isLongText")]
public bool IsLongText { get; set; }
public bool? IsLongText { get; set; }

[JsonProperty("show_mlevel")]
public long ShowMlevel { get; set; }
public long? ShowMlevel { get; set; }

[JsonProperty("darwin_tags")]
public List<DarwinTag>? DarwinTags { get; set; }

[JsonProperty("ad_marked")]
public bool AdMarked { get; set; }
public bool? AdMarked { get; set; }

[JsonProperty("mblogtype")]
public long Mblogtype { get; set; }
public long? Mblogtype { get; set; }

[JsonProperty("item_category")]
public string? ItemCategory { get; set; }
Expand All @@ -161,37 +161,37 @@ public partial class Mblog
public string? Rid { get; set; }

[JsonProperty("extern_safe")]
public long ExternSafe { get; set; }
public long? ExternSafe { get; set; }

[JsonProperty("number_display_strategy")]
public NumberDisplayStrategy? NumberDisplayStrategy { get; set; }

[JsonProperty("content_auth")]
public long ContentAuth { get; set; }
public long? ContentAuth { get; set; }

[JsonProperty("is_show_mixed")]
public bool IsShowMixed { get; set; }
public bool? IsShowMixed { get; set; }

[JsonProperty("comment_manage_info")]
public CommentManageInfo? CommentManageInfo { get; set; }

[JsonProperty("pic_num")]
public long PicNum { get; set; }
public long? PicNum { get; set; }

[JsonProperty("mlevel")]
public long Mlevel { get; set; }
public long? Mlevel { get; set; }

[JsonProperty("region_name")]
public string? RegionName { get; set; }

[JsonProperty("region_opt")]
public long RegionOpt { get; set; }
public long? RegionOpt { get; set; }

[JsonProperty("analysis_extra")]
public string? AnalysisExtra { get; set; }

[JsonProperty("mblog_menu_new_style")]
public long MblogMenuNewStyle { get; set; }
public long? MblogMenuNewStyle { get; set; }

[JsonProperty("edit_config")]
public EditConfig? EditConfig { get; set; }
Expand Down Expand Up @@ -219,13 +219,13 @@ public partial class RetweetedStatus
public partial class CommentManageInfo
{
[JsonProperty("comment_permission_type")]
public long CommentPermissionType { get; set; }
public long? CommentPermissionType { get; set; }

[JsonProperty("approval_comment_type")]
public long ApprovalCommentType { get; set; }
public long? ApprovalCommentType { get; set; }

[JsonProperty("comment_sort_type")]
public long CommentSortType { get; set; }
public long? CommentSortType { get; set; }
}

public partial class DarwinTag
Expand All @@ -249,16 +249,16 @@ public partial class DarwinTag
public partial class EditConfig
{
[JsonProperty("edited")]
public bool Edited { get; set; }
public bool? Edited { get; set; }
}

public partial class NumberDisplayStrategy
{
[JsonProperty("apply_scenario_flag")]
public long ApplyScenarioFlag { get; set; }
public long? ApplyScenarioFlag { get; set; }

[JsonProperty("display_text_min_number")]
public long DisplayTextMinNumber { get; set; }
public long? DisplayTextMinNumber { get; set; }

[JsonProperty("display_text")]
public string? DisplayText { get; set; }
Expand Down Expand Up @@ -342,10 +342,10 @@ public partial class PagePic
public string? Url { get; set; }

[JsonProperty("width")]
public int Width { get; set; }
public int? Width { get; set; }

[JsonProperty("height")]
public int Height { get; set; }
public int? Height { get; set; }
}

public partial class Pic
Expand Down Expand Up @@ -375,13 +375,13 @@ public partial class Pic
public partial class PicGeo
{
[JsonProperty("width")]
public long Width { get; set; }
public long? Width { get; set; }

[JsonProperty("height")]
public long Height { get; set; }
public long? Height { get; set; }

[JsonProperty("croped")]
public bool Croped { get; set; }
public bool? Croped { get; set; }
}

public partial class Large
Expand All @@ -393,25 +393,25 @@ public partial class Large
public string? Url { get; set; }

[JsonProperty("geo")]
public LargeGeo? Geo { get; set; }
public object? Geo { get; set; }
}

public partial class LargeGeo
{
[JsonProperty("width")]
public long Width { get; set; }
public long? Width { get; set; }

[JsonProperty("height")]
public long Height { get; set; }
public long? Height { get; set; }

[JsonProperty("croped")]
public bool Croped { get; set; }
public bool? Croped { get; set; }
}

public partial class User
{
[JsonProperty("id")]
public long Id { get; set; }
public long? Id { get; set; }

[JsonProperty("screen_name")]
public string? ScreenName { get; set; }
Expand All @@ -423,19 +423,19 @@ public partial class User
public string? ProfileUrl { get; set; }

[JsonProperty("close_blue_v")]
public bool CloseBlueV { get; set; }
public bool? CloseBlueV { get; set; }

[JsonProperty("description")]
public string? Description { get; set; }

[JsonProperty("follow_me")]
public bool FollowMe { get; set; }
public bool? FollowMe { get; set; }

[JsonProperty("following")]
public bool Following { get; set; }
public bool? Following { get; set; }

[JsonProperty("follow_count")]
public long FollowCount { get; set; }
public long? FollowCount { get; set; }

[JsonProperty("followers_count")]
public string? FollowersCount { get; set; }
Expand All @@ -447,31 +447,31 @@ public partial class User
public string? AvatarHd { get; set; }

[JsonProperty("badge")]
public Dictionary<string, long>? Badge { get; set; }
public Dictionary<string, long?>? Badge { get; set; }

[JsonProperty("statuses_count")]
public long StatusesCount { get; set; }
public long? StatusesCount { get; set; }

[JsonProperty("verified")]
public bool Verified { get; set; }
public bool? Verified { get; set; }

[JsonProperty("verified_type")]
public long VerifiedType { get; set; }
public long? VerifiedType { get; set; }

[JsonProperty("gender")]
public string? Gender { get; set; }

[JsonProperty("mbtype")]
public long Mbtype { get; set; }
public long? Mbtype { get; set; }

[JsonProperty("svip")]
public long Svip { get; set; }
public long? Svip { get; set; }

[JsonProperty("urank")]
public long Urank { get; set; }
public long? Urank { get; set; }

[JsonProperty("mbrank")]
public long Mbrank { get; set; }
public long? Mbrank { get; set; }

[JsonProperty("followers_count_str")]
public string? FollowersCountStr { get; set; }
Expand All @@ -480,21 +480,21 @@ public partial class User
public string? VerifiedReason { get; set; }

[JsonProperty("like")]
public bool Like { get; set; }
public bool? Like { get; set; }

[JsonProperty("like_me")]
public bool LikeMe { get; set; }
public bool? LikeMe { get; set; }

[JsonProperty("special_follow")]
public bool SpecialFollow { get; set; }
public bool? SpecialFollow { get; set; }
}

public partial class Visible
{
[JsonProperty("type")]
public long Type { get; set; }
public long? Type { get; set; }

[JsonProperty("list_id")]
public long ListId { get; set; }
public long? ListId { get; set; }
}
}

0 comments on commit 76d0dd8

Please sign in to comment.