diff --git a/.vs/WMS.Web/DesignTimeBuild/.dtbcache.v2 b/.vs/WMS.Web/DesignTimeBuild/.dtbcache.v2 index 6bf88877..ef3222e1 100644 Binary files a/.vs/WMS.Web/DesignTimeBuild/.dtbcache.v2 and b/.vs/WMS.Web/DesignTimeBuild/.dtbcache.v2 differ diff --git a/src/WMS.Web.Api/Controllers/TestController.cs b/src/WMS.Web.Api/Controllers/TestController.cs index a706af45..1fec84d5 100644 --- a/src/WMS.Web.Api/Controllers/TestController.cs +++ b/src/WMS.Web.Api/Controllers/TestController.cs @@ -125,7 +125,7 @@ namespace WMS.Web.Api.Controllers //string codes = "AD"; //var b = await _erpInventoryService.GetInventory(new List() { "111"}); //int count = 10 / 5; - //var bcd=await _productInventoryService.LingXing(); + var bcd=await _productInventoryService.JuShuiTan(); //LingXingResponse r = new LingXingResponse(); diff --git a/src/WMS.Web.Domain/Services/Public/JuShuiTanService.cs b/src/WMS.Web.Domain/Services/Public/JuShuiTanService.cs index 384357c7..b2630e74 100644 --- a/src/WMS.Web.Domain/Services/Public/JuShuiTanService.cs +++ b/src/WMS.Web.Domain/Services/Public/JuShuiTanService.cs @@ -11,6 +11,7 @@ using System.Linq; using System.Net; using System.Security.Cryptography; using System.Text; +using System.Threading; using System.Threading.Tasks; using WMS.Web.Core.Dto.Erp; using WMS.Web.Core.Dto.JuShuiTan; @@ -94,6 +95,7 @@ namespace WMS.Web.Domain.Services.Public List list = new List(); foreach (var id in StockId) { + Thread.Sleep(1000);//不能太频繁请求 JuShuiTanInventoryRequst request = new JuShuiTanInventoryRequst(); request.wms_co_id = id;//10923342; request.page_size = 100; @@ -115,6 +117,7 @@ namespace WMS.Web.Domain.Services.Public int count = Convert.ToInt32(resData["data"]["page_count"]); for (int i = 1; i < count; i++) { + Thread.Sleep(1000);//不能太频繁请求 request.page_index++; resContent = PostUrl("/open/inventory/query", JsonConvert.SerializeObject(request)); resData = JObject.Parse(resContent);