微信小店上传商品完成

This commit is contained in:
wule committed 2026-01-14 19:24:22 +08:00
1 parent 0c2930bea5
commit 9e1a354ee5
35 files changed
+1965 -579

No files matched your search

@@ -40,8 +40,8 @@ namespace KJD_Web.BLL.BXX
string main_img = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "main_img"))?.Replace("'", "\\'");
string notes = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "notes"))?.Replace("'", "\\'");
string product_get_type = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_get_type"))?.Replace("'", "\\'");
string sale_count = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_get_type"))?.Replace("'", "\\'");
string sale_count_text = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_get_type"))?.Replace("'", "\\'");
string sale_count = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count"))?.Replace("'", "\\'");
string sale_count_text = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count_text"))?.Replace("'", "\\'");
if (string.IsNullOrEmpty(product_get_type))
{
product_get_type = "母店采集";
@@ -106,6 +106,7 @@ namespace KJD_Web.BLL.BXX
string notes = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "notes"))?.Replace("'", "\\'");
string sale_count = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count"))?.Replace("'", "\\'");
string sale_count_text = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count_text"))?.Replace("'", "\\'");
string wx_safe_status = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "wx_safe_status"))?.Replace("'", "\\'");
if (string.IsNullOrEmpty(user_name))
{
@@ -147,6 +148,8 @@ namespace KJD_Web.BLL.BXX
sql += " p.sale_count='" + sale_count + "',";
if (sale_count_text != null)
sql += " p.sale_count_text='" + sale_count_text + "',";
if (wx_safe_status != null)
sql += " p.wx_safe_status='" + wx_safe_status + "',";
sql += " p.mdy_time='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',";
sql = sql.TrimEnd(',');
sql += " where spu_id='" + spu_id + "';";
@@ -188,6 +191,7 @@ namespace KJD_Web.BLL.BXX
var from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id")?.Replace("'", "\\'");
var product_get_type = RegexUtils.GetStringQuery(ref inputData, "product_get_type")?.Replace("'", "\\'");
var sort_field = RegexUtils.GetStringQuery(ref inputData, "sort_field")?.Replace("'", "\\'");
var wx_safe_status = RegexUtils.GetStringQuery(ref inputData, "wx_safe_status")?.Replace("'", "\\'");
int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt();
int page_size= RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50);
@@ -216,6 +220,8 @@ namespace KJD_Web.BLL.BXX
where += " and p.from_shop_id ='" + from_shop_id + "'";
if (!string.IsNullOrEmpty(product_get_type))
where += " and p.product_get_type ='" + product_get_type + "'";
if (!string.IsNullOrEmpty(wx_safe_status))
where += " and p.wx_safe_status ='" + wx_safe_status + "'";
if (!string.IsNullOrEmpty(search_db_ids))
where += " and p.id in (" + search_db_ids + ")";
sql += where;
@@ -236,7 +242,7 @@ namespace KJD_Web.BLL.BXX
" where p.is_del=0";
else if (string.IsNullOrEmpty(get_select_count))
sql = "select p.id,p.from_shop_id,p.spu_id,p.skc_id,p.main_cat_id,p.main_cat_name,p.cat_id,p.cat_name,p.price_text,p.ext_code,p.product_name,p.main_img,p.notes," +
" p.add_time,p.mdy_time,p.select_total_count,p.fission_words,p.head_words,p.end_words,p.sku_img_replace_id,p.group,p.product_get_type," +
" p.add_time,p.mdy_time,p.select_total_count,p.fission_words,p.head_words,p.end_words,p.sku_img_replace_id,p.group,p.product_get_type,p.wx_safe_status," +
" p.sale_count,p.sale_count_text,s.img_url,e.ext_code_price" +
" FROM bxx.product p " +
" left join bxx.sku_img_replace s ON p.sku_img_replace_id=s.id" +
@@ -244,7 +250,7 @@ namespace KJD_Web.BLL.BXX
" where p.is_del=0";
else
sql = "SELECT p.id,p.from_shop_id,p.spu_id,p.skc_id,p.main_cat_id,p.main_cat_name,p.cat_id,p.cat_name,p.price_text,p.ext_code,p.product_name,p.main_img,p.notes," +
" p.add_time,p.mdy_time,p.select_total_count,p.fission_words,p.head_words,p.end_words,p.sku_img_replace_id,p.group,p.product_get_type," +
" p.add_time,p.mdy_time,p.select_total_count,p.fission_words,p.head_words,p.end_words,p.sku_img_replace_id,p.group,p.product_get_type,p.wx_safe_status," +
" p.sale_count,p.sale_count_text,s.img_url,COUNT(se.id) AS select_count," +
" e.ext_code_price" +
" FROM bxx.product p left join bxx.sku_img_replace s ON p.sku_img_replace_id=s.id LEFT JOIN bxx.product_select se ON p.id=se.out_product_id AND se.shop_id='" + select_shop_id + "' " +
@@ -300,6 +306,7 @@ namespace KJD_Web.BLL.BXX
product_get_type_text = row["product_get_type"].ToString(),
sale_count = row["sale_count"].ParseToInt(),
sale_count_text = row["sale_count_text"].ToString(),
wx_safe_status = row["wx_safe_status"].ToString(),
};
if (isDetail)
{
@@ -552,6 +559,7 @@ namespace KJD_Web.BLL.BXX
var in_groups = RegexUtils.GetStringQuery(ref inputData, "in_groups")?.Replace("'", "\\'");
var in_cates = RegexUtils.GetStringQuery(ref inputData, "in_cates")?.Replace("'", "\\'");
var product_get_type = RegexUtils.GetStringQuery(ref inputData, "product_get_type")?.Replace("'", "\\'");
var wx_safe_status = RegexUtils.GetStringQuery(ref inputData, "wx_safe_status")?.Replace("'", "\\'");
int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt();
int page_size = RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50);
@@ -584,6 +592,8 @@ namespace KJD_Web.BLL.BXX
}
if (!string.IsNullOrEmpty(product_get_type))
where += " and p.product_get_type ='" + product_get_type + "'";
if (!string.IsNullOrEmpty(wx_safe_status))
where += " and p.wx_safe_status ='" + wx_safe_status + "'";
sql += where;
@@ -598,7 +608,7 @@ namespace KJD_Web.BLL.BXX
{
sql = "select p.id,p.from_shop_id,p.spu_id,p.skc_id,p.main_cat_id,p.main_cat_name,p.cat_id,p.cat_name,p.price_text,p.ext_code," +
"p.product_name,p.main_img,p.group,p.notes,p.add_time,p.mdy_time,p.select_total_count,p.product_get_type,p.sale_count,p.sale_count_text," +
"p.fission_words,p.head_words,p.end_words from bxx.product p where p.is_del=0";
"p.fission_words,p.head_words,p.end_words,p.wx_safe_status from bxx.product p where p.is_del=0";
//where子句
sql += where;
@@ -643,6 +653,7 @@ namespace KJD_Web.BLL.BXX
product_get_type_text = row["product_get_type"].ParseToString(),
sale_count = row["sale_count"].ParseToInt(),
sale_count_text = row["sale_count_text"].ToString(),
wx_safe_status = row["wx_safe_status"].ToString(),
};
productLst.Add(prod);
}
@@ -858,6 +869,7 @@ namespace KJD_Web.BLL.BXX
string head_words = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "head_words"))?.Replace("'", "\\'");
string end_words = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "end_words"))?.Replace("'", "\\'");
string sku_edit_json = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sku_edit_json"))?.Replace("'", "\\'");
string wx_safe_status = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "wx_safe_status"))?.Replace("'", "\\'");
if (string.IsNullOrEmpty(user_name))
{
@@ -883,6 +895,8 @@ namespace KJD_Web.BLL.BXX
sql += " p.end_words='" + end_words + "',";
if (sku_edit_json != null)
sql += " p.sku_edit_json='" + sku_edit_json + "',";
if (wx_safe_status != null)
sql += " p.wx_safe_status='" + wx_safe_status + "',";
sql = sql.TrimEnd(',');
if (in_db_ids != null)
{