From 59b24e5ebb3dd9ae399359dfe82abd8a31e36596 Mon Sep 17 00:00:00 2001 From: dengjunjie <dengjunjie@hnkhzn.com> Date: 星期五, 10 一月 2025 14:34:22 +0800 Subject: [PATCH] 优化获取旧WMS辅料仓库存方法 --- 代码管理/WMS/WIDESEA_WMSClient/public/index.html | 1 + 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Base/LocationInfoService.cs | 2 +- 代码管理/WMS/WIDESEA_WMSClient/public/webconfig.js | 3 +++ 代码管理/WMS/WIDESEA_WMSClient/src/api/http.js | 4 ++-- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/index.html" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/index.html" index c902847..53f6fd4 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/index.html" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/index.html" @@ -9,6 +9,7 @@ <meta name="description" content="" /> <link rel="icon" href="<%= BASE_URL %>wms_d.png"> <title><%= htmlWebpackPlugin.options.title %></title> + <script src="webconfig.js"></script> </head> <body> diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/webconfig.js" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/webconfig.js" new file mode 100644 index 0000000..fe29087 --- /dev/null +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/public/webconfig.js" @@ -0,0 +1,3 @@ +window.webConfig = { + "webApiBaseUrl": "http://127.0.0.1:9293/" +} \ No newline at end of file diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/api/http.js" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/api/http.js" index 8ea5bac..002af14 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/api/http.js" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSClient/src/api/http.js" @@ -12,14 +12,14 @@ let loadingInstance; let loadingStatus = false; if (process.env.NODE_ENV == 'development') { - axios.defaults.baseURL = 'http://127.0.0.1:9293/'; + axios.defaults.baseURL = window.webConfig.webApiBaseUrl;; } else if (process.env.NODE_ENV == 'debug') { axios.defaults.baseURL = 'http://127.0.0.1:8098/'; } else if (process.env.NODE_ENV == 'production') { - axios.defaults.baseURL = 'http://10.30.4.92:9283/'; + axios.defaults.baseURL = window.webConfig.webApiBaseUrl;; } if (!axios.defaults.baseURL.endsWith('/')) { axios.defaults.baseURL+="/"; diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Base/LocationInfoService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Base/LocationInfoService.cs" index 701cb7b..45245fd 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Base/LocationInfoService.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Base/LocationInfoService.cs" @@ -156,7 +156,7 @@ Unit = Unit, Status = StockStatusEmun.鍏ュ簱瀹屾垚.ObjToInt(), ProductionDate = ProduceData, - EffectiveDate = ValidData ?? "1", + EffectiveDate = ValidData ?? DateTime.Parse(ProduceData).AddYears(2).ToString("yyyy-MM-dd"), Remark = Standard, InboundOrderRowNo = MId, }; -- Gitblit v1.9.3