diff --git a/AllBase/AllBase.csproj b/AllBase/AllBase.csproj index bed245b..fe29a8d 100644 --- a/AllBase/AllBase.csproj +++ b/AllBase/AllBase.csproj @@ -210,11 +210,13 @@ + + diff --git a/AllBase/BaseClass.cs b/AllBase/BaseClass.cs index 1405b61..1a223d9 100644 --- a/AllBase/BaseClass.cs +++ b/AllBase/BaseClass.cs @@ -27,7 +27,7 @@ namespace AllBase /// /// 版本ID /// - public static int VersionCount = 963; + public static int VersionCount = 967; //public static int VersionCount = 613; /// diff --git a/AllBase/GetHtml.cs b/AllBase/GetHtml.cs index 8700563..01d37db 100644 --- a/AllBase/GetHtml.cs +++ b/AllBase/GetHtml.cs @@ -1186,7 +1186,7 @@ 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) + //if(BaseClass.SaLevel > 0) { //260306 采用GZip/deflate压缩 //request.Headers.Set(HttpRequestHeader.AcceptEncoding, "gzip, deflate, br, zstd"); @@ -1215,14 +1215,14 @@ 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)); - if (BaseClass.SaLevel == 0) - { - return readStream.ReadToEnd().Trim(); - } - else + //if (BaseClass.SaLevel == 0) + //{ + // return readStream.ReadToEnd().Trim(); + //} + //else { //260306 超管采用GZip/deflate压缩 - Thread.Sleep(50); + //Thread.Sleep(50); return GetProxyHtml.ReadResponse(response); } } diff --git a/AllBase/Helper/GlobalConfig.cs b/AllBase/Helper/GlobalConfig.cs index d4bbdfd..59746b3 100644 --- a/AllBase/Helper/GlobalConfig.cs +++ b/AllBase/Helper/GlobalConfig.cs @@ -19,6 +19,7 @@ namespace AllBase.Helper /// 店铺列表 /// public static ConcurrentList ShopLoginList { get; set; } = new ConcurrentList(); + public static ConcurrentList BuyerLoginList { get; set; } = new ConcurrentList(); /// /// 微店店铺列表 /// diff --git a/AllBase/Model/Result/BuyerLoginInfo.cs b/AllBase/Model/Result/BuyerLoginInfo.cs new file mode 100644 index 0000000..63697f3 --- /dev/null +++ b/AllBase/Model/Result/BuyerLoginInfo.cs @@ -0,0 +1,22 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace AllBase.Model.Result +{ + public class BuyerLoginInfo + { + public int id { get; set; } + public string user_name { get; set; } + public string buyer_id { get; set; } + public string buyer_name { get; set; } + public string buyer_nick { get; set; } + public string cookie { get; set; } + public string status { get; set; } + public string notes { get; set; } + public DateTime add_time { get; set; } + public DateTime mdy_time { get; set; } + } +} diff --git a/AllBase/Model/Result/PDDResult/PddBuyerOrderInfoLite.cs b/AllBase/Model/Result/PDDResult/PddBuyerOrderInfoLite.cs new file mode 100644 index 0000000..6a0fc74 --- /dev/null +++ b/AllBase/Model/Result/PDDResult/PddBuyerOrderInfoLite.cs @@ -0,0 +1,100 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace AllBase.Model.Result.PDDResult +{ + public class PddBuyerOrderInfoLite + { + //平台快递编码 微信快递名称 PDD + //EMS EMS 邮政快递包裹 + //JTSD 极兔速递 极兔速递 + //STO 申通快递 申通快递 + //YD 韵达速递 韵达快递 + //YTO 圆通速递 圆通快递 + //ZTO 中通快递 中通快递 + + public string outExpressCompanyMsg { get; set; } // 物流公司名称,可以尝试直接从列表中匹配 + public string outExpressCompanyCode + { + get + { + if (outExpressCompanyMsg == null) return ""; + if (outExpressCompanyMsg.Contains("邮政快递包裹")) return "EMS"; + if (outExpressCompanyMsg.Contains("极兔速递")) return "JTSD"; + if (outExpressCompanyMsg.Contains("申通快递")) return "STO"; + if (outExpressCompanyMsg.Contains("韵达快递")) return "YD"; + if (outExpressCompanyMsg.Contains("圆通快递")) return "YTO"; + if (outExpressCompanyMsg.Contains("中通快递")) return "ZTO"; + if (outExpressCompanyMsg.Contains("顺丰")) return "SF"; + return ""; + } + } + public string outExpressCompanyName + { + get + { + if (outExpressCompanyMsg == null) return ""; + if (outExpressCompanyMsg.Contains("邮政快递包裹")) return "邮政快递包裹"; + if (outExpressCompanyMsg.Contains("极兔速递")) return "极兔速递"; + if (outExpressCompanyMsg.Contains("申通快递")) return "申通快递"; + if (outExpressCompanyMsg.Contains("韵达快递")) return "韵达快递"; + if (outExpressCompanyMsg.Contains("圆通快递")) return "圆通快递"; + if (outExpressCompanyMsg.Contains("中通快递")) return "中通快递"; + if (outExpressCompanyMsg.Contains("顺丰")) return "顺丰速运"; + return ""; + } + } + public string sendStatus { get; set; } = ""; + public string buyerId { get; set; } // 买手Id + public string buyerName { get; set; } // 买手名称 + + public string order_sn { get; set; } // "260409-440915730042665", + public string parent_order_sn { get; set; } // "", + public int? order_amount { get; set; } // 2090, + public int? shipping_amount { get; set; } // 0, + public int? discount_amount { get; set; } // 200, + public int? service_amount { get; set; } // 0, + public string display_amount { get; set; } // 2090 实付款 + public long? order_time { get; set; } // 1775731637 + public string tracking_number { get; set; } // "JT5474027114111", 物流单号 + public string order_link_url { get; set; } // "order.html?order_sn=260408-386657164922665&page_from=1", + + public List order_Goods { get; set; } + public string order_status_prompt { get; set; } // "待收货", + public string order_prompt_color { get; set; } // "#E02E24", + public string activity_type { get; set; } // 3, + + public extra_info extra_info { get; set; } + } + + public class extra_info + { + public order_hint order_hint { get; set; } + } + public class order_hint + { + public string type { get; set; } // "express_info", + public string message { get; set; } // "商家已发货,正在通知极兔速递取件", + } + + public class order_good + { + public string goods_id { get; set; } // "865983669848", + public string sku_id { get; set; } // "1824184724450", + public string goods_name { get; set; } // "新款夏季性感上衣蕾丝吊带带胸垫防走光吊带打底背心女美背内衣女", + public int? goods_price { get; set; } // 2290, + public int? goods_number { get; set; } // 1, + public string thumb_url { get; set; } // "https://img.pddpic.com/mms-goods-image/2026-03-03/bdf06666-5663-4ddf-96a4-cfc09a3ba3aa.jpeg.a.jpeg", + public string spec { get; set; } // "XL(适合140-160斤),白色+可可棕", + public int? event_type { get; set; } // 0, + public int? is_pre_sale { get; set; } // 0, + public int? goods_type { get; set; } // 1, + public long? cat_id_1 { get; set; } // 8583, + public long? cat_id_2 { get; set; } // 8589, + public long? cat_id_3 { get; set; } // 8614, + public long? cat_id_4 { get; set; } // 0 + } +} diff --git a/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs b/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs index 7cf3784..18a9fd5 100644 --- a/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs +++ b/KJDService/KJD_WebService/BLL/BXX/BXXProductManage.cs @@ -250,6 +250,90 @@ namespace KJD_Web.BLL.BXX return "{\"code\":19999,\"msg\":\"输入为空\"}"; } + public string MdyViolationProd(string inputData) + { + if (!string.IsNullOrEmpty(inputData)) + { + var time = 0; + int.TryParse(RegexUtils.GetStringQuery(ref inputData, "time"), out time); + string time1 = RegexUtils.GetStringQuery(ref inputData, "code"); + if (time1 != EncrypUtil.Encryption(time)) + return "{\"code\":50000,\"msg\":\"校验失败\"}"; + + string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name")?.Replace("'", "\\'"); + if (string.IsNullOrEmpty(user_name)) + { + return "{\"code\":500,\"msg\":\"没有用户名\"}"; + } + + string product_name = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "product_name"))?.Replace("'", "\\'"); + string secret_spu_id = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "secret_spu_id"))?.Replace("'", "\\'"); + string spu_id = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "spu_id"))?.Replace("'", "\\'"); + + string group = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "group"))?.Replace("'", "\\'"); + string notes = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "notes"))?.Replace("'", "\\'"); + string wx_safe_status = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "wx_safe_status"))?.Replace("'", "\\'"); + if (string.IsNullOrWhiteSpace(product_name) && string.IsNullOrWhiteSpace(secret_spu_id) && string.IsNullOrWhiteSpace(spu_id)) + return "{\"code\":500,\"msg\":\"没有商品查询信息\"}"; + + string conn = System.Configuration.ConfigurationManager.ConnectionStrings["ConnKJD"].ConnectionString; + MysqlUtils mySql = new MysqlUtils(conn); + string sql = ""; + + if (!string.IsNullOrEmpty(product_name)) + sql = "select id,spu_id from bxx.product p where p.product_name='" + product_name + "' and p.wx_safe_status in ('安全商品','未校验');"; + else if (!string.IsNullOrEmpty(secret_spu_id)) + sql = "select id,spu_id from bxx.product p where p.secret_spu_id='" + secret_spu_id + "' and p.wx_safe_status in ('安全商品','未校验');"; + else + sql = "select id,spu_id from bxx.product p where p.spu_id='" + spu_id + "' and p.wx_safe_status in ('安全商品','未校验');"; + + + var dt = mySql.ExecuteDataTable(sql); + if (!string.IsNullOrEmpty(mySql.Message)) + { + mySql.Close(); + return "{\"code\":500,\"msg\":\"" + mySql.Message + "\"}"; + } + var ids = ""; + foreach(DataRow row in dt.Rows) + { + ids += row["spu_id"].ParseToString() + "','"; + } + ids.Trim(',', '\''); + if (string.IsNullOrEmpty(ids)) + { + return "{\"code\":200,\"msg\":\"success\",\"err_msg\":\"商品不存在\"}"; + } + else + { + sql = "update bxx.product p set"; + if (group != null) + sql += " p.group='" + group + "',"; + if (notes != null) + sql += " p.notes='" + notes + "',"; + if (wx_safe_status != null) + sql += " p.wx_safe_status='" + wx_safe_status + "',"; + sql += " p.mdy_time='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',"; + sql = sql.TrimEnd(','); + sql += " where p.spu_id in('" + ids + "')"; + + + + var rst = mySql.ExecuteNonQuery(sql); + mySql.Close(); + if (rst) + { + return "{\"code\":200,\"msg\":\"success\"}"; + } + else + { + return "{\"code\":500,\"msg\":\"" + mySql.Message + "\"}"; + } + } + } + return "{\"code\":19999,\"msg\":\"输入为空\"}"; + } + public string GetProductSpuIdLst(string inputData) { var timeCalc = DateTime.Now; @@ -1295,11 +1379,11 @@ namespace KJD_Web.BLL.BXX } if (!string.IsNullOrEmpty(wx_cat_2)) { - where += " and p.wx_cat_2=" + wx_cat_2 + ""; + where += " and p.wx_cat_2 in (" + wx_cat_2 + ")"; } if (!string.IsNullOrEmpty(wx_cat_3)) { - where += " and p.wx_cat_3=" + wx_cat_3 + ""; + where += " and p.wx_cat_3 in (" + wx_cat_3 + ")"; } if (!string.IsNullOrEmpty(product_get_type)) where += " and p.product_get_type ='" + product_get_type + "'"; diff --git a/KJDService/KJD_WebService/BLL/BXX/BXXUserManage.cs b/KJDService/KJD_WebService/BLL/BXX/BXXUserManage.cs index 50db1a9..edf7b0c 100644 --- a/KJDService/KJD_WebService/BLL/BXX/BXXUserManage.cs +++ b/KJDService/KJD_WebService/BLL/BXX/BXXUserManage.cs @@ -1,4 +1,6 @@ using KJD_Web.Model; +using KJD_Web.Model.PddModel; +using KJD_Web.Model.ShopModel; using KJD_Web.Utils; using NaiBa.Util.Extension; using System; @@ -201,7 +203,6 @@ namespace KJD_Web.BLL.BXX return "{\"code\":19999,\"msg\":\"输入为空\"}"; } - public string DelUser(string inputData) { if (!string.IsNullOrEmpty(inputData)) @@ -390,8 +391,6 @@ namespace KJD_Web.BLL.BXX return "{\"code\":19999,\"msg\":\"输入为空\"}"; } - - public string ChangePassword(string inputData) { var userName = RegexUtils.GetStringJson(ref inputData, "user_name")?.Replace("'", "\\'"); @@ -527,5 +526,305 @@ namespace KJD_Web.BLL.BXX } return "{\"code\":19999,\"msg\":\"输入为空\"}"; } + + public string AddBuyer(string inputData) + { + if (!string.IsNullOrEmpty(inputData)) + { + string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name")?.Replace("'", "\\'"); + string buyer_id = RegexUtils.GetStringQuery(ref inputData, "buyer_id")?.Replace("'", "\\'"); + string buyer_name = RegexUtils.GetStringQuery(ref inputData, "buyer_name")?.Replace("'", "\\'"); + string buyer_nick = RegexUtils.GetStringQuery(ref inputData, "buyer_nick")?.Replace("'", "\\'"); + string cookie = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cookie"))?.Replace("'", "\\'"); + string notes = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "notes"))?.Replace("'", "\\'"); + + int r2 = 0; + int.TryParse(RegexUtils.GetStringQuery(ref inputData, "r2"), out r2); + + if (string.IsNullOrEmpty(user_name)) + { + return "{\"code\":500,\"msg\":\"没有用户名\"}"; + } + if (string.IsNullOrEmpty(buyer_name)) + { + return "{\"code\":501,\"msg\":\"没有买手登录名\"}"; + } + + string conn = System.Configuration.ConfigurationManager.ConnectionStrings["ConnKJD"].ConnectionString; + MysqlUtils mySql = new MysqlUtils(conn); + string sql = "select exists (select 1 from bxx.shop where buyer_id='" + buyer_id + "' and user_name='" + user_name + "')"; + var exist = mySql.ExecuteFirstInt(sql); + if (exist > 0) + { + mySql.Close(); + return "{\"code\":500,\"msg\":\"买手" + buyer_name + " " + buyer_nick + "已存在\"}"; + } + + sql = "insert into bxx.buyer (user_name,buyer_id,buyer_name,buyer_nick,cookie,notes) " + + "values ('" + user_name + "','" + buyer_id + "','" + buyer_name + "','" + buyer_nick + "','" + cookie + "','" + notes + "');"; + var rst = mySql.ExecuteNonQuery(sql); + mySql.Close(); + if (rst) + { + return "{\"code\":200,\"msg\":\"success\"}"; + } + else + { + return "{\"code\":500,\"msg\":\"" + mySql.Message + "\"}"; + } + } + return "{\"code\":19999,\"msg\":\"未知错误\"}"; + } + + public string MdyBuyer(string inputData) + { + if (!string.IsNullOrEmpty(inputData)) + { + string user_name = RegexUtils.GetStringQuery(ref inputData, "user_name")?.Replace("'", "\\'"); + string buyer_id = RegexUtils.GetStringQuery(ref inputData, "buyer_id")?.Replace("'", "\\'"); + string buyer_name = RegexUtils.GetStringQuery(ref inputData, "buyer_name")?.Replace("'", "\\'"); ; + string buyer_nick = RegexUtils.GetStringQuery(ref inputData, "buyer_nick")?.Replace("'", "\\'"); ; + string cookie = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cookie"))?.Replace("'", "\\'"); ; + string notes = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "notes"))?.Replace("'", "\\'"); + string status = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "status"))?.Replace("'", "\\'"); + + int r2 = 0; + int.TryParse(RegexUtils.GetStringQuery(ref inputData, "r2"), out r2); + + if (string.IsNullOrEmpty(user_name)) + { + return "{\"code\":500,\"msg\":\"没有用户名\"}"; + } + if (string.IsNullOrEmpty(buyer_id)) + { + return "{\"code\":501,\"msg\":\"没有买手号\"}"; + } + + string conn = System.Configuration.ConfigurationManager.ConnectionStrings["ConnKJD"].ConnectionString; + MysqlUtils mySql = new MysqlUtils(conn); + string sql = "update bxx.buyer set"; + if (buyer_name != null) + sql += " buyer_name='" + buyer_name + "',"; + if (buyer_nick != null) + sql += " buyer_nick='" + buyer_nick + "',"; + if (cookie != null) + sql += " cookie='" + cookie + "',"; + if (notes != null) + sql += " notes='" + notes + "',"; + if (status != null) + sql += " status='" + status + "',"; + sql = sql.TrimEnd(','); + + sql += " where buyer_id='" + buyer_id + "' and user_name='" + user_name + "'"; + + var rst = mySql.ExecuteNonQuery(sql); + mySql.Close(); + if (rst) + { + return "{\"code\":200,\"msg\":\"success\"}"; + } + else + { + return "{\"code\":500,\"msg\":\"" + mySql.Message + "\"}"; + } + } + return "{\"code\":19999,\"msg\":\"未知错误\"}"; + } + public string MdyBuyerCookie(string inputData) + { + if (!string.IsNullOrEmpty(inputData)) + { + string user_name = RegexUtils.GetStringQuery(ref inputData, "buyer_user_name")?.Replace("'", "\\'"); + string buyer_id = RegexUtils.GetStringQuery(ref inputData, "buyer_id")?.Replace("'", "\\'"); + string cookie = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "cookie"))?.Replace("'", "\\'"); + string status = HtmlUtils.UrlDecodeUtf8(RegexUtils.GetStringQuery(ref inputData, "status"))?.Replace("'", "\\'"); + + int r2 = 0; + int.TryParse(RegexUtils.GetStringQuery(ref inputData, "r2"), out r2); + + if (string.IsNullOrEmpty(buyer_id)) + { + return "{\"code\":501,\"msg\":\"没有买手号\"}"; + } + + string conn = System.Configuration.ConfigurationManager.ConnectionStrings["ConnKJD"].ConnectionString; + MysqlUtils mySql = new MysqlUtils(conn); + string sql = "update bxx.buyer set"; + if (cookie != null) + sql += " cookie='" + cookie + "',"; + if (status != null) + sql += " status='" + status + "',"; + sql = sql.TrimEnd(','); + + sql += " where buyer_id='" + buyer_id + "';"; + + var rst = mySql.ExecuteNonQuery(sql); + mySql.Close(); + if (rst) + { + return "{\"code\":200,\"msg\":\"success\"}"; + } + else + { + return "{\"code\":500,\"msg\":\"" + mySql.Message + "\"}"; + } + } + return "{\"code\":19999,\"msg\":\"未知错误\"}"; + } + + public string GetBuyer(string inputData) + { + if (!string.IsNullOrEmpty(inputData)) + { + var user_name = RegexUtils.GetStringQuery(ref inputData, "user_name"); + var password = RegexUtils.GetStringQuery(ref inputData, "password"); + if (string.IsNullOrEmpty(user_name)) + { + return "{\"code\":500,\"msg\":\"没有用户名\"}"; + } + + var search_notes = RegexUtils.GetStringQuery(ref inputData, "search_notes"); + var search_buyer_id = RegexUtils.GetStringQuery(ref inputData, "search_buyer_id"); + var search_buyer_name = RegexUtils.GetStringQuery(ref inputData, "search_buyer_name"); + var search_buyer_nick = RegexUtils.GetStringQuery(ref inputData, "search_buyer_nick"); + + var buyer_ids = RegexUtils.GetStringQuery(ref inputData, "buyer_ids")?.Replace("'", ""); + if (!string.IsNullOrWhiteSpace(buyer_ids)) + { + List shopIdLst = buyer_ids.Split(',').ToList(); + buyer_ids = "'" + string.Join("','", shopIdLst) + "'"; + } + var buyer_names = RegexUtils.GetStringQuery(ref inputData, "buyer_names"); + if (!string.IsNullOrWhiteSpace(buyer_names)) + { + List shopNameLst = buyer_names.Split(',').ToList(); + buyer_names = "'" + string.Join("','", shopNameLst) + "'"; + } + var buyer_nicks = RegexUtils.GetStringQuery(ref inputData, "buyer_nicks"); + if (!string.IsNullOrWhiteSpace(buyer_nicks)) + { + List shopNotesLst = buyer_nicks.Split(',').ToList(); + buyer_nicks = "'" + string.Join("','", shopNotesLst) + "'"; + } + + var page = RegexUtils.GetStringQuery(ref inputData, "page").ParseToInt(); + var page_size = RegexUtils.GetStringQuery(ref inputData, "page_size").ParseToInt(); + + if (page_size == 0) + page_size = 50; + int r2 = 0; + int.TryParse(RegexUtils.GetStringQuery(ref inputData, "r2"), out r2); + + string conn = System.Configuration.ConfigurationManager.ConnectionStrings["ConnKJD"].ConnectionString; + MysqlUtils mySql = new MysqlUtils(conn); + + string sql = "SELECT COUNT(s.id) FROM bxx.buyer s WHERE 1=1"; + + //where子句 + string where = ""; + if (!string.IsNullOrWhiteSpace(search_notes)) + where += " and s.notes like '%" + search_notes + "%'"; + if (!string.IsNullOrWhiteSpace(search_buyer_id)) + where += " and s.buyer_id like '%" + search_buyer_id + "%'"; + if (!string.IsNullOrWhiteSpace(search_buyer_name)) + where += " and s.buyer_name like '%" + search_buyer_name + "%'"; + if (!string.IsNullOrWhiteSpace(search_buyer_nick)) + where += " and s.buyer_nick like '%" + search_buyer_nick + "%'"; + + if (!string.IsNullOrWhiteSpace(buyer_ids)) + where += " and s.buyer_id in (" + buyer_ids + ")"; + if (!string.IsNullOrWhiteSpace(buyer_names)) + where += " and s.buyer_name in (" + buyer_names + ")"; + if (!string.IsNullOrWhiteSpace(buyer_nicks)) + where += " and s.buyer_nick in (" + buyer_nicks + ")"; + + if (!string.IsNullOrWhiteSpace(user_name)) + where += " and s.user_name='" + user_name + "'"; + sql += where; + + var count = mySql.ExecuteRowCount(sql); + + DataTable dt; + if (count == 0) + { + dt = new DataTable(); + } + else + { + sql = "SELECT s.*"; + sql += " FROM bxx.buyer s WHERE 1=1"; + + sql += where; // where 子句 + + sql += " ORDER BY s.id DESC"; + sql += " LIMIT " + Math.Max(page - 1, 0) * page_size + "," + page_size; + dt = mySql.ExecuteDataTable(sql); + } + + mySql.Close(); + if (dt != null) + { + List buyerList = new List(); + foreach (DataRow row in dt.Rows) + { + BuyerLoginInfo shop = new BuyerLoginInfo + { + id = Convert.ToInt32(row["id"]), + cookie = row["cookie"].ToString(), + user_name = row["user_name"].ToString(), + notes = row["notes"].ToString(), + add_time = row["add_time"].ParseToString().ParseToDateTime(), + mdy_time = row["mdy_time"].ParseToString().ParseToDateTime(), + buyer_id = row["buyer_id"].ToString(), + buyer_name = row["buyer_name"].ToString(), + buyer_nick = row["buyer_nick"].ToString(), + status = row["status"].ToString(), + }; + buyerList.Add(shop); + } + var data = JsonUtils.SerializeObjectToString(buyerList); + return "{\"code\":200,\"msg\":\"success\",\"data\":" + data + ",\"count\":" + count + "}"; + } + } + return "{\"code\":19999,\"msg\":\"未知错误\"}"; + } + + public string DelBuyer(string inputData) + { + if (!string.IsNullOrEmpty(inputData)) + { + var user_name = RegexUtils.GetStringQuery(ref inputData, "user_name"); + var password = RegexUtils.GetStringQuery(ref inputData, "password"); + if (string.IsNullOrEmpty(user_name)) + { + return "{\"code\":500,\"msg\":\"没有用户名\"}"; + } + + var buyer_id = RegexUtils.GetStringQuery(ref inputData, "buyer_id"); + if (string.IsNullOrEmpty(buyer_id)) + { + return "{\"code\":500,\"msg\":\"没有买手号\"}"; + } + + string conn = System.Configuration.ConfigurationManager.ConnectionStrings["ConnKJD"].ConnectionString; + MysqlUtils mySql = new MysqlUtils(conn); + + string sql = "DELETE FROM bxx.buyer WHERE user_name='" + user_name + "' and buyer_id='" + buyer_id + "'"; + + + var rst = mySql.ExecuteNonQuery(sql); + mySql.Close(); + + if (rst) + { + return "{\"code\":200,\"msg\":\"success\"}"; + } + else + { + return "{\"code\":501,\"msg\":" + mySql.Message + "}"; + } + } + return "{\"code\":19999,\"msg\":\"未知错误\"}"; + } } } \ No newline at end of file diff --git a/KJDService/KJD_WebService/BXXProductService.asmx.cs b/KJDService/KJD_WebService/BXXProductService.asmx.cs index 4ed156e..4a2121f 100644 --- a/KJDService/KJD_WebService/BXXProductService.asmx.cs +++ b/KJDService/KJD_WebService/BXXProductService.asmx.cs @@ -182,6 +182,18 @@ namespace KJD_Web Context.Response.End(); } + [WebMethod] + public void mdy_violation_prod() + { + string jsontext = GetRequestJsonString(); + + var result = jsontext; + result = new BXXProductManage().MdyViolationProd(jsontext); + + Context.Response.Write(result); + Context.Response.End(); + } + [WebMethod] public void del_db_product() { diff --git a/KJDService/KJD_WebService/BXXUserService.asmx.cs b/KJDService/KJD_WebService/BXXUserService.asmx.cs index 3acee8e..1eeee06 100644 --- a/KJDService/KJD_WebService/BXXUserService.asmx.cs +++ b/KJDService/KJD_WebService/BXXUserService.asmx.cs @@ -197,5 +197,62 @@ namespace KJD_Web Context.Response.Write(result); Context.Response.End(); } + + //AddBuyer + [WebMethod] + public void add_buyer() + { + string jsontext = GetRequestJsonString(); + + var result = jsontext; + result = new BXXUserManage().AddBuyer(jsontext); + + Context.Response.Write(result); + Context.Response.End(); + } + [WebMethod] + public void mdy_buyer() + { + string jsontext = GetRequestJsonString(); + + var result = jsontext; + result = new BXXUserManage().MdyBuyer(jsontext); + + Context.Response.Write(result); + Context.Response.End(); + } + [WebMethod] + public void mdy_buyer_cookie() + { + string jsontext = GetRequestJsonString(); + + var result = jsontext; + result = new BXXUserManage().MdyBuyerCookie(jsontext); + + Context.Response.Write(result); + Context.Response.End(); + } + [WebMethod] + public void get_buyer() + { + string jsontext = GetRequestJsonString(); + + var result = jsontext; + result = new BXXUserManage().GetBuyer(jsontext); + + Context.Response.Write(result); + Context.Response.End(); + } + [WebMethod] + public void del_buyer() + { + string jsontext = GetRequestJsonString(); + + var result = jsontext; + result = new BXXUserManage().DelBuyer(jsontext); + + Context.Response.Write(result); + Context.Response.End(); + } } } diff --git a/KJDService/KJD_WebService/KJD_WebService.csproj b/KJDService/KJD_WebService/KJD_WebService.csproj index 3f4a01a..03cc50f 100644 --- a/KJDService/KJD_WebService/KJD_WebService.csproj +++ b/KJDService/KJD_WebService/KJD_WebService.csproj @@ -117,6 +117,7 @@ + diff --git a/KJDService/KJD_WebService/Model/PddModel/BuyerLoginInfo.cs b/KJDService/KJD_WebService/Model/PddModel/BuyerLoginInfo.cs new file mode 100644 index 0000000..78d951c --- /dev/null +++ b/KJDService/KJD_WebService/Model/PddModel/BuyerLoginInfo.cs @@ -0,0 +1,21 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; + +namespace KJD_Web.Model.PddModel +{ + public class BuyerLoginInfo + { + public int id { get; set; } + public string user_name { get; set; } + public string buyer_id { get; set; } + public string buyer_name { get; set; } + public string buyer_nick { get; set; } + public string cookie { get; set; } + public string status { get; set; } + public string notes { get; set; } + public DateTime add_time { get; set; } + public DateTime mdy_time { get; set; } + } +} \ No newline at end of file diff --git a/TEMUKJD/ToolForms/PddMobileLoginForm.Designer.cs b/TEMUKJD/ToolForms/PddMobileLoginForm.Designer.cs index 29fd348..5b5ef81 100644 --- a/TEMUKJD/ToolForms/PddMobileLoginForm.Designer.cs +++ b/TEMUKJD/ToolForms/PddMobileLoginForm.Designer.cs @@ -44,6 +44,10 @@ this.panel2 = new System.Windows.Forms.Panel(); this.label1 = new System.Windows.Forms.Label(); this.label3 = new System.Windows.Forms.Label(); + this.label4 = new System.Windows.Forms.Label(); + this.textBox1 = new System.Windows.Forms.TextBox(); + this.btnSaveCookie = new DevComponents.DotNetBar.PanelEx(); + this.panel3 = new System.Windows.Forms.Panel(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); this.splitContainer1.Panel2.SuspendLayout(); this.splitContainer1.SuspendLayout(); @@ -52,12 +56,14 @@ this.splitContainer2.Panel2.SuspendLayout(); this.splitContainer2.SuspendLayout(); this.panel2.SuspendLayout(); + this.panel3.SuspendLayout(); this.SuspendLayout(); // // splitContainer1 // this.splitContainer1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill; + this.splitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel2; this.splitContainer1.Location = new System.Drawing.Point(0, 0); this.splitContainer1.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4); this.splitContainer1.Name = "splitContainer1"; @@ -65,6 +71,7 @@ // splitContainer1.Panel2 // this.splitContainer1.Panel2.BackColor = System.Drawing.Color.White; + this.splitContainer1.Panel2.Controls.Add(this.panel3); this.splitContainer1.Panel2.Controls.Add(this.label3); this.splitContainer1.Panel2.Controls.Add(this.panel2); this.splitContainer1.Panel2.Paint += new System.Windows.Forms.PaintEventHandler(this.splitContainer1_Panel2_Paint); @@ -241,7 +248,7 @@ this.panel2.Controls.Add(this.btnCopyPassword); this.panel2.Controls.Add(this.txtPassWord); this.panel2.Controls.Add(this.btnCopyUserName); - this.panel2.Location = new System.Drawing.Point(79, 195); + this.panel2.Location = new System.Drawing.Point(95, 398); this.panel2.Name = "panel2"; this.panel2.Size = new System.Drawing.Size(376, 257); this.panel2.TabIndex = 463; @@ -270,6 +277,59 @@ this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleRight; this.label3.Visible = false; // + // label4 + // + this.label4.AutoSize = true; + this.label4.Location = new System.Drawing.Point(28, 44); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(144, 17); + this.label4.TabIndex = 465; + this.label4.Text = "导入PDDAccessToken:"; + // + // textBox1 + // + this.textBox1.Location = new System.Drawing.Point(31, 71); + this.textBox1.Multiline = true; + this.textBox1.Name = "textBox1"; + this.textBox1.Size = new System.Drawing.Size(389, 108); + this.textBox1.TabIndex = 466; + // + // btnSaveCookie + // + this.btnSaveCookie.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.btnSaveCookie.Cursor = System.Windows.Forms.Cursors.Hand; + this.btnSaveCookie.DisabledBackColor = System.Drawing.Color.Empty; + this.btnSaveCookie.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.btnSaveCookie.Location = new System.Drawing.Point(364, 185); + this.btnSaveCookie.Name = "btnSaveCookie"; + this.btnSaveCookie.Size = new System.Drawing.Size(56, 25); + this.btnSaveCookie.Style.Alignment = System.Drawing.StringAlignment.Center; + this.btnSaveCookie.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnSaveCookie.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.btnSaveCookie.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.btnSaveCookie.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.btnSaveCookie.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.btnSaveCookie.Style.ForeColor.Color = System.Drawing.Color.White; + this.btnSaveCookie.Style.GradientAngle = 90; + this.btnSaveCookie.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.btnSaveCookie.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnSaveCookie.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.btnSaveCookie.TabIndex = 470; + this.btnSaveCookie.Text = "保存"; + this.btnSaveCookie.Click += new System.EventHandler(this.btnSaveCookie_Click); + // + // panel3 + // + this.panel3.Anchor = System.Windows.Forms.AnchorStyles.Top; + this.panel3.Controls.Add(this.textBox1); + this.panel3.Controls.Add(this.btnSaveCookie); + this.panel3.Controls.Add(this.label4); + this.panel3.Location = new System.Drawing.Point(51, 135); + this.panel3.Name = "panel3"; + this.panel3.Size = new System.Drawing.Size(452, 241); + this.panel3.TabIndex = 471; + this.panel3.Visible = false; + // // PddMobileLoginForm // this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; @@ -295,6 +355,8 @@ this.splitContainer2.ResumeLayout(false); this.panel2.ResumeLayout(false); this.panel2.PerformLayout(); + this.panel3.ResumeLayout(false); + this.panel3.PerformLayout(); this.ResumeLayout(false); } @@ -316,5 +378,9 @@ private System.Windows.Forms.Panel panel2; public System.Windows.Forms.Label label3; public System.Windows.Forms.Label label1; + private System.Windows.Forms.TextBox textBox1; + private System.Windows.Forms.Label label4; + private DevComponents.DotNetBar.PanelEx btnSaveCookie; + private System.Windows.Forms.Panel panel3; } } \ No newline at end of file diff --git a/TEMUKJD/ToolForms/PddMobileLoginForm.cs b/TEMUKJD/ToolForms/PddMobileLoginForm.cs index fc151f3..b0d6fe5 100644 --- a/TEMUKJD/ToolForms/PddMobileLoginForm.cs +++ b/TEMUKJD/ToolForms/PddMobileLoginForm.cs @@ -61,7 +61,10 @@ namespace TemuKJD.ToolForms { //this.splitContainer1.SplitterDistance = this.splitContainer1.Height - 62; if (openType == EnumOpenType.login) + { this.label3.Visible = true; + this.panel3.Visible = true; + } if (CloseAfterSecond > 0) { @@ -222,11 +225,26 @@ namespace TemuKJD.ToolForms //if (this.openType != EnumOpenType.login) { var t = CEFBrowser.SetCookieAsync(JsonHelper.SerializeObject(cookieLst), cefWebBrowser.GetCookieManager(null)); - //foreach (var cook in cookieLst) - //{ - // var t = CEFBrowser.SetCookieAsync(cook.Domain, cook.Name + "=" + cook.Value + ";", cefWebBrowser.GetCookieManager(null)); - // t.Wait(5000); - //} + foreach (var cook in cookieLst) + { + //var t = CEFBrowser.SetCookieAsync(cook.Domain.Trim('.'), cook.Name + "=" + cook.Value + ";", cefWebBrowser.GetCookieManager(null)); + //t.Wait(5000); + + //if (cook.Name == "PDDAccessToken") + //{ + // var jsStr = "var date = new Date();" + + // "date.setTime(date.getTime() + (465 * 24 * 60 * 60 * 1000)); " + + // "document.cookie='PDDAccessToken=" + cook.Value + ";domain=mobile.yangkeduo.com; expires=' + date.toUTCString()"; + + // jsStr = "document.cookie='PDDAccessToken=" + cook.Value + ";domain=mobile.yangkeduo.com;'"; + // cefWebBrowser.GetMainFrame().EvaluateScriptAsync(jsStr); + + // //cook.Expires = DateTime.Now.AddDays(465); + // //cefWebBrowser.GetCookieManager(null).SetCookie("https://" + cook.Domain.Trim('.'), cook); + //} + ////else + //// cefWebBrowser.GetCookieManager(null).SetCookie("https://" + cook.Domain, cook); + } } //根据登录的具体店铺设置local storage @@ -322,63 +340,73 @@ namespace TemuKJD.ToolForms private void RequestHandler_ResourceLoadComplete(object sender, string url, string postData, string responseData, IRequest request) { //if (url.Contains("https://mobile.yangkeduo.com/personal.html?refer_page_name=login") && openType == EnumOpenType.login) - if (url.Contains("https://mobile.yangkeduo.com/personal.html") && openType == EnumOpenType.login) + if (url.Contains("https://mobile.yangkeduo.com/index.html") && openType == EnumOpenType.login) { - Task.Run(() => + Task.Run(() => { cefWebBrowser.Load("https://mobile.yangkeduo.com/personal.html"); }); + } + + if (url.Contains("https://mobile.yangkeduo.com/personal.html")) + { + if (openType == EnumOpenType.login) { - var data = responseData; - if (data.Contains("\"success\":true") || data.Contains("nickname")) + Task.Run(() => { - var uid = BaseRegex.GetStringJson(ref data, "uid"); - var nickname = BaseRegex.GetStringJson(ref data, "nickname"); - var username = nickname; - - if (!string.IsNullOrEmpty(nickname) && !string.IsNullOrEmpty(uid)) + var data = responseData; + if (data.Contains("\"success\":true") || data.Contains("nickname")) { - List cookieList = CEFBrowser.GetCookieList(shopCookieHead, cefWebBrowser.GetCookieManager(null)); + var uid = BaseRegex.GetStringJson(ref data, "uid"); + var nickname = BaseRegex.GetStringJson(ref data, "nickname"); + var username = nickname; - var buyerUrl = BaseClass.BuildPDDObjString("user/add_buyer"); - - if (this.buyer == null) - buyer = GlobalConfig.BuyerLoginList.FirstOrDefault(buyer => buyer.buyer_id == uid); - if (this.buyer != null) + if (!string.IsNullOrEmpty(nickname) && !string.IsNullOrEmpty(uid)) { - this.buyer.user_name = username; - this.buyer.buyer_nick = nickname; - this.buyer.cookie = JsonHelper.SerializeObject(cookieList); - buyerUrl = BaseClass.BuildPDDObjString("user/mdy_buyer"); - } + Thread.Sleep(2000); - var buyerData = UserLogin.GetSignaturex() - + "&buyer_id=" + uid - + "&buyer_name=" + username - + "&buyer_nick=" + nickname; - var result = GetHtml.PostUtf8(buyerUrl, buyerData); - if (string.IsNullOrEmpty(result) || !result.Contains("\"code\":200")) - result = GetHtml.PostUtf8(buyerUrl, buyerData); + List cookieList = CEFBrowser.GetCookieList(shopCookieHead, cefWebBrowser.GetCookieManager(null)); - buyerUrl = BaseClass.BuildPDDObjString("user/mdy_buyer_cookie"); - buyerData = UserLogin.GetSignaturex() - + "&buyer_id=" + uid - + "&status=" + "在线" - + "&cookie=" + GetHtml.UrlEncodeUtf8(JsonHelper.SerializeObject(cookieList)); - result = GetHtml.PostUtf8(buyerUrl, buyerData); - if (string.IsNullOrEmpty(result) || !result.Contains("\"code\":200")) - result = GetHtml.PostUtf8(buyerUrl, buyerData); + var buyerUrl = BaseClass.BuildPDDObjString("user/add_buyer"); - Invoke(new Action(() => - { - try + if (this.buyer == null || this.buyer.buyer_id != uid) + this.buyer = GlobalConfig.BuyerLoginList.FirstOrDefault(b => b.buyer_id == uid); + if (this.buyer != null) { - if (chkCloseAfterLogin.Checked) - this.Close(); + this.buyer.user_name = username; + this.buyer.buyer_nick = nickname; + this.buyer.cookie = JsonHelper.SerializeObject(cookieList); + buyerUrl = BaseClass.BuildPDDObjString("user/mdy_buyer"); } - catch (Exception ex) - { } - })); + + var buyerData = UserLogin.GetSignaturex() + + "&buyer_id=" + uid + + "&buyer_name=" + username + + "&buyer_nick=" + nickname; + var result = GetHtml.PostUtf8(buyerUrl, buyerData); + if (string.IsNullOrEmpty(result) || !result.Contains("\"code\":200")) + result = GetHtml.PostUtf8(buyerUrl, buyerData); + + buyerUrl = BaseClass.BuildPDDObjString("user/mdy_buyer_cookie"); + buyerData = UserLogin.GetSignaturex() + + "&buyer_id=" + uid + + "&status=" + "在线" + + "&cookie=" + GetHtml.UrlEncodeUtf8(JsonHelper.SerializeObject(cookieList)); + result = GetHtml.PostUtf8(buyerUrl, buyerData); + if (string.IsNullOrEmpty(result) || !result.Contains("\"code\":200")) + result = GetHtml.PostUtf8(buyerUrl, buyerData); + + Invoke(new Action(() => + { + try + { + if (chkCloseAfterLogin.Checked) + this.Close(); + } + catch (Exception ex) + { } + })); + } } - } - }); + }); + } } } @@ -543,5 +571,23 @@ function getElementWithText(sText) { } + + private void btnSaveCookie_Click(object sender, EventArgs e) + { + Cookie cookie = new Cookie(); + cookie.Name = "PDDAccessToken"; + cookie.Domain = "mobile.yangkeduo.com"; + cookie.Expires = DateTime.Now.AddDays(465); + cookie.HttpOnly = true; + cookie.Secure = true; + cookie.Value = textBox1.Text.Trim(); + + if (this.cefWebBrowser != null) + { + var t = CEFBrowser.SetCookieAsync(JsonHelper.SerializeObject(new List { cookie }), cefWebBrowser.GetCookieManager(null)); + t.Wait(2000); + cefWebBrowser.Load("https://mobile.yangkeduo.com/personal.html"); + } + } } } diff --git a/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.Designer.cs b/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.Designer.cs index 5d04333..63e9ed1 100644 --- a/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.Designer.cs +++ b/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.Designer.cs @@ -38,6 +38,10 @@ namespace TemuKJD.WXForms.TalkForms System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle(); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(BuyerOrderListForm)); this.splitContainer1 = new System.Windows.Forms.SplitContainer(); this.btnCheck = new DevComponents.DotNetBar.PanelEx(); @@ -46,9 +50,8 @@ namespace TemuKJD.WXForms.TalkForms this.btnSearch = new DevComponents.DotNetBar.PanelEx(); this.btnAddBuyler = new DevComponents.DotNetBar.PanelEx(); this.btnDel = new DevComponents.DotNetBar.PanelEx(); - this.splitContainer2 = new System.Windows.Forms.SplitContainer(); - this.splitContainer3 = new System.Windows.Forms.SplitContainer(); - this.dgvDbProduct = new TemuKJD.UserComponent.DataGridViewEx(); + this.pbLoading = new System.Windows.Forms.PictureBox(); + this.dgvWxOrder = new TemuKJD.UserComponent.DataGridViewEx(); this.colCheck = new System.Windows.Forms.DataGridViewCheckBoxColumn(); this.colShopId = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colShopName = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -61,7 +64,6 @@ namespace TemuKJD.WXForms.TalkForms this.colOrderStatus = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.col_notes = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.colEdit = new System.Windows.Forms.DataGridViewLinkColumn(); - this.pbLoading = new System.Windows.Forms.PictureBox(); this.dgvBuyer = new TemuKJD.UserComponent.DataGridViewEx(); this.colSelect = new System.Windows.Forms.DataGridViewCheckBoxColumn(); this.colBuyerId = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -71,6 +73,12 @@ namespace TemuKJD.WXForms.TalkForms this.colVisit = new System.Windows.Forms.DataGridViewLinkColumn(); this.colLoginStatus = new System.Windows.Forms.DataGridViewLinkColumn(); this.colMessage = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.splitContainer2 = new System.Windows.Forms.SplitContainer(); + this.splitContainer3 = new System.Windows.Forms.SplitContainer(); + this.panelEx3 = new DevComponents.DotNetBar.PanelEx(); + this.panelEx2 = new DevComponents.DotNetBar.PanelEx(); + this.panelEx1 = new DevComponents.DotNetBar.PanelEx(); + this.dgvPddBuyerOrder = new TemuKJD.UserComponent.DataGridViewEx(); this.chkOnlyShowCurrentShop = new TemuKJD.UserComponent.UcCheckBox(this.components); this.lblCurrentShop = new System.Windows.Forms.Label(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); @@ -84,12 +92,28 @@ namespace TemuKJD.WXForms.TalkForms this.dtpStartTime = new System.Windows.Forms.DateTimePicker(); this.label14 = new System.Windows.Forms.Label(); this.dtpEndTime = new System.Windows.Forms.DateTimePicker(); - this.ucSplitPage1 = new TemuKJD.UserControls.UcSplitPage(); this.statusBar = new TemuKJD.UserControls.StatusBarUserControl(); + this.dataGridViewCheckBoxColumn1 = new System.Windows.Forms.DataGridViewCheckBoxColumn(); + this.colOBuyerId = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOBuyerName = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOPddOrderSn = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOOrderTime = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOImgUrl = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOImg = new System.Windows.Forms.DataGridViewImageColumn(); + this.colOGoodsInfo = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOOrderAmount = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dgvOStatus = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOExpressName = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOExpressId = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colOMsg = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.colSend = new System.Windows.Forms.DataGridViewLinkColumn(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); this.splitContainer1.Panel1.SuspendLayout(); this.splitContainer1.Panel2.SuspendLayout(); this.splitContainer1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.pbLoading)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.dgvWxOrder)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.dgvBuyer)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).BeginInit(); this.splitContainer2.Panel1.SuspendLayout(); this.splitContainer2.Panel2.SuspendLayout(); @@ -98,9 +122,7 @@ namespace TemuKJD.WXForms.TalkForms this.splitContainer3.Panel1.SuspendLayout(); this.splitContainer3.Panel2.SuspendLayout(); this.splitContainer3.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.dgvDbProduct)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.pbLoading)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.dgvBuyer)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.dgvPddBuyerOrder)).BeginInit(); this.tableLayoutPanel1.SuspendLayout(); this.SuspendLayout(); // @@ -109,7 +131,7 @@ namespace TemuKJD.WXForms.TalkForms this.splitContainer1.BackColor = System.Drawing.Color.White; this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill; this.splitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel1; - this.splitContainer1.Location = new System.Drawing.Point(1, 33); + this.splitContainer1.Location = new System.Drawing.Point(0, 0); this.splitContainer1.Name = "splitContainer1"; this.splitContainer1.Orientation = System.Windows.Forms.Orientation.Horizontal; // @@ -124,9 +146,11 @@ namespace TemuKJD.WXForms.TalkForms // // splitContainer1.Panel2 // - this.splitContainer1.Panel2.Controls.Add(this.splitContainer2); - this.splitContainer1.Size = new System.Drawing.Size(1438, 686); - this.splitContainer1.SplitterDistance = 74; + this.splitContainer1.Panel2.Controls.Add(this.pbLoading); + this.splitContainer1.Panel2.Controls.Add(this.dgvWxOrder); + this.splitContainer1.Panel2.Controls.Add(this.dgvBuyer); + this.splitContainer1.Size = new System.Drawing.Size(372, 657); + this.splitContainer1.SplitterDistance = 78; this.splitContainer1.TabIndex = 1; // // btnCheck @@ -135,7 +159,7 @@ namespace TemuKJD.WXForms.TalkForms this.btnCheck.Cursor = System.Windows.Forms.Cursors.Hand; this.btnCheck.DisabledBackColor = System.Drawing.Color.Empty; this.btnCheck.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnCheck.Location = new System.Drawing.Point(269, 16); + this.btnCheck.Location = new System.Drawing.Point(126, 39); this.btnCheck.Name = "btnCheck"; this.btnCheck.Size = new System.Drawing.Size(98, 25); this.btnCheck.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -159,7 +183,7 @@ namespace TemuKJD.WXForms.TalkForms this.btnRefresh.Cursor = System.Windows.Forms.Cursors.Hand; this.btnRefresh.DisabledBackColor = System.Drawing.Color.Empty; this.btnRefresh.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnRefresh.Location = new System.Drawing.Point(165, 16); + this.btnRefresh.Location = new System.Drawing.Point(126, 10); this.btnRefresh.Name = "btnRefresh"; this.btnRefresh.Size = new System.Drawing.Size(98, 25); this.btnRefresh.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -179,13 +203,12 @@ namespace TemuKJD.WXForms.TalkForms // // 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(1350, 16); + this.btnStopStop.Location = new System.Drawing.Point(246, 39); this.btnStopStop.Name = "btnStopStop"; - this.btnStopStop.Size = new System.Drawing.Size(66, 25); + this.btnStopStop.Size = new System.Drawing.Size(118, 25); this.btnStopStop.Style.Alignment = System.Drawing.StringAlignment.Center; this.btnStopStop.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(185)))), ((int)(((byte)(215)))), ((int)(((byte)(255))))); this.btnStopStop.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(185)))), ((int)(((byte)(215)))), ((int)(((byte)(255))))); @@ -204,12 +227,11 @@ namespace TemuKJD.WXForms.TalkForms // // btnSearch // - this.btnSearch.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.btnSearch.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; 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(1226, 16); + this.btnSearch.Location = new System.Drawing.Point(246, 10); this.btnSearch.Name = "btnSearch"; this.btnSearch.Size = new System.Drawing.Size(118, 25); this.btnSearch.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -233,7 +255,7 @@ namespace TemuKJD.WXForms.TalkForms this.btnAddBuyler.Cursor = System.Windows.Forms.Cursors.Hand; this.btnAddBuyler.DisabledBackColor = System.Drawing.Color.Empty; this.btnAddBuyler.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnAddBuyler.Location = new System.Drawing.Point(10, 16); + this.btnAddBuyler.Location = new System.Drawing.Point(10, 10); this.btnAddBuyler.Name = "btnAddBuyler"; this.btnAddBuyler.Size = new System.Drawing.Size(98, 25); this.btnAddBuyler.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -257,7 +279,7 @@ namespace TemuKJD.WXForms.TalkForms this.btnDel.Cursor = System.Windows.Forms.Cursors.Hand; this.btnDel.DisabledBackColor = System.Drawing.Color.Empty; this.btnDel.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - this.btnDel.Location = new System.Drawing.Point(373, 16); + this.btnDel.Location = new System.Drawing.Point(10, 39); this.btnDel.Name = "btnDel"; this.btnDel.Size = new System.Drawing.Size(98, 25); this.btnDel.Style.Alignment = System.Drawing.StringAlignment.Center; @@ -275,59 +297,27 @@ namespace TemuKJD.WXForms.TalkForms this.btnDel.Text = "删除选中买手"; this.btnDel.Click += new System.EventHandler(this.btnDel_Click); // - // splitContainer2 + // pbLoading // - this.splitContainer2.Dock = System.Windows.Forms.DockStyle.Fill; - this.splitContainer2.FixedPanel = System.Windows.Forms.FixedPanel.Panel2; - this.splitContainer2.Location = new System.Drawing.Point(0, 0); - this.splitContainer2.Name = "splitContainer2"; - this.splitContainer2.Orientation = System.Windows.Forms.Orientation.Horizontal; + this.pbLoading.Anchor = System.Windows.Forms.AnchorStyles.None; + this.pbLoading.Image = global::TemuKJD.Properties.Resources.loading_blue; + this.pbLoading.Location = new System.Drawing.Point(161, 262); + this.pbLoading.Name = "pbLoading"; + this.pbLoading.Size = new System.Drawing.Size(50, 50); + this.pbLoading.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; + this.pbLoading.TabIndex = 7; + this.pbLoading.TabStop = false; // - // splitContainer2.Panel1 + // dgvWxOrder // - this.splitContainer2.Panel1.Controls.Add(this.splitContainer3); - this.splitContainer2.Panel1.Padding = new System.Windows.Forms.Padding(4, 0, 4, 0); - // - // splitContainer2.Panel2 - // - this.splitContainer2.Panel2.Controls.Add(this.ucSplitPage1); - this.splitContainer2.Panel2.Controls.Add(this.statusBar); - this.splitContainer2.Size = new System.Drawing.Size(1438, 608); - this.splitContainer2.SplitterDistance = 579; - this.splitContainer2.TabIndex = 0; - // - // splitContainer3 - // - this.splitContainer3.Dock = System.Windows.Forms.DockStyle.Fill; - this.splitContainer3.FixedPanel = System.Windows.Forms.FixedPanel.Panel1; - this.splitContainer3.Location = new System.Drawing.Point(4, 0); - this.splitContainer3.Name = "splitContainer3"; - // - // splitContainer3.Panel1 - // - this.splitContainer3.Panel1.Controls.Add(this.dgvDbProduct); - this.splitContainer3.Panel1.Controls.Add(this.pbLoading); - this.splitContainer3.Panel1.Controls.Add(this.dgvBuyer); - // - // splitContainer3.Panel2 - // - this.splitContainer3.Panel2.Controls.Add(this.chkOnlyShowCurrentShop); - this.splitContainer3.Panel2.Controls.Add(this.lblCurrentShop); - this.splitContainer3.Panel2.Controls.Add(this.tableLayoutPanel1); - this.splitContainer3.Size = new System.Drawing.Size(1430, 579); - this.splitContainer3.SplitterDistance = 372; - this.splitContainer3.TabIndex = 8; - // - // dgvDbProduct - // - this.dgvDbProduct.AllowUserToAddRows = false; - this.dgvDbProduct.AllowUserToDeleteRows = false; + this.dgvWxOrder.AllowUserToAddRows = false; + this.dgvWxOrder.AllowUserToDeleteRows = false; dataGridViewCellStyle1.BackColor = System.Drawing.Color.WhiteSmoke; - this.dgvDbProduct.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1; - this.dgvDbProduct.AutoRowNumber = true; - this.dgvDbProduct.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill; - this.dgvDbProduct.BackgroundColor = System.Drawing.Color.White; - this.dgvDbProduct.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.dgvWxOrder.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1; + this.dgvWxOrder.AutoRowNumber = true; + this.dgvWxOrder.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill; + this.dgvWxOrder.BackgroundColor = System.Drawing.Color.White; + this.dgvWxOrder.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); 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))); @@ -335,9 +325,9 @@ namespace TemuKJD.WXForms.TalkForms dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight; dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText; dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False; - this.dgvDbProduct.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2; - this.dgvDbProduct.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; - this.dgvDbProduct.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.dgvWxOrder.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2; + this.dgvWxOrder.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.dgvWxOrder.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.colCheck, this.colShopId, this.colShopName, @@ -350,16 +340,15 @@ namespace TemuKJD.WXForms.TalkForms this.colOrderStatus, this.col_notes, this.colEdit}); - this.dgvDbProduct.Location = new System.Drawing.Point(6, 342); - this.dgvDbProduct.MultiSelectCheckBox = true; - this.dgvDbProduct.Name = "dgvDbProduct"; - this.dgvDbProduct.ReadOnly = true; - this.dgvDbProduct.RowTemplate.Height = 23; - this.dgvDbProduct.Size = new System.Drawing.Size(354, 212); - this.dgvDbProduct.TabIndex = 6; - this.dgvDbProduct.Visible = false; - this.dgvDbProduct.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvDbProduct_CellContentClick); - this.dgvDbProduct.Scroll += new System.Windows.Forms.ScrollEventHandler(this.dgvDbProduct_Scroll); + this.dgvWxOrder.Location = new System.Drawing.Point(8, 348); + this.dgvWxOrder.MultiSelectCheckBox = true; + this.dgvWxOrder.Name = "dgvWxOrder"; + this.dgvWxOrder.ReadOnly = true; + this.dgvWxOrder.RowTemplate.Height = 23; + this.dgvWxOrder.Size = new System.Drawing.Size(354, 212); + this.dgvWxOrder.TabIndex = 6; + this.dgvWxOrder.Visible = false; + this.dgvWxOrder.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvDbProduct_CellContentClick); // // colCheck // @@ -456,17 +445,6 @@ namespace TemuKJD.WXForms.TalkForms this.colEdit.Resizable = System.Windows.Forms.DataGridViewTriState.True; this.colEdit.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic; // - // 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(161, 248); - this.pbLoading.Name = "pbLoading"; - this.pbLoading.Size = new System.Drawing.Size(50, 50); - this.pbLoading.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; - this.pbLoading.TabIndex = 7; - this.pbLoading.TabStop = false; - // // dgvBuyer // this.dgvBuyer.AllowUserToAddRows = false; @@ -501,7 +479,7 @@ namespace TemuKJD.WXForms.TalkForms this.dgvBuyer.ReadOnly = true; this.dgvBuyer.RowHeadersWidth = 25; this.dgvBuyer.RowTemplate.Height = 23; - this.dgvBuyer.Size = new System.Drawing.Size(372, 579); + this.dgvBuyer.Size = new System.Drawing.Size(372, 575); this.dgvBuyer.TabIndex = 7; this.dgvBuyer.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvShop_CellContentClick); // @@ -569,11 +547,177 @@ namespace TemuKJD.WXForms.TalkForms this.colMessage.Name = "colMessage"; this.colMessage.ReadOnly = true; // + // splitContainer2 + // + this.splitContainer2.BackColor = System.Drawing.Color.White; + this.splitContainer2.Dock = System.Windows.Forms.DockStyle.Fill; + this.splitContainer2.FixedPanel = System.Windows.Forms.FixedPanel.Panel2; + this.splitContainer2.Location = new System.Drawing.Point(1, 33); + this.splitContainer2.Name = "splitContainer2"; + this.splitContainer2.Orientation = System.Windows.Forms.Orientation.Horizontal; + // + // splitContainer2.Panel1 + // + this.splitContainer2.Panel1.Controls.Add(this.splitContainer3); + this.splitContainer2.Panel1.Padding = new System.Windows.Forms.Padding(4, 0, 4, 0); + // + // splitContainer2.Panel2 + // + this.splitContainer2.Panel2.Controls.Add(this.statusBar); + this.splitContainer2.Size = new System.Drawing.Size(1438, 686); + this.splitContainer2.SplitterDistance = 657; + this.splitContainer2.TabIndex = 0; + // + // splitContainer3 + // + this.splitContainer3.Dock = System.Windows.Forms.DockStyle.Fill; + this.splitContainer3.FixedPanel = System.Windows.Forms.FixedPanel.Panel1; + this.splitContainer3.Location = new System.Drawing.Point(4, 0); + this.splitContainer3.Name = "splitContainer3"; + // + // splitContainer3.Panel1 + // + this.splitContainer3.Panel1.Controls.Add(this.splitContainer1); + // + // splitContainer3.Panel2 + // + this.splitContainer3.Panel2.Controls.Add(this.panelEx3); + this.splitContainer3.Panel2.Controls.Add(this.panelEx2); + this.splitContainer3.Panel2.Controls.Add(this.panelEx1); + this.splitContainer3.Panel2.Controls.Add(this.dgvPddBuyerOrder); + this.splitContainer3.Panel2.Controls.Add(this.tableLayoutPanel1); + this.splitContainer3.Panel2.Controls.Add(this.lblCurrentShop); + this.splitContainer3.Panel2.Controls.Add(this.chkOnlyShowCurrentShop); + this.splitContainer3.Size = new System.Drawing.Size(1430, 657); + this.splitContainer3.SplitterDistance = 372; + this.splitContainer3.TabIndex = 8; + // + // panelEx3 + // + this.panelEx3.Anchor = System.Windows.Forms.AnchorStyles.Bottom; + this.panelEx3.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.panelEx3.Cursor = System.Windows.Forms.Cursors.Hand; + this.panelEx3.DisabledBackColor = System.Drawing.Color.Empty; + this.panelEx3.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.panelEx3.Location = new System.Drawing.Point(497, 638); + this.panelEx3.Name = "panelEx3"; + this.panelEx3.Size = new System.Drawing.Size(61, 20); + this.panelEx3.Style.Alignment = System.Drawing.StringAlignment.Center; + this.panelEx3.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.panelEx3.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.panelEx3.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.panelEx3.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.panelEx3.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.panelEx3.Style.ForeColor.Color = System.Drawing.Color.White; + this.panelEx3.Style.GradientAngle = 90; + this.panelEx3.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.panelEx3.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.panelEx3.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.panelEx3.TabIndex = 898; + this.panelEx3.Text = "折叠"; + this.panelEx3.Click += new System.EventHandler(this.panelEx3_Click); + // + // panelEx2 + // + this.panelEx2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.panelEx2.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.panelEx2.Cursor = System.Windows.Forms.Cursors.Hand; + this.panelEx2.DisabledBackColor = System.Drawing.Color.Empty; + this.panelEx2.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.panelEx2.Location = new System.Drawing.Point(1030, 624); + this.panelEx2.Name = "panelEx2"; + this.panelEx2.Size = new System.Drawing.Size(24, 25); + this.panelEx2.Style.Alignment = System.Drawing.StringAlignment.Center; + this.panelEx2.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.panelEx2.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.panelEx2.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.panelEx2.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.panelEx2.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.panelEx2.Style.ForeColor.Color = System.Drawing.Color.White; + this.panelEx2.Style.GradientAngle = 90; + this.panelEx2.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.panelEx2.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.panelEx2.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.panelEx2.TabIndex = 894; + this.panelEx2.Text = "⬇"; + this.panelEx2.Visible = false; + this.panelEx2.Click += new System.EventHandler(this.panelEx2_Click); + // + // panelEx1 + // + this.panelEx1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.panelEx1.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled; + this.panelEx1.Cursor = System.Windows.Forms.Cursors.Hand; + this.panelEx1.DisabledBackColor = System.Drawing.Color.Empty; + this.panelEx1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.panelEx1.Location = new System.Drawing.Point(1030, 593); + this.panelEx1.Name = "panelEx1"; + this.panelEx1.Size = new System.Drawing.Size(24, 25); + this.panelEx1.Style.Alignment = System.Drawing.StringAlignment.Center; + this.panelEx1.Style.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.panelEx1.Style.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + this.panelEx1.Style.BorderColor.ColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBorder; + this.panelEx1.Style.BorderDashStyle = System.Drawing.Drawing2D.DashStyle.Dash; + this.panelEx1.Style.BorderSide = DevComponents.DotNetBar.eBorderSide.None; + this.panelEx1.Style.ForeColor.Color = System.Drawing.Color.White; + this.panelEx1.Style.GradientAngle = 90; + this.panelEx1.StyleMouseOver.Alignment = System.Drawing.StringAlignment.Center; + this.panelEx1.StyleMouseOver.BackColor1.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.panelEx1.StyleMouseOver.BackColor2.Color = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(102)))), ((int)(((byte)(255))))); + this.panelEx1.TabIndex = 890; + this.panelEx1.Text = "⬆"; + this.panelEx1.Visible = false; + this.panelEx1.Click += new System.EventHandler(this.panelEx1_Click); + // + // dgvPddBuyerOrder + // + this.dgvPddBuyerOrder.AllowUserToAddRows = false; + this.dgvPddBuyerOrder.AllowUserToDeleteRows = false; + dataGridViewCellStyle9.BackColor = System.Drawing.Color.WhiteSmoke; + this.dgvPddBuyerOrder.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle9; + this.dgvPddBuyerOrder.AutoRowNumber = true; + this.dgvPddBuyerOrder.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill; + this.dgvPddBuyerOrder.BackgroundColor = System.Drawing.Color.White; + this.dgvPddBuyerOrder.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(126)))), ((int)(((byte)(255))))); + dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle10.BackColor = System.Drawing.SystemColors.Control; + dataGridViewCellStyle10.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle10.ForeColor = System.Drawing.SystemColors.WindowText; + dataGridViewCellStyle10.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle10.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle10.WrapMode = System.Windows.Forms.DataGridViewTriState.False; + this.dgvPddBuyerOrder.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle10; + this.dgvPddBuyerOrder.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.dgvPddBuyerOrder.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.dataGridViewCheckBoxColumn1, + this.colOBuyerId, + this.colOBuyerName, + this.colOPddOrderSn, + this.colOOrderTime, + this.colOImgUrl, + this.colOImg, + this.colOGoodsInfo, + this.colOOrderAmount, + this.dgvOStatus, + this.colOExpressName, + this.colOExpressId, + this.colOMsg, + this.colSend}); + this.dgvPddBuyerOrder.Dock = System.Windows.Forms.DockStyle.Bottom; + this.dgvPddBuyerOrder.Location = new System.Drawing.Point(0, 357); + this.dgvPddBuyerOrder.MultiSelectCheckBox = true; + this.dgvPddBuyerOrder.Name = "dgvPddBuyerOrder"; + this.dgvPddBuyerOrder.ReadOnly = true; + this.dgvPddBuyerOrder.RowTemplate.Height = 23; + this.dgvPddBuyerOrder.Size = new System.Drawing.Size(1054, 300); + this.dgvPddBuyerOrder.TabIndex = 886; + this.dgvPddBuyerOrder.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvPddBuyerOrder_CellContentClick); + // // chkOnlyShowCurrentShop // this.chkOnlyShowCurrentShop.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.chkOnlyShowCurrentShop.AutoSize = true; - this.chkOnlyShowCurrentShop.Location = new System.Drawing.Point(27, 422); + this.chkOnlyShowCurrentShop.Location = new System.Drawing.Point(30, 498); this.chkOnlyShowCurrentShop.Name = "chkOnlyShowCurrentShop"; this.chkOnlyShowCurrentShop.Size = new System.Drawing.Size(135, 21); this.chkOnlyShowCurrentShop.TabIndex = 885; @@ -586,7 +730,7 @@ namespace TemuKJD.WXForms.TalkForms this.lblCurrentShop.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.lblCurrentShop.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.lblCurrentShop.ForeColor = System.Drawing.Color.DarkOrange; - this.lblCurrentShop.Location = new System.Drawing.Point(176, 422); + this.lblCurrentShop.Location = new System.Drawing.Point(179, 498); this.lblCurrentShop.Margin = new System.Windows.Forms.Padding(6, 0, 0, 0); this.lblCurrentShop.Name = "lblCurrentShop"; this.lblCurrentShop.Size = new System.Drawing.Size(214, 17); @@ -624,7 +768,7 @@ namespace TemuKJD.WXForms.TalkForms this.tableLayoutPanel1.Controls.Add(this.dtpStartTime, 5, 1); this.tableLayoutPanel1.Controls.Add(this.label14, 6, 1); this.tableLayoutPanel1.Controls.Add(this.dtpEndTime, 7, 1); - this.tableLayoutPanel1.Location = new System.Drawing.Point(21, 449); + this.tableLayoutPanel1.Location = new System.Drawing.Point(24, 525); this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.RowCount = 3; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 33.33444F)); @@ -771,21 +915,6 @@ namespace TemuKJD.WXForms.TalkForms this.dtpEndTime.TabIndex = 813; this.dtpEndTime.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(985, 0); - this.ucSplitPage1.Margin = new System.Windows.Forms.Padding(0); - this.ucSplitPage1.Name = "ucSplitPage1"; - this.ucSplitPage1.Padding = new System.Windows.Forms.Padding(0, 0, 1, 0); - this.ucSplitPage1.PageSize = 100; - this.ucSplitPage1.Size = new System.Drawing.Size(453, 25); - this.ucSplitPage1.TabIndex = 6; - this.ucSplitPage1.TotalPage = 1; - this.ucSplitPage1.Visible = false; - // // statusBar // this.statusBar.BackColor = System.Drawing.Color.White; @@ -797,11 +926,116 @@ namespace TemuKJD.WXForms.TalkForms this.statusBar.Size = new System.Drawing.Size(1438, 25); this.statusBar.TabIndex = 5; // + // dataGridViewCheckBoxColumn1 + // + this.dataGridViewCheckBoxColumn1.FillWeight = 26F; + this.dataGridViewCheckBoxColumn1.HeaderText = "选"; + this.dataGridViewCheckBoxColumn1.Name = "dataGridViewCheckBoxColumn1"; + this.dataGridViewCheckBoxColumn1.ReadOnly = true; + this.dataGridViewCheckBoxColumn1.Resizable = System.Windows.Forms.DataGridViewTriState.True; + this.dataGridViewCheckBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic; + // + // colOBuyerId + // + this.colOBuyerId.HeaderText = "买手编号"; + this.colOBuyerId.Name = "colOBuyerId"; + this.colOBuyerId.ReadOnly = true; + this.colOBuyerId.Visible = false; + // + // colOBuyerName + // + this.colOBuyerName.FillWeight = 80F; + this.colOBuyerName.HeaderText = "买手名称"; + this.colOBuyerName.Name = "colOBuyerName"; + this.colOBuyerName.ReadOnly = true; + // + // colOPddOrderSn + // + this.colOPddOrderSn.HeaderText = "拍单订单号"; + this.colOPddOrderSn.Name = "colOPddOrderSn"; + this.colOPddOrderSn.ReadOnly = true; + // + // colOOrderTime + // + dataGridViewCellStyle11.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.colOOrderTime.DefaultCellStyle = dataGridViewCellStyle11; + this.colOOrderTime.FillWeight = 70F; + this.colOOrderTime.HeaderText = "拍单时间"; + this.colOOrderTime.Name = "colOOrderTime"; + this.colOOrderTime.ReadOnly = true; + // + // colOImgUrl + // + this.colOImgUrl.HeaderText = "图片路径"; + this.colOImgUrl.Name = "colOImgUrl"; + this.colOImgUrl.ReadOnly = true; + this.colOImgUrl.Visible = false; + // + // colOImg + // + this.colOImg.FillWeight = 35F; + this.colOImg.HeaderText = "订单图片"; + this.colOImg.ImageLayout = System.Windows.Forms.DataGridViewImageCellLayout.Zoom; + this.colOImg.Name = "colOImg"; + this.colOImg.ReadOnly = true; + this.colOImg.Resizable = System.Windows.Forms.DataGridViewTriState.True; + this.colOImg.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic; + this.colOImg.Visible = false; + // + // colOGoodsInfo + // + dataGridViewCellStyle12.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.colOGoodsInfo.DefaultCellStyle = dataGridViewCellStyle12; + this.colOGoodsInfo.FillWeight = 140F; + this.colOGoodsInfo.HeaderText = "商品信息"; + this.colOGoodsInfo.Name = "colOGoodsInfo"; + this.colOGoodsInfo.ReadOnly = true; + // + // colOOrderAmount + // + this.colOOrderAmount.FillWeight = 50F; + this.colOOrderAmount.HeaderText = "金额"; + this.colOOrderAmount.Name = "colOOrderAmount"; + this.colOOrderAmount.ReadOnly = true; + // + // dgvOStatus + // + this.dgvOStatus.HeaderText = "订单状态"; + this.dgvOStatus.Name = "dgvOStatus"; + this.dgvOStatus.ReadOnly = true; + // + // colOExpressName + // + this.colOExpressName.HeaderText = "物流名称"; + this.colOExpressName.Name = "colOExpressName"; + this.colOExpressName.ReadOnly = true; + // + // colOExpressId + // + this.colOExpressId.HeaderText = "物流单号"; + this.colOExpressId.Name = "colOExpressId"; + this.colOExpressId.ReadOnly = true; + // + // colOMsg + // + this.colOMsg.HeaderText = "其他信息"; + this.colOMsg.Name = "colOMsg"; + this.colOMsg.ReadOnly = true; + // + // colSend + // + this.colSend.FillWeight = 50F; + this.colSend.HeaderText = "发送"; + this.colSend.Name = "colSend"; + this.colSend.ReadOnly = true; + this.colSend.Resizable = System.Windows.Forms.DataGridViewTriState.True; + this.colSend.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic; + // // BuyerOrderListForm // this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; this.ClientSize = new System.Drawing.Size(1440, 720); - this.Controls.Add(this.splitContainer1); + this.Controls.Add(this.splitContainer2); this.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.KeyPreview = true; @@ -813,11 +1047,14 @@ namespace TemuKJD.WXForms.TalkForms this.VisibleChanged += new System.EventHandler(this.ProductListForm_VisibleChanged); this.KeyDown += new System.Windows.Forms.KeyEventHandler(this.PDDDBProdListForm_KeyDown); this.KeyUp += new System.Windows.Forms.KeyEventHandler(this.PDDDBProdListForm_KeyUp); - this.Controls.SetChildIndex(this.splitContainer1, 0); + this.Controls.SetChildIndex(this.splitContainer2, 0); this.splitContainer1.Panel1.ResumeLayout(false); this.splitContainer1.Panel2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit(); this.splitContainer1.ResumeLayout(false); + ((System.ComponentModel.ISupportInitialize)(this.pbLoading)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.dgvWxOrder)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.dgvBuyer)).EndInit(); this.splitContainer2.Panel1.ResumeLayout(false); this.splitContainer2.Panel2.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).EndInit(); @@ -827,9 +1064,7 @@ namespace TemuKJD.WXForms.TalkForms this.splitContainer3.Panel2.PerformLayout(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer3)).EndInit(); this.splitContainer3.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.dgvDbProduct)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.pbLoading)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.dgvBuyer)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.dgvPddBuyerOrder)).EndInit(); this.tableLayoutPanel1.ResumeLayout(false); this.tableLayoutPanel1.PerformLayout(); this.ResumeLayout(false); @@ -840,13 +1075,12 @@ namespace TemuKJD.WXForms.TalkForms private System.Windows.Forms.SplitContainer splitContainer1; private System.Windows.Forms.SplitContainer splitContainer2; - private UserControls.UcSplitPage ucSplitPage1; private UserControls.StatusBarUserControl statusBar; private DevComponents.DotNetBar.PanelEx pnlEmpty; private System.Windows.Forms.TextBox txtOrderSn; private System.Windows.Forms.Label label3; private System.Windows.Forms.Label label2; - private UserComponent.DataGridViewEx dgvDbProduct; + private UserComponent.DataGridViewEx dgvWxOrder; private System.Windows.Forms.PictureBox pbLoading; private DevComponents.DotNetBar.PanelEx btnSearch; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; @@ -885,5 +1119,23 @@ namespace TemuKJD.WXForms.TalkForms private System.Windows.Forms.DataGridViewLinkColumn colVisit; private System.Windows.Forms.DataGridViewLinkColumn colLoginStatus; private System.Windows.Forms.DataGridViewTextBoxColumn colMessage; + private UserComponent.DataGridViewEx dgvPddBuyerOrder; + private DevComponents.DotNetBar.PanelEx panelEx3; + private DevComponents.DotNetBar.PanelEx panelEx2; + private DevComponents.DotNetBar.PanelEx panelEx1; + private System.Windows.Forms.DataGridViewCheckBoxColumn dataGridViewCheckBoxColumn1; + private System.Windows.Forms.DataGridViewTextBoxColumn colOBuyerId; + private System.Windows.Forms.DataGridViewTextBoxColumn colOBuyerName; + private System.Windows.Forms.DataGridViewTextBoxColumn colOPddOrderSn; + private System.Windows.Forms.DataGridViewTextBoxColumn colOOrderTime; + private System.Windows.Forms.DataGridViewTextBoxColumn colOImgUrl; + private System.Windows.Forms.DataGridViewImageColumn colOImg; + private System.Windows.Forms.DataGridViewTextBoxColumn colOGoodsInfo; + private System.Windows.Forms.DataGridViewTextBoxColumn colOOrderAmount; + private System.Windows.Forms.DataGridViewTextBoxColumn dgvOStatus; + private System.Windows.Forms.DataGridViewTextBoxColumn colOExpressName; + private System.Windows.Forms.DataGridViewTextBoxColumn colOExpressId; + private System.Windows.Forms.DataGridViewTextBoxColumn colOMsg; + private System.Windows.Forms.DataGridViewLinkColumn colSend; } } \ No newline at end of file diff --git a/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.cs b/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.cs index f0d25fe..08bbf4e 100644 --- a/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.cs +++ b/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.cs @@ -4,6 +4,10 @@ using AllBase.Model.Param; using AllBase.Model.Result; using AllBase.Model.Result.PDDResult; using AllBase.Model.Result.WXResult; +using CefSharp; +using CefSharp.WinForms; +using NaiBa.CefHelper; +using NaiBa.CefHelper.Handler; using NaiBa.Util; using NaiBa.Util.Extension; using Newtonsoft.Json.Linq; @@ -24,6 +28,7 @@ using System.Windows.Forms; using TemuKJD.BaseForms; using TemuKJD.BLL; using TemuKJD.Extension; +using TemuKJD.Helper; using TemuKJD.PDDForms.ProductSelectForms; using TemuKJD.PDDForms.ShopForms; using TemuKJD.ToolForms; @@ -36,11 +41,13 @@ namespace TemuKJD.WXForms.TalkForms private static BuyerOrderListForm instance = null; public static BuyerOrderListForm Instance { get { if (instance == null || instance.IsDisposed || instance.Disposing) instance = new BuyerOrderListForm(); return instance; } } ShopLoginInfo currentShop { get { return this.lblCurrentShop.Tag as ShopLoginInfo; } } - ConcurrentList lstWxOrderInfoLite { get; set; } = new ConcurrentList(); + //ConcurrentList lstWxOrderInfoLite { get; set; } = new ConcurrentList(); + ConcurrentList lstPddBuyerOrderInfoLite { get; set; } = new ConcurrentList(); public CancellationTokenSource cancellationTokenSource { get; set; } = new CancellationTokenSource(); + public ChromiumWebBrowser cefWebBrowser = null; public bool loadComplate = false; public bool firstVisible = false; - public DateTime nextGetOrderTime = DateTime.Now; + public DateTime nextGetOrderTime = DateTime.MinValue; public BuyerOrderListForm() { @@ -54,8 +61,14 @@ namespace TemuKJD.WXForms.TalkForms dtpEndTime.Value = DateTime.Now.Date.AddDays(1).AddSeconds(-1); dgvBuyer.AddSelectorColumn("colSelect"); + + lstPddBuyerOrderInfoLite = NaiBa.Util.Helper.ConfigHelper.LoadConfig> ("pdd_buyer_order"); + if (lstPddBuyerOrderInfoLite == null) + lstPddBuyerOrderInfoLite = new ConcurrentList(); + ShowOrder(); + GetBuyer(); - AutoGetOrder(); + AutoGetPddOrder(); loadComplate = true; } @@ -63,6 +76,223 @@ namespace TemuKJD.WXForms.TalkForms { } + void ShowOrder() + { + Task.Run(() => { + + foreach(var order in lstPddBuyerOrderInfoLite) + { + Invoke(new Action(() => + { + ShowOrder(order); + })); + } + }); + } + + void ShowOrder(PddBuyerOrderInfoLite order) + { + if (order == null) + return; + + var row = dgvPddBuyerOrder.Rows.Cast().FirstOrDefault(p => p.Cells.GetCellValueFromColumnName("colOPddOrderSn").ParseToString() == order.order_sn); + if (row == null) + { + var rowIndex = this.dgvPddBuyerOrder.Rows.Add( + false, + order.buyerId, + order.buyerName, + order.order_sn, + order.order_time == null ? "" : BaseClass.StampToDateTime(order.order_time.ParseToInt()).ToString("yy-MM-dd HH:ss"), + "", // 图片路径, + DataGridViewExtension.defaultBitmap, // 订单图片 + order.order_Goods == null ? "" : string.Join("\r\n", order.order_Goods.Select(g => g.goods_name + " x" + g.goods_number)), // 商品信息 + order.order_amount * 0.01, + order.order_status_prompt, + order.outExpressCompanyName, + order.tracking_number, + order.sendStatus, + "发送" + ); + row = dgvPddBuyerOrder.Rows[rowIndex]; + row.Height = 40; + + } + else + { + //row.Cells["colOSelect"].Value = selectIds.Contains(buyer.buyer_id); + row.Cells["colOBuyerId"].Value = order.buyerId; + row.Cells["colOBuyerName"].Value = order.buyerName; + row.Cells["colOPddOrderSn"].Value = order.order_sn; + row.Cells["colOOrderTime"].Value = order.order_time == null ? "" : BaseClass.StampToDateTime(order.order_time.ParseToInt()).ToString("yy-MM-dd HH:ss"); + //row.Cells["colOImgUrl"].Value = ""; + // 商品信息 + row.Cells["colOGoodsInfo"].Value = order.order_Goods == null ? "" : string.Join("\r\n", order.order_Goods.Select(g => g.goods_name + " x" + g.goods_number)); + row.Cells["colOOrderAmount"].Value = order.order_amount * 0.01; + row.Cells["dgvOStatus"].Value = order.order_status_prompt; + row.Cells["colOExpressName"].Value = order.outExpressCompanyName; + row.Cells["colOExpressId"].Value = order.tracking_number; + row.Cells["colOMsg"].Value = order.sendStatus; + } + } + + private void InitCef() + { + cefWebBrowser = CEFBrowser.CreateChromiumWebBrowser("about:blank", false); + CustomResourceRequestHandlerLocal resourceRequestHandler = new CustomResourceRequestHandlerLocal(); + resourceRequestHandler.ResourceLoadCompleteEvent += RequestHandler_ResourceLoadComplete; + resourceRequestHandler.BeforeResourceLoadEvent += RequestHandler_BeforeResourceLoad; + cefWebBrowser.RequestHandler = new CustomRequestHandler(resourceRequestHandler); + var lifeSapnHandler = new LifeSpanHandlerLocal(PopWindowType.SelfWindow); + cefWebBrowser.LifeSpanHandler = lifeSapnHandler; + cefWebBrowser.KeyboardHandler = new KeyboardHandler(); + cefWebBrowser.FrameLoadEnd += CefWebBrowser_FrameLoadEnd; + cefWebBrowser.AddressChanged += CefWebBrowser_AddressChanged; + cefWebBrowser.LoadError += CefWebBrowser_LoadError; + cefWebBrowser.Dock = DockStyle.Fill; + cefWebBrowser.SendToBack(); + splitContainer3.Panel2.Controls.Add(cefWebBrowser); + + //js绑定C#对象 + //PDDShopBrowserObject shopObj = new PDDShopBrowserObject(); + //shopObj.OnInfoReceived += ShopObj_OnInfoReceived; + //CefSharpSettings.WcfEnabled = true; + //cefWebBrowser.JavascriptObjectRepository.Register( + // name: "shopObj", + // objectToBind: shopObj, + // isAsync: false, + // options: new BindingOptions { Binder = BindingOptions.DefaultBinder.Binder /*CamelCaseJavascriptNames = false*/ /*cef79*/ } + //); + } + + private void RequestHandler_ResourceLoadComplete(object sender, string url, string postData, string responseData, IRequest request) + { + if (url.StartsWith("https://mobile.yangkeduo.com/orders.html?type=3&order_index=0")) + { + + } + if (url.StartsWith("https://mobile.yangkeduo.com/orders.html?type=3")) + { + + } + if (url.StartsWith("https://mobile.yangkeduo.com/orders.html?type=2")) + { + + } + if (url.StartsWith("https://mobile.yangkeduo.com/proxy/api/api/aristotle/order_list_v3")) + { + Task.Run(() => + { + CefReadBuyerOrder(url, responseData); + }); + } + //if (url.StartsWith("https://mobile.yangkeduo.com/proxy/api/api/caterham/v3/query/my_order_group") && !string.IsNullOrEmpty(currentReadBuyer)) + // currentReadBuyer = ""; + } + + string currentReadBuyer = ""; + void CefReadBuyerOrder(string url, string data) + { + if (data.Contains("轻奢壁挂式香皂盒置物架卫生间沥水家居可拆卸收纳盒翻盖肥皂盒")) + { + + } + + var buyer = GlobalConfig.BuyerLoginList.FirstOrDefault(b => url.Contains(b.buyer_id)); + if (buyer == null) + return; + + //{"server_time":1775789489,"orders":[],"extra_info":{}} + if (data.Contains("\"orders\":[]")) + { + currentReadBuyer = ""; + return; + } + if (data.Contains("\"error_code\":40001")) + { + currentReadBuyer = ""; + CheckBuyerLogin(new List { buyer }, false); + return; + } + + var list = JsonHelper.DeserializeJsonToList(JsonHelper.JObjectParse(data)["orders"].ParseToString()); + foreach (var o in list) + { + o.buyerId = buyer.buyer_id; + o.buyerName = buyer.buyer_name; + o.outExpressCompanyMsg = o.extra_info.order_hint?.message; // todo 此处转换 + + PddBuyerOrderInfoLite order = null; + if (!this.lstPddBuyerOrderInfoLite.Any(or => or.order_sn == o.order_sn)) + { + order = o; + lstPddBuyerOrderInfoLite.Add(order); + } + else + { + order = this.lstPddBuyerOrderInfoLite.FirstOrDefault(or => or.order_sn == o.order_sn); + if (JsonHelper.SerializeObject(order) != JsonHelper.SerializeObject(o)) + { + //order = JsonHelper.DeserializeJsonToObject(JsonHelper.SerializeObject(o)); + order.activity_type = o.activity_type; + order.discount_amount = o.discount_amount; + order.display_amount = o.display_amount; + order.extra_info = JsonHelper.DeserializeJsonToObject(JsonHelper.SerializeObject(o.extra_info)); + order.order_amount = o.order_amount; + order.order_Goods = JsonHelper.DeserializeJsonToList(JsonHelper.SerializeObject(o.order_Goods)); + order.order_link_url = o.order_link_url; + order.order_prompt_color = o.order_prompt_color; + order.order_status_prompt = o.order_status_prompt; + order.parent_order_sn = o.parent_order_sn; + order.service_amount = o.service_amount; + order.shipping_amount = o.shipping_amount; + order.outExpressCompanyMsg = o.outExpressCompanyMsg; + order.order_time = o.order_time; + order.tracking_number = o.tracking_number; + } + } + + Task.Run(() => + { + //SendOrderE57(order); + }); + + Invoke(new Action(() => + { + ShowOrder(order); + })); + } + NaiBa.Util.Helper.ConfigHelper.SaveConfig("pdd_buyer_order", lstPddBuyerOrderInfoLite); + } + + private bool RequestHandler_BeforeResourceLoad(object sender, string url, string postData, IRequest request) + { + return false; + } + private void CefWebBrowser_FrameLoadEnd(object sender, CefSharp.FrameLoadEndEventArgs e) + { + ////js绑定C#对象 html页面内声明绑定的C#对象 + //StringBuilder sb = new StringBuilder(); + //sb.Append("(function(){"); + //sb.Append("CefSharp.BindObjectAsync('shopObj');"); + //sb.Append("})();"); + //cefWebBrowser.GetBrowser().MainFrame.EvaluateScriptAsync(sb.ToString()); + } + private void CefWebBrowser_AddressChanged(object sender, CefSharp.AddressChangedEventArgs e) + { + if (this.Created && !this.Disposing && !this.IsDisposed) + { + //Invoke(new Action(() => + //{ + // currentUrl = e.Address; + // txtAddress.Text = e.Address; + //})); + } + } + private void CefWebBrowser_LoadError(object sender, CefSharp.LoadErrorEventArgs e) + { + } + void GetBuyer() { var ids = dgvBuyer.Rows.Cast().Where(r => r.Cells["colSelect"].Value.ParseToBool() == true).Select(s => s.Cells["colBuyerId"].Value.ParseToString()).ToList(); @@ -81,8 +311,25 @@ namespace TemuKJD.WXForms.TalkForms if (result.Contains("\"code\":200")) { List loginInfoLst = JsonHelper.DeserializeJsonToList(JsonHelper.JObjectParse(result)["data"].ParseToString()); - GlobalConfig.BuyerLoginList.Clear(); - GlobalConfig.BuyerLoginList.AddRange(loginInfoLst); + GlobalConfig.BuyerLoginList.RemoveAll(bu => !loginInfoLst.Any(b => b.buyer_id == bu.buyer_id)); + foreach (var b in loginInfoLst) + { + var buyer = GlobalConfig.BuyerLoginList.FirstOrDefault(bu => bu.buyer_id == b.buyer_id); + if (buyer == null) + GlobalConfig.BuyerLoginList.Add(b); + else + { + buyer.add_time = b.add_time; + buyer.buyer_id = b.buyer_id; + buyer.buyer_name = b.buyer_name; + buyer.buyer_nick = b.buyer_nick; + buyer.cookie = b.cookie; + buyer.mdy_time = b.mdy_time; + buyer.notes = b.notes; + buyer.status = b.status; + buyer.user_name = b.user_name; + } + } Invoke(new Action(() => { @@ -93,15 +340,7 @@ namespace TemuKJD.WXForms.TalkForms { Invoke(new Action(() => { - var rowIndex = this.dgvBuyer.Rows.Add( - ids.Contains(buyer.buyer_id), - buyer.buyer_id, - buyer.buyer_name, - buyer.buyer_nick, - buyer.notes, - "访问", - buyer.status - ); + BindBuyer(buyer, "", ids); })); } } @@ -113,16 +352,70 @@ namespace TemuKJD.WXForms.TalkForms }); } - void AutoGetOrder() + private void BindBuyer(List buyers, string msg = "", List selectIds = null) + { + foreach (var buyer in buyers) + { + Invoke(new Action(() => + { + BindBuyer(buyer, msg, selectIds); + })); + } + } + + private void BindBuyer(BuyerLoginInfo buyer, string msg = "", List selectIds = null) + { + if (buyer == null) + return; + + if (selectIds == null) + selectIds = dgvBuyer.Rows.Cast().Where(r => r.Cells["colSelect"].Value.ParseToBool() == true).Select(s => s.Cells["colBuyerId"].Value.ParseToString()).ToList(); + + bool canUse = buyer.status == "在线"; + var row = dgvBuyer.Rows.Cast().FirstOrDefault(p => p.Cells.GetCellValueFromColumnName("colBuyerId").ParseToString() == buyer.buyer_id); + if (row == null) + { + var rowIndex = this.dgvBuyer.Rows.Add( + selectIds.Contains(buyer.buyer_id), + buyer.buyer_id, + buyer.buyer_name, + buyer.buyer_nick, + buyer.notes, + "访问", + buyer.status + ); + row = dgvBuyer.Rows[rowIndex]; + } + else + { + row.Cells["colSelect"].Value = selectIds.Contains(buyer.buyer_id); + row.Cells["colBuyerId"].Value = buyer.buyer_id; + row.Cells["dgvBuyerName"].Value = buyer.buyer_name; + row.Cells["dgvBuyerNick"].Value = buyer.buyer_nick; + row.Cells["colShopNotes"].Value = buyer.notes; + row.Cells["colBuyerId"].Value = buyer.buyer_id; + row.Cells["colLoginStatus"].Value = buyer.status; + row.Cells["colMessage"].Value = msg; + } + + (row.Cells["colLoginStatus"] as DataGridViewLinkCell).Style.ForeColor = canUse ? Color.Blue : Color.Red; + (row.Cells["colLoginStatus"] as DataGridViewLinkCell).LinkColor = canUse ? Color.Blue : Color.Red; + (row.Cells["colLoginStatus"] as DataGridViewLinkCell).ActiveLinkColor = canUse ? Color.LightBlue : Color.OrangeRed; + (row.Cells["colLoginStatus"] as DataGridViewLinkCell).VisitedLinkColor = canUse ? Color.DarkBlue : Color.DarkRed; + } + + + void AutoGetPddOrder() { Task.Run(() => - { + { + Thread.Sleep(5000); while (true) { if (DateTime.Now > nextGetOrderTime) { nextGetOrderTime = DateTime.Now.AddMinutes(30); - GetOrder(); + GetPddOrder(); } Thread.Sleep(1000); Invoke(new Action(() => @@ -134,14 +427,89 @@ namespace TemuKJD.WXForms.TalkForms }); } - void GetOrder() + void GetPddOrder() { + if (cancellationTokenSource != null) + cancellationTokenSource.Cancel(); cancellationTokenSource = new CancellationTokenSource(); Task.Run(() => { - foreach (var shop in GlobalConfig.ShopLoginList) - { + currentReadBuyer = ""; + foreach (var buyer in GlobalConfig.BuyerLoginList) + { + if (cancellationTokenSource.IsCancellationRequested) + break; + + if (buyer.status != "在线") + continue; + + try + { + if (cefWebBrowser == null) + { + Invoke(new Action(() => + { + InitCef(); + })); + while (!cefWebBrowser.IsBrowserInitialized || !cefWebBrowser.GetBrowser().MainFrame.IsValid) + { + Thread.Sleep(1); + } + } + + CEFBrowser.DeleteCookie(cefWebBrowser.GetCookieManager(null)); + + var cookieLst = JsonHelper.DeserializeJsonToList(buyer?.cookie); + var t = CEFBrowser.SetCookieAsync(JsonHelper.SerializeObject(cookieLst), cefWebBrowser.GetCookieManager(null)); + + string readBuyer = buyer.buyer_id; + currentReadBuyer = buyer.buyer_id; + cefWebBrowser.Load("https://mobile.yangkeduo.com/orders.html?type=2"); + Thread.Sleep(Randomx.GetId(2000, 3000)); + + while (currentReadBuyer == readBuyer) + { + if (cancellationTokenSource.IsCancellationRequested) + break; + + Thread.Sleep(Randomx.GetId(100,300)); + + var jsStr = @"window.scroll({ + top: document.body.scrollHeight, + left: 0, + behavior: 'smooth' // 可选,使滚动平滑 + });"; + var t1 = cefWebBrowser.GetMainFrame().EvaluateScriptAsync(jsStr); + t1.Wait(1000); + } + Thread.Sleep(Randomx.GetId(2000, 3000)); + + readBuyer = buyer.buyer_id; + currentReadBuyer = buyer.buyer_id; + cefWebBrowser.Load("https://mobile.yangkeduo.com/orders.html?type=3"); + Thread.Sleep(Randomx.GetId(2000, 3000)); + + while (currentReadBuyer == readBuyer) + { + if (cancellationTokenSource.IsCancellationRequested) + break; + + Thread.Sleep(Randomx.GetId(100, 300)); + + var jsStr = @"window.scroll({ + top: document.body.scrollHeight, + left: 0, + behavior: 'smooth' // 可选,使滚动平滑 + });"; + var t1 = cefWebBrowser.GetMainFrame().EvaluateScriptAsync(jsStr); + t1.Wait(1000); + } + } + catch + { + } + Thread.Sleep(Randomx.GetId(6000, 8000)); } }, cancellationTokenSource.Token); } @@ -149,7 +517,7 @@ namespace TemuKJD.WXForms.TalkForms private void btnSearch_Click(object sender, EventArgs e) { nextGetOrderTime = DateTime.Now.AddMinutes(30); - GetOrder(); + GetPddOrder(); } private void pnlEmpty_Click(object sender, EventArgs e) @@ -161,7 +529,7 @@ namespace TemuKJD.WXForms.TalkForms { if (e.ColumnIndex < 0 || e.RowIndex < 0) return; - string headerText = dgvDbProduct.Columns[e.ColumnIndex].HeaderText; + string headerText = dgvWxOrder.Columns[e.ColumnIndex].HeaderText; //var dbId = dgvDbProduct.Rows[e.RowIndex].Cells["col_db_id"].Value.ParseToString(); //var dbProduct = lstTemuDbProduct.FirstOrDefault(p => p.id.ToString() == dbId); @@ -187,23 +555,20 @@ namespace TemuKJD.WXForms.TalkForms //dgvDbProduct.Rows[e.RowIndex].Cells["colSkuReplaceImgUrl"].Value = dbProduct.sku_img_replace_url; break; case "主图": - ShowImgForm imgFrom = new ShowImgForm(dgvDbProduct.Rows[e.RowIndex].Cells["colImgUrl"].Value.ParseToString().Replace("?imageView2/2/w/90/h/90", "")); + ShowImgForm imgFrom = new ShowImgForm(dgvWxOrder.Rows[e.RowIndex].Cells["colImgUrl"].Value.ParseToString().Replace("?imageView2/2/w/90/h/90", "")); imgFrom.ShowDialog(); break; case "": - dgvDbProduct.Rows[e.RowIndex].Cells["colCheck"].Value = !(bool)dgvDbProduct.Rows[e.RowIndex].Cells["colCheck"].Value; + dgvWxOrder.Rows[e.RowIndex].Cells["colCheck"].Value = !(bool)dgvWxOrder.Rows[e.RowIndex].Cells["colCheck"].Value; break; default: break; } } - private void dgvDbProduct_Scroll(object sender, ScrollEventArgs e) - { - } - private void btnStopStop_Click(object sender, EventArgs e) { + currentReadBuyer = ""; if (cancellationTokenSource != null) cancellationTokenSource.Cancel(); Task.Run(() => @@ -320,7 +685,7 @@ namespace TemuKJD.WXForms.TalkForms // 先从服务端取最新cookie var url = BaseClass.BuildPDDObjString("user/get_buyer"); var data = UserLogin.GetSignaturex(); - data += "&buyer_id=" + buyer.buyer_id; + data += "&buyer_ids=" + buyer.buyer_id; data += "&page_size=1"; var result = GetHtml.PostUtf8(url, data); if (string.IsNullOrEmpty(result) || !result.Contains("\"code\":200")) @@ -342,7 +707,7 @@ namespace TemuKJD.WXForms.TalkForms if (buyer != null) { var loginResult = CheckBuyerLogin(buyer); - if (loginResult.Contains("\"success\":true") && !loginResult.Contains("\"login\":true")) + if (!loginResult.Contains("\"success\":true") && !loginResult.Contains("\"login\":true") && !loginResult.Contains("\"nickname\"")) { buyer.cookie = "[]"; foreach (var buy in buys) @@ -367,6 +732,7 @@ namespace TemuKJD.WXForms.TalkForms this.statusBar.lblTaskStatus.Text = "正在检测..."; this.statusBar.pgbTaskProgress.Value = (i + 1); this.statusBar.pgbTaskProgress.Text = (i + 1) + "/" + checkBuyers.Count; + BindBuyer(buyer); })); } } @@ -402,7 +768,6 @@ namespace TemuKJD.WXForms.TalkForms var buyers = GlobalConfig.BuyerLoginList.Where(b => ids.Contains(b.buyer_id)).ToList(); Task.Run(() => { CheckBuyerLogin(buyers); - GetBuyer(); }); } @@ -445,6 +810,114 @@ namespace TemuKJD.WXForms.TalkForms GetBuyer(); }); } + + private void dgvPddBuyerOrder_CellContentClick(object sender, DataGridViewCellEventArgs e) + { + if (e.ColumnIndex < 0 || e.RowIndex < 0) + return; + string headerText = dgvPddBuyerOrder.Columns[e.ColumnIndex].HeaderText; + var orderSn = dgvPddBuyerOrder.Rows[e.RowIndex].Cells["colOPddOrderSn"].Value.ParseToString(); + var order = lstPddBuyerOrderInfoLite.FirstOrDefault(p => p.order_sn == orderSn); + + + switch (headerText) + { + case "详情": + case "编辑/详情": + break; + case "发送": + SendOrderE57(order); + break; + case "图片": + ShowImgForm imgFrom = new ShowImgForm(dgvPddBuyerOrder.Rows[e.RowIndex].Cells["colImgUrl"].Value.ParseToString().Replace("?imageView2/2/w/90/h/90", "")); + imgFrom.ShowDialog(); + break; + case "": + case "全选": + dgvPddBuyerOrder.Rows[e.RowIndex].Cells["colCheck"].Value = !(bool)dgvPddBuyerOrder.Rows[e.RowIndex].Cells["colCheck"].Value; + break; + default: + break; + } + } + + public void SendOrderE57(PddBuyerOrderInfoLite order) + { + if (order.sendStatus == "已发送") + { + return; + } + // 已发货且没有运单号的属于已退货,不再发送 + if (order.order_status_prompt != "拼单成功,待发货" && string.IsNullOrEmpty(order.tracking_number)) + { + order.sendStatus = "已发货无运单号"; + Invoke(new Action(() => + { + ShowOrder(order); + })); + NaiBa.Util.Helper.ConfigHelper.SaveConfig("pdd_buyer_order", lstPddBuyerOrderInfoLite); + return; + } + + JObject obj = new JObject(); + obj["platform"] = "WEISHOP"; + obj["outAmount"] = order.order_amount; + obj["outAccount"] = order.buyerName; + obj["outOrderNo"] = order.order_sn; + obj["outExpressCompany"] = order.outExpressCompanyCode; + obj["outExpressNo"] = order.tracking_number; + var dataStr = JsonHelper.SerializeObject(obj); + string url = "https://po.e57.cn/prod-api/api/oms-api/external_procurement/bind"; + //成功 "0SUCCESS" + //失败 已存在 + //1505调用微信接口更新物流信息失败: 非法参数, 同运单号拦截 rid: 69d8ab9c-22baa3b1-67de0d95 + var exportRst = WXHttpResponseBLL.e57PostResponse(url, dataStr, ""); + if(exportRst.Contains("SUCCESS") || exportRst.Contains("已存在") || exportRst.Contains("同运单号拦截")) + { + order.sendStatus = "已发送"; + NaiBa.Util.Helper.ConfigHelper.SaveConfig("pdd_buyer_order", lstPddBuyerOrderInfoLite); + } + else if (exportRst != null && exportRst.Contains("") && exportRst.Contains("")) + { + order.sendStatus = exportRst.Substring(exportRst.IndexOf("") + 5).Substring(0, exportRst.IndexOf("")); + NaiBa.Util.Helper.ConfigHelper.SaveConfig("pdd_buyer_order", lstPddBuyerOrderInfoLite); + } + else + { + order.sendStatus = "发送失败 " + exportRst; + NaiBa.Util.Helper.ConfigHelper.SaveConfig("pdd_buyer_order", lstPddBuyerOrderInfoLite); + } + Invoke(new Action(() => + { + ShowOrder(order); + })); + //Thread.Sleep(500); + } + + private void panelEx3_Click(object sender, EventArgs e) + { + dgvPddBuyerOrder.Visible = !dgvPddBuyerOrder.Visible; + if (dgvPddBuyerOrder.Visible == false) + panelEx3.Text = "打开"; + else + panelEx3.Text = "折叠"; + } + + private void panelEx1_Click(object sender, EventArgs e) + { + if (dgvPddBuyerOrder.Height < dgvPddBuyerOrder.Parent.Height) + dgvPddBuyerOrder.Height += 50; + if (dgvPddBuyerOrder.Height > dgvPddBuyerOrder.Parent.Height) + dgvPddBuyerOrder.Height = dgvPddBuyerOrder.Parent.Height; + } + + private void panelEx2_Click(object sender, EventArgs e) + { + if (dgvPddBuyerOrder.Height > 100) + dgvPddBuyerOrder.Height -= 100; + if (dgvPddBuyerOrder.Height < 100) + dgvPddBuyerOrder.Height = 100; + } } public class YkdBuyerOrder diff --git a/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.resx b/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.resx index 53e7e5c..28ed96d 100644 --- a/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.resx +++ b/TEMUKJD/WXForms/TalkForms/BuyerOrderListForm.resx @@ -174,6 +174,48 @@ True + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + + + True + diff --git a/TEMUKJD/WXForms/TalkForms/WxTalkForm.cs b/TEMUKJD/WXForms/TalkForms/WxTalkForm.cs index 1c15871..6882f1f 100644 --- a/TEMUKJD/WXForms/TalkForms/WxTalkForm.cs +++ b/TEMUKJD/WXForms/TalkForms/WxTalkForm.cs @@ -98,6 +98,16 @@ namespace TemuKJD.WXForms.TalkForms private void WxTalkForm_Load(object sender, EventArgs e) { + this.ucTabControl1.SelectedIndex = 2; + Task.Run(() => + { + Thread.Sleep(2000); + Invoke(new Action(() => + { + this.ucTabControl1.SelectedIndex = 0; + })); + }); + if (BaseClass.LogoImage != null) pbLogo.Image = BaseClass.LogoImage; if (BaseClass.Ico != null)