From e4be26c0c229a941cfa5182f0daf785a59067288 Mon Sep 17 00:00:00 2001 From: hutongqing <hutongqing@hnkhzn.com> Date: 星期六, 04 一月 2025 10:34:43 +0800 Subject: [PATCH] PDA自动更新 --- /dev/null | 0 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/PDAController.cs | 30 +++++++++++++++--------------- 代码管理/淮安PDA/pages/index/index.vue | 26 ++++++++++++++------------ 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/d4c63503-44a3-443c-a699-9cde9edbeae2.vsidx | 0 代码管理/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b45813db-207a-41f6-8e14-ddcbb57bee26.vsidx | 0 5 files changed, 29 insertions(+), 27 deletions(-) diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/543d3d70-8433-4b19-aabd-dfd52610493b.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/543d3d70-8433-4b19-aabd-dfd52610493b.vsidx" deleted file mode 100644 index 05aa72e..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/543d3d70-8433-4b19-aabd-dfd52610493b.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b28e2128-7595-489a-b656-9987625a9f04.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b28e2128-7595-489a-b656-9987625a9f04.vsidx" deleted file mode 100644 index 13df731..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b28e2128-7595-489a-b656-9987625a9f04.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b45813db-207a-41f6-8e14-ddcbb57bee26.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b45813db-207a-41f6-8e14-ddcbb57bee26.vsidx" new file mode 100644 index 0000000..40b0150 --- /dev/null +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/b45813db-207a-41f6-8e14-ddcbb57bee26.vsidx" Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/f4112718-bcb9-48e2-a673-ba30ecbb98de.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/f4112718-bcb9-48e2-a673-ba30ecbb98de.vsidx" deleted file mode 100644 index 444ebd4..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/f4112718-bcb9-48e2-a673-ba30ecbb98de.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/d4c63503-44a3-443c-a699-9cde9edbeae2.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/d4c63503-44a3-443c-a699-9cde9edbeae2.vsidx" new file mode 100644 index 0000000..ceb7064 --- /dev/null +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/d4c63503-44a3-443c-a699-9cde9edbeae2.vsidx" Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/e529db47-ecd0-417a-8581-4e85c8667e4e.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/e529db47-ecd0-417a-8581-4e85c8667e4e.vsidx" deleted file mode 100644 index 56b5e05..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/e529db47-ecd0-417a-8581-4e85c8667e4e.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/f68413a2-ad64-418c-b6b3-1cbbe0a09b03.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/f68413a2-ad64-418c-b6b3-1cbbe0a09b03.vsidx" deleted file mode 100644 index b8d828b..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/f68413a2-ad64-418c-b6b3-1cbbe0a09b03.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/PDAController.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/PDAController.cs" index 68a3577..33d6641 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/PDAController.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/PDAController.cs" @@ -93,21 +93,21 @@ } } - //[HttpPost, HttpGet, Route("GetPDAVersion"), AllowAnonymous] - //public WebResponseContent GetPDAVersion(string version) - //{ - // try - // { - // string versionP = ConfigUtil.GetConfiguration["PDAVersion"]; - // if (Convert.ToInt32(versionP) > Convert.ToInt32(version)) - // return WebResponseContent.Instance.OK(data: true); - // else return WebResponseContent.Instance.OK(data: false); - // } - // catch (Exception ex) - // { - // return WebResponseContent.Instance.Error(ex.Message); - // } + [HttpPost, HttpGet, Route("GetPDAVersion"), AllowAnonymous] + public WebResponseContent GetPDAVersion(string version) + { + try + { + string versionP = AppSettings.Get("PDAVersion"); + if (Convert.ToInt32(versionP) > Convert.ToInt32(version)) + return WebResponseContent.Instance.OK(data: true); + else return WebResponseContent.Instance.OK(data: false); + } + catch (Exception ex) + { + return WebResponseContent.Instance.Error(ex.Message); + } - //} + } } } diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/index/index.vue" "b/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/index/index.vue" index b562ab4..445e832 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/index/index.vue" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/index/index.vue" @@ -31,16 +31,18 @@ } }, onShow() { - // uni.getSystemInfo({ - // success: (res) => { - // this.version = res.appWgtVersion; - // // console.log(res); - // //妫�娴嬪綋鍓嶅钩鍙帮紝濡傛灉鏄畨鍗撳垯鍚姩瀹夊崜鏇存柊 - // if (res.platform == "android") { - // this.AndroidCheckUpdate(); - // } - // } - // }); + console.log(); + + uni.getSystemInfo({ + success: (res) => { + this.version = res.appWgtVersion; + // console.log(res); + //妫�娴嬪綋鍓嶅钩鍙帮紝濡傛灉鏄畨鍗撳垯鍚姩瀹夊崜鏇存柊 + if (res.platform == "android") { + this.AndroidCheckUpdate(); + } + } + }); }, onLoad() { this.getCurrentTree(); @@ -52,7 +54,7 @@ AndroidCheckUpdate: function() { var _this = this; uni.request({ - url: 'http://10.1.211.101:9004/api/PDA/GetPDAVersion?version=' + this.version, + url: this.$u.http.config.baseUrl+'/api/PDA/GetPDAVersion?version=' + this.version, method: 'GET', data: {}, success: res => { @@ -65,7 +67,7 @@ icon: "none" }); var dtask = plus.downloader.createDownload( - "http://10.1.211.101:9004/api/PDA/DownLoadApp", {}, + this.$u.http.config.baseUrl+"/api/PDA/DownLoadApp", {}, function(d, status) { // 涓嬭浇瀹屾垚 if (status == 200) { -- Gitblit v1.9.3