用户列表页面完成 订单列表页面开始 10%

This commit is contained in:
wule committed 2026-06-19 16:56:02 +08:00
1 parent 25cdf642bf
commit edc7913637
52 files changed
+2032 -365

No files matched your search

@@ -215,7 +215,7 @@ namespace _29WxOrder.FactoryExportForms
public void UpdateOrderStatusAndEncrypt(string orderId)
{
DouYinOrderModel douYinOrderModel = this.lstDouYinOrder.Find(x => x.order_id == orderId);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == douYinOrderModel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == douYinOrderModel.shop_id.ToString());
if (douYinOrderModel != null && shop != null)
{
DouyinApi dyapi = new DouyinApi(shop);
+69 -61
View File
@@ -41,6 +41,7 @@ using Work.Api;
using Work.BaseForms;
using Work.BuyUsers;
using _29WxOrder.MyControl;
using Work.BLL;
namespace _29WxOrder
{
@@ -352,7 +353,7 @@ namespace _29WxOrder
{
Task.Run(() =>
{
GetServerDouShop();
GetServerShop();
});
}
private void readBuyOrder(object sender, EventArgs e)
@@ -1642,7 +1643,7 @@ namespace _29WxOrder
DouOrderListInfo.Shop_order_listItem orderListItem = new DouOrderListInfo.Shop_order_listItem();
orderListItem.order_id = jOrderObj["shop_order_id"].ToString();
orderListItem.shop_id = shop.ShopId.ParseToInt();
orderListItem.shop_name = shop.ShopName;
orderListItem.shop_name = shop.ShopAccount;
orderListItem.post_tel = jOrderObj["receiver_info"]["post_tel"].ToString();
orderListItem.productName = jOrderObj["product_item"][0]["product_name"].ToString();
orderListItem.post_receiver = jOrderObj["receiver_info"]["post_receiver"].ToString();
@@ -1816,7 +1817,7 @@ namespace _29WxOrder
foreach (DouYinOrderModel getOrderShop in onelist)
{
if (BaseClass.is_read_commission == 1) { break; }
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == getOrderShop.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == getOrderShop.shop_id.ToString());
if (shop != null && !string.IsNullOrEmpty(shop.Cookies))
{
var td = CEFBrowser.DeleteCookieAsync(cefJuLiangWebBrowser.RequestContext.GetCookieManager(null));
@@ -2211,7 +2212,7 @@ namespace _29WxOrder
DouyinApi apix = new DouyinApi(shop);
apix.JsonData = dic;
BaseClass.ShopId = shop.ShopId;
BaseClass.ShopName = shop.ShopName;
BaseClass.ShopName = shop.ShopAccount;
string html = apix.GetOrderList();
for (int i = 0; i < 5 && html.Contains("系统繁忙,请稍后重试"); i++)
@@ -2413,7 +2414,7 @@ namespace _29WxOrder
#region 店铺
bool readshop = false;
public List<ShopLoginInfo> GetServerDouShop()
public List<ShopLoginInfo> GetServerShop()
{
List<ShopLoginInfo> list = new List<ShopLoginInfo>();
if (readshop == false)
@@ -2431,64 +2432,68 @@ namespace _29WxOrder
while (true)
{
page++;
var url = BaseClass.Build29WxObjString("shop&act=get_shop_list");
//var url = BaseClass.BuildObjString("shop&act=get_shop_list");
var url = BaseClass.Build29WxObjString("shop/get_shop_list");
var data = UserLogin.GetSignaturex() + "&page=" + page;
var html = GetHtml.PostUtf8(url, data);
while (string.IsNullOrEmpty(html))
{
Thread.Sleep(1000);
if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200"))
html = GetHtml.PostUtf8(url, data);
}
if (string.IsNullOrEmpty(html) || !html.Contains("shop_name") || !html.Contains("shop_id") || !html.Contains("name") || !html.Contains("password"))
if (string.IsNullOrEmpty(html) || !html.Contains("\"code\":200"))
html = GetHtml.PostUtf8(url, data);
if (string.IsNullOrEmpty(html)
|| !html.Contains("shop_id") || !html.Contains("shop_account") || !html.Contains("login_pass"))
{
break;
}
var jArr = JObject.Parse(html)["data"]["list"];
var jArr = JObject.Parse(html)["data"];
if (jArr.Count() == 0)
break;
foreach (JObject jObj in jArr)
{
string shopStr = jObj.ToString();
ShopLoginInfo shop = new ShopLoginInfo();
shop.DbId = BaseRegex.GetStringJson(ref shopStr, "id");
if (shop.DbId == null)
continue;
shop.UserName = BaseRegex.GetStringJson(ref shopStr, "name");
shop.ShopName = BaseRegex.GetStringJson(ref shopStr, "shop_name");
shop.ApiAuthStatus = "读取中...";
shop.LoginStatus = "读取中...";
shop.Password = BaseRegex.GetStringJson(ref shopStr, "password");
shop.ShopId = BaseRegex.GetStringJson(ref shopStr, "shop_id");
//string shopStr = jObj.ToString();
//ShopLoginInfo shop = new ShopLoginInfo();
//shop.DbId = BaseRegex.GetStringJson(ref shopStr, "id");
//if (shop.DbId == null)
// continue;
//shop.LoginName = BaseRegex.GetStringJson(ref shopStr, "login_name");
//shop.ShopAccount = BaseRegex.GetStringJson(ref shopStr, "shop_name");
//shop.ApiAuthStatus = "读取中...";
//shop.LoginStatus = "读取中...";
//shop.Password = BaseRegex.GetStringJson(ref shopStr, "password");
//shop.ShopId = BaseRegex.GetStringJson(ref shopStr, "shop_id");
url = BaseClass.Build29WxObjString("shop&act=get_shop_token");
data = UserLogin.GetSignaturex() + "&shop_id=" + shop.ShopId;
//url = BaseClass.Build29WxObjString("shop&act=get_shop_token");
//data = UserLogin.GetSignaturex() + "&shop_id=" + shop.ShopId;
string htmltoken = GetHtml.PostUtf8(url, data, "", 5);
for (int i = 0; i < 10 && (string.IsNullOrEmpty(htmltoken) || htmltoken.Replace(" ", "").Contains("\"code\":400")); i++)
{
Thread.Sleep(100);
htmltoken = GetHtml.PostUtf8(url, data, "", 5);
}
var jArrs = JObject.Parse(htmltoken)["data"];
foreach (JObject jObjs in jArrs)
{
string tokens = jObjs.ToString();
string token = BaseRegex.GetStringJson(ref tokens, "access_token");
string app_key = BaseRegex.GetStringJson(ref tokens, "app_key");
string expires_in = BaseRegex.GetStringJson(ref tokens, "expires_in");
if (app_key == "7016502755254683171")
{
shop.AccessToken = token;
shop.TokenExpiresTime = Convert.ToDateTime(expires_in);
}
}
//string htmltoken = GetHtml.PostUtf8(url, data, "", 5);
//for (int i = 0; i < 10 && (string.IsNullOrEmpty(htmltoken) || htmltoken.Replace(" ", "").Contains("\"code\":400")); i++)
//{
// Thread.Sleep(100);
// htmltoken = GetHtml.PostUtf8(url, data, "", 5);
//}
//var jArrs = JObject.Parse(htmltoken)["data"];
//foreach (JObject jObjs in jArrs)
//{
// string tokens = jObjs.ToString();
// string token = BaseRegex.GetStringJson(ref tokens, "access_token");
// string app_key = BaseRegex.GetStringJson(ref tokens, "app_key");
// string expires_in = BaseRegex.GetStringJson(ref tokens, "expires_in");
// if (app_key == "7016502755254683171")
// {
// shop.AccessToken = token;
// shop.TokenExpiresTime = Convert.ToDateTime(expires_in);
// }
//}
shop.Group = BaseRegex.GetStringJson(ref shopStr, "cat_name");
shop.BuyAccount = BaseRegex.GetStringJson(ref shopStr, "buy_user_name");
shop.UploadAccount = BaseRegex.GetStringJson(ref shopStr, "upload_user_name");
if (list.Any(l => l.UserName == shop.UserName) || list.Any(l => l.ShopName == shop.ShopName))
//shop.GroupName = BaseRegex.GetStringJson(ref shopStr, "cat_name");
//shop.BuyAccount = BaseRegex.GetStringJson(ref shopStr, "buy_user_name");
//shop.UploadAccount = BaseRegex.GetStringJson(ref shopStr, "upload_user_name");
var shop = ShopBLL.DeserializationShop(jObj);
if (list.Any(l => l.ShopId == shop.ShopId))
continue;
list.Add(shop);
@@ -2509,7 +2514,7 @@ namespace _29WxOrder
string shopNames = "";
foreach (var shop in list)
{
shopNames += shop.ShopName + ",";
shopNames += shop.ShopAccount + ",";
}
var cookies = GetServerShopCookies(shopNames);
@@ -2520,9 +2525,9 @@ namespace _29WxOrder
{
for (int j = 0; data != null && j < data.Count(); j++)
{
if (data[j][shop.ShopName] != null)
if (data[j][shop.ShopAccount] != null)
{
shop.Cookies = data[j][shop.ShopName].ToString().Replace("&", "&").Replace("%", "%").Replace("+", "+");
shop.Cookies = data[j][shop.ShopAccount].ToString().Replace("&", "&").Replace("%", "%").Replace("+", "+");
break;
}
}
@@ -2581,7 +2586,10 @@ namespace _29WxOrder
}
#endregion
}
GlobalConfig.ShopLoginList = list;
foreach (var shop in list)
{
GlobalConfig.ShopLoginList.Add(shop);
}
CheckShopLogin(list);
readshop = false;
@@ -2597,11 +2605,11 @@ namespace _29WxOrder
{
var row = this.dgvShop.Rows.Cast<DataGridViewRow>().FirstOrDefault(r => r.Cells["colShopId"].Value?.ToString() == shop.ShopId);
if (row == null)
dgvShop.Rows.Add(true, shop.ShopId, shop.UserName, shop.ShopName, shop.ApiAuthStatus, shop.LoginStatus);
dgvShop.Rows.Add(true, shop.ShopId, shop.LoginName, shop.ShopAccount, shop.ApiAuthStatus, shop.LoginStatus);
else
{
row.Cells["colShopAccount"].Value = shop.UserName;
row.Cells["colShopName"].Value = shop.ShopName;
row.Cells["colShopAccount"].Value = shop.LoginName;
row.Cells["colShopName"].Value = shop.ShopAccount;
row.Cells["colAuthStatus"].Value = shop.ApiAuthStatus;
row.Cells["colLoginStatus"].Value = shop.LoginStatus;
}
@@ -2636,7 +2644,7 @@ namespace _29WxOrder
var data = UserLogin.GetSignaturex() + "&timestamp=" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "&shop_id=" + doushop.ShopId;
var result = GetHtml.PostUtf8(url, data);
var shop = GlobalConfig.ShopLoginList.FirstOrDefault(v => v.ShopName == doushop.ShopName);
var shop = GlobalConfig.ShopLoginList.FirstOrDefault(v => v.ShopAccount == doushop.ShopAccount);
if (shop != null)
{
var loginResult = GetShopStatus(shop);
@@ -2654,7 +2662,7 @@ namespace _29WxOrder
shop.ExpiresTime = Convert.ToDateTime(expires_in);
}
if (!string.IsNullOrEmpty(shopToken)) shop.ShopToken = shopToken;
if (!string.IsNullOrEmpty(shopName)) shop.ShopName = shopName;
if (!string.IsNullOrEmpty(shopName)) shop.ShopAccount = shopName;
if (!string.IsNullOrEmpty(mobile)) shop.Mobile = mobile;
}
else if (loginResult.Contains("未登录"))
@@ -3055,7 +3063,7 @@ namespace _29WxOrder
/// <param name="shopid">店铺ID</param>
public void chaqi(string orderid, int color, string shopid)
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
if (shop != null)
{
DouyinApi apix = new DouyinApi(shop);
@@ -3238,7 +3246,7 @@ namespace _29WxOrder
if (text == "店铺账号")
{
string shopname = dgvShop.Rows[e.RowIndex].Cells[e.ColumnIndex].Value.ToString();
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.UserName == shopname);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.LoginName == shopname);
ShopBrower shopBrower = new ShopBrower();
shopBrower.TitleText = "店铺后台";
shopBrower.shop = shop;
@@ -3738,7 +3746,7 @@ namespace _29WxOrder
DouyinApi apix = new DouyinApi(shop);
apix.JsonData = dic;
BaseClass.ShopId = shop.ShopId;
BaseClass.ShopName = shop.ShopName;
BaseClass.ShopName = shop.ShopAccount;
string html = apix.GetOrderList();
for (int i = 0; i < 5 && html.Contains("系统繁忙,请稍后重试"); i++)
@@ -3823,7 +3831,7 @@ namespace _29WxOrder
{
foreach (ShopLoginInfo shop in GlobalConfig.ShopLoginList)
{
if (shop.ShopName == "开箱小店")
if (shop.ShopAccount == "开箱小店")
{
DouyinApi api = new DouyinApi(shop);
api.CreateOrder();
@@ -111,7 +111,7 @@ namespace _29WxOrder.OrderForms
isread = true;
foreach (var shop in GlobalConfig.ShopLoginList)
{
Invoke(new Action(() => { this.mainform.lblMsg.Text = "正在读取售后:" + shop.ShopName; }));
Invoke(new Action(() => { this.mainform.lblMsg.Text = "正在读取售后:" + shop.ShopAccount; }));
int size = 10;
int page = 0;
if (shop.ApiAuthStatus != "授权成功")
@@ -490,7 +490,7 @@ namespace _29WxOrder.OrderForms
{
int rowId = DgvSaleOrderList.Rows.Add(
/*"售后单号"*/ afterSale.aftersale_info.aftersale_id,
/*"店铺名称"*/ shop.ShopName,
/*"店铺名称"*/ shop.ShopAccount,
/*"店铺编号"*/ shop.ShopId,
/*"上家ID"*/ up_product_id,
/*"本店ID"*/ item.product_id,
@@ -605,7 +605,7 @@ namespace _29WxOrder.OrderForms
string name = DgvSaleOrderList.Columns[e.ColumnIndex].HeaderText;
if (name == "售后订单编号")
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
ShopBrower shopBrower = new ShopBrower();
shopBrower.TitleText = "店铺后台-售后";
shopBrower.shop = shop;
@@ -615,7 +615,7 @@ namespace _29WxOrder.OrderForms
}
else if (name == "订单号")
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
if (shop != null)
{
ShopForms.ShopBrower shopBrower = new ShopForms.ShopBrower();
@@ -753,7 +753,7 @@ namespace _29WxOrder.OrderForms
{
IEnumerable<DataGridViewRow> enumerableList = this.DgvSaleOrderList.Rows.Cast<DataGridViewRow>();
List<DataGridViewRow> list = (from item in enumerableList where item.Cells["col_order_id"].Value.ToString() == orderid select item).ToList();
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == DgvSaleOrderList.Rows[mouseEvent.RowIndex].Cells["shopId"].Value.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == DgvSaleOrderList.Rows[mouseEvent.RowIndex].Cells["shopId"].Value.ToString());
if (shop != null)
{
DouyinApi dyapi = new DouyinApi(shop);
@@ -898,7 +898,7 @@ namespace _29WxOrder.OrderForms
}
var shopid = DgvSaleOrderList.Rows[mouseEvent.RowIndex].Cells["shopId"].Value.ToString();
string aftersale_id = DgvSaleOrderList.Rows[mouseEvent.RowIndex].Cells["col_aftersale_id"].Value.ToString();
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
ShopBrower shopBrower = new ShopBrower();
shopBrower.TitleText = "店铺后台-售后";
shopBrower.shop = shop;
@@ -82,7 +82,7 @@ namespace _29WxOrder.OrderForms
{
if (lstProvince.Count == 0)
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == _shopId);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == _shopId);
DouyinApi api = new DouyinApi(shop);
var address = api.GetAddressProvince();
//{"code":10000,"data":[{"province":"安徽省","province_id":34},{"province":"澳门特别行政区","province_id":82},{"province":"北京市","province_id":11},{"province":"重庆市","province_id":50},{"province":"福建省","province_id":35},{"province":"广东省","province_id":44},{"province":"甘肃省","province_id":62},{"province":"广西壮族自治区","province_id":45},{"province":"贵州省","province_id":52},{"province":"河北省","province_id":13},{"province":"湖北省","province_id":42},{"province":"黑龙江省","province_id":23},{"province":"河南省","province_id":41},{"province":"湖南省","province_id":43},{"province":"海南省","province_id":46},{"province":"吉林省","province_id":22},{"province":"江苏省","province_id":32},{"province":"江西省","province_id":36},{"province":"辽宁省","province_id":21},{"province":"内蒙古自治区","province_id":15},{"province":"宁夏回族自治区","province_id":64},{"province":"青海省","province_id":63},{"province":"四川省","province_id":51},{"province":"山东省","province_id":37},{"province":"上海市","province_id":31},{"province":"山西省","province_id":14},{"province":"陕西省","province_id":61},{"province":"天津市","province_id":12},{"province":"台湾省","province_id":71},{"province":"香港特别行政区","province_id":81},{"province":"新疆维吾尔自治区","province_id":65},{"province":"西藏自治区","province_id":54},{"province":"云南省","province_id":53},{"province":"浙江省","province_id":33}],"err_no":0,"log_id":"20220715142943010208016085061166AE","message":"success","msg":"success","sub_code":"","sub_msg":""}
@@ -265,7 +265,7 @@ namespace _29WxOrder.OrderForms
var prov = lstArea.FirstOrDefault(a => a.code.ToString() == item.Name);
if (prov == null)
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == _shopId);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == _shopId);
DouyinApi api = new DouyinApi(shop);
var area = api.GetAreasByProvince(item.Name.ToString());
if (area.Contains("\"message\":\"success\"") || area.Contains("\"code\":10000"))
@@ -346,7 +346,7 @@ namespace _29WxOrder.OrderForms
private void btnAcceptReturnRefund_Click(object sender, EventArgs e)
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == _shopId);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == _shopId);
var type = "101";
+1 -1
View File
@@ -254,7 +254,7 @@ namespace _29WxOrder.OrderForms
#region 更新订单
shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == orderDetail.shop_id.ToString());
shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == orderDetail.shop_id.ToString());
this.buyOrderListForm.UpdateOrderStatusAndEncrypt(orderDetail);
#endregion
+7 -7
View File
@@ -78,7 +78,7 @@ namespace _29WxOrder.OrderForms
for (int i = 0; i < CollectionClass.orderDataList.Count; i++)
{
DouYinOrderModel dymodel = CollectionClass.orderDataList[i];
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == dymodel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == dymodel.shop_id.ToString());
if (BaseClass.isUseSimGetRealAddress && (dymodel.name.Contains("解密失败") || dymodel.mobile.Contains("#1##") || dymodel.mobile == "******"))
{
isdecryption = false;
@@ -1003,7 +1003,7 @@ namespace _29WxOrder.OrderForms
/// </summary>
public void UpdateOrderStatusAndEncrypt(DouYinOrderModel douYinOrderModel, UpdateOrderType updateOrderType = UpdateOrderType.UpdateAll)
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == douYinOrderModel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == douYinOrderModel.shop_id.ToString());
if (douYinOrderModel != null)
{
if (shop != null)
@@ -1342,9 +1342,9 @@ namespace _29WxOrder.OrderForms
string districtId = "";
BuyOrderForms.MatchAddress(ref address, ref province, ref provinceId, ref city, ref cityId, ref district, ref districtId);
var shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
var shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
string data = @"{""order_id"":""" + orderid +
@""",""shop_name"":""" + GetHtml.UrlEncodeUtf8(shop.ShopName) +
@""",""shop_name"":""" + GetHtml.UrlEncodeUtf8(shop.ShopAccount) +
@""",""up_goods_id"":""" + upproductid.Replace("pdd-", "").Replace("pd-", "") +
@""",""pay_name"":""" + GetHtml.UrlEncodeUtf8(orderDetail.name) +
@""",""pay_phone"":""" + orderDetail.mobile +
@@ -1404,7 +1404,7 @@ namespace _29WxOrder.OrderForms
}
else if (name == "订单号")
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
if (shop != null)
{
ShopForms.ShopBrower shopBrower = new ShopForms.ShopBrower();
@@ -1419,7 +1419,7 @@ namespace _29WxOrder.OrderForms
string GetOrderStatusl(string orderid)
{
DouYinOrderModel douYinOrderModel = CollectionClass.orderDataList.Find(x => x.order_id == orderid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == douYinOrderModel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == douYinOrderModel.shop_id.ToString());
if (douYinOrderModel != null)
{
if (shop != null)
@@ -1442,7 +1442,7 @@ namespace _29WxOrder.OrderForms
var msg = BaseRegex.GetStringJson(ref htmljm, "sub_msg");
if (!string.IsNullOrEmpty(msg))
{
BaseMsgForm.ShowError(msg.Replace("access_token已过期", "店铺 " + shop.ShopName + " 授权已过期,请重新授权"));
BaseMsgForm.ShowError(msg.Replace("access_token已过期", "店铺 " + shop.ShopAccount + " 授权已过期,请重新授权"));
}
}
}
+1 -1
View File
@@ -191,7 +191,7 @@ namespace _29WxOrder.OrderForms
sb.Append("&remark=" + tbremark.Text);
sb.Append("&is_update_order=0"); // 1修改状态0不修改状态
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == orderDetail.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == orderDetail.shop_id.ToString());
if (shop != null)
{
orderDetail.remark = tbremark.Text.ToString();
+1 -1
View File
@@ -45,7 +45,7 @@ namespace _29WxOrder.OrderForms
return;
}
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == douYinOrderModel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == douYinOrderModel.shop_id.ToString());
if (shop != null)
{
douYinOrderModel.remark = tbremark.Text.ToString();
+2 -2
View File
@@ -465,7 +465,7 @@ namespace _29WxOrder.OrderForms
#region 更新订单
DouYinOrderModel douYinOrderModel = CollectionClass.orderSenderDataList.Find(x => x.order_id == orderid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == douYinOrderModel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == douYinOrderModel.shop_id.ToString());
if (douYinOrderModel != null)
{
if (shop != null)
@@ -809,7 +809,7 @@ namespace _29WxOrder.OrderForms
{
string orderid = DgvSendOrderList.Rows[e.RowIndex].Cells["col_order_id"].Value.ToString();
string shopid = DgvSendOrderList.Rows[e.RowIndex].Cells["col_shop_id"].Value.ToString();
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
if (shop != null)
{
ShopForms.ShopBrower shopBrower = new ShopForms.ShopBrower();
+3 -3
View File
@@ -92,7 +92,7 @@ namespace _29WxOrder.OrderForms
CollectionClass.successOrderDataList.Add(douYinOrderModel);
orderList.Add(douYinOrderModel);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == douYinOrderModel.shop_id.ToString());
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == douYinOrderModel.shop_id.ToString());
if (shop != null && douYinOrderModel.order_status != 4) // 订单状态不为4的放入列表,后面按时间段查询更新订单。
{
if (!shopList.Contains(shop))
@@ -302,7 +302,7 @@ namespace _29WxOrder.OrderForms
DouyinApi apix = new DouyinApi(shop);
apix.JsonData = dic;
BaseClass.ShopId = shop.ShopId;
BaseClass.ShopName = shop.ShopName;
BaseClass.ShopName = shop.ShopAccount;
string html = apix.GetOrderList();
for (int i = 0; i < 5 && html.Contains("系统繁忙,请稍后重试"); i++)
@@ -653,7 +653,7 @@ namespace _29WxOrder.OrderForms
}
else if (name == "订单号")
{
ShopLoginInfo shop = GlobalConfig.ShopLoginList.Find(x => x.ShopId == shopid);
ShopLoginInfo shop = GlobalConfig.ShopLoginList.FirstOrDefault(x => x.ShopId == shopid);
if (shop != null)
{
ShopForms.ShopBrower shopBrower = new ShopForms.ShopBrower();