淘宝买手登录 70%

This commit is contained in:
wule committed 2026-09-22 09:51:42 +08:00
1 parent 97278249ae
commit 78ef8eedf3
10 files changed
+1117 -93

No files matched your search

+69 -3
View File
@@ -93,7 +93,8 @@ namespace _29WxOrderWpf
Task.Run(() =>
{
GetPddBuyer();
});
GetTaobaoBuyer();
});
}
}
protected virtual void OnPropertyChanged(string propertyName)
@@ -435,9 +436,74 @@ namespace _29WxOrderWpf
isGetPddBuyer = false;
hasGetPddBuyer = true;
}
#endregion
#endregion
private void lblBalance_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
#region 读取拼多多买手号
public bool isGetTaobaoBuyer = false;
public bool hasGetTaobaoBuyer = false;
/// <summary>
/// 读取拼多多买手
/// </summary>
public void GetTaobaoBuyer()
{
if (isGetTaobaoBuyer)
return;
isGetTaobaoBuyer = true;
try
{
var url = BaseClass.Build29WxObjString("user/get_taobao_buyer");
var data = UserLogin.GetSignaturex();
data += "&page_size=200";
var result = GetHtml.PostUtf8(url, data);
if (string.IsNullOrEmpty(result) || !result.Contains("\"code\":200"))
result = GetHtml.PostUtf8(url, data);
if (result.Contains("\"code\":200"))
{
List<BuyerLoginInfo> loginInfoLst = JsonHelper.DeserializeJsonToList<BuyerLoginInfo>(JsonHelper.JObjectParse(result)["data"].ParseToString());
foreach (var buyer in GlobalConfig.TaobaoBuyerLoginList.Where(bu => !loginInfoLst.Any(b => b.buyer_id == bu.buyer_id)).ToList())
{
Dispatcher.Invoke(new Action(() => { GlobalConfig.TaobaoBuyerLoginList.Remove(buyer); }));
}
foreach (var b in loginInfoLst)
{
Dispatcher.Invoke(new Action(() =>
{
var buyer = GlobalConfig.TaobaoBuyerLoginList.FirstOrDefault(bu => bu.buyer_id == b.buyer_id);
if (buyer == null)
GlobalConfig.TaobaoBuyerLoginList.Add(b);
else
{
buyer.add_time = b.add_time;
buyer.buyer_id = b.buyer_id;
buyer.buyer_name = b.buyer_name;
buyer.buyer_nick = b.buyer_nick;
buyer.cookie = b.cookie;
buyer.mdy_time = b.mdy_time;
buyer.notes = b.notes;
buyer.status = b.status;
buyer.user_name = b.user_name;
}
}));
}
}
}
catch
{
}
isGetTaobaoBuyer = false;
hasGetTaobaoBuyer = true;
}
#endregion
private void lblBalance_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
{
WXGetBalanceQrCodeForm balanceQrCodeForm = new WXGetBalanceQrCodeForm(StartUp.UpdateBalance);
balanceQrCodeForm.ShowDialog();