11
啊鑫
2025-07-15 5dc3cc86f5835369cd830f2a83318b9a8d69cf69
MESApplication/Controllers/Base/LoginController.cs
@@ -1,10 +1,10 @@
using MES.Service.Dto.@base;
using System.Dynamic;
using MES.Service.Dto.@base;
using MES.Service.service;
using MES.Service.util;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using System.Dynamic;
namespace MESApplication.Controllers.Base;
@@ -27,7 +27,8 @@
        try
        {
            dynamic resultInfos = new ExpandoObject();
            var tbBillList =  new LoginService().login(model.userID, model.userPass);
            var tbBillList =
                new LoginService().login(model.userID, model.userPass);
            resultInfos.tbBillList = tbBillList;
            return new ResponseResult
            {
@@ -105,12 +106,7 @@
            return ResponseResult.ResponseError(ex);
        }
    }
    public class Root
    {
        public string version { get; set; }
        public string apkUrl { get; set; }
    }
    /// <summary>
    ///    获取App最新版本信息
    /// </summary>
@@ -119,11 +115,10 @@
    [HttpPost("getAppUpgradeInfo")]
    public async Task<ResponseResult> getAppUpgradeInfo()
    {
        try
        {
            HttpClient client = new();
            var requestUrl = $"http://192.168.1.92:8282/UpgradeInformation.json";
            var requestUrl = "http://192.168.1.92:8282/UpgradeInformation.json";
            var response = await client.GetAsync(requestUrl);
            response.EnsureSuccessStatusCode(); // 检查HTTP状态码
            var responseContent = await response.Content.ReadAsStringAsync();
@@ -134,11 +129,17 @@
                message = "OK",
                data = a
            };
        }
        catch (Exception ex)
        {
            return null;
        }
    }
    public class Root
    {
        public string version { get; set; }
        public string apkUrl { get; set; }
    }
}