From d82fec9e2a4238ff1833e67c01bc9b34e525d904 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 25 二月 2022 16:37:12 +0800 Subject: [PATCH] 2022-02-25 --- src/tabviews/zshare/actionList/normalbutton/index.jsx | 36 ++++++++++++++++++++++++++++++++++-- 1 files changed, 34 insertions(+), 2 deletions(-) diff --git a/src/tabviews/zshare/actionList/normalbutton/index.jsx b/src/tabviews/zshare/actionList/normalbutton/index.jsx index 12daac6..55ca27b 100644 --- a/src/tabviews/zshare/actionList/normalbutton/index.jsx +++ b/src/tabviews/zshare/actionList/normalbutton/index.jsx @@ -172,13 +172,39 @@ } actionSubmit = (res) => { - const { btn } = this.props + const { btn, setting, BID } = this.props + const { selines } = this.state if (btn.uuid !== res.menuId) return + let data = selines || [] + + if (setting.supModule && !BID) { + notification.warning({ + top: 92, + message: '闇�瑕佷笂绾т富閿�硷紒', + duration: 3 + }) + return + } else if (btn.Ot !== 'notRequired' && data.length === 0) { + notification.warning({ + top: 92, + message: '璇烽�夋嫨琛岋紒', + duration: 5 + }) + return + } else if (btn.Ot === 'requiredSgl' && data.length !== 1) { + notification.warning({ + top: 92, + message: '璇烽�夋嫨鍗曡鏁版嵁锛�', + duration: 5 + }) + return + } + this.setState({ loading: true }) - this.execSubmit(this.state.selines, () => {}, res.form) + this.execSubmit(data, () => {}, res.form) } resetModuleParam = (menuId, btnId, param) => { @@ -995,6 +1021,12 @@ _resolve() }) } + // xml璋冪敤鏂瑰紡 + // Api.directRequest('http://localhost:3001/test.xml', 'get', null, 'true').then(res => { + // let $x2js = new x2js() + // let jsonObj = $x2js.xml2js(res); + // console.info(jsonObj) + // }) /** * @description 鑷畾涔夎姹傚惊鐜墽琛� -- Gitblit v1.8.0