From 61d7445ab27d1f80ef0319a44e5d564ff8061ed4 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 28 十月 2021 12:55:52 +0800 Subject: [PATCH] 2021-10-28 --- src/tabviews/zshare/mutilform/index.jsx | 11 +++++++---- src/api/index.js | 4 ++-- src/templates/modalconfig/settingform/index.jsx | 17 +++++++++++++++++ src/views/design/header/versions/index.jsx | 2 +- 4 files changed, 27 insertions(+), 7 deletions(-) diff --git a/src/api/index.js b/src/api/index.js index 500faad..01fda72 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -676,7 +676,7 @@ * @param {Object} param 璇锋眰鍙傛暟 * @param {Boolean} SSO 鏄惁涓哄崟鐐圭櫥褰曞湴鍧� */ - getSystemCacheConfig (param) { + getSystemCacheConfig (param, cache = true) { param.userid = param.userid || sessionStorage.getItem('UserID') || '' param.lang = param.lang || sessionStorage.getItem('lang') || '' param.SessionUid = localStorage.getItem('SessionUid') || '' @@ -696,7 +696,7 @@ _param = JSON.stringify(_param) _param = md5(_param) - if (window.GLOB.CacheMap.has(_param)) { + if (cache && window.GLOB.CacheMap.has(_param)) { return Promise.resolve(window.GLOB.CacheMap.get(_param)) } else { param = this.encryptParam(param) diff --git a/src/tabviews/zshare/mutilform/index.jsx b/src/tabviews/zshare/mutilform/index.jsx index c855e56..373b36e 100644 --- a/src/tabviews/zshare/mutilform/index.jsx +++ b/src/tabviews/zshare/mutilform/index.jsx @@ -379,11 +379,12 @@ * @description 鑾峰彇涓嬫媺琛ㄥ崟閫夐」淇℃伅 */ improveActionForm = (deForms) => { - const { BID, menuType } = this.props + const { BID, menuType, action } = this.props let deffers = [] let mainItems = [] // 浜戠鎴栧崟鐐规暟鎹� let localItems = [] // 鏈湴鏁版嵁 + let cache = action.setting.cache !== 'false' deForms.forEach(item => { if (item.database === 'sso') { @@ -419,7 +420,7 @@ deffers.push( new Promise(resolve => { - Api.getSystemCacheConfig(param).then(res => { + Api.getSystemCacheConfig(param, cache).then(res => { if (!res.status) { notification.warning({ top: 92, @@ -461,7 +462,7 @@ deffers.push( new Promise(resolve => { - Api.getSystemCacheConfig(mainparam).then(res => { + Api.getSystemCacheConfig(mainparam, cache).then(res => { if (!res.status) { notification.warning({ top: 92, @@ -491,6 +492,8 @@ * @description 娴嬭瘯绯荤粺鑾峰彇涓嬫媺琛ㄥ崟閫夐」淇℃伅 */ improveSimpleActionForm = (deForms) => { + let cache = this.props.action.setting.cache !== 'false' + let deffers = deForms.map((form, index) => { let param = { func: 'sPC_Get_SelectedList', @@ -506,7 +509,7 @@ return ( new Promise(resolve => { setTimeout(() => { - Api.getSystemCacheConfig(param).then(res => { + Api.getSystemCacheConfig(param, cache).then(res => { if (!res.status) { notification.warning({ top: 92, diff --git a/src/templates/modalconfig/settingform/index.jsx b/src/templates/modalconfig/settingform/index.jsx index 8504fa7..076ea81 100644 --- a/src/templates/modalconfig/settingform/index.jsx +++ b/src/templates/modalconfig/settingform/index.jsx @@ -194,6 +194,23 @@ </Col> <Col span={12}> <Form.Item label={ + <Tooltip placement="topLeft" title="闇�瑕侀�氳繃鏁版嵁婧愭煡璇㈢殑閫夐」锛屾槸鍚︿娇鐢ㄧ紦瀛樸��"> + <Icon type="question-circle" /> + 閫夐」鏌ヨ + </Tooltip> + }> + {getFieldDecorator('cache', { + initialValue: config.setting.cache || 'true' + })( + <Radio.Group> + <Radio value="true">缂撳瓨</Radio> + <Radio value="false">瀹炴椂</Radio> + </Radio.Group> + )} + </Form.Item> + </Col> + <Col span={12}> + <Form.Item label={ <Tooltip placement="topLeft" title="鎵撳嵃鎸夐挳涓棤鏁堛��"> <Icon type="question-circle" /> 鏄剧ず鏂瑰紡 diff --git a/src/views/design/header/versions/index.jsx b/src/views/design/header/versions/index.jsx index 1d7d987..6013932 100644 --- a/src/views/design/header/versions/index.jsx +++ b/src/views/design/header/versions/index.jsx @@ -127,7 +127,7 @@ } else if (!result.vid) { notification.warning({ top: 92, - message: '褰撳墠搴旂敤闇�瑕佸崌绾х郴缁熸帴鍙o紝璇疯仈绯荤鐞嗗憳锛�', + message: '褰撳墠搴旂敤鏃犳硶鑷姩鍗囩骇锛岃澶嶅埗浼犺緭鍙凤紝鎵嬪姩瀹屾垚鍗囩骇锛�', duration: 5 }) this.execError() -- Gitblit v1.8.0