shanji 3 years ago
parent
commit
a3ed2870b8
  1. 4
      BBWY.Client/App.xaml.cs
  2. 1
      BBWY.Client/ViewModels/MainViewModel.cs
  3. 2
      BBWY.Server.Business/MDSBusiness.cs
  4. 8
      BBWY.Server.Business/Order/OrderBusiness.cs
  5. 6
      BBWY.Server.Business/PurchaseOrder/PurchaseOrderBusiness.cs
  6. 2
      BBWY.Server.Business/Vender/VenderBusiness.cs
  7. 2
      BBWY.Server.Model/Dto/Response/Vender/ShopResponse.cs

4
BBWY.Client/App.xaml.cs

@ -30,11 +30,11 @@ namespace BBWY.Client
var gl = new GlobalContext();
string userToken = string.Empty;
#if DEBUG
//userToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNDM5OTA3NDY1MDMzNDIwODAwIiwidGVhbUlkIjoiMTQzNjI4ODUwMDIzNTI0MzUyMCIsImV4cCI6MTY4MjU3NzUzNn0.76Ll9syp3R21VD01NxpHmcs7TyBKzqeob3i5avpLv-E"; //齐越小一
userToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNDA1MTUxNjE5NTk0NTg4MTYwIiwidGVhbUlkIjoiMTQxMDk1NTYwNDYxMjA5MTkwNCIsImV4cCI6MTY4NjQ4MjU0M30.emnQNDcbqnuO2jH0Kgfk2Ui7crrwzRb986Sa511iS-U"; //齐越小一
//userToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNDM5OTA1OTcyOTk3ODUzMTg0IiwidGVhbUlkIjoiMTQzOTkwNDA1MDc3NzY5MDExMiIsImV4cCI6MTY4NjQxODcyOH0.K7-MXjt_zfNK5v_08VjmCDnhAGF6SI7sEQr5sgDn7Jk"; //齐越珍珍
userToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNDM5OTE0NjczMzA5NzQ5MjQ4IiwidGVhbUlkIjoiMTQ0ODY4MTU0NDE4ODE3MDI0MCIsImV4cCI6MTY4NjQ1OTY0Mn0.4yCbZxOtogD0N868-YgySR5A-16VNnrp8fC13VCRs20"; //齐越耐克
//userToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxNDM5OTE0NjczMzA5NzQ5MjQ4IiwidGVhbUlkIjoiMTQ0ODY4MTU0NDE4ODE3MDI0MCIsImV4cCI6MTY4NjQ1OTY0Mn0.4yCbZxOtogD0N868-YgySR5A-16VNnrp8fC13VCRs20"; //齐越耐克
#else
var uid = e.Args.Count() > 0 ? e.Args.LastOrDefault(args => args.StartsWith("uid:")) : string.Empty;

1
BBWY.Client/ViewModels/MainViewModel.cs

