自动批量登录

This commit is contained in:
wule committed 2026-11-09 16:54:40 +08:00
1 parent 82adb510be
commit 6754342366
4 files changed
+1346 -1072

No files matched your search

@@ -34,6 +34,8 @@ namespace TemuKJD.WXForms.ShopForms
{
public static WXShopMultiLoginForm shopMultiLoginFormInstance { get; set; } = null;
public bool isAutoLogin = false;
public int CloseAfterSecond { get; set; }
public EnumOpenType openType = EnumOpenType.manage;
public bool isMultiLogin = false;
@@ -100,6 +102,26 @@ namespace TemuKJD.WXForms.ShopForms
{
BaseMsgForm.ShowError("切换列表解析失败!");
}
if (isAutoLogin)
{
Thread.Sleep(Randomx.GetId(2500, 3500));
while(this.cefWebBrowser == null || this.cefWebBrowser.IsLoading)
{
if (!this.Created)
return;
Thread.Sleep(100);
continue;
}
if (!this.Created)
return;
Invoke(() =>
{
btnRefreshNum_Click(null, null);
});
}
});
}
@@ -416,12 +438,18 @@ namespace TemuKJD.WXForms.ShopForms
Thread.Sleep(Randomx.GetId(2500, 5000));
}
if (!this.Created)
return;
Invoke(new Action(() =>
{
btnRefreshNum.Enabled = true;
pbLoading.Visible = false;
BaseMsgForm.ShowInfo("操作完成!");
if (this.isAutoLogin)
this.Close();
else
BaseMsgForm.ShowInfo("操作完成!");
}));
});
}
@@ -448,8 +476,15 @@ namespace TemuKJD.WXForms.ShopForms
string refere = "https://store.weixin.qq.com/shop/home";
var result = WXHttpResponseBLL.WeiXinGetResponse(shop, url, refere);
return result;
}
}
}
public static async Task<string> getShopSwitchListAsync(ShopLoginInfo shop)
{
string url = "https://store.weixin.qq.com/shop-faas/mmecnodelogin/session/getShopSwitchList?token=&lang=zh_CN";
string refere = "https://store.weixin.qq.com/shop/home";
var result = await WXHttpResponseBLL.WeiXinGetResponseAsync(shop, url, refere);
return result;
}
}
public class ShopSwitchInfo
{