拼多多活动上货尝试
This commit is contained in:
1 parent
0c97f2481b
commit
90ead052f3
9 files changed
+252
-224
No files matched your search
@@ -27,7 +27,7 @@ namespace AllBase
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 版本ID
|
/// 版本ID
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static int VersionCount = 767;
|
public static int VersionCount = 768;
|
||||||
//public static int VersionCount = 613;
|
//public static int VersionCount = 613;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -712,7 +712,7 @@ namespace KJD_Web.BLL
|
|||||||
|
|
||||||
string where = "";
|
string where = "";
|
||||||
if (!isAdmin || is_client_jit)
|
if (!isAdmin || is_client_jit)
|
||||||
where += " AND (s.user_name='" + user_name + "' or s.sub_user_name='" + user_name + "')";
|
where += " AND (s.user_name='" + user_name + "' or s.sub_user_name like '%" + user_name + "%')";
|
||||||
if (!string.IsNullOrEmpty(operate_sub_sa_name))
|
if (!string.IsNullOrEmpty(operate_sub_sa_name))
|
||||||
{
|
{
|
||||||
where += " AND s.operate_sub_sa_name = '" + operate_sub_sa_name + "'";
|
where += " AND s.operate_sub_sa_name = '" + operate_sub_sa_name + "'";
|
||||||
|
|||||||
@@ -604,7 +604,7 @@ namespace KJD_Web.BLL
|
|||||||
|
|
||||||
string where = "";
|
string where = "";
|
||||||
if (!isAdmin)
|
if (!isAdmin)
|
||||||
where += " and (s.user_name='" + user_name + "' or s.sub_user_name ='" + user_name + "')";
|
where += " and (s.user_name='" + user_name + "' or s.sub_user_name like '%" + user_name + "%')";
|
||||||
if (!string.IsNullOrEmpty(operate_sub_sa_name))
|
if (!string.IsNullOrEmpty(operate_sub_sa_name))
|
||||||
{
|
{
|
||||||
where += " and s.operate_sub_sa_name = '" + operate_sub_sa_name + "'";
|
where += " and s.operate_sub_sa_name = '" + operate_sub_sa_name + "'";
|
||||||
|
|||||||
@@ -252,7 +252,8 @@ namespace TemuKJD.KJDForms.ProductForms.TemuJitSubForms
|
|||||||
j_template_edit.Add("punish_time", wait_task.punish_time);
|
j_template_edit.Add("punish_time", wait_task.punish_time);
|
||||||
j_template_edit.Add("sale_effect_info", JObject.Parse(JsonHelper.SerializeObject(wait_task.sale_effect_info)));
|
j_template_edit.Add("sale_effect_info", JObject.Parse(JsonHelper.SerializeObject(wait_task.sale_effect_info)));
|
||||||
j_template_edit.Add("rep_detail_list", new JArray());
|
j_template_edit.Add("rep_detail_list", new JArray());
|
||||||
var rep_detail = temp.rep_detail_list.FirstOrDefault(r => r.rep_name == cmbEUPerson.Text.Trim());
|
var rep_detail = temp.rep_detail_list.FirstOrDefault(r => r.rep_name.Trim() == cmbEUPerson.Text.Trim());
|
||||||
|
//var rep_detail = temp.rep_detail_list.FirstOrDefault(r => r.rep_name == cmbEUPerson.Text); // 欧盟负责人可能有空格,不要trim或者两边都trim
|
||||||
rep_detail_param rep_param = new rep_detail_param { rep_id = rep_detail?.rep_id, rep_name = rep_detail?.rep_name };
|
rep_detail_param rep_param = new rep_detail_param { rep_id = rep_detail?.rep_id, rep_name = rep_detail?.rep_name };
|
||||||
(j_template_edit["rep_detail_list"] as JArray).Add(JObject.Parse(JsonHelper.SerializeObject(rep_param)));
|
(j_template_edit["rep_detail_list"] as JArray).Add(JObject.Parse(JsonHelper.SerializeObject(rep_param)));
|
||||||
}
|
}
|
||||||
@@ -266,6 +267,7 @@ namespace TemuKJD.KJDForms.ProductForms.TemuJitSubForms
|
|||||||
j_template_edit.Add("sale_effect_info", JObject.Parse(JsonHelper.SerializeObject(wait_task.sale_effect_info)));
|
j_template_edit.Add("sale_effect_info", JObject.Parse(JsonHelper.SerializeObject(wait_task.sale_effect_info)));
|
||||||
j_template_edit.Add("rep_detail_list", new JArray());
|
j_template_edit.Add("rep_detail_list", new JArray());
|
||||||
var rep_detail = temp.rep_detail_list.FirstOrDefault(r => r.rep_name.Trim() == cmbMakerInfo.Text.Trim());
|
var rep_detail = temp.rep_detail_list.FirstOrDefault(r => r.rep_name.Trim() == cmbMakerInfo.Text.Trim());
|
||||||
|
//var rep_detail = temp.rep_detail_list.FirstOrDefault(r => r.rep_name == cmbMakerInfo.Text); // 制造商信息可能有空格,不要trim或者两边都trim
|
||||||
rep_detail_param rep_param = new rep_detail_param { rep_id = rep_detail?.rep_id, rep_name = rep_detail?.rep_name };
|
rep_detail_param rep_param = new rep_detail_param { rep_id = rep_detail?.rep_id, rep_name = rep_detail?.rep_name };
|
||||||
(j_template_edit["rep_detail_list"] as JArray).Add(JObject.Parse(JsonHelper.SerializeObject(rep_param)));
|
(j_template_edit["rep_detail_list"] as JArray).Add(JObject.Parse(JsonHelper.SerializeObject(rep_param)));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1866,7 +1866,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pddUploadRule.IsSignActivity && 1 == 1) // 在图片上画线,没有效果
|
if (pddUploadRule.IsSignActivity && 1 == 1) // 每张sku图都单独上传,(并在图片上画线,没有效果)
|
||||||
{
|
{
|
||||||
if (!new_Sku_Img_Dic.Keys.Contains(skuParam.thumb_url))
|
if (!new_Sku_Img_Dic.Keys.Contains(skuParam.thumb_url))
|
||||||
{
|
{
|
||||||
@@ -1875,7 +1875,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
var imageBg = new Bitmap(image.Width, image.Height);
|
var imageBg = new Bitmap(image.Width, image.Height);
|
||||||
if (!string.IsNullOrEmpty(getImgError) || image == null)
|
if (!string.IsNullOrEmpty(getImgError) || image == null)
|
||||||
{
|
{
|
||||||
return "设置升级款sku失败 图片上传失败";
|
return "设置sku失败 图片上传失败";
|
||||||
}
|
}
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@@ -1888,9 +1888,6 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
//g.DrawLine(pen, Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height), Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height));
|
//g.DrawLine(pen, Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height), Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height));
|
||||||
//pen = new Pen(Color.Green);
|
//pen = new Pen(Color.Green);
|
||||||
//g.DrawLine(pen, Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height), Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height));
|
//g.DrawLine(pen, Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height), Randomx.GetId(0, image.Width), Randomx.GetId(0, image.Height));
|
||||||
////var imageUp = pbUpgradeVersion.Image;
|
|
||||||
////// 将升级版图片绘制到sku图片上
|
|
||||||
////g.DrawImage(imageUp, new Rectangle(0, 0, image.Width, image.Height), 0, 0, imageUp.Width, imageUp.Height, GraphicsUnit.Pixel);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
@@ -1903,12 +1900,12 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
var error = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "error_msg");
|
var error = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "error_msg");
|
||||||
if (string.IsNullOrEmpty(error))
|
if (string.IsNullOrEmpty(error))
|
||||||
error = uploadUpgradeSkuImgRst;
|
error = uploadUpgradeSkuImgRst;
|
||||||
return "上传升级款sku图片失败 " + error;
|
return "上传sku图片失败 " + error;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var upgrid_thumb_url = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "url");
|
var new_thumb_url = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "url");
|
||||||
new_Sku_Img_Dic[skuParam.thumb_url] = upgrid_thumb_url;
|
new_Sku_Img_Dic[skuParam.thumb_url] = new_thumb_url;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
skuParam.thumb_url = new_Sku_Img_Dic[skuParam.thumb_url];
|
skuParam.thumb_url = new_Sku_Img_Dic[skuParam.thumb_url];
|
||||||
@@ -2423,24 +2420,11 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
string fakeImgUrl = "";
|
string fakeImgUrl = "";
|
||||||
if (1 == 1) // 商品先上高价sku图,参加活动后改回sku原图
|
if (1 == 1) // 商品先上高价sku图,参加活动后改回sku原图
|
||||||
{
|
{
|
||||||
//fakeImgUrlDefault = "https://img.pddpic.com/mms-goods-image/2025-09-23/a82199c7-eec1-40bc-a95a-a643f5ebf934.jpeg.a.jpeg"; // 不值钱的鞋
|
|
||||||
//https://img.pddpic.com/mms-goods-image/2025-09-23/aa714d65-08ba-437b-a62a-429b6f4ad061.jpeg.a.jpeg?imageView2/2/w/1700/q/85 // 图片缩略图格式
|
|
||||||
//https://img.pddpic.com/open-gw/2024-11-27/8c4b66e0-b80d-4a8f-bbab-9bb0d8adf015.jpeg //机会商品主图
|
|
||||||
//https://img.pddpic.com/open-gw/2025-08-13/97a2999c-0f60-47fb-a62f-21ecc0765cb9.jpeg //机会商品主图
|
|
||||||
List<string> skuImgStrLst = new List<string>()
|
List<string> skuImgStrLst = new List<string>()
|
||||||
{
|
{
|
||||||
"https://img.pddpic.com/mms-goods-image/2025-10-09/fb24e835-e588-4570-b772-ad7acdf90fdf.jpeg.a.jpeg",
|
"https://img.pddpic.com/mms-goods-image/2025-10-09/fb24e835-e588-4570-b772-ad7acdf90fdf.jpeg.a.jpeg",
|
||||||
"https://img.pddpic.com/mms-goods-image/2025-10-09/d743cdc2-1a4b-4e3b-ada7-8f857fe49d26.jpeg.a.jpeg",
|
"https://img.pddpic.com/mms-goods-image/2025-10-09/d743cdc2-1a4b-4e3b-ada7-8f857fe49d26.jpeg.a.jpeg",
|
||||||
"https://img.pddpic.com/mms-goods-image/2025-10-09/b63f2256-fe5c-452b-91cd-688e06f3a944.jpeg.a.jpeg",
|
"https://img.pddpic.com/mms-goods-image/2025-10-09/b63f2256-fe5c-452b-91cd-688e06f3a944.jpeg.a.jpeg",
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/e7b614a6-07fb-4d49-adf5-6f48e9afd36f.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/35151a9e-962e-4490-9d61-3477c090d29f.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/7c1d1098-d348-460e-b663-e19c960aede8.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/aa714d65-08ba-437b-a62a-429b6f4ad061.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/faaca32a-aae2-4ae5-85c9-44be1489208f.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/df8fa493-e8e2-4e07-8e8a-db30d10d5c9c.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/1b98757c-efb0-4a4e-8031-025056310c9f.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/c0e083d2-2e05-4b3d-9543-bcad49a17873.jpeg.a.jpeg",
|
|
||||||
//"https://img.pddpic.com/mms-goods-image/2025-09-23/7ea07200-05da-45b9-9e9a-fba4d46cfec9.jpeg.a.jpeg",
|
|
||||||
};
|
};
|
||||||
|
|
||||||
string img_type = "鞋(不含拖鞋)";
|
string img_type = "鞋(不含拖鞋)";
|
||||||
@@ -2501,8 +2485,9 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
}
|
}
|
||||||
if (string.IsNullOrEmpty(fakeImgUrl))
|
if (string.IsNullOrEmpty(fakeImgUrl))
|
||||||
{
|
{
|
||||||
int fakeimgIndex = Randomx.GetId(skuImgStrLst.Count);
|
//int fakeimgIndex = Randomx.GetId(skuImgStrLst.Count);
|
||||||
fakeImgUrl = skuImgStrLst[fakeimgIndex];
|
//fakeImgUrl = skuImgStrLst[fakeimgIndex];
|
||||||
|
return "SKU图获取失败";
|
||||||
}
|
}
|
||||||
dbProd.sku_img_replace_url = fakeImgUrl;
|
dbProd.sku_img_replace_url = fakeImgUrl;
|
||||||
}
|
}
|
||||||
@@ -2529,14 +2514,14 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
prodParamHighPrice.skus.Add(skuParam);
|
prodParamHighPrice.skus.Add(skuParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
#region 添加升级版sku
|
#region 活动加价商品添加升级版sku
|
||||||
if (pddUploadRule.IsUpgradeVersion)
|
if (pddUploadRule.IsUpgradeVersion)
|
||||||
{
|
{
|
||||||
List<sku_param> upgrade_Sku_Lst = new List<sku_param>();
|
List<sku_param> upgrade_sku_lst = new List<sku_param>();
|
||||||
foreach (var skuParam in prodParamHighPrice.skus)
|
foreach (var skuParam in prodParamHighPrice.skus)
|
||||||
{
|
{
|
||||||
var skuParamUpgrade = JsonHelper.DeserializeJsonToObject<sku_param>(JsonHelper.SerializeObject(skuParam));
|
var skuParamUpgrade = JsonHelper.DeserializeJsonToObject<sku_param>(JsonHelper.SerializeObject(skuParam));
|
||||||
upgrade_Sku_Lst.Add(skuParamUpgrade);
|
upgrade_sku_lst.Add(skuParamUpgrade);
|
||||||
|
|
||||||
skuParamUpgrade.multi_price += (txtUpgradeVersionAddPrice.Text.ParseToDecimal() * 100).ParseToInt();
|
skuParamUpgrade.multi_price += (txtUpgradeVersionAddPrice.Text.ParseToDecimal() * 100).ParseToInt();
|
||||||
skuParamUpgrade.price += (txtUpgradeVersionAddPrice.Text.ParseToDecimal() * 100).ParseToInt();
|
skuParamUpgrade.price += (txtUpgradeVersionAddPrice.Text.ParseToDecimal() * 100).ParseToInt();
|
||||||
@@ -2606,21 +2591,21 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var upgrid_thumb_url = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "url");
|
var upgrade_thumb_url = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "url");
|
||||||
upgrade_Sku_Img_Dic[skuParamUpgrade.thumb_url] = upgrid_thumb_url;
|
upgrade_Sku_Img_Dic[skuParamUpgrade.thumb_url] = upgrade_thumb_url;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
skuParamUpgrade.thumb_url = upgrade_Sku_Img_Dic[skuParamUpgrade.thumb_url];
|
skuParamUpgrade.thumb_url = upgrade_Sku_Img_Dic[skuParamUpgrade.thumb_url];
|
||||||
skuParamUpgrade.thumb_url_file_id = null;
|
skuParamUpgrade.thumb_url_file_id = null;
|
||||||
}
|
}
|
||||||
foreach (var skuParam in upgrade_Sku_Lst)
|
foreach (var skuParam in upgrade_sku_lst)
|
||||||
{
|
{
|
||||||
prodParamHighPrice.skus.Add(skuParam);
|
prodParamHighPrice.skus.Add(skuParam);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region // 添加一个申请活动的低价sku
|
#region 添加一个申请活动的低价sku
|
||||||
if (isLowPriceSku)
|
if (isLowPriceSku)
|
||||||
{
|
{
|
||||||
List<spec_param> first_spec_lst = new List<spec_param>();
|
List<spec_param> first_spec_lst = new List<spec_param>();
|
||||||
@@ -2670,9 +2655,46 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
|
|
||||||
// 复制一份商品使用sku替换图片
|
// 复制一份商品使用sku替换图片
|
||||||
var prodParamHighPriceFakeSkuImg = JsonHelper.DeserializeJsonToObject<PDDProductUploadParam>(JsonHelper.SerializeObject(prodParamHighPrice));
|
var prodParamHighPriceFakeSkuImg = JsonHelper.DeserializeJsonToObject<PDDProductUploadParam>(JsonHelper.SerializeObject(prodParamHighPrice));
|
||||||
|
var fake_sku_img_dic = new Dictionary<string, string>();
|
||||||
foreach (var skuParam in prodParamHighPriceFakeSkuImg.skus)
|
foreach (var skuParam in prodParamHighPriceFakeSkuImg.skus)
|
||||||
{
|
{
|
||||||
skuParam.thumb_url = fakeImgUrl;
|
if (!fake_sku_img_dic.Keys.Contains(skuParam.thumb_url))
|
||||||
|
{
|
||||||
|
string getImgError;
|
||||||
|
var image = GetHtml.GetUrlImg(fakeImgUrl, out getImgError);
|
||||||
|
var imageBg = new Bitmap(image.Width, image.Height);
|
||||||
|
if (!string.IsNullOrEmpty(getImgError) || image == null)
|
||||||
|
{
|
||||||
|
return "设置替换sku失败 图片上传失败";
|
||||||
|
}
|
||||||
|
try
|
||||||
|
{
|
||||||
|
using (Graphics g = Graphics.FromImage(imageBg))
|
||||||
|
{
|
||||||
|
g.DrawImage(image, new Rectangle(0, 0, image.Width, image.Height), 0, 0, image.Width, image.Height, GraphicsUnit.Pixel);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
return "修改替换sku图片失败 " + ex.Message;
|
||||||
|
}
|
||||||
|
string uploadUpgradeSkuImgRst = UploadProdSkuImg(shop, imageBg, prodParam.goods_id.ParseToString(), prodParam.goods_commit_id, prodInfo.chance_tab);
|
||||||
|
if (!uploadUpgradeSkuImgRst.Contains("\"url\":\"https:"))
|
||||||
|
{
|
||||||
|
var error = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "error_msg");
|
||||||
|
if (string.IsNullOrEmpty(error))
|
||||||
|
error = uploadUpgradeSkuImgRst;
|
||||||
|
return "上传替换sku图片失败 " + error;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var fake_thumb_url = BaseRegex.GetStringJson(ref uploadUpgradeSkuImgRst, "url");
|
||||||
|
fake_sku_img_dic[skuParam.thumb_url] = fake_thumb_url;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
skuParam.thumb_url = fake_sku_img_dic[skuParam.thumb_url];
|
||||||
|
|
||||||
|
//skuParam.thumb_url = fakeImgUrl;
|
||||||
skuParam.thumb_url_file_id = null;
|
skuParam.thumb_url_file_id = null;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
@@ -2834,13 +2856,14 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
Thread.Sleep(Randomx.GetId(30000, 40000));
|
Thread.Sleep(Randomx.GetId(30000, 40000));
|
||||||
Thread.Sleep(Randomx.GetId(6000, 12000));
|
Thread.Sleep(Randomx.GetId(6000, 12000));
|
||||||
|
|
||||||
var ta = Task.Run(() => SignActivityInTask(shop, prodParam, prodParamHighPrice, cell, startTime));
|
var ta = Task.Run(() => SignActivityInTask(shop, prodParam, prodParamHighPrice, prodParamHighPriceFakeSkuImg, cell, startTime));
|
||||||
//ta.Wait();
|
//ta.Wait();
|
||||||
}
|
}
|
||||||
return "{\"success\":true,\"draftId\":" + prodParam.goods_id + ",\"status\":\"已上传\",\"msg\":\"上传成功\"}";
|
return "{\"success\":true,\"draftId\":" + prodParam.goods_id + ",\"status\":\"已上传\",\"msg\":\"上传成功\"}";
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SignActivityInTask(ShopLoginInfo shop, PDDProductUploadParam prodParam, PDDProductUploadParam prodParamHighPrice, DataGridViewCell cell, DateTime startTime)
|
public void SignActivityInTask(ShopLoginInfo shop, PDDProductUploadParam prodParam, PDDProductUploadParam prodParamHighPrice,
|
||||||
|
PDDProductUploadParam prodParamHighPriceFakeSkuImg, DataGridViewCell cell, DateTime startTime)
|
||||||
{
|
{
|
||||||
Thread.Sleep(2000);
|
Thread.Sleep(2000);
|
||||||
var endTime = DateTime.Now;
|
var endTime = DateTime.Now;
|
||||||
@@ -2860,13 +2883,13 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
|
|
||||||
Thread.Sleep(Randomx.GetId(2000, 6000));
|
Thread.Sleep(Randomx.GetId(2000, 6000));
|
||||||
// 判断商品是否上架成功
|
// 判断商品是否上架成功
|
||||||
var getProdRst1 = queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 22347, 0);
|
var getProdRst1 = queryActivityGoodsEnabled(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), 22347, 0);
|
||||||
var getProdRst2 = queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 22347, 1);
|
var getProdRst2 = queryActivityGoodsEnabled(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), 22347, 1);
|
||||||
var getProdRst3 = ""; // queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 20981, 0);
|
var getProdRst3 = ""; // queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 20981, 0);
|
||||||
var getProdRst4 = ""; // queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 20981, 1);
|
var getProdRst4 = ""; // queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 20981, 1);
|
||||||
|
|
||||||
if (!getProdRst1.Contains(prodParam.goods_id.ParseToString()) && !getProdRst2.Contains(prodParam.goods_id.ParseToString()) &&
|
if (!getProdRst1.Contains(prodParamHighPriceFakeSkuImg.goods_id.ParseToString()) && !getProdRst2.Contains(prodParamHighPriceFakeSkuImg.goods_id.ParseToString()) &&
|
||||||
!getProdRst3.Contains(prodParam.goods_id.ParseToString()) && !getProdRst4.Contains(prodParam.goods_id.ParseToString()))
|
!getProdRst3.Contains(prodParamHighPriceFakeSkuImg.goods_id.ParseToString()) && !getProdRst4.Contains(prodParamHighPriceFakeSkuImg.goods_id.ParseToString()))
|
||||||
{
|
{
|
||||||
if (cell != null)
|
if (cell != null)
|
||||||
{
|
{
|
||||||
@@ -2883,7 +2906,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
else if (chk22347.Checked)
|
else if (chk22347.Checked)
|
||||||
{
|
{
|
||||||
// 如果报了直通车,判断商品自动加入直通车以后再放行(循环12次应该已加入,否则认为加入失败跳过)
|
// 如果报了直通车,判断商品自动加入直通车以后再放行(循环12次应该已加入,否则认为加入失败跳过)
|
||||||
for (int i = 0; i < 30 && !getProdRst2.Contains(prodParam.goods_id.ParseToString()) && chk22347.Checked; i++)
|
for (int i = 0; i < 30 && !getProdRst2.Contains(prodParamHighPriceFakeSkuImg.goods_id.ParseToString()) && chk22347.Checked; i++)
|
||||||
{
|
{
|
||||||
if (cell != null)
|
if (cell != null)
|
||||||
{
|
{
|
||||||
@@ -2897,8 +2920,8 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
}
|
}
|
||||||
Thread.Sleep(60 * 1000);
|
Thread.Sleep(60 * 1000);
|
||||||
//getProdRst1 = queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 22347, 0);
|
//getProdRst1 = queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 22347, 0);
|
||||||
getProdRst2 = queryActivityGoodsEnabled(shop, prodParam.goods_id.ParseToString(), 22347, 1);
|
getProdRst2 = queryActivityGoodsEnabled(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), 22347, 1);
|
||||||
if (getProdRst2.Contains(prodParam.goods_id.ParseToString()))
|
if (getProdRst2.Contains(prodParamHighPriceFakeSkuImg.goods_id.ParseToString()))
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -2928,8 +2951,15 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
{
|
{
|
||||||
loginForm.cefWebBrowser.Load("https://mms.pinduoduo.com/act/multi-act-enroll?activityId=20981&activityType=27&SourceType=PROMO-OwnHome&formInfoSceneType=realBigSaleQuickEnrollMultiActivityScene");
|
loginForm.cefWebBrowser.Load("https://mms.pinduoduo.com/act/multi-act-enroll?activityId=20981&activityType=27&SourceType=PROMO-OwnHome&formInfoSceneType=realBigSaleQuickEnrollMultiActivityScene");
|
||||||
}));
|
}));
|
||||||
|
Thread.Sleep(Randomx.GetId(4000, 10000));
|
||||||
|
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
//https://mms.pinduoduo.com/act/choose_goods/v2?id=20981&SourceType=MMSActicon
|
||||||
|
loginForm.cefWebBrowser.Load("https://mms.pinduoduo.com/act/goods_price/confirm?activityId=20981&activityType=27&from=chooseGoods&SourceType=MMSActicon");
|
||||||
|
}));
|
||||||
|
Thread.Sleep(Randomx.GetId(4000, 10000));
|
||||||
}
|
}
|
||||||
Thread.Sleep(Randomx.GetId(4000, 10000));
|
|
||||||
|
|
||||||
Invoke(new Action(() =>
|
Invoke(new Action(() =>
|
||||||
{
|
{
|
||||||
@@ -2940,19 +2970,15 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
var getProdIdRst = get_prod_commit_id(shop, prodParamHighPrice.goods_id.ParseToString(), false);
|
var getProdIdRst = get_prod_commit_id(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), false);
|
||||||
var newCommitId = BaseRegex.GetStringJson(ref getProdIdRst, "goods_commit_id");
|
var newCommitId = BaseRegex.GetStringJson(ref getProdIdRst, "goods_commit_id");
|
||||||
prodParamHighPrice.goods_commit_id = newCommitId;
|
prodParamHighPriceFakeSkuImg.goods_commit_id = newCommitId;
|
||||||
if (string.IsNullOrEmpty(newCommitId) || !getProdIdRst.Contains("\"success\":true"))
|
if (string.IsNullOrEmpty(newCommitId) || !getProdIdRst.Contains("\"success\":true"))
|
||||||
{
|
{
|
||||||
var error = BaseRegex.GetStringJson(ref getProdIdRst, "error_msg");
|
var error = BaseRegex.GetStringJson(ref getProdIdRst, "error_msg");
|
||||||
if (string.IsNullOrEmpty(error))
|
if (string.IsNullOrEmpty(error))
|
||||||
error = getProdIdRst;
|
error = getProdIdRst;
|
||||||
|
|
||||||
//if (BaseClass.SaLevel != 1 && 1 != 1)
|
|
||||||
// return "上传失败";
|
|
||||||
//return "上传失败 校验上传失败 " + error;
|
|
||||||
|
|
||||||
if (cell != null)
|
if (cell != null)
|
||||||
{
|
{
|
||||||
endTime = DateTime.Now;
|
endTime = DateTime.Now;
|
||||||
@@ -2966,18 +2992,17 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
PDDProductDetailInfo dbProdDetailInfo = null;
|
PDDProductDetailInfo newProdInfo = null;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var prod_on_shop_rst = PDDShopBrowserObject.GetPddProdDetailOnShop(shop, prodParamHighPrice.goods_id.ParseToString(), prodParamHighPrice.goods_commit_id);
|
//var prod_on_shop_rst = PDDShopBrowserObject.GetPddProdDetailOnShop(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), prodParamHighPriceFakeSkuImg.goods_commit_id);
|
||||||
|
var prod_detail_rst = PDDShopBrowserObject.GetPddProdDetail(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), prodParamHighPriceFakeSkuImg.goods_commit_id);
|
||||||
var prod_detail_rst = PDDShopBrowserObject.GetPddProdDetail(shop, prodParamHighPrice.goods_id.ParseToString(), prodParamHighPrice.goods_commit_id);
|
|
||||||
|
|
||||||
JObject prod_detail_obj = JObject.Parse(prod_detail_rst);
|
JObject prod_detail_obj = JObject.Parse(prod_detail_rst);
|
||||||
var detail_json = JsonHelper.SerializeObject(prod_detail_obj["result"]);
|
var detail_json = JsonHelper.SerializeObject(prod_detail_obj["result"]);
|
||||||
|
|
||||||
dbProdDetailInfo = JsonHelper.DeserializeJsonToObject<PDDProductDetailInfo>(detail_json);
|
newProdInfo = JsonHelper.DeserializeJsonToObject<PDDProductDetailInfo>(detail_json);
|
||||||
if (dbProdDetailInfo == null || detail_json.Length < 10)
|
if (newProdInfo == null || detail_json.Length < 10)
|
||||||
{
|
{
|
||||||
Invoke(new Action(() =>
|
Invoke(new Action(() =>
|
||||||
{
|
{
|
||||||
@@ -2995,17 +3020,17 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
prodParamHighPrice.check_status = 9;
|
prodParamHighPriceFakeSkuImg.check_status = 9;
|
||||||
prodParamHighPrice.first_upload_carousel = null;
|
prodParamHighPriceFakeSkuImg.first_upload_carousel = null;
|
||||||
prodParamHighPrice.uploadDragAB = null;
|
prodParamHighPriceFakeSkuImg.uploadDragAB = null;
|
||||||
prodParamHighPrice.title_keywords = null;
|
prodParamHighPriceFakeSkuImg.title_keywords = null;
|
||||||
prodParamHighPrice.prefillWhitePic = null;
|
prodParamHighPriceFakeSkuImg.prefillWhitePic = null;
|
||||||
prodParamHighPrice.is_shop = 1;
|
prodParamHighPriceFakeSkuImg.is_shop = 1;
|
||||||
prodParamHighPrice.pre_sale_time = "";
|
prodParamHighPriceFakeSkuImg.pre_sale_time = "";
|
||||||
prodParam.goods_pattern = dbProdDetailInfo.goods_pattern;
|
prodParamHighPriceFakeSkuImg.goods_pattern = newProdInfo.goods_pattern;
|
||||||
foreach (var skuParam in prodParamHighPrice.skus)
|
foreach (var skuParam in prodParamHighPriceFakeSkuImg.skus)
|
||||||
{
|
{
|
||||||
var skuInfo = dbProdDetailInfo.sku.FirstOrDefault(sk => string.Join(";", sk.spec.Select(s => s.spec_name)) == string.Join(";", skuParam.spec.Select(s => s.spec_name)));
|
var skuInfo = newProdInfo.sku.FirstOrDefault(sk => string.Join(";", sk.spec.Select(s => s.spec_name)) == string.Join(";", skuParam.spec.Select(s => s.spec_name)));
|
||||||
if (skuInfo != null)
|
if (skuInfo != null)
|
||||||
{
|
{
|
||||||
skuParam.id = skuInfo.id;
|
skuParam.id = skuInfo.id;
|
||||||
@@ -3022,7 +3047,6 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
skuParam.spec = JsonHelper.DeserializeJsonToList<spec_param>(JsonHelper.SerializeObject(skuInfo.spec));
|
skuParam.spec = JsonHelper.DeserializeJsonToList<spec_param>(JsonHelper.SerializeObject(skuInfo.spec));
|
||||||
//skuParam.thumb_url = skuInfo.thumb_url;
|
//skuParam.thumb_url = skuInfo.thumb_url;
|
||||||
//skuParam.thumb_url_file_id = skuInfo.thumb_url_file_id;
|
//skuParam.thumb_url_file_id = skuInfo.thumb_url_file_id;
|
||||||
//skuParam.thumb_url_file_id = skuInfo.ref_sku_commit_id;
|
|
||||||
skuParam.weight = skuInfo.weight;
|
skuParam.weight = skuInfo.weight;
|
||||||
skuParam.length = skuInfo.length;
|
skuParam.length = skuInfo.length;
|
||||||
skuParam.price_in_yuan = ""; // 内部计算直接置空
|
skuParam.price_in_yuan = ""; // 内部计算直接置空
|
||||||
@@ -3038,14 +3062,14 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
}
|
}
|
||||||
|
|
||||||
loginForm = null;
|
loginForm = null;
|
||||||
if (pddUploadRule.IsSignActivity && 1 == 1 && 1 == 2)
|
if (pddUploadRule.IsSignActivity && 1 == 2) // 测试在网页里面直接修改 不使用截断提交方式一次最多改两个,使用的话最多改一个
|
||||||
{
|
{
|
||||||
Invoke(new Action(() =>
|
Invoke(new Action(() =>
|
||||||
{
|
{
|
||||||
//this.panel1.SendToBack();
|
//this.panel1.SendToBack();
|
||||||
this.panel1.BringToFront();
|
this.panel1.BringToFront();
|
||||||
loginForm = new PDDShopLoginForm(shop);
|
loginForm = new PDDShopLoginForm(shop);
|
||||||
loginForm.prodParam = prodParamHighPrice;
|
loginForm.prodParam = prodParam;
|
||||||
loginForm.TopLevel = false;
|
loginForm.TopLevel = false;
|
||||||
loginForm.openType = EnumOpenType.manage;
|
loginForm.openType = EnumOpenType.manage;
|
||||||
loginForm.WindowState = FormWindowState.Maximized;
|
loginForm.WindowState = FormWindowState.Maximized;
|
||||||
@@ -3060,14 +3084,16 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
{
|
{
|
||||||
Invoke(new Action(() =>
|
Invoke(new Action(() =>
|
||||||
{
|
{
|
||||||
loginForm.cefWebBrowser.Load("https://mms.pinduoduo.com/goods/goods_add/index?id=" + prodParamHighPrice.goods_commit_id +
|
loginForm.cefWebBrowser.Load("https://mms.pinduoduo.com/goods/goods_add/index?id=" + prodParamHighPriceFakeSkuImg.goods_commit_id +
|
||||||
"&goods_id=" + prodParamHighPrice.goods_id + "&type=edit");
|
"&goods_id=" + prodParamHighPriceFakeSkuImg.goods_id + "&type=edit");
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
Thread.Sleep(Randomx.GetId(5000, 10000));
|
Thread.Sleep(Randomx.GetId(5000, 10000));
|
||||||
}
|
}
|
||||||
while (loginForm != null && loginForm.Created && !loginForm.Disposing && !loginForm.IsDisposed)
|
while (true)
|
||||||
{
|
{
|
||||||
|
if (loginForm == null || loginForm.Disposing || loginForm.IsDisposed)
|
||||||
|
break;
|
||||||
Thread.Sleep(Randomx.GetId(500, 1000));
|
Thread.Sleep(Randomx.GetId(500, 1000));
|
||||||
}
|
}
|
||||||
Invoke(new Action(() =>
|
Invoke(new Action(() =>
|
||||||
@@ -3075,65 +3101,85 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.panel1.SendToBack();
|
this.panel1.SendToBack();
|
||||||
}));
|
}));
|
||||||
|
|
||||||
//var reSaveProdRst = save_goods_edit(shop, prodParamHighPrice, prodParamHighPrice.goods_id.ParseToString(), prodParamHighPrice.goods_commit_id, isChanceApi, "edit");
|
|
||||||
var reSaveProdRst = save_goods_edit(shop, prodParamHighPrice, prodParamHighPrice.goods_id.ParseToString(), prodParamHighPrice.goods_commit_id, false, "edit");
|
|
||||||
if (!reSaveProdRst.Contains("\"success\":true"))
|
|
||||||
{
|
|
||||||
var error = BaseRegex.GetStringJson(ref reSaveProdRst, "error_msg");
|
|
||||||
if (string.IsNullOrEmpty(error))
|
|
||||||
error = reSaveProdRst;
|
|
||||||
|
|
||||||
//if (BaseClass.SaLevel != 1 && 1 != 1)
|
var spec0NameLst = prodParamHighPriceFakeSkuImg.skus.Select(s => s.spec[0].spec_name).Distinct().ToList();
|
||||||
// return "上传失败";
|
|
||||||
//return "上传失败 保存失败 " + error;
|
foreach (var specName in spec0NameLst)
|
||||||
if (cell != null)
|
{
|
||||||
|
var fakeImgskuLst = prodParamHighPriceFakeSkuImg.skus.Where(s => s.spec[0].spec_name == specName).ToList();
|
||||||
|
var skuImg = prodParamHighPriceFakeSkuImg.skus.FirstOrDefault(s => s.spec[0].spec_name == specName)?.thumb_url;
|
||||||
|
foreach (var fakeImgSku in fakeImgskuLst)
|
||||||
{
|
{
|
||||||
endTime = DateTime.Now;
|
fakeImgSku.thumb_url = skuImg;
|
||||||
timeSpan = endTime - startTime;
|
fakeImgSku.thumb_url_file_id = null;
|
||||||
duration = timeSpan.TotalSeconds;
|
|
||||||
Invoke(new Action(() =>
|
|
||||||
{
|
|
||||||
cell.Value = "上传失败 保存失败 " + error + " " + duration.ParseToInt() + "秒";
|
|
||||||
}));
|
|
||||||
}
|
}
|
||||||
return;
|
|
||||||
|
getProdIdRst = get_prod_commit_id(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), false);
|
||||||
|
newCommitId = BaseRegex.GetStringJson(ref getProdIdRst, "goods_commit_id");
|
||||||
|
prodParamHighPriceFakeSkuImg.goods_commit_id = newCommitId;
|
||||||
|
if (string.IsNullOrEmpty(newCommitId) || !getProdIdRst.Contains("\"success\":true"))
|
||||||
|
{
|
||||||
|
var error = BaseRegex.GetStringJson(ref getProdIdRst, "error_msg");
|
||||||
|
if (string.IsNullOrEmpty(error))
|
||||||
|
error = getProdIdRst;
|
||||||
|
|
||||||
|
if (cell != null)
|
||||||
|
{
|
||||||
|
endTime = DateTime.Now;
|
||||||
|
timeSpan = endTime - startTime;
|
||||||
|
duration = timeSpan.TotalSeconds;
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
cell.Value = "上传失败 校验上传失败 " + error + " " + duration.ParseToInt() + "秒";
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
var reSaveProdRst = save_goods_edit(shop, prodParamHighPriceFakeSkuImg, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(),
|
||||||
|
prodParamHighPriceFakeSkuImg.goods_commit_id, isChanceApi, "edit");
|
||||||
|
if (!reSaveProdRst.Contains("\"success\":true"))
|
||||||
|
{
|
||||||
|
var error = BaseRegex.GetStringJson(ref reSaveProdRst, "error_msg");
|
||||||
|
if (string.IsNullOrEmpty(error))
|
||||||
|
error = reSaveProdRst;
|
||||||
|
|
||||||
|
if (cell != null)
|
||||||
|
{
|
||||||
|
endTime = DateTime.Now;
|
||||||
|
timeSpan = endTime - startTime;
|
||||||
|
duration = timeSpan.TotalSeconds;
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
cell.Value = "上传失败 保存失败 " + error + " " + duration.ParseToInt() + "秒";
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
Thread.Sleep(Randomx.GetId(20, 100));
|
||||||
|
var reUploadRst = submit_goods_edit(shop, prodParamHighPriceFakeSkuImg.goods_id.ParseToString(), prodParamHighPriceFakeSkuImg.goods_commit_id, isChanceApi, "edit");
|
||||||
|
if (!reUploadRst.Contains("\"success\":true"))
|
||||||
|
{
|
||||||
|
var error = BaseRegex.GetStringJson(ref reUploadRst, "error_msg");
|
||||||
|
if (string.IsNullOrEmpty(error))
|
||||||
|
error = reUploadRst;
|
||||||
|
|
||||||
|
if (cell != null)
|
||||||
|
{
|
||||||
|
endTime = DateTime.Now;
|
||||||
|
timeSpan = endTime - startTime;
|
||||||
|
duration = timeSpan.TotalSeconds;
|
||||||
|
Invoke(new Action(() =>
|
||||||
|
{
|
||||||
|
cell.Value = "上传失败 保存失败 " + error + " " + duration.ParseToInt() + "秒";
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
Thread.Sleep(Randomx.GetId(12000, 15000));
|
||||||
}
|
}
|
||||||
|
|
||||||
Thread.Sleep(Randomx.GetId(20, 100));
|
|
||||||
//var str = JsonHelper.SerializeObject(prodParam);
|
|
||||||
//var reUploadRst = submit_goods_edit(shop, prodParamHighPrice.goods_id.ParseToString(), prodParamHighPrice.goods_commit_id, isChanceApi, "edit");
|
|
||||||
var reUploadRst = submit_goods_edit(shop, prodParamHighPrice.goods_id.ParseToString(), prodParamHighPrice.goods_commit_id, isChanceApi, "edit");
|
|
||||||
if (!reUploadRst.Contains("\"success\":true"))
|
|
||||||
{
|
|
||||||
var error = BaseRegex.GetStringJson(ref reUploadRst, "error_msg");
|
|
||||||
if (string.IsNullOrEmpty(error))
|
|
||||||
error = reUploadRst;
|
|
||||||
|
|
||||||
//if (BaseClass.SaLevel != 1 && 1 != 1)
|
|
||||||
// return "上传失败";
|
|
||||||
//return "上传失败 提交失败 " + error;
|
|
||||||
|
|
||||||
if (cell != null)
|
|
||||||
{
|
|
||||||
endTime = DateTime.Now;
|
|
||||||
timeSpan = endTime - startTime;
|
|
||||||
duration = timeSpan.TotalSeconds;
|
|
||||||
Invoke(new Action(() =>
|
|
||||||
{
|
|
||||||
cell.Value = "上传失败 保存失败 " + error + " " + duration.ParseToInt() + "秒";
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
Invoke(new Action(() =>
|
|
||||||
{
|
|
||||||
if (loginForm != null)
|
|
||||||
loginForm.Close();
|
|
||||||
loginForm = null;
|
|
||||||
}));
|
|
||||||
|
|
||||||
Thread.Sleep(Randomx.GetId(12000, 15000));
|
|
||||||
string activityErr = SignActivity(shop, prodParam, sign22347, sign20981, sign23165, sign15996);
|
string activityErr = SignActivity(shop, prodParam, sign22347, sign20981, sign23165, sign15996);
|
||||||
|
|
||||||
//Thread.Sleep(Randomx.GetId(4000, 8000));
|
//Thread.Sleep(Randomx.GetId(4000, 8000));
|
||||||
@@ -5643,31 +5689,6 @@ Content-Type: image/jpeg
|
|||||||
this.pbUpgradeVersion.Tag = imgBase64;
|
this.pbUpgradeVersion.Tag = imgBase64;
|
||||||
this.pbUpgradeVersion.ImageLocation = "";
|
this.pbUpgradeVersion.ImageLocation = "";
|
||||||
this.pbUpgradeVersion.Image = image;
|
this.pbUpgradeVersion.Image = image;
|
||||||
|
|
||||||
//if (!this.pbSkuImg.Tag.ParseToString().IsNullOrEmpty())
|
|
||||||
//{
|
|
||||||
// byte[] imageBytes = Convert.FromBase64String(pbSkuImg.Tag.ParseToString());
|
|
||||||
// // 使用MemoryStream创建图片对象
|
|
||||||
// using (MemoryStream ms = new MemoryStream(imageBytes))
|
|
||||||
// {
|
|
||||||
// Image imageBg = Image.FromStream(ms);
|
|
||||||
|
|
||||||
// using (Graphics g = Graphics.FromImage(imageBg))
|
|
||||||
// {
|
|
||||||
// // 将第一张图片绘制到结果图像上
|
|
||||||
// g.DrawImage(image, new Rectangle(0, 0, image.Width, image.Height), 0, 0, image.Width, image.Height, GraphicsUnit.Pixel);
|
|
||||||
// //// 将第二张图片绘制到结果图像上(叠加在第一张图片上)
|
|
||||||
// //g.DrawImage(img2, new Rectangle(0, 0, img2.Width, img2.Height), 0, 0, img2.Width, img2.Height, GraphicsUnit.Pixel);
|
|
||||||
// }
|
|
||||||
|
|
||||||
// // 保存图片到文件系统
|
|
||||||
// try
|
|
||||||
// {
|
|
||||||
// imageBg.Save("D:\\图片1.jpg", System.Drawing.Imaging.ImageFormat.Jpeg);
|
|
||||||
// }
|
|
||||||
// catch (Exception ex) { BaseMsgForm.ShowError("存图失败 " + ex.Message); }
|
|
||||||
// }
|
|
||||||
//}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
|
|||||||
@@ -77,6 +77,9 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.pbLoading = new System.Windows.Forms.PictureBox();
|
this.pbLoading = new System.Windows.Forms.PictureBox();
|
||||||
this.panel2 = new System.Windows.Forms.Panel();
|
this.panel2 = new System.Windows.Forms.Panel();
|
||||||
this.dgvChanceProduct = new TemuKJD.UserComponent.DataGridViewEx();
|
this.dgvChanceProduct = new TemuKJD.UserComponent.DataGridViewEx();
|
||||||
|
this.chk = new TemuKJD.UserComponent.UcCheckBox(this.components);
|
||||||
|
this.statusBar = new TemuKJD.UserControls.StatusBarUserControl();
|
||||||
|
this.ucSplitPage1 = new TemuKJD.UserControls.UcSplitPage();
|
||||||
this.colCheck = new System.Windows.Forms.DataGridViewCheckBoxColumn();
|
this.colCheck = new System.Windows.Forms.DataGridViewCheckBoxColumn();
|
||||||
this.colChanceId = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.colChanceId = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.colImgUrl = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.colImgUrl = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
@@ -85,10 +88,8 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.colHotValue = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.colHotValue = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.colCate = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.colCate = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.colPrice = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.colPrice = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
|
this.colDel = new System.Windows.Forms.DataGridViewLinkColumn();
|
||||||
this.colMsg = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.colMsg = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.chk = new TemuKJD.UserComponent.UcCheckBox(this.components);
|
|
||||||
this.statusBar = new TemuKJD.UserControls.StatusBarUserControl();
|
|
||||||
this.ucSplitPage1 = new TemuKJD.UserControls.UcSplitPage();
|
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
|
||||||
this.splitContainer1.Panel1.SuspendLayout();
|
this.splitContainer1.Panel1.SuspendLayout();
|
||||||
this.splitContainer1.Panel2.SuspendLayout();
|
this.splitContainer1.Panel2.SuspendLayout();
|
||||||
@@ -124,7 +125,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
// splitContainer1.Panel2
|
// splitContainer1.Panel2
|
||||||
//
|
//
|
||||||
this.splitContainer1.Panel2.Controls.Add(this.splitContainer2);
|
this.splitContainer1.Panel2.Controls.Add(this.splitContainer2);
|
||||||
this.splitContainer1.Size = new System.Drawing.Size(1119, 635);
|
this.splitContainer1.Size = new System.Drawing.Size(1179, 635);
|
||||||
this.splitContainer1.SplitterDistance = 120;
|
this.splitContainer1.SplitterDistance = 120;
|
||||||
this.splitContainer1.TabIndex = 4;
|
this.splitContainer1.TabIndex = 4;
|
||||||
//
|
//
|
||||||
@@ -159,7 +160,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.ucGroupBoxEx1.Controls.Add(this.chkOverride);
|
this.ucGroupBoxEx1.Controls.Add(this.chkOverride);
|
||||||
this.ucGroupBoxEx1.Location = new System.Drawing.Point(3, 2);
|
this.ucGroupBoxEx1.Location = new System.Drawing.Point(3, 2);
|
||||||
this.ucGroupBoxEx1.Name = "ucGroupBoxEx1";
|
this.ucGroupBoxEx1.Name = "ucGroupBoxEx1";
|
||||||
this.ucGroupBoxEx1.Size = new System.Drawing.Size(1114, 118);
|
this.ucGroupBoxEx1.Size = new System.Drawing.Size(1174, 118);
|
||||||
this.ucGroupBoxEx1.TabIndex = 0;
|
this.ucGroupBoxEx1.TabIndex = 0;
|
||||||
this.ucGroupBoxEx1.TabStop = false;
|
this.ucGroupBoxEx1.TabStop = false;
|
||||||
this.ucGroupBoxEx1.Text = "操作";
|
this.ucGroupBoxEx1.Text = "操作";
|
||||||
@@ -195,7 +196,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.btnSelectSuccess.Cursor = System.Windows.Forms.Cursors.Hand;
|
this.btnSelectSuccess.Cursor = System.Windows.Forms.Cursors.Hand;
|
||||||
this.btnSelectSuccess.DisabledBackColor = System.Drawing.Color.Empty;
|
this.btnSelectSuccess.DisabledBackColor = System.Drawing.Color.Empty;
|
||||||
this.btnSelectSuccess.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
this.btnSelectSuccess.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
this.btnSelectSuccess.Location = new System.Drawing.Point(716, 75);
|
this.btnSelectSuccess.Location = new System.Drawing.Point(776, 75);
|
||||||
this.btnSelectSuccess.Name = "btnSelectSuccess";
|
this.btnSelectSuccess.Name = "btnSelectSuccess";
|
||||||
this.btnSelectSuccess.Size = new System.Drawing.Size(170, 25);
|
this.btnSelectSuccess.Size = new System.Drawing.Size(170, 25);
|
||||||
this.btnSelectSuccess.Style.Alignment = System.Drawing.StringAlignment.Center;
|
this.btnSelectSuccess.Style.Alignment = System.Drawing.StringAlignment.Center;
|
||||||
@@ -277,7 +278,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.btnAddToDb.Cursor = System.Windows.Forms.Cursors.Hand;
|
this.btnAddToDb.Cursor = System.Windows.Forms.Cursors.Hand;
|
||||||
this.btnAddToDb.DisabledBackColor = System.Drawing.Color.Empty;
|
this.btnAddToDb.DisabledBackColor = System.Drawing.Color.Empty;
|
||||||
this.btnAddToDb.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
this.btnAddToDb.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
this.btnAddToDb.Location = new System.Drawing.Point(973, 75);
|
this.btnAddToDb.Location = new System.Drawing.Point(1033, 75);
|
||||||
this.btnAddToDb.Name = "btnAddToDb";
|
this.btnAddToDb.Name = "btnAddToDb";
|
||||||
this.btnAddToDb.Size = new System.Drawing.Size(116, 25);
|
this.btnAddToDb.Size = new System.Drawing.Size(116, 25);
|
||||||
this.btnAddToDb.Style.Alignment = System.Drawing.StringAlignment.Center;
|
this.btnAddToDb.Style.Alignment = System.Drawing.StringAlignment.Center;
|
||||||
@@ -302,7 +303,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.btnGetDetail.Cursor = System.Windows.Forms.Cursors.Hand;
|
this.btnGetDetail.Cursor = System.Windows.Forms.Cursors.Hand;
|
||||||
this.btnGetDetail.DisabledBackColor = System.Drawing.Color.Empty;
|
this.btnGetDetail.DisabledBackColor = System.Drawing.Color.Empty;
|
||||||
this.btnGetDetail.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
this.btnGetDetail.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
this.btnGetDetail.Location = new System.Drawing.Point(973, 22);
|
this.btnGetDetail.Location = new System.Drawing.Point(1033, 22);
|
||||||
this.btnGetDetail.Name = "btnGetDetail";
|
this.btnGetDetail.Name = "btnGetDetail";
|
||||||
this.btnGetDetail.Size = new System.Drawing.Size(116, 25);
|
this.btnGetDetail.Size = new System.Drawing.Size(116, 25);
|
||||||
this.btnGetDetail.Style.Alignment = System.Drawing.StringAlignment.Center;
|
this.btnGetDetail.Style.Alignment = System.Drawing.StringAlignment.Center;
|
||||||
@@ -493,7 +494,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
//
|
//
|
||||||
this.chkOverride.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
this.chkOverride.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
this.chkOverride.AutoSize = true;
|
this.chkOverride.AutoSize = true;
|
||||||
this.chkOverride.Location = new System.Drawing.Point(892, 77);
|
this.chkOverride.Location = new System.Drawing.Point(952, 77);
|
||||||
this.chkOverride.Name = "chkOverride";
|
this.chkOverride.Name = "chkOverride";
|
||||||
this.chkOverride.Size = new System.Drawing.Size(87, 21);
|
this.chkOverride.Size = new System.Drawing.Size(87, 21);
|
||||||
this.chkOverride.TabIndex = 757;
|
this.chkOverride.TabIndex = 757;
|
||||||
@@ -518,7 +519,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.splitContainer2.Panel2.Controls.Add(this.chk);
|
this.splitContainer2.Panel2.Controls.Add(this.chk);
|
||||||
this.splitContainer2.Panel2.Controls.Add(this.statusBar);
|
this.splitContainer2.Panel2.Controls.Add(this.statusBar);
|
||||||
this.splitContainer2.Panel2.Controls.Add(this.ucSplitPage1);
|
this.splitContainer2.Panel2.Controls.Add(this.ucSplitPage1);
|
||||||
this.splitContainer2.Size = new System.Drawing.Size(1119, 511);
|
this.splitContainer2.Size = new System.Drawing.Size(1179, 511);
|
||||||
this.splitContainer2.SplitterDistance = 482;
|
this.splitContainer2.SplitterDistance = 482;
|
||||||
this.splitContainer2.TabIndex = 0;
|
this.splitContainer2.TabIndex = 0;
|
||||||
//
|
//
|
||||||
@@ -539,7 +540,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.splitContainer3.Panel2.Controls.Add(this.pbLoading);
|
this.splitContainer3.Panel2.Controls.Add(this.pbLoading);
|
||||||
this.splitContainer3.Panel2.Controls.Add(this.panel2);
|
this.splitContainer3.Panel2.Controls.Add(this.panel2);
|
||||||
this.splitContainer3.Panel2.Controls.Add(this.dgvChanceProduct);
|
this.splitContainer3.Panel2.Controls.Add(this.dgvChanceProduct);
|
||||||
this.splitContainer3.Size = new System.Drawing.Size(1111, 482);
|
this.splitContainer3.Size = new System.Drawing.Size(1171, 482);
|
||||||
this.splitContainer3.SplitterDistance = 290;
|
this.splitContainer3.SplitterDistance = 290;
|
||||||
this.splitContainer3.TabIndex = 9;
|
this.splitContainer3.TabIndex = 9;
|
||||||
//
|
//
|
||||||
@@ -668,7 +669,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
//
|
//
|
||||||
this.pbLoading.Anchor = System.Windows.Forms.AnchorStyles.None;
|
this.pbLoading.Anchor = System.Windows.Forms.AnchorStyles.None;
|
||||||
this.pbLoading.Image = global::TemuKJD.Properties.Resources.loading_blue;
|
this.pbLoading.Image = global::TemuKJD.Properties.Resources.loading_blue;
|
||||||
this.pbLoading.Location = new System.Drawing.Point(383, 216);
|
this.pbLoading.Location = new System.Drawing.Point(413, 216);
|
||||||
this.pbLoading.Name = "pbLoading";
|
this.pbLoading.Name = "pbLoading";
|
||||||
this.pbLoading.Size = new System.Drawing.Size(50, 50);
|
this.pbLoading.Size = new System.Drawing.Size(50, 50);
|
||||||
this.pbLoading.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
|
this.pbLoading.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
|
||||||
@@ -683,7 +684,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
| System.Windows.Forms.AnchorStyles.Right)));
|
| System.Windows.Forms.AnchorStyles.Right)));
|
||||||
this.panel2.Location = new System.Drawing.Point(409, 355);
|
this.panel2.Location = new System.Drawing.Point(409, 355);
|
||||||
this.panel2.Name = "panel2";
|
this.panel2.Name = "panel2";
|
||||||
this.panel2.Size = new System.Drawing.Size(385, 107);
|
this.panel2.Size = new System.Drawing.Size(445, 107);
|
||||||
this.panel2.TabIndex = 8;
|
this.panel2.TabIndex = 8;
|
||||||
//
|
//
|
||||||
// dgvChanceProduct
|
// dgvChanceProduct
|
||||||
@@ -714,16 +715,57 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.colHotValue,
|
this.colHotValue,
|
||||||
this.colCate,
|
this.colCate,
|
||||||
this.colPrice,
|
this.colPrice,
|
||||||
|
this.colDel,
|
||||||
this.colMsg});
|
this.colMsg});
|
||||||
this.dgvChanceProduct.Dock = System.Windows.Forms.DockStyle.Fill;
|
this.dgvChanceProduct.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
this.dgvChanceProduct.Location = new System.Drawing.Point(0, 0);
|
this.dgvChanceProduct.Location = new System.Drawing.Point(0, 0);
|
||||||
this.dgvChanceProduct.Name = "dgvChanceProduct";
|
this.dgvChanceProduct.Name = "dgvChanceProduct";
|
||||||
this.dgvChanceProduct.ReadOnly = true;
|
this.dgvChanceProduct.ReadOnly = true;
|
||||||
this.dgvChanceProduct.RowTemplate.Height = 23;
|
this.dgvChanceProduct.RowTemplate.Height = 23;
|
||||||
this.dgvChanceProduct.Size = new System.Drawing.Size(817, 482);
|
this.dgvChanceProduct.Size = new System.Drawing.Size(877, 482);
|
||||||
this.dgvChanceProduct.TabIndex = 6;
|
this.dgvChanceProduct.TabIndex = 6;
|
||||||
this.dgvChanceProduct.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvChanceProduct_CellContentClick);
|
this.dgvChanceProduct.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvChanceProduct_CellContentClick);
|
||||||
//
|
//
|
||||||
|
// chk
|
||||||
|
//
|
||||||
|
this.chk.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||||
|
this.chk.AutoSize = true;
|
||||||
|
this.chk.Checked = true;
|
||||||
|
this.chk.CheckState = System.Windows.Forms.CheckState.Checked;
|
||||||
|
this.chk.Location = new System.Drawing.Point(1112, 3);
|
||||||
|
this.chk.Name = "chk";
|
||||||
|
this.chk.Size = new System.Drawing.Size(63, 21);
|
||||||
|
this.chk.TabIndex = 671;
|
||||||
|
this.chk.Text = "多选框";
|
||||||
|
this.chk.UseVisualStyleBackColor = true;
|
||||||
|
this.chk.Visible = false;
|
||||||
|
//
|
||||||
|
// statusBar
|
||||||
|
//
|
||||||
|
this.statusBar.BackColor = System.Drawing.Color.White;
|
||||||
|
this.statusBar.Dock = System.Windows.Forms.DockStyle.Left;
|
||||||
|
this.statusBar.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
|
this.statusBar.Location = new System.Drawing.Point(296, 0);
|
||||||
|
this.statusBar.Margin = new System.Windows.Forms.Padding(0);
|
||||||
|
this.statusBar.Name = "statusBar";
|
||||||
|
this.statusBar.Size = new System.Drawing.Size(743, 25);
|
||||||
|
this.statusBar.TabIndex = 5;
|
||||||
|
//
|
||||||
|
// ucSplitPage1
|
||||||
|
//
|
||||||
|
this.ucSplitPage1.CurrentPage = 1;
|
||||||
|
this.ucSplitPage1.Dock = System.Windows.Forms.DockStyle.Left;
|
||||||
|
this.ucSplitPage1.IsShowPageSize = false;
|
||||||
|
this.ucSplitPage1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.ucSplitPage1.Margin = new System.Windows.Forms.Padding(0);
|
||||||
|
this.ucSplitPage1.Name = "ucSplitPage1";
|
||||||
|
this.ucSplitPage1.Padding = new System.Windows.Forms.Padding(0, 0, 1, 0);
|
||||||
|
this.ucSplitPage1.PageSize = 50;
|
||||||
|
this.ucSplitPage1.Size = new System.Drawing.Size(296, 25);
|
||||||
|
this.ucSplitPage1.TabIndex = 6;
|
||||||
|
this.ucSplitPage1.TotalPage = 1;
|
||||||
|
this.ucSplitPage1.PageChange += new System.Action<object>(this.ucSplitPage1_PageChange);
|
||||||
|
//
|
||||||
// colCheck
|
// colCheck
|
||||||
//
|
//
|
||||||
this.colCheck.FillWeight = 26F;
|
this.colCheck.FillWeight = 26F;
|
||||||
@@ -789,6 +831,13 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.colPrice.Name = "colPrice";
|
this.colPrice.Name = "colPrice";
|
||||||
this.colPrice.ReadOnly = true;
|
this.colPrice.ReadOnly = true;
|
||||||
//
|
//
|
||||||
|
// colDel
|
||||||
|
//
|
||||||
|
this.colDel.FillWeight = 35F;
|
||||||
|
this.colDel.HeaderText = "删除";
|
||||||
|
this.colDel.Name = "colDel";
|
||||||
|
this.colDel.ReadOnly = true;
|
||||||
|
//
|
||||||
// colMsg
|
// colMsg
|
||||||
//
|
//
|
||||||
dataGridViewCellStyle7.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
|
dataGridViewCellStyle7.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
|
||||||
@@ -798,50 +847,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
this.colMsg.Name = "colMsg";
|
this.colMsg.Name = "colMsg";
|
||||||
this.colMsg.ReadOnly = true;
|
this.colMsg.ReadOnly = true;
|
||||||
//
|
//
|
||||||
// chk
|
|
||||||
//
|
|
||||||
this.chk.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
|
||||||
this.chk.AutoSize = true;
|
|
||||||
this.chk.Checked = true;
|
|
||||||
this.chk.CheckState = System.Windows.Forms.CheckState.Checked;
|
|
||||||
this.chk.Location = new System.Drawing.Point(1052, 3);
|
|
||||||
this.chk.Name = "chk";
|
|
||||||
this.chk.Size = new System.Drawing.Size(63, 21);
|
|
||||||
this.chk.TabIndex = 671;
|
|
||||||
this.chk.Text = "多选框";
|
|
||||||
this.chk.UseVisualStyleBackColor = true;
|
|
||||||
this.chk.Visible = false;
|
|
||||||
//
|
|
||||||
// statusBar
|
|
||||||
//
|
|
||||||
this.statusBar.BackColor = System.Drawing.Color.White;
|
|
||||||
this.statusBar.Dock = System.Windows.Forms.DockStyle.Left;
|
|
||||||
this.statusBar.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
|
||||||
this.statusBar.Location = new System.Drawing.Point(296, 0);
|
|
||||||
this.statusBar.Margin = new System.Windows.Forms.Padding(0);
|
|
||||||
this.statusBar.Name = "statusBar";
|
|
||||||
this.statusBar.Size = new System.Drawing.Size(743, 25);
|
|
||||||
this.statusBar.TabIndex = 5;
|
|
||||||
//
|
|
||||||
// ucSplitPage1
|
|
||||||
//
|
|
||||||
this.ucSplitPage1.CurrentPage = 1;
|
|
||||||
this.ucSplitPage1.Dock = System.Windows.Forms.DockStyle.Left;
|
|
||||||
this.ucSplitPage1.IsShowPageSize = false;
|
|
||||||
this.ucSplitPage1.Location = new System.Drawing.Point(0, 0);
|
|
||||||
this.ucSplitPage1.Margin = new System.Windows.Forms.Padding(0);
|
|
||||||
this.ucSplitPage1.Name = "ucSplitPage1";
|
|
||||||
this.ucSplitPage1.Padding = new System.Windows.Forms.Padding(0, 0, 1, 0);
|
|
||||||
this.ucSplitPage1.PageSize = 50;
|
|
||||||
this.ucSplitPage1.Size = new System.Drawing.Size(296, 25);
|
|
||||||
this.ucSplitPage1.TabIndex = 6;
|
|
||||||
this.ucSplitPage1.TotalPage = 1;
|
|
||||||
this.ucSplitPage1.PageChange += new System.Action<object>(this.ucSplitPage1_PageChange);
|
|
||||||
//
|
|
||||||
// PDDGetChanceProdForm
|
// PDDGetChanceProdForm
|
||||||
//
|
//
|
||||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
|
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
|
||||||
this.ClientSize = new System.Drawing.Size(1119, 635);
|
this.ClientSize = new System.Drawing.Size(1179, 635);
|
||||||
this.Controls.Add(this.splitContainer1);
|
this.Controls.Add(this.splitContainer1);
|
||||||
this.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
this.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||||
this.Name = "PDDGetChanceProdForm";
|
this.Name = "PDDGetChanceProdForm";
|
||||||
@@ -913,6 +922,9 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
private System.Windows.Forms.TextBox txtSearchCount;
|
private System.Windows.Forms.TextBox txtSearchCount;
|
||||||
private System.Windows.Forms.Label label5;
|
private System.Windows.Forms.Label label5;
|
||||||
private UserComponent.UcCheckBox chkOverride;
|
private UserComponent.UcCheckBox chkOverride;
|
||||||
|
private DevComponents.DotNetBar.PanelEx btnStop;
|
||||||
|
private DevComponents.DotNetBar.PanelEx btnSelectSuccess;
|
||||||
|
private DevComponents.DotNetBar.PanelEx btnStopStop;
|
||||||
private System.Windows.Forms.DataGridViewCheckBoxColumn colCheck;
|
private System.Windows.Forms.DataGridViewCheckBoxColumn colCheck;
|
||||||
private System.Windows.Forms.DataGridViewTextBoxColumn colChanceId;
|
private System.Windows.Forms.DataGridViewTextBoxColumn colChanceId;
|
||||||
private System.Windows.Forms.DataGridViewTextBoxColumn colImgUrl;
|
private System.Windows.Forms.DataGridViewTextBoxColumn colImgUrl;
|
||||||
@@ -921,9 +933,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
private System.Windows.Forms.DataGridViewTextBoxColumn colHotValue;
|
private System.Windows.Forms.DataGridViewTextBoxColumn colHotValue;
|
||||||
private System.Windows.Forms.DataGridViewTextBoxColumn colCate;
|
private System.Windows.Forms.DataGridViewTextBoxColumn colCate;
|
||||||
private System.Windows.Forms.DataGridViewTextBoxColumn colPrice;
|
private System.Windows.Forms.DataGridViewTextBoxColumn colPrice;
|
||||||
|
private System.Windows.Forms.DataGridViewLinkColumn colDel;
|
||||||
private System.Windows.Forms.DataGridViewTextBoxColumn colMsg;
|
private System.Windows.Forms.DataGridViewTextBoxColumn colMsg;
|
||||||
private DevComponents.DotNetBar.PanelEx btnStop;
|
|
||||||
private DevComponents.DotNetBar.PanelEx btnSelectSuccess;
|
|
||||||
private DevComponents.DotNetBar.PanelEx btnStopStop;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -398,7 +398,8 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
chanceProductResult.keywords,
|
chanceProductResult.keywords,
|
||||||
chanceProductResult.hot_index,
|
chanceProductResult.hot_index,
|
||||||
chanceProductResult.cat_id_3.ParseToLong() == 0 ? new long?() : chanceProductResult.cat_id_3.ParseToLong(),
|
chanceProductResult.cat_id_3.ParseToLong() == 0 ? new long?() : chanceProductResult.cat_id_3.ParseToLong(),
|
||||||
"采集详情后显示"
|
"采集详情后显示",
|
||||||
|
"删除"
|
||||||
);
|
);
|
||||||
dgvChanceProduct.Rows[rowId].Height = 60;
|
dgvChanceProduct.Rows[rowId].Height = 60;
|
||||||
}));
|
}));
|
||||||
@@ -438,6 +439,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
string headerText = dgvChanceProduct.Columns[e.ColumnIndex].HeaderText;
|
string headerText = dgvChanceProduct.Columns[e.ColumnIndex].HeaderText;
|
||||||
var chanceId = dgvChanceProduct.Rows[e.RowIndex].Cells["colChanceId"].Value.ParseToString();
|
var chanceId = dgvChanceProduct.Rows[e.RowIndex].Cells["colChanceId"].Value.ParseToString();
|
||||||
var chanceProd = lstChanceProductResult.FirstOrDefault(p => p.chance_id == chanceId);
|
var chanceProd = lstChanceProductResult.FirstOrDefault(p => p.chance_id == chanceId);
|
||||||
|
var row = dgvChanceProduct.Rows[e.RowIndex];
|
||||||
|
|
||||||
switch (headerText)
|
switch (headerText)
|
||||||
{
|
{
|
||||||
@@ -445,6 +447,8 @@ namespace TemuKJD.PDDForms.ProductSelectForms
|
|||||||
//if (BaseMsgForm.ShowConfirm("确定删除商品吗?删除后不可恢复!").DialogResult == DialogResult.Cancel)
|
//if (BaseMsgForm.ShowConfirm("确定删除商品吗?删除后不可恢复!").DialogResult == DialogResult.Cancel)
|
||||||
// return;
|
// return;
|
||||||
//DeleteProduct(dbId);
|
//DeleteProduct(dbId);
|
||||||
|
dgvChanceProduct.Rows.Remove(row);
|
||||||
|
lstChanceProductResult.Remove(chanceProd);
|
||||||
break;
|
break;
|
||||||
case "图片":
|
case "图片":
|
||||||
var imgUrl = dgvChanceProduct.Rows[e.RowIndex].Cells["colImgUrl"].Value.ParseToString().Replace("?imageView2/2/w/90/h/90", "");
|
var imgUrl = dgvChanceProduct.Rows[e.RowIndex].Cells["colImgUrl"].Value.ParseToString().Replace("?imageView2/2/w/90/h/90", "");
|
||||||
|
|||||||
@@ -165,6 +165,9 @@
|
|||||||
<metadata name="colPrice.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="colPrice.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
|
<metadata name="colDel.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
<metadata name="colMsg.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="colMsg.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
|
|||||||
@@ -609,27 +609,15 @@ namespace TemuKJD.PDDForms.ShopForms
|
|||||||
if (skuBase != null)
|
if (skuBase != null)
|
||||||
skuObj["thumb_url"] = skuBase.thumb_url;
|
skuObj["thumb_url"] = skuBase.thumb_url;
|
||||||
|
|
||||||
skuObj["thumb_url"] = "https://img.pddpic.com/mms-material-img/2025-12-27/23e40222-1a08-4ba1-a6a3-65588c75e0cd.jpeg.a.jpeg";
|
//skuObj["thumb_url"] = "https://img.pddpic.com/mms-material-img/2025-12-27/23e40222-1a08-4ba1-a6a3-65588c75e0cd.jpeg.a.jpeg";
|
||||||
}
|
}
|
||||||
|
|
||||||
//https://img.pddpic.com/mms-material-img/2025-12-18/4b0e7e61-1a78-4842-a0e8-f6b7ef88fe18.jpeg.a.jpeg
|
|
||||||
|
|
||||||
//postData = postData.Replace(
|
|
||||||
// "https://img.pddpic.com/mms-material-img/2025-12-18/4b0e7e61-1a78-4842-a0e8-f6b7ef88fe18.jpeg.a.jpeg",
|
|
||||||
// "https://img.pddpic.com/mms-material-img/2025-12-26/748ae660-53f4-4806-9e88-2712a7b5114b.jpeg.a.jpeg");
|
|
||||||
|
|
||||||
//postData = postData.Replace(
|
|
||||||
// "https://img.pddpic.com/mms-material-img/2025-12-26/748ae660-53f4-4806-9e88-2712a7b5114b.jpeg.a.jpeg",
|
|
||||||
// "https://img.pddpic.com/mms-goods-image/2025-12-26/1a788e0c-468a-4b6d-9389-cc2dab1f69a0.jpeg.a.jpeg?imageView2/2/w/1700/q/85");
|
|
||||||
|
|
||||||
//skuStrNew = skuStrNew.Replace("\"thumb_url_file_id\":null,", "");
|
//skuStrNew = skuStrNew.Replace("\"thumb_url_file_id\":null,", "");
|
||||||
//postData = postData.Replace(skuStr, skuStrNew);
|
//postData = postData.Replace(skuStr, skuStrNew);
|
||||||
|
|
||||||
postData = JsonHelper.SerializeObject(jObj);
|
postData = JsonHelper.SerializeObject(jObj);
|
||||||
|
|
||||||
request.PostData.Elements[0].Bytes = System.Text.Encoding.UTF8.GetBytes(postData);
|
request.PostData.Elements[0].Bytes = System.Text.Encoding.UTF8.GetBytes(postData);
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
public PDDProductUploadParam prodParam = null;
|
public PDDProductUploadParam prodParam = null;
|
||||||
|
|||||||
Reference in new issue
Block a user