@ -204,6 +204,7 @@ namespace BBWY.Client.ViewModels
}
else
{
ShowShopChoosePanel = true;
var response = shopService.GetDepartmentList();
if (!response.Success)
throw new Exception(response.Msg);

2
BBWY.Server.Business/MDSBusiness.cs

@ -42,7 +42,7 @@ namespace BBWY.Server.Business
AppKey = shopJToken.Value<string>("AppKey"),
AppSecret = shopJToken.Value<string>("AppSecret"),
AppToken = shopJToken.Value<string>("AppToken"),
Platform = (Enums.Platform)shopJToken.Value<int>("PlatformId"),
PlatformId = (Enums.Platform)shopJToken.Value<int>("PlatformId"),
VenderType = shopJToken.Value<string>("ShopType"),
ShopId = shopId.ToString(),
ShopName = shopJToken.Value<string>("ShopName"),

8
BBWY.Server.Business/Order/OrderBusiness.cs

@ -913,10 +913,10 @@ namespace BBWY.Server.Business
var shop = mdsBusiness.GetShopInfoByShopId(shopId);
try
{
if (!syncOrderMethodDic.ContainsKey(shop.Platform))
if (!syncOrderMethodDic.ContainsKey(shop.PlatformId))
throw new Exception("不支持的平台");
var relayAPIHost = GetPlatformRelayAPIHost(shop.Platform);
var relayAPIHost = GetPlatformRelayAPIHost(shop.PlatformId);
var orderListApiResult = restApiService.SendRequest(relayAPIHost, "api/PlatformSDK/GetOrderList", new SearchPlatformOrderRequest()
{
StartDate = startTime ?? DateTime.Now.AddHours(-3),
@ -926,7 +926,7 @@ namespace BBWY.Server.Business
AppToken = shop.AppToken,
PageIndex = 1,
PageSize = 100,
Platform = shop.Platform,
Platform = shop.PlatformId,
JDColType = string.IsNullOrEmpty(shop.VenderType) ? "0" : shop.VenderType,
SaveResponseLog = true,
OrderId = orderId
@ -941,7 +941,7 @@ namespace BBWY.Server.Business
if (orderListResponse.Data == null || orderListResponse.Data.Count == 0)
return;
syncOrderMethodDic[shop.Platform](orderListResponse.Data, shopId, relayAPIHost, shop.AppKey, shop.AppSecret, shop.AppToken, shop.PlatformCommissionRatio ?? 0.05M);
syncOrderMethodDic[shop.PlatformId](orderListResponse.Data, shopId, relayAPIHost, shop.AppKey, shop.AppSecret, shop.AppToken, shop.PlatformCommissionRatio ?? 0.05M);
}
catch (Exception ex)
{

6
BBWY.Server.Business/PurchaseOrder/PurchaseOrderBusiness.cs

@ -543,7 +543,7 @@ namespace BBWY.Server.Business
AppKey = shop.AppKey,
AppSecret = shop.AppSecret,
AppToken = shop.AppToken,
Platform = shop.Platform
Platform = shop.PlatformId
});
if (logisticsCompanyList != null)
logisticsCompanyListInfo = JsonConvert.SerializeObject(logisticsCompanyList);
@ -552,7 +552,7 @@ namespace BBWY.Server.Business
#region 物流公司翻译
currentProgress = "物流公司翻译";
//logisticsCompanyId = ConvertLogisticsCompanyId(wayBillNoResponse.LogisticsCompanyName, logisticsCompanyList, shop.Platform);
logisticsCompanyId = logisticsCompanyConverter.Converter(wayBillNoResponse.LogisticsCompanyName, callbackPlatform, shop.Platform, logisticsCompanyList);
logisticsCompanyId = logisticsCompanyConverter.Converter(wayBillNoResponse.LogisticsCompanyName, callbackPlatform, shop.PlatformId, logisticsCompanyList);
#endregion
#region 店铺平台订单出库
@ -563,7 +563,7 @@ namespace BBWY.Server.Business
AppSecret = shop.AppSecret,
AppToken = shop.AppToken,
OrderId = orderDropshipping.OrderId,
Platform = shop.Platform,
Platform = shop.PlatformId,
WayBillNo = wayBillNoResponse.WayBillNo,
LogisticsId = logisticsCompanyId, //物流公司Id
SaveResponseLog = true

2
BBWY.Server.Business/Vender/VenderBusiness.cs

@ -186,7 +186,7 @@ namespace BBWY.Server.Business
AppSecret = string.IsNullOrEmpty(x.AppSecret) ? "866a9877f5f24b03b537483b4defe75d" : x.AppSecret,
AppToken = x.AppToken,
ManagePwd = x.ManagePwd,
Platform = (Enums.Platform)x.PlatformId,
PlatformId = (Enums.Platform)x.PlatformId,
PlatformCommissionRatio = x.PlatformCommissionRatio,
ShopId = x.ShopId,
ShopName = x.ShopName,

2
BBWY.Server.Model/Dto/Response/Vender/ShopResponse.cs

@ -20,7 +20,7 @@ namespace BBWY.Server.Model.Dto
/// <summary>
/// 店铺平台
/// </summary>
public Enums.Platform Platform { get; set; }
public Enums.Platform PlatformId { get; set; }
public string AppKey { get; set; }

Loading…
Cancel
Save