From bbcb3f45ad0ef4c808bf5a68ec10c0464c094e2f Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 27 十月 2021 11:51:40 +0800
Subject: [PATCH] Merge branch 'master' into bms

---
 src/menu/components/share/actioncomponent/actionform/index.jsx |   15 ++++++++++++---
 1 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/src/menu/components/share/actioncomponent/actionform/index.jsx b/src/menu/components/share/actioncomponent/actionform/index.jsx
index 5213db6..880e257 100644
--- a/src/menu/components/share/actioncomponent/actionform/index.jsx
+++ b/src/menu/components/share/actioncomponent/actionform/index.jsx
@@ -118,7 +118,11 @@
           item.options = this.state.interTypeOptions.filter(op => (iscustom || op.value !== 'custom'))
         } else if (item.key === 'Ot') {
           if (type === 'card') {
-            item.options = this.state.requireOptions.filter(op => ['notRequired', 'requiredSgl'].includes(op.value))
+            if (card.sqlType === 'insert') {
+              item.options = this.state.requireOptions.filter(op => ['notRequired'].includes(op.value))
+            } else {
+              item.options = this.state.requireOptions.filter(op => ['notRequired', 'requiredSgl'].includes(op.value))
+            }
           } else if (_pageTemplate === 'pay') { // 琛岀骇鎸夐挳銆佹敮浠樻寜閽紝鍙兘閫夊崟琛�
             item.options = this.state.requireOptions.filter(op => ['requiredSgl'].includes(op.value))
           } else if (['innerpage', 'tab', 'popview', 'excelIn'].includes(_opentype)) {
@@ -146,7 +150,7 @@
 
   getOptions = (_opentype, _intertype, _funcType, _pageTemplate, _procMode, _Ot) => {
     let _options = actionTypeOptions[_opentype] ? fromJS(actionTypeOptions[_opentype]).toJS() : [] // 閫夐」鍒楄〃
-    
+
     if (_opentype === 'innerpage') {         // 鏂伴〉闈紝鍙�夋ā鏉�(鑷畾涔夋椂锛屽彲濉叆澶栭儴閾炬帴)
       if (_pageTemplate === 'custom') {
         _options.push('url', 'joint')
@@ -301,6 +305,7 @@
       }
 
       this.setState({
+        funcType: value,
         formlist: this.state.formlist.map(item => {
           item.hidden = !_options.includes(item.key)
 
@@ -326,7 +331,11 @@
       this.setState({
         formlist: this.state.formlist.map(item => {
           if (item.key === 'Ot' && type === 'card') {
-            item.options = this.state.requireOptions.filter(op => ['notRequired', 'requiredSgl'].includes(op.value))
+            if (value === 'insert') {
+              item.options = this.state.requireOptions.filter(op => ['notRequired'].includes(op.value))
+            } else {
+              item.options = this.state.requireOptions.filter(op => ['notRequired', 'requiredSgl'].includes(op.value))
+            }
           } else if (item.key === 'Ot' && value === 'insert') {
             item.options = this.state.requireOptions.filter(op => ['notRequired'].includes(op.value))
           } else if (item.key === 'Ot') {

--
Gitblit v1.8.0