供应商网站相关服务接口
This commit is contained in:
1 parent
3996dcce09
commit
c2c4c8da1a
2 files changed
+83
-28
No files matched your search
@@ -24,12 +24,15 @@ namespace KJD_Web.BLL.BXX
|
|||||||
if (time1 != EncrypUtil.Encryption(time))
|
if (time1 != EncrypUtil.Encryption(time))
|
||||||
return "{\"code\":50000,\"msg\":\"校验失败\"}";
|
return "{\"code\":50000,\"msg\":\"校验失败\"}";
|
||||||
|
|
||||||
string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name");
|
string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name")?.Replace("'", "\\'");
|
||||||
string from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id");
|
string from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id")?.Replace("'", "\\'");
|
||||||
string spu_id = RegexUtils.GetStringQuery(ref inputData, "spu_id");
|
string from_shop_name = RegexUtils.GetStringQuery(ref inputData, "from_shop_name")?.Replace("'", "\\'");
|
||||||
string skc_id = RegexUtils.GetStringQuery(ref inputData, "skc_id");
|
string offline_supplier_id = RegexUtils.GetStringQuery(ref inputData, "offline_supplier_id")?.Replace("'", "\\'");
|
||||||
string price_text = RegexUtils.GetStringQuery(ref inputData, "price_text");
|
string offline_supplier_name = RegexUtils.GetStringQuery(ref inputData, "offline_supplier_name")?.Replace("'", "\\'");
|
||||||
string main_cat_id = RegexUtils.GetStringQuery(ref inputData, "main_cat_id");
|
string spu_id = RegexUtils.GetStringQuery(ref inputData, "spu_id")?.Replace("'", "\\'");
|
||||||
|
string skc_id = RegexUtils.GetStringQuery(ref inputData, "skc_id")?.Replace("'", "\\'");
|
||||||
|
string price_text = RegexUtils.GetStringQuery(ref inputData, "price_text")?.Replace("'", "\\'");
|
||||||
|
string main_cat_id = RegexUtils.GetStringQuery(ref inputData, "main_cat_id")?.Replace("'", "\\'");
|
||||||
string main_cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "main_cat_name"))?.Replace("'", "\\'");
|
string main_cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "main_cat_name"))?.Replace("'", "\\'");
|
||||||
string cat_id = RegexUtils.GetStringQuery(ref inputData, "cat_id");
|
string cat_id = RegexUtils.GetStringQuery(ref inputData, "cat_id");
|
||||||
string cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cat_name"))?.Replace("'", "\\'");
|
string cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cat_name"))?.Replace("'", "\\'");
|
||||||
@@ -42,6 +45,7 @@ namespace KJD_Web.BLL.BXX
|
|||||||
string product_get_type = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_get_type"))?.Replace("'", "\\'");
|
string product_get_type = 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 = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count"))?.Replace("'", "\\'");
|
||||||
string sale_count_text = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count_text"))?.Replace("'", "\\'");
|
string sale_count_text = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count_text"))?.Replace("'", "\\'");
|
||||||
|
string distribution_set = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "distribution_set"))?.Replace("'", "\\'");
|
||||||
string special_prod_type = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "special_prod_type"))?.Replace("'", "\\'");
|
string special_prod_type = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "special_prod_type"))?.Replace("'", "\\'");
|
||||||
if (special_prod_type == null)
|
if (special_prod_type == null)
|
||||||
special_prod_type = "普通商品";
|
special_prod_type = "普通商品";
|
||||||
@@ -61,12 +65,13 @@ namespace KJD_Web.BLL.BXX
|
|||||||
string sql = "";
|
string sql = "";
|
||||||
sql = "insert into ";
|
sql = "insert into ";
|
||||||
sql += "bxx.product ";
|
sql += "bxx.product ";
|
||||||
sql +="(from_shop_id,spu_id,skc_id,main_cat_id,main_cat_name,cat_id,cat_name,price_text,product_name,ext_code," +
|
sql += "(from_shop_id,from_shop_name,offline_supplier_id,offline_supplier_name,spu_id,skc_id,main_cat_id,main_cat_name,cat_id,cat_name,price_text," +
|
||||||
"main_img,product_json,size_json,notes,product_get_type,sale_count,sale_count_text,special_prod_type,add_time,mdy_time) " +
|
"product_name,ext_code,main_img,product_json,size_json,notes,product_get_type,sale_count,sale_count_text,special_prod_type,distribution_set," +
|
||||||
"values ('" + from_shop_id + "','" + spu_id + "','" + skc_id + "','" + main_cat_id + "','" + main_cat_name + "','" +
|
"add_time,mdy_time) " +
|
||||||
cat_id + "','" + cat_name + "','" + price_text + "','" + product_name + "','" + ext_code + "','" + main_img + "','" +
|
"values ('" + from_shop_id + "','" + from_shop_name + "','" + offline_supplier_id + "','" + offline_supplier_name + "','" + spu_id + "','" +
|
||||||
product_json + "','" + size_json + "','" + notes + "','" + product_get_type + "','" + sale_count + "','" + sale_count_text + "','" +
|
skc_id + "','" + main_cat_id + "','" + main_cat_name + "','" + cat_id + "','" + cat_name + "','" + price_text + "','" + product_name + "','" +
|
||||||
special_prod_type + "','" +
|
ext_code + "','" + main_img + "','" + product_json + "','" + size_json + "','" + notes + "','" + product_get_type + "','" +
|
||||||
|
sale_count + "','" + sale_count_text + "','" + special_prod_type + "'," + distribution_set.ParseToInt() + ",'" +
|
||||||
DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "','" +
|
DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "','" +
|
||||||
DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "');";
|
DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "');";
|
||||||
var rst = mySql.ExecuteNonQuery(sql);
|
var rst = mySql.ExecuteNonQuery(sql);
|
||||||
@@ -93,14 +98,17 @@ namespace KJD_Web.BLL.BXX
|
|||||||
if (time1 != EncrypUtil.Encryption(time))
|
if (time1 != EncrypUtil.Encryption(time))
|
||||||
return "{\"code\":50000,\"msg\":\"校验失败\"}";
|
return "{\"code\":50000,\"msg\":\"校验失败\"}";
|
||||||
|
|
||||||
string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name");
|
string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name")?.Replace("'", "\\'");
|
||||||
string from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id");
|
string from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id")?.Replace("'", "\\'");
|
||||||
string spu_id = RegexUtils.GetStringQuery(ref inputData, "spu_id");
|
string from_shop_name = RegexUtils.GetStringQuery(ref inputData, "from_shop_name")?.Replace("'", "\\'");
|
||||||
string skc_id = RegexUtils.GetStringQuery(ref inputData, "skc_id");
|
string offline_supplier_id = RegexUtils.GetStringQuery(ref inputData, "offline_supplier_id")?.Replace("'", "\\'");
|
||||||
string price_text = RegexUtils.GetStringQuery(ref inputData, "price_text");
|
string offline_supplier_name = RegexUtils.GetStringQuery(ref inputData, "offline_supplier_name")?.Replace("'", "\\'");
|
||||||
string main_cat_id = RegexUtils.GetStringQuery(ref inputData, "main_cat_id");
|
string spu_id = RegexUtils.GetStringQuery(ref inputData, "spu_id")?.Replace("'", "\\'");
|
||||||
|
string skc_id = RegexUtils.GetStringQuery(ref inputData, "skc_id")?.Replace("'", "\\'");
|
||||||
|
string price_text = RegexUtils.GetStringQuery(ref inputData, "price_text")?.Replace("'", "\\'");
|
||||||
|
string main_cat_id = RegexUtils.GetStringQuery(ref inputData, "main_cat_id")?.Replace("'", "\\'");
|
||||||
string main_cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "main_cat_name"))?.Replace("'", "\\'");
|
string main_cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "main_cat_name"))?.Replace("'", "\\'");
|
||||||
string cat_id = RegexUtils.GetStringQuery(ref inputData, "cat_id");
|
string cat_id = RegexUtils.GetStringQuery(ref inputData, "cat_id")?.Replace("'", "\\'");
|
||||||
string cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cat_name"))?.Replace("'", "\\'");
|
string cat_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cat_name"))?.Replace("'", "\\'");
|
||||||
string ext_code = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "ext_code"))?.Replace("'", "\\'");
|
string ext_code = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "ext_code"))?.Replace("'", "\\'");
|
||||||
string product_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_name"))?.Replace("'", "\\'");
|
string product_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_name"))?.Replace("'", "\\'");
|
||||||
@@ -113,6 +121,10 @@ namespace KJD_Web.BLL.BXX
|
|||||||
string sale_count_text = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sale_count_text"))?.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("'", "\\'");
|
string wx_safe_status = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "wx_safe_status"))?.Replace("'", "\\'");
|
||||||
string special_prod_type = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "special_prod_type"))?.Replace("'", "\\'");
|
string special_prod_type = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "special_prod_type"))?.Replace("'", "\\'");
|
||||||
|
string wx_cate = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "wx_cate"))?.Replace("'", "\\'");
|
||||||
|
string delivery_fee_set = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "delivery_fee_set"))?.Replace("'", "\\'");
|
||||||
|
string after_sale_set = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "after_sale_set"))?.Replace("'", "\\'");
|
||||||
|
string distribution_set = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "distribution_set"))?.Replace("'", "\\'");
|
||||||
|
|
||||||
if (string.IsNullOrEmpty(user_name))
|
if (string.IsNullOrEmpty(user_name))
|
||||||
{
|
{
|
||||||
@@ -126,6 +138,12 @@ namespace KJD_Web.BLL.BXX
|
|||||||
sql = "update bxx.product p set";
|
sql = "update bxx.product p set";
|
||||||
if (from_shop_id != null)
|
if (from_shop_id != null)
|
||||||
sql += " p.from_shop_id='" + from_shop_id + "',";
|
sql += " p.from_shop_id='" + from_shop_id + "',";
|
||||||
|
if (from_shop_name != null)
|
||||||
|
sql += " p.from_shop_name='" + from_shop_name + "',";
|
||||||
|
if (offline_supplier_id != null)
|
||||||
|
sql += " p.offline_supplier_id='" + offline_supplier_id + "',";
|
||||||
|
if (offline_supplier_name != null)
|
||||||
|
sql += " p.offline_supplier_name='" + offline_supplier_name + "',";
|
||||||
if (main_cat_id != null)
|
if (main_cat_id != null)
|
||||||
sql += " p.main_cat_id='" + main_cat_id + "',";
|
sql += " p.main_cat_id='" + main_cat_id + "',";
|
||||||
if (main_cat_name != null)
|
if (main_cat_name != null)
|
||||||
@@ -158,6 +176,14 @@ namespace KJD_Web.BLL.BXX
|
|||||||
sql += " p.wx_safe_status='" + wx_safe_status + "',";
|
sql += " p.wx_safe_status='" + wx_safe_status + "',";
|
||||||
if (special_prod_type != null && special_prod_type != "")
|
if (special_prod_type != null && special_prod_type != "")
|
||||||
sql += " p.special_prod_type='" + special_prod_type + "',";
|
sql += " p.special_prod_type='" + special_prod_type + "',";
|
||||||
|
if (wx_cate != null)
|
||||||
|
sql += " p.wx_cate='" + wx_cate + "',";
|
||||||
|
if (delivery_fee_set != null)
|
||||||
|
sql += " p.delivery_fee_set='" + delivery_fee_set + "',";
|
||||||
|
if (after_sale_set != null)
|
||||||
|
sql += " p.after_sale_set='" + after_sale_set + "',";
|
||||||
|
if (distribution_set != null)
|
||||||
|
sql += " p.distribution_set='" + distribution_set + "',";
|
||||||
sql += " p.mdy_time='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',";
|
sql += " p.mdy_time='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',";
|
||||||
sql = sql.TrimEnd(',');
|
sql = sql.TrimEnd(',');
|
||||||
sql += " where spu_id='" + spu_id + "';";
|
sql += " where spu_id='" + spu_id + "';";
|
||||||
@@ -198,10 +224,12 @@ namespace KJD_Web.BLL.BXX
|
|||||||
var get_select_count = RegexUtils.GetStringQuery(ref inputData, "get_select_count")?.Replace("'", "\\'");
|
var get_select_count = RegexUtils.GetStringQuery(ref inputData, "get_select_count")?.Replace("'", "\\'");
|
||||||
var select_shop_id = RegexUtils.GetStringQuery(ref inputData, "select_shop_id")?.Replace("'", "\\'");
|
var select_shop_id = RegexUtils.GetStringQuery(ref inputData, "select_shop_id")?.Replace("'", "\\'");
|
||||||
var from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id")?.Replace("'", "\\'");
|
var from_shop_id = RegexUtils.GetStringQuery(ref inputData, "from_shop_id")?.Replace("'", "\\'");
|
||||||
|
var from_shop_name = RegexUtils.GetStringQuery(ref inputData, "from_shop_name")?.Replace("'", "\\'");
|
||||||
var product_get_type = RegexUtils.GetStringQuery(ref inputData, "product_get_type")?.Replace("'", "\\'");
|
var product_get_type = RegexUtils.GetStringQuery(ref inputData, "product_get_type")?.Replace("'", "\\'");
|
||||||
var sort_field = RegexUtils.GetStringQuery(ref inputData, "sort_field")?.Replace("'", "\\'");
|
var sort_field = RegexUtils.GetStringQuery(ref inputData, "sort_field")?.Replace("'", "\\'");
|
||||||
var wx_safe_status = RegexUtils.GetStringQuery(ref inputData, "wx_safe_status")?.Replace("'", "\\'");
|
var wx_safe_status = RegexUtils.GetStringQuery(ref inputData, "wx_safe_status")?.Replace("'", "\\'");
|
||||||
var special_prod_type = RegexUtils.GetStringQuery(ref inputData, "special_prod_type")?.Replace("'", "\\'");
|
var special_prod_type = RegexUtils.GetStringQuery(ref inputData, "special_prod_type")?.Replace("'", "\\'");
|
||||||
|
var is_supplier_prod_ok = RegexUtils.GetStringQuery(ref inputData, "is_supplier_prod_ok")?.Replace("'", "\\'");
|
||||||
|
|
||||||
int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt();
|
int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt();
|
||||||
int page_size= RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50);
|
int page_size= RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50);
|
||||||
@@ -214,6 +242,8 @@ namespace KJD_Web.BLL.BXX
|
|||||||
string where = "";
|
string where = "";
|
||||||
if (!string.IsNullOrEmpty(from_shop_id))
|
if (!string.IsNullOrEmpty(from_shop_id))
|
||||||
where += " and p.from_shop_id ='" + from_shop_id + "'";
|
where += " and p.from_shop_id ='" + from_shop_id + "'";
|
||||||
|
if (!string.IsNullOrEmpty(from_shop_name))
|
||||||
|
where += " and p.from_shop_name ='" + from_shop_name + "'";
|
||||||
if (!string.IsNullOrEmpty(search_db_ids))
|
if (!string.IsNullOrEmpty(search_db_ids))
|
||||||
where += " and p.id in (" + search_db_ids + ")";
|
where += " and p.id in (" + search_db_ids + ")";
|
||||||
if (!string.IsNullOrEmpty(product_get_type))
|
if (!string.IsNullOrEmpty(product_get_type))
|
||||||
@@ -237,6 +267,14 @@ namespace KJD_Web.BLL.BXX
|
|||||||
where += " and p.group like '%" + search_group + "%'";
|
where += " and p.group like '%" + search_group + "%'";
|
||||||
if (!string.IsNullOrWhiteSpace(search_notes))
|
if (!string.IsNullOrWhiteSpace(search_notes))
|
||||||
where += " and p.notes like '%" + search_notes + "%'";
|
where += " and p.notes like '%" + search_notes + "%'";
|
||||||
|
// 供应商货源是否已完成初始设置
|
||||||
|
if (!string.IsNullOrEmpty(is_supplier_prod_ok))
|
||||||
|
{
|
||||||
|
if (is_supplier_prod_ok == "1" || is_supplier_prod_ok == "已设置")
|
||||||
|
where += " and wx_cate!='' and delivery_fee_set=1 and after_sale_set=1 and distribution_set=1";
|
||||||
|
else
|
||||||
|
where += " and (wx_cate='' or delivery_fee_set=0 or after_sale_set=0 or distribution_set=0)";
|
||||||
|
}
|
||||||
sql += where;
|
sql += where;
|
||||||
|
|
||||||
var count = mySql.ExecuteRowCount(sql);
|
var count = mySql.ExecuteRowCount(sql);
|
||||||
@@ -254,18 +292,19 @@ namespace KJD_Web.BLL.BXX
|
|||||||
" LEFT JOIN bxx.ext_code_price e ON p.ext_code=e.ext_code" +
|
" LEFT JOIN bxx.ext_code_price e ON p.ext_code=e.ext_code" +
|
||||||
" where p.is_del=0";
|
" where p.is_del=0";
|
||||||
else if (string.IsNullOrEmpty(get_select_count))
|
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," +
|
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.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.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.sale_count,p.sale_count_text,p.special_prod_type,s.img_url,e.ext_code_price" +
|
" p.product_get_type,p.wx_safe_status,p.sale_count,p.sale_count_text,p.special_prod_type,p.from_shop_name,p.wx_cate," +
|
||||||
|
" s.img_url,e.ext_code_price" +
|
||||||
" FROM bxx.product p " +
|
" FROM bxx.product p " +
|
||||||
" left join bxx.sku_img_replace s ON p.sku_img_replace_id=s.id" +
|
" left join bxx.sku_img_replace s ON p.sku_img_replace_id=s.id" +
|
||||||
" LEFT JOIN bxx.ext_code_price e ON p.ext_code=e.ext_code" +
|
" LEFT JOIN bxx.ext_code_price e ON p.ext_code=e.ext_code" +
|
||||||
" where p.is_del=0";
|
" where p.is_del=0";
|
||||||
else
|
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," +
|
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.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.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.sale_count,p.sale_count_text,p.special_prod_type,s.img_url,COUNT(se.id) AS select_count," +
|
" p.product_get_type,p.wx_safe_status,p.sale_count,p.sale_count_text,p.special_prod_type,p.from_shop_name,p.wx_cate" +
|
||||||
" e.ext_code_price" +
|
" 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 + "' " +
|
" 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 + "' " +
|
||||||
" LEFT JOIN bxx.ext_code_price e ON p.ext_code=e.ext_code" +
|
" LEFT JOIN bxx.ext_code_price e ON p.ext_code=e.ext_code" +
|
||||||
" WHERE p.is_del=0";
|
" WHERE p.is_del=0";
|
||||||
@@ -295,10 +334,14 @@ namespace KJD_Web.BLL.BXX
|
|||||||
{
|
{
|
||||||
id = Convert.ToInt32(row["id"]),
|
id = Convert.ToInt32(row["id"]),
|
||||||
from_shop_id = row["from_shop_id"].ToString(),
|
from_shop_id = row["from_shop_id"].ToString(),
|
||||||
|
from_shop_name = row["from_shop_name"].ToString(),
|
||||||
|
//offline_supplier_id = row["offline_supplier_id"].ToString(),
|
||||||
|
//offline_supplier_name = row["offline_supplier_name"].ToString(),
|
||||||
skc_id = row["skc_id"].ToString(),
|
skc_id = row["skc_id"].ToString(),
|
||||||
spu_id = row["spu_id"].ToString(),
|
spu_id = row["spu_id"].ToString(),
|
||||||
cat_id = row["cat_id"].ToString(),
|
cat_id = row["cat_id"].ToString(),
|
||||||
cat_name = row["cat_name"].ToString(),
|
cat_name = row["cat_name"].ToString(),
|
||||||
|
wx_cate = row["wx_cate"].ToString(),
|
||||||
product_name = row["product_name"].ToString(),
|
product_name = row["product_name"].ToString(),
|
||||||
main_img = row["main_img"].ToString(),
|
main_img = row["main_img"].ToString(),
|
||||||
ext_code = row["ext_code"].ToString(),
|
ext_code = row["ext_code"].ToString(),
|
||||||
@@ -577,6 +620,7 @@ namespace KJD_Web.BLL.BXX
|
|||||||
var product_get_type = RegexUtils.GetStringQuery(ref inputData, "product_get_type")?.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("'", "\\'");
|
var wx_safe_status = RegexUtils.GetStringQuery(ref inputData, "wx_safe_status")?.Replace("'", "\\'");
|
||||||
var special_prod_type = RegexUtils.GetStringQuery(ref inputData, "special_prod_type")?.Replace("'", "\\'");
|
var special_prod_type = RegexUtils.GetStringQuery(ref inputData, "special_prod_type")?.Replace("'", "\\'");
|
||||||
|
var is_supplier_prod_ok = RegexUtils.GetStringQuery(ref inputData, "is_supplier_prod_ok")?.Replace("'", "\\'");
|
||||||
|
|
||||||
int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt();
|
int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt();
|
||||||
int page_size = RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50);
|
int page_size = RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50);
|
||||||
@@ -612,8 +656,15 @@ namespace KJD_Web.BLL.BXX
|
|||||||
if (!string.IsNullOrEmpty(wx_safe_status))
|
if (!string.IsNullOrEmpty(wx_safe_status))
|
||||||
where += " and p.wx_safe_status ='" + wx_safe_status + "'";
|
where += " and p.wx_safe_status ='" + wx_safe_status + "'";
|
||||||
if (!string.IsNullOrEmpty(special_prod_type))
|
if (!string.IsNullOrEmpty(special_prod_type))
|
||||||
where += " and p.special_prod_type ='" + special_prod_type + "'";
|
where += " and p.special_prod_type ='" + special_prod_type + "'";
|
||||||
|
// 供应商货源是否已完成初始设置
|
||||||
|
if (!string.IsNullOrEmpty(is_supplier_prod_ok))
|
||||||
|
{
|
||||||
|
if (is_supplier_prod_ok == "1" || is_supplier_prod_ok == "已设置")
|
||||||
|
where += " and wx_cate!='' and delivery_fee_set=1 and after_sale_set=1 and distribution_set=1";
|
||||||
|
else
|
||||||
|
where += " and (wx_cate='' or delivery_fee_set=0 or after_sale_set=0 or distribution_set=0)";
|
||||||
|
}
|
||||||
sql += where;
|
sql += where;
|
||||||
|
|
||||||
var count = mySql.ExecuteRowCount(sql);
|
var count = mySql.ExecuteRowCount(sql);
|
||||||
|
|||||||
@@ -12,12 +12,16 @@ namespace KJD_Web.Model
|
|||||||
{
|
{
|
||||||
public int id { get; set; }
|
public int id { get; set; }
|
||||||
public string from_shop_id { get; set; } = "";
|
public string from_shop_id { get; set; } = "";
|
||||||
|
public string from_shop_name { get; set; } = "";
|
||||||
|
public string offline_supplier_id { get; set; }
|
||||||
|
public string offline_supplier_name { get; set; }
|
||||||
public string spu_id { get; set; }
|
public string spu_id { get; set; }
|
||||||
public string skc_id { get; set; }
|
public string skc_id { get; set; }
|
||||||
public string main_cat_id { get; set; }
|
public string main_cat_id { get; set; }
|
||||||
public string cat_id { get; set; }
|
public string cat_id { get; set; }
|
||||||
public string main_cat_name { get; set; }
|
public string main_cat_name { get; set; }
|
||||||
public string cat_name { get; set; }
|
public string cat_name { get; set; }
|
||||||
|
public string wx_cate { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 母店价格
|
/// 母店价格
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
Reference in new issue
Block a user