From 12dd55d710cf151f68690deaa44dde9fc538a0f1 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 21 四月 2022 16:29:21 +0800
Subject: [PATCH] 2022-04-21

---
 src/menu/components/table/normal-table/options.jsx     |    2 +-
 src/menu/components/card/prop-card/index.jsx           |    2 +-
 src/templates/zshare/verifycard/index.jsx              |    2 +-
 src/utils/utils-custom.js                              |    9 ++++++++-
 src/menu/components/card/data-card/index.jsx           |    2 +-
 src/templates/zshare/verifycard/billcodeform/index.jsx |    2 +-
 6 files changed, 13 insertions(+), 6 deletions(-)

diff --git a/src/menu/components/card/data-card/index.jsx b/src/menu/components/card/data-card/index.jsx
index 7c031be..4b81300 100644
--- a/src/menu/components/card/data-card/index.jsx
+++ b/src/menu/components/card/data-card/index.jsx
@@ -56,7 +56,7 @@
         name: card.name,
         subtype: card.subtype,
         setting: { interType: 'system' },
-        wrap: { name: card.name, width: card.width || 24, title: '', pagestyle: 'page', switch: 'false', cardType: '' },
+        wrap: { name: card.name, width: card.width || 24, title: '', pagestyle: 'page', cardType: '' },
         style: { marginLeft: '0px', marginRight: '0px', marginTop: '8px', marginBottom: '8px' },
         headerStyle: { fontSize: '16px', borderBottomWidth: '1px', borderBottomColor: '#e8e8e8' },
         columns: [],
diff --git a/src/menu/components/card/prop-card/index.jsx b/src/menu/components/card/prop-card/index.jsx
index 052e076..280f2d7 100644
--- a/src/menu/components/card/prop-card/index.jsx
+++ b/src/menu/components/card/prop-card/index.jsx
@@ -55,7 +55,7 @@
         name: card.name,
         subtype: card.subtype,
         setting: { interType: 'system' },
-        wrap: { name: card.name, width: card.width || 24, title: '', switch: 'false', datatype: 'static' },
+        wrap: { name: card.name, width: card.width || 24, title: '', datatype: 'static' },
         style: { marginLeft: '0px', marginRight: '0px', marginTop: '8px', marginBottom: '8px' },
         headerStyle: { fontSize: '16px', borderBottomWidth: '1px', borderBottomColor: '#e8e8e8' },
         columns: [],
diff --git a/src/menu/components/table/normal-table/options.jsx b/src/menu/components/table/normal-table/options.jsx
index fdbc79c..170dbb0 100644
--- a/src/menu/components/table/normal-table/options.jsx
+++ b/src/menu/components/table/normal-table/options.jsx
@@ -58,7 +58,7 @@
       type: 'radio',
       field: 'tableType',
       label: '琛ㄦ牸灞炴��',
-      initval: wrap.tableType,
+      initval: wrap.tableType || '',
       required: false,
       options: [
         {value: '', label: '涓嶅彲閫�'},
diff --git a/src/templates/zshare/verifycard/billcodeform/index.jsx b/src/templates/zshare/verifycard/billcodeform/index.jsx
index 8b6a946..a5ac2c7 100644
--- a/src/templates/zshare/verifycard/billcodeform/index.jsx
+++ b/src/templates/zshare/verifycard/billcodeform/index.jsx
@@ -156,7 +156,7 @@
         values.fieldName = _funField ? _funField.label : ''
 
         // 涓�绾ц彍鍗曞�间负20190203125926873D6029A9C511041719420鏃禩ypeCharTwo=TableCode锛屽叾浠栫敤BillCode
-        if (values.ModularCode === '20190203125926873D6029A9C511041719420') {
+        if (values.ModularCode === '20190203125926873D6029A9C511041719420' || values.ModularCode === '01') {
           values.TypeCharTwo = 'TableCode'
         } else {
           values.TypeCharTwo = 'BillCode'
diff --git a/src/templates/zshare/verifycard/index.jsx b/src/templates/zshare/verifycard/index.jsx
index a3963e6..b98a3c2 100644
--- a/src/templates/zshare/verifycard/index.jsx
+++ b/src/templates/zshare/verifycard/index.jsx
@@ -473,7 +473,7 @@
           let _type = record.Type
           if (_type && typeof(_type) === 'string') {
             _type = parseInt(_type)
-          } else {
+          } else if (!_type) {
             _type = 4
           }
 
diff --git a/src/utils/utils-custom.js b/src/utils/utils-custom.js
index 4ad2bfd..0d109b5 100644
--- a/src/utils/utils-custom.js
+++ b/src/utils/utils-custom.js
@@ -95,9 +95,16 @@
           children: null
         }
       } else if (item.switchable) { // 鏁版嵁鍙垏鎹�
+        let disabled = false
+        if (item.type === 'card') {
+          disabled = item.wrap.cardType === ''
+        } else if (item.type === 'table') {
+          disabled = item.wrap.tableType === ''
+        }
         return {
           value: item.uuid,
-          label: item.name
+          label: item.name,
+          disabled: disabled
         }
       } else if (item.type === 'form') { // 鏁版嵁鏍煎紡锛屽瓨鍦ㄦ暟鎹簮
         return {

--
Gitblit v1.8.0