From f6dbdd98a13296455b8efc5dadd6e9e4eaa63693 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期一, 11 九月 2023 18:04:37 +0800
Subject: [PATCH] 2023-09-11

---
 src/api/index.js |   23 ++++++-----------------
 1 files changed, 6 insertions(+), 17 deletions(-)

diff --git a/src/api/index.js b/src/api/index.js
index e01aca6..e6b983c 100644
--- a/src/api/index.js
+++ b/src/api/index.js
@@ -82,7 +82,6 @@
   
   /**
    * @description 浣跨敤dostar鎺ュ彛锛岃烦杩囬獙璇�
-   * @param {Object} param 鏌ヨ鍙婃彁浜ゅ弬鏁�
    */
   dostarInterface (param) {
     param.userid = param.userid || ''
@@ -522,11 +521,7 @@
     param.appkey = param.appkey || window.GLOB.appkey
 
     let url = '/webapi/dostars'
-    if (window.GLOB.mkHS && window.GLOB.cloudServiceApi) { // HS涓嬶紝涓斿瓨鍦ㄤ簯绔湴鍧�
-      url = window.GLOB.cloudServiceApi
-      param.userid = sessionStorage.getItem('CloudUserID') || ''
-      param.LoginUID = sessionStorage.getItem('CloudLoginUID') || ''
-    } else if (window.GLOB.mainSystemApi) {
+    if (window.GLOB.mainSystemApi) {
       if (!window.GLOB.transfer) {
         url = window.GLOB.mainSystemApi
       } else {
@@ -554,13 +549,7 @@
     param.appkey = param.appkey || window.GLOB.appkey || ''
 
     let url = '/webapi/dostars'
-    if (window.GLOB.mkHS) {          // HS涓嬶紝鍗曠偣鐧诲綍鏈嶅姟鍣ㄤ负浜戠
-      if (window.GLOB.cloudServiceApi) { // 瀛樺湪浜戠鍦板潃鏃讹紝浣跨敤浜戠绯荤粺鍙傛暟
-        url = window.GLOB.cloudServiceApi
-        param.userid = sessionStorage.getItem('CloudUserID') || ''
-        param.LoginUID = sessionStorage.getItem('CloudLoginUID') || ''
-      }
-    } else if (window.GLOB.mainSystemApi) {
+    if (window.GLOB.mainSystemApi) {
       if (!window.GLOB.transfer) {
         url = window.GLOB.mainSystemApi
       } else {
@@ -631,7 +620,7 @@
     if (window.GLOB.CacheMap.has(_param)) {
       return Promise.resolve(window.GLOB.CacheMap.get(_param))
     } else {
-      return Promise.resolve({ErrCode: 'S', ErrMesg: '', LongParam: '', message: '', status: false})
+      return Promise.resolve({ErrCode: 'S', LongParam: '', message: '', status: false})
     }
   }
 
@@ -735,7 +724,7 @@
       token = JSON.parse(window.decodeURIComponent(window.atob(token)))
     } catch (e) {
       token = null
-      _resolve({status: false, ErrCode: 'E', message: '鎺ュ彛淇℃伅瑙f瀽澶辫触锛�', ErrMesg: 'token_error'})
+      _resolve({status: false, ErrCode: 'token_error', message: '鎺ュ彛淇℃伅瑙f瀽澶辫触锛�'})
     }
 
     if (!token) return
@@ -838,7 +827,7 @@
     param.appkey = window.GLOB.appkey || ''
 
     if (param.$token === '') {
-      return Promise.resolve({status: false, ErrCode: 'E', message: '鎺ュ彛鍦板潃灏氭湭璁剧疆锛�', ErrMesg: 'token_error'})
+      return Promise.resolve({status: false, ErrCode: 'token_error', message: '鎺ュ彛鍦板潃灏氭湭璁剧疆锛�'})
     } else if (param.$token) {
       return new Promise(resolve => this.visitOuterSystem(param, resolve))
     }
@@ -877,7 +866,7 @@
       let time = +sessionStorage.getItem(rduri)
       let c_time = Math.round(new Date().getTime() / 1000)
 
-      if (time && c_time - time <= 60) {
+      if (time && c_time - time <= 1800) {
         sessionStorage.setItem(rduri, c_time)
         return axios({
           url: `${url}${param.func ? '/' + param.func : ''}`,

--
Gitblit v1.8.0