微信小店地址管理

This commit is contained in:
wule committed 2026-05-02 10:15:04 +08:00
1 parent 0c5ebf421e
commit 5ac8eb2571
29 files changed
+1489 -378

No files matched your search

@@ -35,6 +35,7 @@ namespace TemuKJD.WXForms.ProductForms
public partial class WXDBProdUploadForm : BaseForm
{
public CancellationTokenSource cancellationTokenSource { get; set; } = null;
public bool IsWxNotUseSoftwareDefaultAddressOnce { get; set; } = false;
public bool IsLoadComplate { get; set; } = false;
bool isInit = false;
@@ -799,6 +800,45 @@ namespace TemuKJD.WXForms.ProductForms
cancellationTokenSource = new CancellationTokenSource();
Task.Run(() =>
{
if (GlobalConfig.GlobalSettings.IsWxUseSoftwareDefaultAddress == true && !IsWxNotUseSoftwareDefaultAddressOnce &&
lstTemuDBProductSelect.Any(p => p.product_get_type_text != "厂商直采" && p.product_get_type_text != "1688厂家"))
{
if (GlobalConfig.WXShopDefaultAddressList.Any(a => !shopIdLst.Contains(a.shop_id)))
WXShopDefaultAddressListForm.GetShopDefaultAddress();
var addressLst = GlobalConfig.WXShopDefaultAddressList.Where(s => shopIdLst.Contains(s.shop_id)).ToList();
foreach (var add in addressLst)
{
if (!add.isFullAddress)
{
string msg = "未设置店铺售后地址!\r\n" +
"\r\n部分商品无默认售后地址信息,需要设置店铺售后地址,";
if (BaseClass.GroupId == 3)
msg += "\r\n将自动跳转 店铺管理-店铺地址管理 界面设置,";
else
msg += "\r\n请使用主账号进行设置,";
msg += "\r\n或者点击 取消 按钮,本次使用店铺后台默认地址。\r\n" +
"\r\n可在系统设置选项卡更改配置永久使用店铺后台地址。\r\n\r\n";
var rst = BaseMsgForm.ShowConfirm(msg, "注意", FormLevel.LARGE, true);
if (rst.DialogResult == DialogResult.OK)
{
if (BaseClass.GroupId == 3)
Invoke(new Action(() =>
{
btnUpload.Enabled = true;
MainForm.instance.pnlShop_Click(MainForm.instance.pnlShop, null);
WXShopForm.instance.ClickShopAddress();
}));
return;
}
else
{
IsWxNotUseSoftwareDefaultAddressOnce = true;
break;
}
}
}
}
AddProductArr(shopIdLst);
Invoke(new Action(() =>
{
@@ -2362,9 +2402,14 @@ namespace TemuKJD.WXForms.ProductForms
}
}
else
else if(GlobalConfig.GlobalSettings.IsWxUseSoftwareDefaultAddress == true && !IsWxNotUseSoftwareDefaultAddressOnce)
{
if (GlobalConfig.WXShopDefaultAddressList.Any(a => a.shop_id == shop.ShopId))
WXShopDefaultAddressListForm.GetShopDefaultAddress(new List<ShopLoginInfo>() { shop });
var address = GlobalConfig.WXShopDefaultAddressList.First(a => a.shop_id == shop.ShopId);
if (!address.isFullAddress)
return "{\"success\":false,\"draftId\":0,\"status\":\"未上传\",\"errMsg\":\"店铺地址信息获取失败\"}";
afterSaleAddress = JsonHelper.SerializeObject(address);
}
if (!string.IsNullOrEmpty(afterSaleAddress))
+7 -7
View File
@@ -420,7 +420,7 @@ namespace TemuKJD.WXForms.ProductForms
this.cmbCat3.DropDownWidth = 1;
this.cmbCat3.FormattingEnabled = true;
this.cmbCat3.IntegralHeight = false;
this.cmbCat3.Location = new System.Drawing.Point(718, 7);
this.cmbCat3.Location = new System.Drawing.Point(718, 5);
this.cmbCat3.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbCat3.Name = "cmbCat3";
this.cmbCat3.Size = new System.Drawing.Size(146, 25);
@@ -448,7 +448,7 @@ namespace TemuKJD.WXForms.ProductForms
this.cmbCat2.DropDownWidth = 1;
this.cmbCat2.FormattingEnabled = true;
this.cmbCat2.IntegralHeight = false;
this.cmbCat2.Location = new System.Drawing.Point(515, 7);
this.cmbCat2.Location = new System.Drawing.Point(515, 5);
this.cmbCat2.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbCat2.Name = "cmbCat2";
this.cmbCat2.Size = new System.Drawing.Size(146, 25);
@@ -476,7 +476,7 @@ namespace TemuKJD.WXForms.ProductForms
this.cmbCat1.DropDownWidth = 1;
this.cmbCat1.FormattingEnabled = true;
this.cmbCat1.IntegralHeight = false;
this.cmbCat1.Location = new System.Drawing.Point(293, 5);
this.cmbCat1.Location = new System.Drawing.Point(293, 7);
this.cmbCat1.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbCat1.Name = "cmbCat1";
this.cmbCat1.Size = new System.Drawing.Size(146, 25);
@@ -536,7 +536,7 @@ namespace TemuKJD.WXForms.ProductForms
"安全+未校验",
"安全商品",
"未校验"});
this.cmbWxSafe.Location = new System.Drawing.Point(71, 40);
this.cmbWxSafe.Location = new System.Drawing.Point(71, 42);
this.cmbWxSafe.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbWxSafe.Name = "cmbWxSafe";
this.cmbWxSafe.Size = new System.Drawing.Size(146, 25);
@@ -559,7 +559,7 @@ namespace TemuKJD.WXForms.ProductForms
//
this.cmbGroupFilter.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
this.cmbGroupFilter.FormattingEnabled = true;
this.cmbGroupFilter.Location = new System.Drawing.Point(938, 7);
this.cmbGroupFilter.Location = new System.Drawing.Point(938, 5);
this.cmbGroupFilter.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbGroupFilter.Name = "cmbGroupFilter";
this.cmbGroupFilter.Size = new System.Drawing.Size(146, 25);
@@ -580,7 +580,7 @@ namespace TemuKJD.WXForms.ProductForms
"机会商品",
"以图搜品",
"外部数据"});
this.cmbSourceType.Location = new System.Drawing.Point(718, 42);
this.cmbSourceType.Location = new System.Drawing.Point(718, 40);
this.cmbSourceType.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbSourceType.Name = "cmbSourceType";
this.cmbSourceType.Size = new System.Drawing.Size(146, 25);
@@ -610,7 +610,7 @@ namespace TemuKJD.WXForms.ProductForms
"",
"是",
"否"});
this.cmbRelation.Location = new System.Drawing.Point(938, 42);
this.cmbRelation.Location = new System.Drawing.Point(938, 40);
this.cmbRelation.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3);
this.cmbRelation.Name = "cmbRelation";
this.cmbRelation.Size = new System.Drawing.Size(146, 25);