diff --git a/AllBase/AllBase.csproj b/AllBase/AllBase.csproj index 6d0045d..a5466b2 100644 --- a/AllBase/AllBase.csproj +++ b/AllBase/AllBase.csproj @@ -197,6 +197,7 @@ + diff --git a/AllBase/BaseClass.cs b/AllBase/BaseClass.cs index 9f8c483..48c199c 100644 --- a/AllBase/BaseClass.cs +++ b/AllBase/BaseClass.cs @@ -27,7 +27,7 @@ namespace AllBase /// /// 版本ID /// - public static int VersionCount = 883; + public static int VersionCount = 888; //public static int VersionCount = 613; /// diff --git a/AllBase/GetHtml.cs b/AllBase/GetHtml.cs index b952e17..8700563 100644 --- a/AllBase/GetHtml.cs +++ b/AllBase/GetHtml.cs @@ -1186,6 +1186,12 @@ Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrom request.ReadWriteTimeout = BaseClass.TimeOut * 1000; request.Proxy = null; request.ContentType = "application/x-www-form-urlencoded; charset=" + codeType; + if(BaseClass.SaLevel > 0) + { + //260306 采用GZip/deflate压缩 + //request.Headers.Set(HttpRequestHeader.AcceptEncoding, "gzip, deflate, br, zstd"); + request.Headers.Set(HttpRequestHeader.AcceptEncoding, "gzip, deflate"); + } if (url.StartsWith("https://openapi.jinritemai.com/")) { request.Headers.Add("X-USE-BOE", "1"); @@ -1208,7 +1214,17 @@ Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrom Stream receiveStream = response.GetResponseStream(); StreamReader readStream = new StreamReader(receiveStream, Encoding.GetEncoding(codeType)); - return readStream.ReadToEnd().Trim(); + + if (BaseClass.SaLevel == 0) + { + return readStream.ReadToEnd().Trim(); + } + else + { + //260306 超管采用GZip/deflate压缩 + Thread.Sleep(50); + return GetProxyHtml.ReadResponse(response); + } } catch (Exception e) { @@ -1218,6 +1234,7 @@ Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrom // isError = true; // goto reTry; //} + Thread.Sleep(50); return ""; } diff --git a/AllBase/Model/Result/JST/JSTOrderInfo.cs b/AllBase/Model/Result/JST/JSTOrderInfo.cs new file mode 100644 index 0000000..066701c --- /dev/null +++ b/AllBase/Model/Result/JST/JSTOrderInfo.cs @@ -0,0 +1,173 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace AllBase.Model.Result.JST +{ + public class JSTOrderDataInfo + { + public int? code { get; set; } // 0 //错误码 + public string msg { get; set; } // 执行成功 //错误描述 + public JSTDataInfo data { get; set; } + } + + public class JSTDataInfo + { + public int? page_size { get; set; } // 2 每页多少条 + public int? page_index { get; set; } // 1 第几页 + public int? data_count { get; set; } // 2 总条数 + public int? page_count { get; set; } // 1 总页数 + public bool? has_next { get; set; } // false 是否有下一页 + /// + /// 订单数据合集 + /// + public List orders { get; set; } + } + + public class JSTOrderInfo + { + public bool? is_cod { get; set; } // boolean false 是否货到付款 + public string l_id { get; set; } // string 快递单号 + public string send_date { get; set; } // string 发货日期 + public string pay_date { get; set; } // string 2019-12-16 16:35:28 支付时间 + public string freight { get; set; } // string 4.0 买家支付运费,保留两位小数,单位(元) + public string first_freight { get; set; } // string 跨境订单-头程运费 + public string outerwms_freight { get; set; } // string 跨境订单-尾程运费 + public string receiver_address { get; set; } // string 收货地址 + public string receiver_district { get; set; } // string 区 + public string wms_co_id { get; set; } // string 0 发货仓编号(当值为0表示主仓) + public string logistics_company { get; set; } // string 快递公司 + public long? as_id { get; set; } // number 补发换货单对应的售后单号 + public decimal? free_amount { get; set; } // number 抵扣金额 + public string shop_name { get; set; } // string 川梣铺子 店铺名称 + public string question_type { get; set; } // string 等待订单合并 问题类型,仅当问题订单时有效 + public string outer_pay_id { get; set; } // string 20210928 外部支付单号 + public string so_id { get; set; } // string 20210928 线上订单号,线上同步过来的订单号,最长不超过20;唯一 + public string type { get; set; } // string 普通订单 订单类型,普通订单;补发订单;分销Plus;供销Plus;换货订单 + public string order_from { get; set; } // string open 订单来源,ERP:手工下单; COPY:复制; MERGE:合并; SPLIT:拆分;拆分还原; MOBILE:京东; IMPORT:导入; drp-s:供销推送; drp-d:分销推送; KWAISHOP:快手;微商城; PINDUODUO;拼多多; TOUTIAOFXG;头条放心购 + public string status { get; set; } // string Question 聚水潭订单状态 待付款:WaitPay;发货中:Delivering;被合并:Merged;异常:Question;被拆分:Split;等供销商|外仓发货:WaitOuterSent;已付款待审核:WaitConfirm;已客审待财审:WaitFConfirm;已发货:Sent;取消:Cancelled + public long? pay_amount { get; set; } // number 应付金额,保留两位小数,单位(元) + public string shop_buyer_id { get; set; } // string 买家昵称 + public string open_id { get; set; } // string 平台买家唯一值,仅限平台已经支持的才会返回 + public string shop_status { get; set; } // string 平台订单状态: 等待买家付款=WAIT_BUYER_PAY, 等待卖家发货=WAIT_SELLER_SEND_GOODS,等待买家确认收货=WAIT_BUYER_CONFIRM_GOODS, 交易成功=TRADE_FINISHED, 付款后交易关闭=TRADE_CLOSED,付款前交易关闭=TRADE_CLOSED_BY_TAOBAO; https://jushuitan.yuque.com/cscvxv/al2cbn/ycunxb?singleDoc#8lWt 《平台订单shop_status字段枚举》 密码:tyuy + public string receiver_mobile { get; set; } // string 手机 + public string receiver_phone { get; set; } // string 电话 + public string order_date { get; set; } // string 2019-12-15 18:14:26 订单日期 + public string question_desc { get; set; } // string 问题描述 + public string receiver_city { get; set; } // string 收件信息-市 + public string receiver_state { get; set; } // string 收件信息-省 + public string receiver_name { get; set; } // string 收件信息-收件人 + public long? o_id { get; set; } // integer 38852 ERP内部订单号,聚水潭生成的订单号,唯一 + public long? shop_id { get; set; } // integer 11690153 店铺编号 + public long? co_id { get; set; } // integer 11053062 公司编号 + public string remark { get; set; } // string 订单备注;卖家备注 + public string package_no { get; set; } // string 参考号 + public string warehouse_oid { get; set; } // string 外部单据号 + public string drp_co_id_from { get; set; } // string 分销商编号 + public string modified { get; set; } // string 2021-09-28 16:08:13 最后修改时间 + public string labels { get; set; } // string 延时发货 多标签 + public long? paid_amount { get; set; } // number pay节点的支付金额 + public string platform_free_amount { get; set; } // string 营收小计:平台优惠;null值处理成了空字符串返回,实际有值的是number类型返回 + public string pay_free_amount { get; set; } // string 营收小计:支付优惠;null值处理成了空字符串返回,实际有值的是number类型返回 + public string referrer_free_amount { get; set; } // string 营收小计:达人优惠;null值处理成了空字符串返回,实际有值的是number类型返回 + public string shop_free_amount { get; set; } // string 营收小计:店铺优惠;null值处理成了空字符串返回,实际有值的是number类型返回 + public string currency { get; set; } // string 币种 + public string buyer_message { get; set; } // string 买家留言 + public string lc_id { get; set; } // string 物流公司编码 + public string cb_total_tax { get; set; } // string 跨境平台税金 + public string invoice_title { get; set; } // string 发票抬头 + public string invoice_type { get; set; } // string 发票类型 + public long? invoice_amount { get; set; } // number 发票金额 + public string buyer_tax_no { get; set; } // string 发票税号 + public string creator_name { get; set; } // string 订单业务员 + public string plan_delivery_date { get; set; } // string 计划发货时间 + public string node { get; set; } // string 线下备注 + public string receiver_town { get; set; } // string 收件信息-街道 + public string drp_co_id_to { get; set; } // string 供销商编号 + public string shop_site { get; set; } // string 商家自有商城 店铺站点信息 + public string un_lid { get; set; } // string 国际物流单号 + public string end_time { get; set; } // string 确认收货时间(仅限淘系平台,头条放心购、拼多多、苏宁易购、快手电商、有赞微商城,如果线上状态为取消,该时间为完结时间) + public string receiver_country { get; set; } // string 国家代码;(映射关系参考https://openweb.jushuitan.com/doc?docId=225) + public string receiver_zip { get; set; } // string 邮编 + public long? seller_flag { get; set; } // integer 旗帜(1红旗,2黄旗,3绿旗,4蓝旗,5紫旗) + public string receiver_email { get; set; } // string 收货邮箱 + public string referrer_id { get; set; } // string 主播id + public string referrer_name { get; set; } // string 主播名称 + public string created { get; set; } // string 2021-09-28 16:08:13 订单创建时间 + /// + /// 支付信息 + /// + public List pays { get; set; } + /// + /// 商品信息 + /// + public List items { get; set; } + + public string skus { get; set; } // string 商品(商品总数.sku_id* qty) + public decimal? f_weight { get; set; } // number 实称重量 + public decimal? weight { get; set; } // number 重量 + public long? ts { get; set; } // integer 数据库行版本号:https://docs.microsoft.com/zh-cn/sql/t-sql/data-types/rowversion-transact-sql?view=sql-server-ver16 + public string buyer_id { get; set; } // string 买家ID(系统根据shop_buyer_id生成的) + public decimal? buyer_paid_amount { get; set; } // number 营收小计:买家实付(仅限爱库存,阿里巴巴,百度小店,得物,饿百零售,好食期,好衣库,京东,快团团,快手电商,蘑菇街,团好货,拼多多,杉杉商业,淘宝天猫,头条放心购,小红书,有赞) + public decimal? seller_income_amount { get; set; } // number 营收小计:卖家实收(仅限淘宝天猫,爱库存,阿里巴巴,百度小店,得物,饿百零售,好食期,好衣库,京东,快团团,快手电商,蘑菇街,团好货,拼多多,杉杉商业,头条放心购,小红书,有赞) + public string chosen_channel { get; set; } // string 实发快递渠道 + public string channel_name { get; set; } // string 发货渠道(自定义之后的名称) + public string cb_lc_code { get; set; } // string 渠道编码 + public string cb_lc_name { get; set; } // string 发货渠道(自定义之前的名称) + public string link_o_id { get; set; } // string 被合并被拆分的订单内部单号 + public string merge_so_id { get; set; } // string 合并线上订单号 + public string shipment { get; set; } // string 买家指定物流 + public string sign_time { get; set; } // string 预计送达时间 + + // ... + } + + public class JSTItemInfo + { + public bool? is_gift { get; set; } // boolean false 是否赠品 + public string sku_id { get; set; } // string CY001 原始商品编码 + public string name { get; set; } // string CY001 商品名称 + public string refund_status { get; set; } // string 申请退款的状态, 未申请:none;退款中:waiting;退款成功:success;退款关闭:closed + public string refund_id { get; set; } // string 退款的唯一单号 + public decimal? price { get; set; } // number 单价 + public string outer_oi_id { get; set; } // string 201911 子订单号,商家系统订单商品明细主键,为了拆单合单时溯源,最长不超过50 + public string item_status { get; set; } // string 商品状态;None:无;WaitPay:待付款;WaitConfirm:等待审核;Question:异常;WaitDeliver:平台接口告知ERP订单项解锁可发货的状态; WaitFConfirm:等待财务审核;Delivering:发货中;WaitOuterSent:等待外仓发货;Sent:已发货;OuterSent:外仓发货;Merged:被合并;Cancelled:用户取消订单;Replaced:被替换(明细);Split:被拆分; Delete:删除;Lock:锁定;SentCancelled:发货后取消。非必填字段可以为null,不表示任何含义 + public string i_id { get; set; } // string 001 款式编码 + public string properties_value { get; set; } // string CY001 属性 + public long? oi_id { get; set; } // integer 39845 子订单号,最长不超过20 + public decimal? amount { get; set; } // number 223.0 总额 + public string shop_sku_id { get; set; } // string 201911 店铺商品编码,对应店铺商品资料页面平台店铺商品编码 + public string raw_so_id { get; set; } // string 20210928 原始线上单号 + public int? qty { get; set; } // integer 1 数量 + public bool? is_presale { get; set; } // boolean 是否预售 + public decimal? base_price { get; set; } // number 223.0 基本售价(原价) + public string pic { get; set; } // string 商品图片 + public string sku_type { get; set; } // string normal 商品类型;nomal:普通商品;combine:组合装商品;no_deliver:不发货 + public string shop_i_id { get; set; } // string 店铺款式编码 + public decimal? buyer_paid_amount { get; set; } // number 营收小计:买家实付(仅限爱库存,阿里巴巴,百度小店,得物,饿百零售,好食期,好衣库,京东,快团团,快手电商,蘑菇街,团好货,拼多多,杉杉商业,淘宝天猫,头条放心购,小红书,有赞) + public decimal? seller_income_amount { get; set; } // number 营收小计:卖家实收(仅限淘宝天猫,爱库存,阿里巴巴,百度小店,得物,饿百零售,好食期,好衣库,京东,快团团,快手电商,蘑菇街,团好货,拼多多,杉杉商业,头条放心购,小红书,有赞) + public string referrer_id { get; set; } // string 主播ID + public string lwh_id { get; set; } // string 虚拟仓编号 + public string lwh_name { get; set; } // string 虚拟仓名称 + public string remark { get; set; } // string 明细备注 + public string produced_date { get; set; } // string 生产日期 + public string batch_id { get; set; } // string 批次号 + public string item_ext_data { get; set; } // string 订单明细扩展字段 + } + + public class JSTPayInfo + { + public bool? is_order_pay { get; set; } // boolean true 是否支付 + public string buyer_account { get; set; } // string 38 支付帐号 + public decimal? amount { get; set; } // number 706.0 支付金额 + public string pay_date { get; set; } // string 2019-12-1616:35:28 支付时间 + public string outer_pay_id { get; set; } // string 20210928 外部支付单号 + public string pay_id { get; set; } // string 37163 支付单ID + public string payment { get; set; } // string 微信 支付方式 + public string status { get; set; } // string 支付状态(None:无 / 未定义;WaitConfirm:待审核;Confirmed:已确认;Finished:完成;Cancelled:作废;Deleted:删除;Lock:锁定;VirtualFinished:虚拟完成;Replace:替换;Reset:重置;Reserve:预占(保留)) + public string pay_type { get; set; } // string 支付类型(1 支付,-1 退款) + public long? o_id { get; set; } // number 内部订单号 + } +} diff --git a/AllBase/Model/Result/KJDDBProduct.cs b/AllBase/Model/Result/KJDDBProduct.cs index ff61253..93a9634 100644 --- a/AllBase/Model/Result/KJDDBProduct.cs +++ b/AllBase/Model/Result/KJDDBProduct.cs @@ -94,6 +94,9 @@ namespace AllBase.Model.Result public int? distribution_set { get; set; } public int? send_to_out_server { get; set; } + + public string standby3 { get; set; } + /// /// 是否有完善后的微信回采商品数据(详情存在微信回采数据表内) /// diff --git a/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs b/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs index 8050875..4d518cd 100644 --- a/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs +++ b/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs @@ -148,6 +148,7 @@ namespace KJD_Web.BLL.BXX string sku_edit_json = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sku_edit_json"))?.Replace("'", "\\'"); string sku_secret_json = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "sku_secret_json"))?.Replace("'", "\\'"); string wx_img_map_json = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "wx_img_map_json"))?.Replace("'", "\\'"); + string standby3 = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "standby3"))?.Replace("'", "\\'"); if (string.IsNullOrEmpty(user_name)) { @@ -223,6 +224,8 @@ namespace KJD_Web.BLL.BXX sql += " p.sku_secret_json=@sku_secret_json,"; if (wx_img_map_json != null) sql += " p.wx_img_map_json=@wx_img_map_json,"; + if (!standby3.IsNullOrEmpty()) + sql += " p.standby3=" + standby3 + ","; sql += " p.mdy_time='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',"; sql = sql.TrimEnd(','); sql += " where spu_id='" + spu_id + "';"; @@ -342,6 +345,9 @@ namespace KJD_Web.BLL.BXX var search_skc = RegexUtils.GetStringQuery(ref inputData, "search_skc")?.Replace("'", "\\'"); var search_cat1 = RegexUtils.GetStringQuery(ref inputData, "search_cat1")?.Replace("'", "\\'"); var search_cat = RegexUtils.GetStringQuery(ref inputData, "search_cat")?.Replace("'", "\\'"); + var wx_cat_1 = RegexUtils.GetStringQuery(ref inputData, "wx_cat_1")?.Replace("'", "\\'"); + var wx_cat_2 = RegexUtils.GetStringQuery(ref inputData, "wx_cat_2")?.Replace("'", "\\'"); + var wx_cat_3 = RegexUtils.GetStringQuery(ref inputData, "wx_cat_3")?.Replace("'", "\\'"); var search_ext_code = RegexUtils.GetStringQuery(ref inputData, "search_ext_code")?.Replace("'", "\\'"); var search_prod_name = RegexUtils.GetStringQuery(ref inputData, "search_prod_name")?.Replace("'", "\\'"); var search_group = RegexUtils.GetStringQuery(ref inputData, "search_group")?.Replace("'", "\\'"); @@ -360,6 +366,9 @@ namespace KJD_Web.BLL.BXX var has_wx_cat = RegexUtils.GetStringQuery(ref inputData, "has_wx_cat")?.Replace("'", "\\'"); var send_to_out_server = RegexUtils.GetStringQuery(ref inputData, "send_to_out_server")?.Replace("'", "\\'"); var has_send_to_out_server = RegexUtils.GetStringQuery(ref inputData, "has_send_to_out_server")?.Replace("'", "\\'"); + var real_coid = RegexUtils.GetStringQuery(ref inputData, "real_coid")?.Replace("'", "\\'"); + var has_wx_format = RegexUtils.GetStringQuery(ref inputData, "has_wx_format")?.Replace("'", "\\'"); + var standby3 = RegexUtils.GetStringQuery(ref inputData, "standby3")?.Replace("'", "\\'"); int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt(); int page_size= RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(50); @@ -415,6 +424,14 @@ namespace KJD_Web.BLL.BXX where += " and p.group like '%" + search_group + "%'"; if (!string.IsNullOrWhiteSpace(search_notes)) where += " and p.notes like '%" + search_notes + "%'"; + + if (!string.IsNullOrWhiteSpace(wx_cat_1)) + where += " and p.wx_cat_1 in (" + wx_cat_1 + ")"; + if (!string.IsNullOrWhiteSpace(wx_cat_2)) + where += " and p.wx_cat_2 in (" + wx_cat_2 + ")"; + if (!string.IsNullOrWhiteSpace(wx_cat_3)) + where += " and p.wx_cat_3 in (" + wx_cat_3 + ")"; + if (!string.IsNullOrEmpty(has_wx_cat)) { if (has_wx_cat.ToLower() == "true") @@ -443,6 +460,18 @@ namespace KJD_Web.BLL.BXX else where += " and (wx_cat_leaf IS NULL or send_to_out_server!=1 or distribution_set=0)"; } + if (!string.IsNullOrEmpty(real_coid)) + { + where += " and real_coid='" + real_coid + "'"; + } + if (!string.IsNullOrEmpty(has_wx_format)) + { + where += " and has_wx_format='" + has_wx_format + "'"; + } + if (!string.IsNullOrEmpty(standby3)) + { + where += " and standby3 is null"; + } sql += where; var count = 0; @@ -846,6 +875,8 @@ namespace KJD_Web.BLL.BXX var search_spu_ids = RegexUtils.GetStringQuery(ref inputData, "search_spu_ids")?.Replace("'", "\\'"); var search_sku_codes = RegexUtils.GetStringQuery(ref inputData, "search_sku_codes")?.Replace("'", "\\'"); var search_secret_spu_ids = RegexUtils.GetStringQuery(ref inputData, "search_secret_spu_ids")?.Replace("'", "\\'"); + if (search_spu_ids.IsNullOrEmpty() && search_sku_codes.IsNullOrEmpty() && search_secret_spu_ids.IsNullOrEmpty()) + return "{\"code\":500,\"msg\":\"查询条件不能全部为空\",\"data\":[],\"count\":" + 0 + "}"; int page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt(); int page_size = RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(1000); diff --git a/TEMUKJD/BLL/WXHttpResponseBLL.cs b/TEMUKJD/BLL/WXHttpResponseBLL.cs index fc6ca03..9add9e8 100644 --- a/TEMUKJD/BLL/WXHttpResponseBLL.cs +++ b/TEMUKJD/BLL/WXHttpResponseBLL.cs @@ -329,8 +329,10 @@ namespace TemuKJD.BLL return result; } - public static string e57PostResponse(string _url, string _data, string referer) + public static string e57PostResponse(string _url, string _data, string referer, string Authorization = null) { + if (string.IsNullOrEmpty(Authorization)) + Authorization = "Bearer eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6IjQ3YmRlOGNlLWY5MDUtNDIzOS05M2VjLWZiN2U3MjRmOTY0NiJ9.vwxhj3t4zTDdBQTyfVjcKr-0Oma8-VtPDzE2LVkw4A4aWftncY1ikXgEhGwoYHn9E7yOnhS_Pb7FfzgecTqqHA"; HttpWebResponse response = null; string result; try @@ -360,6 +362,7 @@ namespace TemuKJD.BLL request.Headers.Add("sec-ch-ua-mobile", @"?0"); request.Headers.Add("sec-ch-ua-platform", @"""Windows"""); request.Headers.Add("Upgrade-Insecure-Requests", @"1"); + request.Headers.Add("Authorization", Authorization); request.UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/144.0.0.0 Safari/537.36"; request.Accept = "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7"; request.Headers.Add("Sec-Fetch-Site", @"none"); diff --git a/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.Designer.cs b/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.Designer.cs index f496c40..b021bcf 100644 --- a/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.Designer.cs +++ b/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.Designer.cs @@ -49,6 +49,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle17 = new System.Windows.Forms.DataGridViewCellStyle(); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(PDDDBProdListForm)); this.splitContainer1 = new System.Windows.Forms.SplitContainer(); + this.btnReturnSecretData = new DevComponents.DotNetBar.PanelEx(); this.btnStopStop = new DevComponents.DotNetBar.PanelEx(); this.btnPull = new DevComponents.DotNetBar.PanelEx(); this.btnPushToOutServer = new DevComponents.DotNetBar.PanelEx(); @@ -63,8 +64,14 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.label8 = new System.Windows.Forms.Label(); this.txtReplaceText = new System.Windows.Forms.TextBox(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); + this.chkHasReturn = new TemuKJD.UserComponent.UcCheckBox(this.components); + this.chkWXComplateProd = new TemuKJD.UserComponent.UcCheckBox(this.components); + this.txtRealCoid = new System.Windows.Forms.TextBox(); + this.cmbCat2 = new System.Windows.Forms.ComboBox(); + this.label1 = new System.Windows.Forms.Label(); this.label16 = new System.Windows.Forms.Label(); this.txtSecretStyleCode = new System.Windows.Forms.TextBox(); + this.label14 = new System.Windows.Forms.Label(); this.label15 = new System.Windows.Forms.Label(); this.label13 = new System.Windows.Forms.Label(); this.cmbSourceType = new System.Windows.Forms.ComboBox(); @@ -87,10 +94,12 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.txtProdName = new System.Windows.Forms.TextBox(); this.cmbWxSafe = new System.Windows.Forms.ComboBox(); this.lblWxSafe = new System.Windows.Forms.Label(); - this.label2 = new System.Windows.Forms.Label(); - this.cmbCat1 = new System.Windows.Forms.ComboBox(); this.lblNotes = new System.Windows.Forms.Label(); this.txtNotes = new System.Windows.Forms.TextBox(); + this.cmbCat1 = new System.Windows.Forms.ComboBox(); + this.label2 = new System.Windows.Forms.Label(); + this.cmbCat3 = new System.Windows.Forms.ComboBox(); + this.label17 = new System.Windows.Forms.Label(); this.btnExportTxt = new DevComponents.DotNetBar.PanelEx(); this.btnDelSelect = new DevComponents.DotNetBar.PanelEx(); this.cmbGroup = new System.Windows.Forms.ComboBox(); @@ -99,9 +108,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.chkPullAfterPush = new TemuKJD.UserComponent.UcCheckBox(this.components); this.splitContainer2 = new System.Windows.Forms.SplitContainer(); this.cmbSpProdType = new System.Windows.Forms.ComboBox(); - this.cmbCat2 = new System.Windows.Forms.ComboBox(); this.btnGetAllCate = new DevComponents.DotNetBar.PanelEx(); - this.label14 = new System.Windows.Forms.Label(); this.pnlEditExtCodePrice = new System.Windows.Forms.Panel(); this.lblExtCode = new System.Windows.Forms.Label(); this.panel2 = new System.Windows.Forms.Panel(); @@ -116,6 +123,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.colSelect = new System.Windows.Forms.DataGridViewCheckBoxColumn(); this.col_db_id = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colFromShopId = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colFromShopName = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.col_product_name = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colImgUrl = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colMainImg = new System.Windows.Forms.DataGridViewImageColumn(); @@ -174,6 +182,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // // splitContainer1.Panel1 // + this.splitContainer1.Panel1.Controls.Add(this.btnReturnSecretData); this.splitContainer1.Panel1.Controls.Add(this.btnStopStop); this.splitContainer1.Panel1.Controls.Add(this.btnPull); this.splitContainer1.Panel1.Controls.Add(this.btnPushToOutServer); @@ -202,13 +211,38 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.splitContainer1.SplitterDistance = 110; this.splitContainer1.TabIndex = 1; // + // btnReturnSecretData + // + this.btnReturnSecretData.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnReturnSecretData.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.btnReturnSecretData.Cursor = System.Windows.Forms.Cursors.Hand; + this.btnReturnSecretData.DisabledBackColor = System.Drawing.Color.Empty; + this.btnReturnSecretData.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.btnReturnSecretData.Location = new System.Drawing.Point(750, 79); + this.btnReturnSecretData.Name = "btnReturnSecretData"; + this.btnReturnSecretData.Size = new System.Drawing.Size(94, 25); + this.btnReturnSecretData.Style.Alignment = System.Drawing.StringAlignment.Center; + this.btnReturnSecretData.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnReturnSecretData.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnReturnSecretData.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.btnReturnSecretData.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.btnReturnSecretData.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.btnReturnSecretData.Style.ForeColor.Color = System.Drawing.Color.White; + this.btnReturnSecretData.Style.GradientAngle = 90; + this.btnReturnSecretData.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.btnReturnSecretData.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnReturnSecretData.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnReturnSecretData.TabIndex = 909; + this.btnReturnSecretData.Text = "加密数据回传"; + this.btnReturnSecretData.Click += new System.EventHandler(this.btnReturnSecretData_Click); + // // btnStopStop // this.btnStopStop.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.btnStopStop.CanvasColor = System.Drawing.SystemColors.Control; this.btnStopStop.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; this.btnStopStop.DisabledBackColor = System.Drawing.Color.Empty; - this.btnStopStop.Location = new System.Drawing.Point(672, 23); + this.btnStopStop.Location = new System.Drawing.Point(672, 13); this.btnStopStop.Name = "btnStopStop"; this.btnStopStop.Size = new System.Drawing.Size(76, 25); this.btnStopStop.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -234,7 +268,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.btnPull.Cursor = System.Windows.Forms.Cursors.Hand; this.btnPull.DisabledBackColor = System.Drawing.Color.Empty; this.btnPull.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnPull.Location = new System.Drawing.Point(810, 57); + this.btnPull.Location = new System.Drawing.Point(810, 47); this.btnPull.Name = "btnPull"; this.btnPull.Size = new System.Drawing.Size(34, 25); this.btnPull.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -259,7 +293,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.btnPushToOutServer.Cursor = System.Windows.Forms.Cursors.Hand; this.btnPushToOutServer.DisabledBackColor = System.Drawing.Color.Empty; this.btnPushToOutServer.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnPushToOutServer.Location = new System.Drawing.Point(750, 57); + this.btnPushToOutServer.Location = new System.Drawing.Point(750, 47); this.btnPushToOutServer.Name = "btnPushToOutServer"; this.btnPushToOutServer.Size = new System.Drawing.Size(58, 25); this.btnPushToOutServer.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -284,7 +318,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.btnGetProdWxCate.Cursor = System.Windows.Forms.Cursors.Hand; this.btnGetProdWxCate.DisabledBackColor = System.Drawing.Color.Empty; this.btnGetProdWxCate.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnGetProdWxCate.Location = new System.Drawing.Point(750, 23); + this.btnGetProdWxCate.Location = new System.Drawing.Point(750, 13); this.btnGetProdWxCate.Name = "btnGetProdWxCate"; this.btnGetProdWxCate.Size = new System.Drawing.Size(94, 25); this.btnGetProdWxCate.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -454,8 +488,14 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 16.66666F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle()); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle()); + this.tableLayoutPanel1.Controls.Add(this.chkHasReturn, 10, 2); + this.tableLayoutPanel1.Controls.Add(this.chkWXComplateProd, 8, 2); + this.tableLayoutPanel1.Controls.Add(this.txtRealCoid, 0, 2); + this.tableLayoutPanel1.Controls.Add(this.cmbCat2, 5, 2); + this.tableLayoutPanel1.Controls.Add(this.label1, 0, 2); this.tableLayoutPanel1.Controls.Add(this.label16, 0, 1); this.tableLayoutPanel1.Controls.Add(this.txtSecretStyleCode, 5, 0); + this.tableLayoutPanel1.Controls.Add(this.label14, 4, 2); this.tableLayoutPanel1.Controls.Add(this.label15, 4, 0); this.tableLayoutPanel1.Controls.Add(this.label13, 10, 1); this.tableLayoutPanel1.Controls.Add(this.cmbSourceType, 5, 1); @@ -478,10 +518,12 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.tableLayoutPanel1.Controls.Add(this.txtProdName, 9, 0); this.tableLayoutPanel1.Controls.Add(this.cmbWxSafe, 9, 1); this.tableLayoutPanel1.Controls.Add(this.lblWxSafe, 8, 1); - this.tableLayoutPanel1.Controls.Add(this.label2, 0, 2); - this.tableLayoutPanel1.Controls.Add(this.cmbCat1, 1, 2); this.tableLayoutPanel1.Controls.Add(this.lblNotes, 2, 0); this.tableLayoutPanel1.Controls.Add(this.txtNotes, 3, 0); + this.tableLayoutPanel1.Controls.Add(this.cmbCat1, 3, 2); + this.tableLayoutPanel1.Controls.Add(this.label2, 2, 2); + this.tableLayoutPanel1.Controls.Add(this.cmbCat3, 7, 2); + this.tableLayoutPanel1.Controls.Add(this.label17, 6, 2); this.tableLayoutPanel1.Location = new System.Drawing.Point(4, 4); this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.RowCount = 3; @@ -491,6 +533,60 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.tableLayoutPanel1.Size = new System.Drawing.Size(650, 105); this.tableLayoutPanel1.TabIndex = 679; // + // chkHasReturn + // + this.chkHasReturn.Anchor = System.Windows.Forms.AnchorStyles.Left; + this.chkHasReturn.Location = new System.Drawing.Point(495, 77); + this.chkHasReturn.Margin = new System.Windows.Forms.Padding(6, 3, 3, 3); + this.chkHasReturn.Name = "chkHasReturn"; + this.chkHasReturn.Size = new System.Drawing.Size(57, 21); + this.chkHasReturn.TabIndex = 910; + this.chkHasReturn.Text = "未回传"; + this.chkHasReturn.UseVisualStyleBackColor = true; + // + // chkWXComplateProd + // + this.chkWXComplateProd.Anchor = System.Windows.Forms.AnchorStyles.Left; + this.tableLayoutPanel1.SetColumnSpan(this.chkWXComplateProd, 2); + this.chkWXComplateProd.Location = new System.Drawing.Point(388, 77); + this.chkWXComplateProd.Margin = new System.Windows.Forms.Padding(6, 3, 3, 3); + this.chkWXComplateProd.Name = "chkWXComplateProd"; + this.chkWXComplateProd.Size = new System.Drawing.Size(87, 21); + this.chkWXComplateProd.TabIndex = 808; + this.chkWXComplateProd.Text = "微信回采商品"; + this.chkWXComplateProd.UseVisualStyleBackColor = true; + // + // txtRealCoid + // + this.txtRealCoid.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); + this.txtRealCoid.Location = new System.Drawing.Point(72, 76); + this.txtRealCoid.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); + this.txtRealCoid.Name = "txtRealCoid"; + this.txtRealCoid.Size = new System.Drawing.Size(34, 23); + this.txtRealCoid.TabIndex = 814; + // + // cmbCat2 + // + this.cmbCat2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); + this.cmbCat2.FormattingEnabled = true; + this.cmbCat2.Location = new System.Drawing.Point(254, 77); + this.cmbCat2.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); + this.cmbCat2.Name = "cmbCat2"; + this.cmbCat2.Size = new System.Drawing.Size(34, 25); + this.cmbCat2.TabIndex = 804; + this.cmbCat2.SelectedIndexChanged += new System.EventHandler(this.cmbCateFilter2_SelectedIndexChanged); + // + // label1 + // + this.label1.Anchor = System.Windows.Forms.AnchorStyles.Right; + this.label1.AutoSize = true; + this.label1.Location = new System.Drawing.Point(3, 79); + this.label1.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(69, 17); + this.label1.TabIndex = 813; + this.label1.Text = "真实coid:"; + // // label16 // this.label16.Anchor = System.Windows.Forms.AnchorStyles.Right; @@ -505,17 +601,28 @@ namespace TemuKJD.PDDForms.ProductSelectForms // txtSecretStyleCode // this.txtSecretStyleCode.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); - this.txtSecretStyleCode.Location = new System.Drawing.Point(246, 6); + this.txtSecretStyleCode.Location = new System.Drawing.Point(254, 6); this.txtSecretStyleCode.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.txtSecretStyleCode.Name = "txtSecretStyleCode"; - this.txtSecretStyleCode.Size = new System.Drawing.Size(37, 23); + this.txtSecretStyleCode.Size = new System.Drawing.Size(34, 23); this.txtSecretStyleCode.TabIndex = 812; // + // label14 + // + this.label14.Anchor = System.Windows.Forms.AnchorStyles.Right; + this.label14.AutoSize = true; + this.label14.Location = new System.Drawing.Point(203, 79); + this.label14.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); + this.label14.Name = "label14"; + this.label14.Size = new System.Drawing.Size(51, 17); + this.label14.TabIndex = 784; + this.label14.Text = "类目2:"; + // // label15 // this.label15.Anchor = System.Windows.Forms.AnchorStyles.Right; this.label15.AutoSize = true; - this.label15.Location = new System.Drawing.Point(202, 9); + this.label15.Location = new System.Drawing.Point(210, 9); this.label15.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label15.Name = "label15"; this.label15.Size = new System.Drawing.Size(44, 17); @@ -526,7 +633,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.label13.Anchor = System.Windows.Forms.AnchorStyles.Right; this.label13.AutoSize = true; - this.label13.Location = new System.Drawing.Point(487, 44); + this.label13.Location = new System.Drawing.Point(492, 44); this.label13.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label13.Name = "label13"; this.label13.Size = new System.Drawing.Size(68, 17); @@ -544,17 +651,18 @@ namespace TemuKJD.PDDForms.ProductSelectForms "机会商品", "以图搜品", "外部数据"}); - this.cmbSourceType.Location = new System.Drawing.Point(246, 42); + this.cmbSourceType.Location = new System.Drawing.Point(254, 42); this.cmbSourceType.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.cmbSourceType.Name = "cmbSourceType"; - this.cmbSourceType.Size = new System.Drawing.Size(37, 25); + this.cmbSourceType.Size = new System.Drawing.Size(34, 25); this.cmbSourceType.TabIndex = 654; + this.cmbSourceType.SelectedIndexChanged += new System.EventHandler(this.cmbSourceType_SelectedIndexChanged); // // label10 // - this.label10.Anchor = System.Windows.Forms.AnchorStyles.Left; + this.label10.Anchor = System.Windows.Forms.AnchorStyles.Right; this.label10.AutoSize = true; - this.label10.Location = new System.Drawing.Point(202, 44); + this.label10.Location = new System.Drawing.Point(210, 44); this.label10.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label10.Name = "label10"; this.label10.Size = new System.Drawing.Size(44, 17); @@ -578,7 +686,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.txtSPU.Location = new System.Drawing.Point(72, 6); this.txtSPU.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.txtSPU.Name = "txtSPU"; - this.txtSPU.Size = new System.Drawing.Size(37, 23); + this.txtSPU.Size = new System.Drawing.Size(34, 23); this.txtSPU.TabIndex = 434; // // cmbWxCat @@ -589,10 +697,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms "", "是", "否"}); - this.cmbWxCat.Location = new System.Drawing.Point(555, 7); + this.cmbWxCat.Location = new System.Drawing.Point(560, 7); this.cmbWxCat.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.cmbWxCat.Name = "cmbWxCat"; - this.cmbWxCat.Size = new System.Drawing.Size(37, 25); + this.cmbWxCat.Size = new System.Drawing.Size(33, 25); this.cmbWxCat.TabIndex = 802; // // txtSKC @@ -601,7 +709,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.txtSKC.Location = new System.Drawing.Point(72, 41); this.txtSKC.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.txtSKC.Name = "txtSKC"; - this.txtSKC.Size = new System.Drawing.Size(37, 23); + this.txtSKC.Size = new System.Drawing.Size(34, 23); this.txtSKC.TabIndex = 432; // // cmbSort @@ -611,10 +719,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.cmbSort.Items.AddRange(new object[] { "入库时间", "认领总数"}); - this.cmbSort.Location = new System.Drawing.Point(333, 42); + this.cmbSort.Location = new System.Drawing.Point(345, 42); this.cmbSort.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.cmbSort.Name = "cmbSort"; - this.cmbSort.Size = new System.Drawing.Size(37, 25); + this.cmbSort.Size = new System.Drawing.Size(34, 25); this.cmbSort.TabIndex = 448; this.cmbSort.Text = "入库时间"; // @@ -622,7 +730,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.label6.Anchor = System.Windows.Forms.AnchorStyles.Right; this.label6.AutoSize = true; - this.label6.Location = new System.Drawing.Point(289, 44); + this.label6.Location = new System.Drawing.Point(301, 44); this.label6.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label6.Name = "label6"; this.label6.Size = new System.Drawing.Size(44, 17); @@ -633,7 +741,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.label4.Anchor = System.Windows.Forms.AnchorStyles.Right; this.label4.AutoSize = true; - this.label4.Location = new System.Drawing.Point(289, 9); + this.label4.Location = new System.Drawing.Point(301, 9); this.label4.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(44, 17); @@ -644,7 +752,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.label12.Anchor = System.Windows.Forms.AnchorStyles.Right; this.label12.AutoSize = true; - this.label12.Location = new System.Drawing.Point(487, 9); + this.label12.Location = new System.Drawing.Point(492, 9); this.label12.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label12.Name = "label12"; this.label12.Size = new System.Drawing.Size(68, 17); @@ -654,10 +762,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms // txtExtCode // this.txtExtCode.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); - this.txtExtCode.Location = new System.Drawing.Point(333, 6); + this.txtExtCode.Location = new System.Drawing.Point(345, 6); this.txtExtCode.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.txtExtCode.Name = "txtExtCode"; - this.txtExtCode.Size = new System.Drawing.Size(37, 23); + this.txtExtCode.Size = new System.Drawing.Size(34, 23); this.txtExtCode.TabIndex = 429; // // btnSearch @@ -667,7 +775,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.btnSearch.Cursor = System.Windows.Forms.Cursors.Hand; this.btnSearch.DisabledBackColor = System.Drawing.Color.Empty; this.btnSearch.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnSearch.Location = new System.Drawing.Point(598, 5); + this.btnSearch.Location = new System.Drawing.Point(599, 5); this.btnSearch.Name = "btnSearch"; this.btnSearch.Size = new System.Drawing.Size(46, 25); this.btnSearch.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -689,7 +797,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.lblGroup.Anchor = System.Windows.Forms.AnchorStyles.Right; this.lblGroup.AutoSize = true; - this.lblGroup.Location = new System.Drawing.Point(115, 44); + this.lblGroup.Location = new System.Drawing.Point(119, 44); this.lblGroup.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.lblGroup.Name = "lblGroup"; this.lblGroup.Size = new System.Drawing.Size(44, 17); @@ -700,10 +808,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.cmbGroupFilter.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); this.cmbGroupFilter.FormattingEnabled = true; - this.cmbGroupFilter.Location = new System.Drawing.Point(159, 42); + this.cmbGroupFilter.Location = new System.Drawing.Point(163, 42); this.cmbGroupFilter.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.cmbGroupFilter.Name = "cmbGroupFilter"; - this.cmbGroupFilter.Size = new System.Drawing.Size(37, 25); + this.cmbGroupFilter.Size = new System.Drawing.Size(34, 25); this.cmbGroupFilter.TabIndex = 653; // // pnlEmpty @@ -712,7 +820,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.pnlEmpty.CanvasColor = System.Drawing.SystemColors.Control; this.pnlEmpty.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; this.pnlEmpty.DisabledBackColor = System.Drawing.Color.Empty; - this.pnlEmpty.Location = new System.Drawing.Point(598, 40); + this.pnlEmpty.Location = new System.Drawing.Point(599, 40); this.pnlEmpty.Name = "pnlEmpty"; this.pnlEmpty.Size = new System.Drawing.Size(46, 25); this.pnlEmpty.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -740,17 +848,17 @@ namespace TemuKJD.PDDForms.ProductSelectForms "是", "否", "导出未拉回"}); - this.cmbExportToOutServer.Location = new System.Drawing.Point(555, 42); + this.cmbExportToOutServer.Location = new System.Drawing.Point(560, 42); this.cmbExportToOutServer.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.cmbExportToOutServer.Name = "cmbExportToOutServer"; - this.cmbExportToOutServer.Size = new System.Drawing.Size(37, 25); + this.cmbExportToOutServer.Size = new System.Drawing.Size(33, 25); this.cmbExportToOutServer.TabIndex = 803; // // label3 // this.label3.Anchor = System.Windows.Forms.AnchorStyles.Left; this.label3.AutoSize = true; - this.label3.Location = new System.Drawing.Point(376, 9); + this.label3.Location = new System.Drawing.Point(385, 9); this.label3.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(68, 17); @@ -760,10 +868,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms // txtProdName // this.txtProdName.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); - this.txtProdName.Location = new System.Drawing.Point(444, 6); + this.txtProdName.Location = new System.Drawing.Point(453, 6); this.txtProdName.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.txtProdName.Name = "txtProdName"; - this.txtProdName.Size = new System.Drawing.Size(37, 23); + this.txtProdName.Size = new System.Drawing.Size(33, 23); this.txtProdName.TabIndex = 427; // // cmbWxSafe @@ -776,10 +884,10 @@ namespace TemuKJD.PDDForms.ProductSelectForms "安全商品", "违规商品", "未校验"}); - this.cmbWxSafe.Location = new System.Drawing.Point(444, 42); + this.cmbWxSafe.Location = new System.Drawing.Point(453, 42); this.cmbWxSafe.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.cmbWxSafe.Name = "cmbWxSafe"; - this.cmbWxSafe.Size = new System.Drawing.Size(37, 25); + this.cmbWxSafe.Size = new System.Drawing.Size(33, 25); this.cmbWxSafe.TabIndex = 676; this.cmbWxSafe.Text = "安全+未校验"; // @@ -787,39 +895,18 @@ namespace TemuKJD.PDDForms.ProductSelectForms // this.lblWxSafe.Anchor = System.Windows.Forms.AnchorStyles.Left; this.lblWxSafe.AutoSize = true; - this.lblWxSafe.Location = new System.Drawing.Point(376, 44); + this.lblWxSafe.Location = new System.Drawing.Point(385, 44); this.lblWxSafe.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.lblWxSafe.Name = "lblWxSafe"; this.lblWxSafe.Size = new System.Drawing.Size(68, 17); this.lblWxSafe.TabIndex = 651; this.lblWxSafe.Text = "微信安检:"; // - // label2 - // - this.label2.Anchor = System.Windows.Forms.AnchorStyles.Left; - this.label2.AutoSize = true; - this.label2.Location = new System.Drawing.Point(3, 79); - this.label2.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); - this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(51, 17); - this.label2.TabIndex = 426; - this.label2.Text = "类目1:"; - // - // cmbCat1 - // - this.cmbCat1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); - this.cmbCat1.FormattingEnabled = true; - this.cmbCat1.Location = new System.Drawing.Point(72, 77); - this.cmbCat1.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); - this.cmbCat1.Name = "cmbCat1"; - this.cmbCat1.Size = new System.Drawing.Size(37, 25); - this.cmbCat1.TabIndex = 805; - // // lblNotes // this.lblNotes.Anchor = System.Windows.Forms.AnchorStyles.Right; this.lblNotes.AutoSize = true; - this.lblNotes.Location = new System.Drawing.Point(115, 9); + this.lblNotes.Location = new System.Drawing.Point(119, 9); this.lblNotes.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); this.lblNotes.Name = "lblNotes"; this.lblNotes.Size = new System.Drawing.Size(44, 17); @@ -829,12 +916,56 @@ namespace TemuKJD.PDDForms.ProductSelectForms // txtNotes // this.txtNotes.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); - this.txtNotes.Location = new System.Drawing.Point(159, 6); + this.txtNotes.Location = new System.Drawing.Point(163, 6); this.txtNotes.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); this.txtNotes.Name = "txtNotes"; - this.txtNotes.Size = new System.Drawing.Size(37, 23); + this.txtNotes.Size = new System.Drawing.Size(34, 23); this.txtNotes.TabIndex = 439; // + // cmbCat1 + // + this.cmbCat1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); + this.cmbCat1.FormattingEnabled = true; + this.cmbCat1.Location = new System.Drawing.Point(163, 75); + this.cmbCat1.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); + this.cmbCat1.Name = "cmbCat1"; + this.cmbCat1.Size = new System.Drawing.Size(34, 25); + this.cmbCat1.TabIndex = 805; + this.cmbCat1.SelectedIndexChanged += new System.EventHandler(this.cmbCateFilter1_SelectedIndexChanged); + // + // label2 + // + this.label2.Anchor = System.Windows.Forms.AnchorStyles.Right; + this.label2.AutoSize = true; + this.label2.Location = new System.Drawing.Point(112, 79); + this.label2.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(51, 17); + this.label2.TabIndex = 426; + this.label2.Text = "类目1:"; + // + // cmbCat3 + // + this.cmbCat3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); + this.cmbCat3.FormattingEnabled = true; + this.cmbCat3.Location = new System.Drawing.Point(345, 77); + this.cmbCat3.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); + this.cmbCat3.Name = "cmbCat3"; + this.cmbCat3.Size = new System.Drawing.Size(34, 25); + this.cmbCat3.TabIndex = 811; + this.cmbCat3.SelectedIndexChanged += new System.EventHandler(this.cmbCateFilter3_SelectedIndexChanged); + // + // label17 + // + this.label17.Anchor = System.Windows.Forms.AnchorStyles.Right; + this.label17.AutoSize = true; + this.label17.Location = new System.Drawing.Point(294, 79); + this.label17.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); + this.label17.Name = "label17"; + this.label17.Size = new System.Drawing.Size(51, 17); + this.label17.TabIndex = 811; + this.label17.Text = "类目3:"; + // // btnExportTxt // this.btnExportTxt.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); @@ -936,7 +1067,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.chkPullAfterPush.AutoSize = true; this.chkPullAfterPush.Checked = true; this.chkPullAfterPush.CheckState = System.Windows.Forms.CheckState.Checked; - this.chkPullAfterPush.Location = new System.Drawing.Point(672, 59); + this.chkPullAfterPush.Location = new System.Drawing.Point(672, 49); this.chkPullAfterPush.Name = "chkPullAfterPush"; this.chkPullAfterPush.Size = new System.Drawing.Size(87, 21); this.chkPullAfterPush.TabIndex = 874; @@ -954,9 +1085,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms // splitContainer2.Panel1 // this.splitContainer2.Panel1.Controls.Add(this.cmbSpProdType); - this.splitContainer2.Panel1.Controls.Add(this.cmbCat2); this.splitContainer2.Panel1.Controls.Add(this.btnGetAllCate); - this.splitContainer2.Panel1.Controls.Add(this.label14); this.splitContainer2.Panel1.Controls.Add(this.pnlEditExtCodePrice); this.splitContainer2.Panel1.Controls.Add(this.pbLoading); this.splitContainer2.Panel1.Controls.Add(this.btnSelect); @@ -987,17 +1116,6 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.cmbSpProdType.TabIndex = 677; this.cmbSpProdType.Visible = false; // - // cmbCat2 - // - this.cmbCat2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); - this.cmbCat2.FormattingEnabled = true; - this.cmbCat2.Location = new System.Drawing.Point(82, 114); - this.cmbCat2.Margin = new System.Windows.Forms.Padding(0, 3, 3, 3); - this.cmbCat2.Name = "cmbCat2"; - this.cmbCat2.Size = new System.Drawing.Size(37, 25); - this.cmbCat2.TabIndex = 804; - this.cmbCat2.Visible = false; - // // btnGetAllCate // this.btnGetAllCate.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; @@ -1023,18 +1141,6 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.btnGetAllCate.Visible = false; this.btnGetAllCate.Click += new System.EventHandler(this.btnGetAllCate_Click); // - // label14 - // - this.label14.Anchor = System.Windows.Forms.AnchorStyles.Left; - this.label14.AutoSize = true; - this.label14.Location = new System.Drawing.Point(31, 118); - this.label14.Margin = new System.Windows.Forms.Padding(3, 0, 0, 0); - this.label14.Name = "label14"; - this.label14.Size = new System.Drawing.Size(51, 17); - this.label14.TabIndex = 784; - this.label14.Text = "类目2:"; - this.label14.Visible = false; - // // pnlEditExtCodePrice // this.pnlEditExtCodePrice.Anchor = System.Windows.Forms.AnchorStyles.None; @@ -1203,6 +1309,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.colSelect, this.col_db_id, this.colFromShopId, + this.colFromShopName, this.col_product_name, this.colImgUrl, this.colMainImg, @@ -1267,6 +1374,12 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.colFromShopId.ReadOnly = true; this.colFromShopId.Visible = false; // + // colFromShopName + // + this.colFromShopName.HeaderText = "来源店铺名称"; + this.colFromShopName.Name = "colFromShopName"; + this.colFromShopName.ReadOnly = true; + // // col_product_name // dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.True; @@ -1650,9 +1763,15 @@ namespace TemuKJD.PDDForms.ProductSelectForms private DevComponents.DotNetBar.PanelEx btnStopStop; private System.Windows.Forms.TextBox txtSecretStyleCode; private System.Windows.Forms.Label label15; + private System.Windows.Forms.Label label16; + private System.Windows.Forms.TextBox txtRealCoid; + private System.Windows.Forms.Label label1; + private System.Windows.Forms.Label label17; + private System.Windows.Forms.ComboBox cmbCat3; private System.Windows.Forms.DataGridViewCheckBoxColumn colSelect; private System.Windows.Forms.DataGridViewTextBoxColumn col_db_id; private System.Windows.Forms.DataGridViewTextBoxColumn colFromShopId; + private System.Windows.Forms.DataGridViewTextBoxColumn colFromShopName; private System.Windows.Forms.DataGridViewTextBoxColumn col_product_name; private System.Windows.Forms.DataGridViewTextBoxColumn colImgUrl; private System.Windows.Forms.DataGridViewImageColumn colMainImg; @@ -1683,6 +1802,8 @@ namespace TemuKJD.PDDForms.ProductSelectForms private System.Windows.Forms.DataGridViewLinkColumn col_edit; private System.Windows.Forms.DataGridViewLinkColumn col_delete; private System.Windows.Forms.DataGridViewLinkColumn col_select_product; - private System.Windows.Forms.Label label16; + private UserComponent.UcCheckBox chkWXComplateProd; + private DevComponents.DotNetBar.PanelEx btnReturnSecretData; + private UserComponent.UcCheckBox chkHasReturn; } } \ No newline at end of file diff --git a/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.cs b/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.cs index 5d54121..50dc21e 100644 --- a/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.cs +++ b/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.cs @@ -69,7 +69,11 @@ namespace TemuKJD.PDDForms.ProductSelectForms lblGroup.Visible = cmbGroup.Visible = btnSetGroup.Visible = true; - GetPDDProductGroup(new List { cmbGroup, cmbGroupFilter, }); + Task.Run(() => + { + GetPDDProductGroup(new List { cmbGroup, cmbGroupFilter, }); + GetPddProductCate(); + }); } else { @@ -198,6 +202,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms false, prod.id, prod.from_shop_id, + prod.from_shop_name, prod.product_name, prod?.main_img?.Replace("https", "http") + "?imageView2/2/w/90/h/90", defaultBitmap, // prod.main_img, @@ -312,13 +317,39 @@ namespace TemuKJD.PDDForms.ProductSelectForms "&search_spu=" + txtSPU.Text.Trim() + "&search_skc=" + txtSKC.Text.Trim() + "&search_notes=" + txtNotes.Text.Trim() + - "&search_cat1=" + cmbCat1.Text.Trim() + - "&search_cat=" + cmbCat2.Text.Trim() + "&search_ext_code=" + txtExtCode.Text.Trim() + "&search_group=" + cmbGroupFilter.Text.Trim() + "&search_prod_name=" + txtProdName.Text.Trim() + "&wx_safe_status=" + cmbWxSafe.Text.Trim().Replace("安全+未校验", "安全商品,未校验") + "&special_prod_type=" + cmbSpProdType.Text.Trim(); + + if (cmbSourceType.Text != "厂商直采") + { + data += "&search_cat1=" + cmbCat1.Text.Trim(); + data += "&search_cat=" + cmbCat2.Text.Trim(); + } + else + { + var cate1 = GlobalConfig.WxCatList.FirstOrDefault(c => c.level == 1 && c.name == cmbCat1.Text.Trim()); + var cates2 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate1?.cat_id).ToList(); + var cate2 = cates2.FirstOrDefault(c => c.level == 2 && c.name == cmbCat2.Text.Trim()); + var cates3 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate2?.cat_id).ToList(); + var cate3 = cates3.FirstOrDefault(c => c.level == 3 && c.name == cmbCat3.Text.Trim()); + + if (!string.IsNullOrEmpty(cmbCat1.Text) && cate1 != null) + data += "&wx_cat_1=" + cate1.cat_id; + //else if (chkSkipQualification.Checked) + //{ + // // 厂商直采普通店铺不要随特殊商品 + // data += "&wx_cat_1=" + string.Join(",", GlobalConfig.WxCatList.Where(c => c.level == 1 && !(c.name == "图书" || c.name == "食品饮料" || c.name == "成人用品")) + // .Select(c => c.cat_id)); + //} + if (!string.IsNullOrEmpty(cmbCat2.Text) && cate2 != null) + data += "&wx_cat_2=" + cate2.cat_id; + if (!string.IsNullOrEmpty(cmbCat3.Text) && cate3 != null) + data += "&wx_cat_3=" + cate3.cat_id; + } + if (!string.IsNullOrEmpty(txtSecretStyleCode.Text.Trim())) { data += "&search_secret_spu_ids=" + string.Join(",", txtSecretStyleCode.Text.Trim().Split(new string[] { " ", ",", "," }, StringSplitOptions.RemoveEmptyEntries)); @@ -351,6 +382,14 @@ namespace TemuKJD.PDDForms.ProductSelectForms { data += "&sort_field=select_total_count"; } + if (!this.txtRealCoid.Text.Trim().IsNullOrEmpty()) + { + data += "&real_coid=" + this.txtRealCoid.Text.Trim(); + } + if (chkWXComplateProd.Checked) + data += "&has_wx_format=1"; + if (chkHasReturn.Checked) + data += "&standby3=1"; })); var html = GetHtml.PostUtf8(url, data); @@ -424,6 +463,48 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.txtSecretStyleCode.Text = ""; } + private void cmbCateFilter1_SelectedIndexChanged(object sender, EventArgs e) + { + if (cmbSourceType.Text != "厂商直采") + return; + + cmbCat2.Text = ""; + cmbCat2.Items.Clear(); + var cate1 = GlobalConfig.WxCatList.FirstOrDefault(c => c.level == 1 && c.name == cmbCat1.Text.Trim()); + var cates2 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate1?.cat_id).ToList(); + foreach (var cate2 in cates2) + { + cmbCat2.Items.Add(cate2.name); + } + + } + + private void cmbCateFilter2_SelectedIndexChanged(object sender, EventArgs e) + { + if (cmbSourceType.Text != "厂商直采") + return; + + cmbCat3.Text = ""; + cmbCat3.Items.Clear(); + var cate1 = GlobalConfig.WxCatList.FirstOrDefault(c => c.level == 1 && c.name == cmbCat1.Text.Trim()); + var cates2 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate1?.cat_id).ToList(); + var cate2 = cates2.FirstOrDefault(c => c.level == 2 && c.name == cmbCat2.Text.Trim()); + var cates3 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate2?.cat_id).ToList(); + foreach (var cate3 in cates3) + { + cmbCat3.Items.Add(cate3.name); + } + } + + private void cmbCateFilter3_SelectedIndexChanged(object sender, EventArgs e) + { + var cate1 = GlobalConfig.WxCatList.FirstOrDefault(c => c.level == 1 && c.name == cmbCat1.Text.Trim()); + var cates2 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate1?.cat_id).ToList(); + var cate2 = cates2.FirstOrDefault(c => c.level == 2 && c.name == cmbCat1.Text.Trim()); + var cates3 = GlobalConfig.WxCatList.Where(c => c.f_cat_id == cate2?.cat_id).ToList(); + var cate3 = cates3.FirstOrDefault(c => c.level == 3 && c.name == cmbCat1.Text.Trim()); + } + private void dgvDbProduct_CellContentClick(object sender, DataGridViewCellEventArgs e) { if (e.ColumnIndex < 0 || e.RowIndex < 0) @@ -653,6 +734,7 @@ namespace TemuKJD.PDDForms.ProductSelectForms { GetPDDProductGroup(new List { box }); } + public static void GetPDDProductGroup(List boxs) { var url = BaseClass.BuildPDDObjString("product/get_product_groups"); @@ -1376,6 +1458,12 @@ namespace TemuKJD.PDDForms.ProductSelectForms this.statusBar.lblTaskStatus.Text = "正在导出 " + this.statusBar.pgbTaskProgress.Value + "/" + dbProdLst.Count; })); var dbProd = PDDDBProdEditForm.GetPddProductDetail(prod.id.ParseToString()); + + if (!dbProd.sku_secret_json.IsNullOrEmpty() && dbProd.sku_secret_json.Length > 10) + { + continue; + } + var rst = new WxProdFormConverter().JstPddConvertToWxOutServer(dbProd); if (!rst.Contains("\"success\":true")) { @@ -1703,5 +1791,229 @@ namespace TemuKJD.PDDForms.ProductSelectForms break; } } + + private void cmbSourceType_SelectedIndexChanged(object sender, EventArgs e) + { + + if (cmbSourceType.Text != "厂商直采") + fillPddCate(); + else + fillWxCate(); + } + + /// + /// 获取商品所有类目 + /// + void GetPddProductCate() + { + var url = BaseClass.BuildObjString("product/get_pdd_product_cates"); + var data = UserLogin.GetSignaturex(); + var html = GetHtml.PostUtf8(url, data); + if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200")) + html = GetHtml.PostUtf8(url, data); + if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200")) + { + BaseMsgForm.ShowError("商品类目获取失败,请重试!" + BaseRegex.GetStringJson(ref html, "msg")); + } + else + { + pdd_product_cates = BaseRegex.GetStringJson(ref html, "data"); + } + + Invoke(new Action(() => + { + if (cmbSourceType.Text != "厂商直采") + { + fillPddCate(); + } + else + { + fillWxCate(); + } + })); + } + + public string pdd_product_cates = ""; + void fillPddCate() + { + cmbCat1.Items.Clear(); + cmbCat2.Items.Clear(); + cmbCat3.Items.Clear(); + cmbCat1.Text = ""; + cmbCat2.Text = ""; + cmbCat3.Text = ""; + foreach (var item in pdd_product_cates.Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries)) + { + cmbCat1.Items.Add(item); + } + cmbCat1.Items.Add(""); + } + + void fillWxCate() + { + cmbCat1.Items.Clear(); + cmbCat2.Items.Clear(); + cmbCat3.Items.Clear(); + cmbCat1.Text = ""; + cmbCat2.Text = ""; + cmbCat3.Text = ""; + foreach (var cate in GlobalConfig.WxCatList.Where(c => c.level == 1).ToList()) + { + cmbCat1.Items.Add(cate.name); + } + } + + private void btnReturnSecretData_Click(object sender, EventArgs e) + { + + var lstProdId = dgvDbProduct.Rows.Cast().Where(row + => row.Cells["colSelect"]?.Value.ParseToBool() == true).Select(r => r.Cells["col_spu_id"]?.Value.ToString()).ToList(); + var prodList = this.lstTemuDbProduct.Where(p => lstProdId.Contains(p.spu_id)).ToList(); + if (prodList.Count == 0) + return; + + this.statusBar.pgbTaskProgress.Maximum = prodList.Count; + this.statusBar.UpdateProgressBar(0); + this.pbLoading.Visible = true; + if (cancellationTokenSource == null || cancellationTokenSource.IsCancellationRequested) + { + cancellationTokenSource = new CancellationTokenSource(); + } + Task.Run(() => + { + try + { + ReturnToServer(prodList); + } + catch (Exception ex) + { + BaseMsgForm.ShowError(ex.Message); + } + // 刷新结果 + SearchDbProd(this.ucSplitPage1.CurrentPage); + Invoke(new Action(() => + { + pbLoading.Visible = false; + BaseMsgForm.ShowInfo("操作完成!数据回传 " + prodList.Count() + " 条数据,成功 " + prodList.Where(p => p.standby3 == "1").Count() + " 条"); + })); + }, cancellationTokenSource.Token); + } + + public void ReturnToServer(List dbProdLst) + { + foreach (var prod in dbProdLst) + { + if (cancellationTokenSource.IsCancellationRequested) + break; + + Invoke(new Action(() => + { + this.statusBar.UpdateProgressBar(this.statusBar.pgbTaskProgress.Value + 1); + this.statusBar.lblTaskStatus.Text = "正在回传 " + this.statusBar.pgbTaskProgress.Value + "/" + dbProdLst.Count + " 成功:" + dbProdLst.Where(p => p.standby3 == "1").Count(); + })); + var dbProd = PDDDBProdEditForm.GetPddProductDetail(prod.id.ParseToString()); + + if (string.IsNullOrEmpty(dbProd?.sku_secret_json) && dbProd.sku_secret_json.Length > 10) + { + //continue; + } + + var rst = new WxProdFormConverter().JstPddConvertToWxOutServer(dbProd); + if (!rst.Contains("\"success\":true")) + { + continue; + } + var prodDataStr = ""; + try + { + var prodDataObj = JsonHelper.JObjectParse(rst)["data"]; + prodDataObj["spuCode"] = dbProd.ext_code; + prodDataStr = JsonHelper.SerializeObject(prodDataObj); + } + catch + { + continue; + } + string url = "https://po.e57.cn/prod-api/api/sys-api/system/open/api/addGoods"; + var exportRst = WXHttpResponseBLL.e57PostResponse(url, prodDataStr, ""); + //Thread.Sleep(500); + + + // 导出成功,回写数据 + if (exportRst.Contains("\"code\":200")) + { + if (chkPullAfterPush.Checked) + { + url = "https://po.e57.cn/prod-api/api/oms-api/updateGoodsId"; + string body = dbProd.sku_secret_json.TrimStart('[').TrimEnd(']'); + var getRst = WXHttpResponseBLL.e57PostResponse(url, body, ""); + if (getRst.Contains("\"code\":0") || getRst.Contains("200")) + { + try + { + { + //url = "https://po.e57.cn/prod-api/api/sys-api/system/open/api/goods/list/get"; + //string bodyx = "{\"spuCodes\":[\"" + dbProd.ext_code + "\"]}"; + //var getRstx = WXHttpResponseBLL.e57PostResponse(url, bodyx, ""); + } + + var url3 = BaseClass.BuildPDDObjString("product/mdy_product"); + if (1==1) + { + var data3 = Work.UserLogin.GetSignaturex() + + "&spu_id=" + dbProd.spu_id + + "&standby3=" + 1; + var html = GetHtml.PostUtf8(url3, data3); + if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200")) + html = GetHtml.PostUtf8(url3, data3); + if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200")) + { + } + else + { + prod.standby3 = "1"; + dbProd.standby3 = "1"; + } + } + else + { + } + } + catch + { + } + } + else + { + } + } + + + ////如果外部服务端提示入库成功又没有实际加成功,则记录未回拉 + //if (prod.send_to_out_server == 2) + //{ + // var url2 = BaseClass.BuildPDDObjString("product/mdy_product"); + // var data2 = Work.UserLogin.GetSignaturex() + + // "&spu_id=" + dbProd.spu_id + + // "&send_to_out_server=" + 2; + // var html = GetHtml.PostUtf8(url2, data2); + // if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200")) + // html = GetHtml.PostUtf8(url2, data2); + // if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200")) + // { + // } + //} + } + else + { + } + Thread.Sleep(100); + + // 查询微信接口token + //url = "https://po.e57.cn/prod-api/api/sys-api/system/open/api/shop/list?userName=阿杰账户"; + //exportRst = WXHttpResponseBLL.e57PostResponse(url, "&warehouseNum=123456&shopId=46568955", ""); + //exportRst = WXHttpResponseBLL.e57GetResponse(url, ""); + } + } } } diff --git a/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.resx b/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.resx index de66977..19acb7c 100644 --- a/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.resx +++ b/TEMUKJD/PDDForms/ProductSelectForms/PDDDBProdListForm.resx @@ -126,6 +126,9 @@ True + + True + True diff --git a/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.Designer.cs b/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.Designer.cs index 524255c..022e0e7 100644 --- a/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.Designer.cs +++ b/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.Designer.cs @@ -30,9 +30,9 @@ namespace TemuKJD.WXForms.AdminForms private void InitializeComponent() { this.components = new System.ComponentModel.Container(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle(); this.splitContainer5 = new System.Windows.Forms.SplitContainer(); this.label7 = new System.Windows.Forms.Label(); this.chkWXComplateProd = new TemuKJD.UserComponent.UcCheckBox(this.components); @@ -68,9 +68,11 @@ namespace TemuKJD.WXForms.AdminForms this.label40 = new System.Windows.Forms.Label(); this.splitContainer1 = new System.Windows.Forms.SplitContainer(); this.dgvUser = new TemuKJD.UserComponent.DataGridViewEx(); + this.btnExportShopErp = new DevComponents.DotNetBar.PanelEx(); this.UserIdColumn = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.UserNickNameColumn = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.mobileColumn = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colParentUserName = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.groupIdColumn = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.groupNameColumn = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colCompany = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -86,6 +88,7 @@ namespace TemuKJD.WXForms.AdminForms this.splitContainer5.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); this.splitContainer1.Panel1.SuspendLayout(); + this.splitContainer1.Panel2.SuspendLayout(); this.splitContainer1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.dgvUser)).BeginInit(); this.SuspendLayout(); @@ -490,6 +493,10 @@ namespace TemuKJD.WXForms.AdminForms // splitContainer1.Panel1 // this.splitContainer1.Panel1.Controls.Add(this.dgvUser); + // + // splitContainer1.Panel2 + // + this.splitContainer1.Panel2.Controls.Add(this.btnExportShopErp); this.splitContainer1.Size = new System.Drawing.Size(1013, 517); this.splitContainer1.SplitterDistance = 486; this.splitContainer1.TabIndex = 2; @@ -498,25 +505,26 @@ namespace TemuKJD.WXForms.AdminForms // this.dgvUser.AllowUserToAddRows = false; this.dgvUser.AllowUserToDeleteRows = false; - dataGridViewCellStyle4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(249)))), ((int)(((byte)(249)))), ((int)(((byte)(249))))); - this.dgvUser.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle4; + dataGridViewCellStyle1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(249)))), ((int)(((byte)(249)))), ((int)(((byte)(249))))); + this.dgvUser.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1; this.dgvUser.AutoRowNumber = true; this.dgvUser.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill; this.dgvUser.BackgroundColor = System.Drawing.Color.White; this.dgvUser.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); - dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Control; - dataGridViewCellStyle5.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.WindowText; - dataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.False; - this.dgvUser.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle5; + dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle2.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False; + this.dgvUser.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2; this.dgvUser.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.dgvUser.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.UserIdColumn, this.UserNickNameColumn, this.mobileColumn, + this.colParentUserName, this.groupIdColumn, this.groupNameColumn, this.colCompany, @@ -526,14 +534,14 @@ namespace TemuKJD.WXForms.AdminForms this.colAuthority, this.editColumn, this.deleteColumn}); - dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Window; - dataGridViewCellStyle6.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.ControlText; - dataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.ControlText; - dataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.False; - this.dgvUser.DefaultCellStyle = dataGridViewCellStyle6; + dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Window; + dataGridViewCellStyle3.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.ControlText; + dataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.ControlText; + dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False; + this.dgvUser.DefaultCellStyle = dataGridViewCellStyle3; this.dgvUser.Dock = System.Windows.Forms.DockStyle.Fill; this.dgvUser.GridColor = System.Drawing.Color.FromArgb(((int)(((byte)(208)))), ((int)(((byte)(215)))), ((int)(((byte)(229))))); this.dgvUser.Location = new System.Drawing.Point(0, 0); @@ -544,6 +552,31 @@ namespace TemuKJD.WXForms.AdminForms this.dgvUser.TabIndex = 1; this.dgvUser.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvUser_CellContentClick); // + // btnExportShopErp + // + this.btnExportShopErp.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.btnExportShopErp.Cursor = System.Windows.Forms.Cursors.Hand; + this.btnExportShopErp.DisabledBackColor = System.Drawing.Color.Empty; + this.btnExportShopErp.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.btnExportShopErp.Location = new System.Drawing.Point(0, 1); + this.btnExportShopErp.Name = "btnExportShopErp"; + this.btnExportShopErp.Size = new System.Drawing.Size(140, 25); + this.btnExportShopErp.Style.Alignment = System.Drawing.StringAlignment.Center; + this.btnExportShopErp.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnExportShopErp.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnExportShopErp.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.btnExportShopErp.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.btnExportShopErp.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.btnExportShopErp.Style.ForeColor.Color = System.Drawing.Color.White; + this.btnExportShopErp.Style.GradientAngle = 90; + this.btnExportShopErp.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.btnExportShopErp.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnExportShopErp.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnExportShopErp.TabIndex = 439; + this.btnExportShopErp.Text = "导出用户到后台系统"; + this.btnExportShopErp.Visible = false; + this.btnExportShopErp.Click += new System.EventHandler(this.btnExportShopErp_Click); + // // UserIdColumn // this.UserIdColumn.HeaderText = "id"; @@ -563,6 +596,12 @@ namespace TemuKJD.WXForms.AdminForms this.mobileColumn.Name = "mobileColumn"; this.mobileColumn.ReadOnly = true; // + // colParentUserName + // + this.colParentUserName.HeaderText = "主账号"; + this.colParentUserName.Name = "colParentUserName"; + this.colParentUserName.ReadOnly = true; + // // groupIdColumn // this.groupIdColumn.HeaderText = "groupId"; @@ -640,6 +679,7 @@ namespace TemuKJD.WXForms.AdminForms ((System.ComponentModel.ISupportInitialize)(this.splitContainer5)).EndInit(); this.splitContainer5.ResumeLayout(false); this.splitContainer1.Panel1.ResumeLayout(false); + this.splitContainer1.Panel2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit(); this.splitContainer1.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.dgvUser)).EndInit(); @@ -684,9 +724,11 @@ namespace TemuKJD.WXForms.AdminForms private System.Windows.Forms.ComboBox cmbSaLevel; private System.Windows.Forms.Label label7; private UserComponent.UcCheckBox chkWXComplateProd; + private DevComponents.DotNetBar.PanelEx btnExportShopErp; private System.Windows.Forms.DataGridViewTextBoxColumn UserIdColumn; private System.Windows.Forms.DataGridViewTextBoxColumn UserNickNameColumn; private System.Windows.Forms.DataGridViewTextBoxColumn mobileColumn; + private System.Windows.Forms.DataGridViewTextBoxColumn colParentUserName; private System.Windows.Forms.DataGridViewTextBoxColumn groupIdColumn; private System.Windows.Forms.DataGridViewTextBoxColumn groupNameColumn; private System.Windows.Forms.DataGridViewTextBoxColumn colCompany; diff --git a/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.cs b/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.cs index 40fd9fa..82778cf 100644 --- a/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.cs +++ b/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.cs @@ -8,9 +8,11 @@ using System.Data; using System.Drawing; using System.Linq; using System.Text; +using System.Threading; using System.Threading.Tasks; using System.Windows.Forms; using TemuKJD.BaseForms; +using TemuKJD.BLL; using Work; namespace TemuKJD.WXForms.AdminForms @@ -143,12 +145,14 @@ namespace TemuKJD.WXForms.AdminForms user.company_name = BaseRegex.GetStringJson(ref oStr, "company_name"); user.sa_level = BaseRegex.GetIntJson(ref oStr, "sa_level"); user.authority = BaseRegex.GetStringJson(ref oStr, "authority"); + var parent_user_name = BaseRegex.GetStringJson(ref oStr, "parent_user_name"); AllUsers.Add(user); dgvUser.Rows.Add( user.id, user.nick_name, - user.user_name, + user.user_name, + parent_user_name, user.group_id, user.group_name, user.company_name, @@ -285,5 +289,26 @@ namespace TemuKJD.WXForms.AdminForms this.txtSearch.Focus(); this.lblWatermark.Visible = false; } + + private void btnExportShopErp_Click(object sender, EventArgs e) + { + foreach (var user in AllUsers) + { + //if (user.group_id != "3") + // continue; + + //string prodDataStr = "{\"userName\":\"15288888888\",\"password\":\"Andy@1984\",\"phonenumber\":\"15288888888\",\"status\": \"0\",\"remark\":\"a15288888888.\",\"roleIds\":[\"5\"]}"; + //prodDataStr = "{\"userName\":\"" + user.user_name + "\",\"password\":\"" + user.user_name + "\",\"phonenumber\":\"" + user.mobile + + // "\",\"status\": \"0\",\"nickName\":\"" + user.nick_name + "\",\"roleIds\":[\"5\"]}"; + + //string url = "https://po.e57.cn/prod-api/api/sys-api/system/user"; + //var exportRst = WXHttpResponseBLL.e57PostResponse(url, prodDataStr, "", "Bearer eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6IjFlODI2ZjNiLTFhMzItNDEwOS04ODlmLTIzYmEwOTUyMDYxYiJ9.L68qzzZZxaQoxrUeB8pBt4TWB7UbTwHkxlmQduzy-VEFkBI4oxtj4VrH-2yJpSD--ZdM-5Wm3VtTvy57nMaFMQ"); + //Thread.Sleep(500); + //if (!exportRst.Contains("\"code\":200")) + //{ + + //} + } + } } } diff --git a/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.resx b/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.resx index 67bc4a6..b03e5d3 100644 --- a/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.resx +++ b/TEMUKJD/WXForms/AdminForms/WXAdminAccountForm.resx @@ -126,6 +126,9 @@ True + + True + True diff --git a/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.Designer.cs b/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.Designer.cs index d67ea1d..6612d22 100644 --- a/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.Designer.cs +++ b/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.Designer.cs @@ -41,6 +41,7 @@ namespace TemuKJD.WXForms.AdminForms this.btnLoginSelect = new TemuKJD.UserControls.ButtonEx(); this.btnCheck = new TemuKJD.UserControls.ButtonEx(); this.panel4 = new System.Windows.Forms.Panel(); + this.btnExportShopErp = new DevComponents.DotNetBar.PanelEx(); this.btnSetSubSa = new TemuKJD.UserControls.ButtonEx(); this.txtUserName = new System.Windows.Forms.TextBox(); this.label5 = new System.Windows.Forms.Label(); @@ -64,9 +65,6 @@ namespace TemuKJD.WXForms.AdminForms this.btnRemainOK = new DevComponents.DotNetBar.PanelEx(); this.lblAddProdRemaining = new System.Windows.Forms.Label(); this.dgvShop = new TemuKJD.UserComponent.DataGridViewEx(); - this.chkAutoDrag = new System.Windows.Forms.CheckBox(); - this.ucSplitPage1 = new TemuKJD.UserControls.UcSplitPage(); - this.statusBar = new TemuKJD.UserControls.StatusBarUserControl(); this.colSelect = new System.Windows.Forms.DataGridViewCheckBoxColumn(); this.colLoginName = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colShopId = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -97,6 +95,9 @@ namespace TemuKJD.WXForms.AdminForms this.colSubSa = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colEdit = new System.Windows.Forms.DataGridViewLinkColumn(); this.colDelete = new System.Windows.Forms.DataGridViewLinkColumn(); + this.chkAutoDrag = new System.Windows.Forms.CheckBox(); + this.ucSplitPage1 = new TemuKJD.UserControls.UcSplitPage(); + this.statusBar = new TemuKJD.UserControls.StatusBarUserControl(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); this.splitContainer1.Panel1.SuspendLayout(); this.splitContainer1.Panel2.SuspendLayout(); @@ -133,7 +134,7 @@ namespace TemuKJD.WXForms.AdminForms this.splitContainer1.Panel2.Controls.Add(this.splitContainer2); this.splitContainer1.Panel2.Margin = new System.Windows.Forms.Padding(4); this.splitContainer1.Size = new System.Drawing.Size(1273, 610); - this.splitContainer1.SplitterDistance = 46; + this.splitContainer1.SplitterDistance = 84; this.splitContainer1.TabIndex = 34; // // tableLayoutPanel2 @@ -148,7 +149,7 @@ namespace TemuKJD.WXForms.AdminForms this.tableLayoutPanel2.Name = "tableLayoutPanel2"; this.tableLayoutPanel2.RowCount = 1; this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel2.Size = new System.Drawing.Size(1273, 46); + this.tableLayoutPanel2.Size = new System.Drawing.Size(1273, 84); this.tableLayoutPanel2.TabIndex = 37; // // panel5 @@ -208,6 +209,7 @@ namespace TemuKJD.WXForms.AdminForms // // panel4 // + this.panel4.Controls.Add(this.btnExportShopErp); this.panel4.Controls.Add(this.btnSetSubSa); this.panel4.Controls.Add(this.txtUserName); this.panel4.Controls.Add(this.label5); @@ -224,9 +226,34 @@ namespace TemuKJD.WXForms.AdminForms this.panel4.Dock = System.Windows.Forms.DockStyle.Fill; this.panel4.Location = new System.Drawing.Point(3, 3); this.panel4.Name = "panel4"; - this.panel4.Size = new System.Drawing.Size(1001, 40); + this.panel4.Size = new System.Drawing.Size(1001, 78); this.panel4.TabIndex = 0; // + // btnExportShopErp + // + this.btnExportShopErp.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.btnExportShopErp.Cursor = System.Windows.Forms.Cursors.Hand; + this.btnExportShopErp.DisabledBackColor = System.Drawing.Color.Empty; + this.btnExportShopErp.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.btnExportShopErp.Location = new System.Drawing.Point(613, 10); + this.btnExportShopErp.Name = "btnExportShopErp"; + this.btnExportShopErp.Size = new System.Drawing.Size(140, 25); + this.btnExportShopErp.Style.Alignment = System.Drawing.StringAlignment.Center; + this.btnExportShopErp.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnExportShopErp.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnExportShopErp.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.btnExportShopErp.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.btnExportShopErp.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.btnExportShopErp.Style.ForeColor.Color = System.Drawing.Color.White; + this.btnExportShopErp.Style.GradientAngle = 90; + this.btnExportShopErp.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.btnExportShopErp.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnExportShopErp.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnExportShopErp.TabIndex = 435; + this.btnExportShopErp.Text = "导出店铺到后台系统"; + this.btnExportShopErp.Visible = false; + this.btnExportShopErp.Click += new System.EventHandler(this.btnExportShopErp_Click); + // // btnSetSubSa // this.btnSetSubSa.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); @@ -246,7 +273,7 @@ namespace TemuKJD.WXForms.AdminForms // // txtUserName // - this.txtUserName.Location = new System.Drawing.Point(34, 11); + this.txtUserName.Location = new System.Drawing.Point(57, 12); this.txtUserName.Name = "txtUserName"; this.txtUserName.Size = new System.Drawing.Size(90, 23); this.txtUserName.TabIndex = 419; @@ -254,7 +281,7 @@ namespace TemuKJD.WXForms.AdminForms // label5 // this.label5.AutoSize = true; - this.label5.Location = new System.Drawing.Point(1, 14); + this.label5.Location = new System.Drawing.Point(24, 15); this.label5.Name = "label5"; this.label5.Size = new System.Drawing.Size(44, 17); this.label5.TabIndex = 420; @@ -262,7 +289,7 @@ namespace TemuKJD.WXForms.AdminForms // // txtLoginName // - this.txtLoginName.Location = new System.Drawing.Point(185, 11); + this.txtLoginName.Location = new System.Drawing.Point(208, 12); this.txtLoginName.Name = "txtLoginName"; this.txtLoginName.Size = new System.Drawing.Size(90, 23); this.txtLoginName.TabIndex = 417; @@ -270,7 +297,7 @@ namespace TemuKJD.WXForms.AdminForms // label1 // this.label1.AutoSize = true; - this.label1.Location = new System.Drawing.Point(128, 14); + this.label1.Location = new System.Drawing.Point(151, 15); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(68, 17); this.label1.TabIndex = 418; @@ -281,7 +308,7 @@ namespace TemuKJD.WXForms.AdminForms this.pnlEmpty.CanvasColor = System.Drawing.SystemColors.Control; this.pnlEmpty.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; this.pnlEmpty.DisabledBackColor = System.Drawing.Color.Empty; - this.pnlEmpty.Location = new System.Drawing.Point(749, 9); + this.pnlEmpty.Location = new System.Drawing.Point(502, 10); this.pnlEmpty.Name = "pnlEmpty"; this.pnlEmpty.Size = new System.Drawing.Size(56, 26); this.pnlEmpty.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -307,7 +334,7 @@ namespace TemuKJD.WXForms.AdminForms this.btnSearch.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSearch.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnSearch.ForeColor = System.Drawing.Color.White; - this.btnSearch.Location = new System.Drawing.Point(688, 9); + this.btnSearch.Location = new System.Drawing.Point(441, 10); this.btnSearch.Margin = new System.Windows.Forms.Padding(2); this.btnSearch.Name = "btnSearch"; this.btnSearch.Size = new System.Drawing.Size(56, 26); @@ -318,7 +345,7 @@ namespace TemuKJD.WXForms.AdminForms // // txtNotes // - this.txtNotes.Location = new System.Drawing.Point(589, 11); + this.txtNotes.Location = new System.Drawing.Point(208, 41); this.txtNotes.Name = "txtNotes"; this.txtNotes.Size = new System.Drawing.Size(90, 23); this.txtNotes.TabIndex = 376; @@ -326,7 +353,7 @@ namespace TemuKJD.WXForms.AdminForms // label4 // this.label4.AutoSize = true; - this.label4.Location = new System.Drawing.Point(556, 14); + this.label4.Location = new System.Drawing.Point(175, 44); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(44, 17); this.label4.TabIndex = 377; @@ -334,7 +361,7 @@ namespace TemuKJD.WXForms.AdminForms // // txtShopName // - this.txtShopName.Location = new System.Drawing.Point(462, 11); + this.txtShopName.Location = new System.Drawing.Point(57, 41); this.txtShopName.Name = "txtShopName"; this.txtShopName.Size = new System.Drawing.Size(90, 23); this.txtShopName.TabIndex = 374; @@ -342,7 +369,7 @@ namespace TemuKJD.WXForms.AdminForms // label3 // this.label3.AutoSize = true; - this.label3.Location = new System.Drawing.Point(417, 14); + this.label3.Location = new System.Drawing.Point(12, 44); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(56, 17); this.label3.TabIndex = 375; @@ -350,7 +377,7 @@ namespace TemuKJD.WXForms.AdminForms // // txtShopId // - this.txtShopId.Location = new System.Drawing.Point(323, 11); + this.txtShopId.Location = new System.Drawing.Point(346, 12); this.txtShopId.Name = "txtShopId"; this.txtShopId.Size = new System.Drawing.Size(90, 23); this.txtShopId.TabIndex = 372; @@ -358,7 +385,7 @@ namespace TemuKJD.WXForms.AdminForms // label2 // this.label2.AutoSize = true; - this.label2.Location = new System.Drawing.Point(279, 14); + this.label2.Location = new System.Drawing.Point(302, 15); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(55, 17); this.label2.TabIndex = 373; @@ -386,15 +413,15 @@ namespace TemuKJD.WXForms.AdminForms this.splitContainer2.Panel2.Controls.Add(this.chkAutoDrag); this.splitContainer2.Panel2.Controls.Add(this.ucSplitPage1); this.splitContainer2.Panel2.Controls.Add(this.statusBar); - this.splitContainer2.Size = new System.Drawing.Size(1273, 560); - this.splitContainer2.SplitterDistance = 531; + this.splitContainer2.Size = new System.Drawing.Size(1273, 522); + this.splitContainer2.SplitterDistance = 493; this.splitContainer2.TabIndex = 0; // // pbLoading // this.pbLoading.Anchor = System.Windows.Forms.AnchorStyles.None; this.pbLoading.Image = global::TemuKJD.Properties.Resources.loading_blue; - this.pbLoading.Location = new System.Drawing.Point(611, 240); + this.pbLoading.Location = new System.Drawing.Point(611, 221); this.pbLoading.Name = "pbLoading"; this.pbLoading.Size = new System.Drawing.Size(50, 50); this.pbLoading.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; @@ -408,7 +435,7 @@ namespace TemuKJD.WXForms.AdminForms this.pnlAddProdRemaining.Controls.Add(this.lblShopId); this.pnlAddProdRemaining.Controls.Add(this.panel2); this.pnlAddProdRemaining.Controls.Add(this.lblAddProdRemaining); - this.pnlAddProdRemaining.Location = new System.Drawing.Point(399, 70); + this.pnlAddProdRemaining.Location = new System.Drawing.Point(399, 51); this.pnlAddProdRemaining.Name = "pnlAddProdRemaining"; this.pnlAddProdRemaining.Size = new System.Drawing.Size(474, 146); this.pnlAddProdRemaining.TabIndex = 7; @@ -560,48 +587,11 @@ namespace TemuKJD.WXForms.AdminForms this.dgvShop.ReadOnly = true; this.dgvShop.RowTemplate.Height = 23; this.dgvShop.ShowCellErrors = false; - this.dgvShop.Size = new System.Drawing.Size(1265, 531); + this.dgvShop.Size = new System.Drawing.Size(1265, 493); this.dgvShop.TabIndex = 5; this.dgvShop.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvShop_CellContentClick); this.dgvShop.CellMouseDown += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dgvShop_CellMouseDown); // - // chkAutoDrag - // - this.chkAutoDrag.Anchor = System.Windows.Forms.AnchorStyles.Right; - this.chkAutoDrag.AutoSize = true; - this.chkAutoDrag.BackColor = System.Drawing.Color.White; - this.chkAutoDrag.Location = new System.Drawing.Point(597, 0); - this.chkAutoDrag.Name = "chkAutoDrag"; - this.chkAutoDrag.Size = new System.Drawing.Size(159, 21); - this.chkAutoDrag.TabIndex = 3; - this.chkAutoDrag.Text = "登录时自动滑动拼图验证"; - this.chkAutoDrag.UseVisualStyleBackColor = false; - this.chkAutoDrag.Visible = false; - // - // ucSplitPage1 - // - this.ucSplitPage1.CurrentPage = 1; - this.ucSplitPage1.Dock = System.Windows.Forms.DockStyle.Right; - this.ucSplitPage1.IsShowPageSize = false; - this.ucSplitPage1.Location = new System.Drawing.Point(911, 0); - this.ucSplitPage1.Margin = new System.Windows.Forms.Padding(0); - this.ucSplitPage1.Name = "ucSplitPage1"; - this.ucSplitPage1.PageSize = 50; - this.ucSplitPage1.Size = new System.Drawing.Size(362, 25); - this.ucSplitPage1.TabIndex = 4; - this.ucSplitPage1.TotalPage = 1; - // - // statusBar - // - this.statusBar.BackColor = System.Drawing.Color.White; - this.statusBar.Dock = System.Windows.Forms.DockStyle.Fill; - 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(0, 0); - this.statusBar.Margin = new System.Windows.Forms.Padding(0); - this.statusBar.Name = "statusBar"; - this.statusBar.Size = new System.Drawing.Size(1273, 25); - this.statusBar.TabIndex = 1; - // // colSelect // this.colSelect.FillWeight = 26F; @@ -853,6 +843,43 @@ namespace TemuKJD.WXForms.AdminForms this.colDelete.ReadOnly = true; this.colDelete.Visible = false; // + // chkAutoDrag + // + this.chkAutoDrag.Anchor = System.Windows.Forms.AnchorStyles.Right; + this.chkAutoDrag.AutoSize = true; + this.chkAutoDrag.BackColor = System.Drawing.Color.White; + this.chkAutoDrag.Location = new System.Drawing.Point(597, 0); + this.chkAutoDrag.Name = "chkAutoDrag"; + this.chkAutoDrag.Size = new System.Drawing.Size(159, 21); + this.chkAutoDrag.TabIndex = 3; + this.chkAutoDrag.Text = "登录时自动滑动拼图验证"; + this.chkAutoDrag.UseVisualStyleBackColor = false; + this.chkAutoDrag.Visible = false; + // + // ucSplitPage1 + // + this.ucSplitPage1.CurrentPage = 1; + this.ucSplitPage1.Dock = System.Windows.Forms.DockStyle.Right; + this.ucSplitPage1.IsShowPageSize = true; + this.ucSplitPage1.Location = new System.Drawing.Point(884, 0); + this.ucSplitPage1.Margin = new System.Windows.Forms.Padding(0); + this.ucSplitPage1.Name = "ucSplitPage1"; + this.ucSplitPage1.PageSize = 50; + this.ucSplitPage1.Size = new System.Drawing.Size(389, 25); + this.ucSplitPage1.TabIndex = 4; + this.ucSplitPage1.TotalPage = 1; + // + // statusBar + // + this.statusBar.BackColor = System.Drawing.Color.White; + this.statusBar.Dock = System.Windows.Forms.DockStyle.Fill; + 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(0, 0); + this.statusBar.Margin = new System.Windows.Forms.Padding(0); + this.statusBar.Name = "statusBar"; + this.statusBar.Size = new System.Drawing.Size(1273, 25); + this.statusBar.TabIndex = 1; + // // WXAdminShopListForm // this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; @@ -952,5 +979,6 @@ namespace TemuKJD.WXForms.AdminForms private System.Windows.Forms.DataGridViewTextBoxColumn colSubSa; private System.Windows.Forms.DataGridViewLinkColumn colEdit; private System.Windows.Forms.DataGridViewLinkColumn colDelete; + private DevComponents.DotNetBar.PanelEx btnExportShopErp; } } \ No newline at end of file diff --git a/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.cs b/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.cs index 895f38c..e3ddfdd 100644 --- a/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.cs +++ b/TEMUKJD/WXForms/AdminForms/WXAdminShopListForm.cs @@ -101,7 +101,7 @@ namespace TemuKJD.WXForms.AdminForms { int pageCount; decimal seconds = 0; - var list = AdminGetServerShopLst(out pageCount, out seconds, page); + var list = AdminGetServerShopLst(out pageCount, out seconds, page, ucSplitPage1.PageSize); lstAdminShopInfo.AddRange(list); this.ucSplitPage1.TotalPage = pageCount; @@ -629,5 +629,32 @@ namespace TemuKJD.WXForms.AdminForms { this.pnlAddProdRemaining.Visible = false; } + + private void btnExportShopErp_Click(object sender, EventArgs e) + { + //int success = 0; + //foreach (var shop in lstAdminShopInfo) + //{ + // ////if (user.group_id != "3") + // //// continue; + + // //string prodDataStr = "{\"userName\":\"15288888888\",\"password\":\"Andy@1984\",\"phonenumber\":\"15288888888\",\"status\": \"0\",\"remark\":\"a15288888888.\",\"roleIds\":[\"5\"]}"; + // //prodDataStr = "{\"userName\":\"" + user.user_name + "\",\"password\":\"" + user.user_name + "\",\"phonenumber\":\"" + user.mobile + + // // "\",\"status\": \"0\",\"nickName\":\"" + user.nick_name + "\",\"roleIds\":[\"5\"]}"; + + // string url = "https://po.e57.cn/prod-api/api/oms-api/shop/addShopTemp"; + // string data = "{\"mainAccountUserName\":\"" + shop.UserName + "\",\"appId\":\"" + shop.ShopId + "\",\"shopName\":\"" + shop.ShopAccount + "\"}"; + // var exportRst = WXHttpResponseBLL.e57PostResponse(url, data, ""); + // if (exportRst.Contains("200")) + // { + // success++; + // } + // else + // { + + // } + // //Thread.Sleep(500); + //} + } } } diff --git a/TEMUKJD/WXForms/ProductForms/WXProdSyncForm.cs b/TEMUKJD/WXForms/ProductForms/WXProdSyncForm.cs index a4d09ab..2659e26 100644 --- a/TEMUKJD/WXForms/ProductForms/WXProdSyncForm.cs +++ b/TEMUKJD/WXForms/ProductForms/WXProdSyncForm.cs @@ -1100,8 +1100,8 @@ namespace TemuKJD.WXForms.ProductForms { var prodId = row.Cells["colDraftId"].Value.ParseToString(); var extCode = row.Cells["colExtCode"].Value.ParseToString(); - prodIdLst.Add(prodId); - extCodeLst.Add(extCode); + prodIdLst.Add(prodId.IsNullOrEmpty() ? "emptyProdId" : prodId); + extCodeLst.Add(extCode.IsNullOrEmpty() ? "emptyExtCode" : extCode); } // 查询下架库有没有