sjz
2025-06-26 bf780b6c83012b5beb3d7515b8fb61753c5fb736
MES.Service/service/PLM/WarehouseDownloadDoc.cs
@@ -15,12 +15,12 @@
        {
            get
            {
                string json = "{\"ap1\":{ \"AcctID\":\"" + "6722eada66becb" + "\",\"Username\":\"Administrator\",\"Password\":\"Yc123456@\",\"Lcid\":2052,\"AuthenticateType\":1,\"PasswordIsEncrypted\":\"false\",\"ClientInfo\":{\"ClientType\":8}}";
                string json = "{\"ap1\":{ \"AcctID\":\"" + "61ce591aee4c5a" + "\",\"Username\":\"Administrator\",\"Password\":\"Yc123456@\",\"Lcid\":2052,\"AuthenticateType\":1,\"PasswordIsEncrypted\":\"false\",\"ClientInfo\":{\"ClientType\":8}}";
                var resp = GetResponse("http://121.36.245.199/k3cloud/Kingdee.BOS.ServiceFacade.ServicesStub.User.UserService.ValidateLoginInfo.common.kdsvc", json, new Dictionary<string, string>());
                string ret = (new StreamReader(resp.GetResponseStream(), Encoding.UTF8)).ReadToEnd();
                var result = JObject.Parse(ret)["Context"];
                string token = result["UserToken"].ToString();
                var warehouseCtx = string.Format("LoginUrl={0}/&UserToken={1}", _cloudUrl, token);
                var warehouseCtx = string.Format("LoginUrl={0}&KDServiceSessionId={1}", _cloudUrl, JObject.Parse(ret)["KDSVCSessionId"].ToString());//安全新方式
                return Convert.ToBase64String(Encoding.UTF8.GetBytes(warehouseCtx));
            }
        }