From 7b0dbecd1d6155d26ec67be0a47a16264c738c85 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期二, 09 五月 2023 14:48:10 +0800
Subject: [PATCH] 2023-05-09

---
 src/tabviews/zshare/mutilform/index.jsx |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/src/tabviews/zshare/mutilform/index.jsx b/src/tabviews/zshare/mutilform/index.jsx
index 4a96938..f6f2a1c 100644
--- a/src/tabviews/zshare/mutilform/index.jsx
+++ b/src/tabviews/zshare/mutilform/index.jsx
@@ -19,6 +19,7 @@
 
 const MKCheckCard = asyncComponent(() => import('./mkCheckCard'))
 const MKSwitch = asyncComponent(() => import('./mkSwitch'))
+const MKCheck = asyncComponent(() => import('./mkCheck'))
 const MKCheckbox = asyncComponent(() => import('./mkCheckbox'))
 const MKRadio = asyncComponent(() => import('./mkRadio'))
 const MKDatePicker = asyncComponent(() => import('./mkDatePicker'))
@@ -124,11 +125,13 @@
         item.precision = 'second'
       }
 
-      if (!item.field || !['text', 'number', 'switch', 'rate', 'select', 'link', 'cascader', 'linkMain', 'funcvar', 'date', 'datemonth', 'radio', 'checkbox', 'checkcard', 'fileupload', 'textarea', 'multiselect', 'brafteditor', 'color', 'vercode'].includes(item.type)) return false
+      if (!item.field || !['text', 'number', 'switch', 'check', 'rate', 'select', 'link', 'cascader', 'linkMain', 'funcvar', 'date', 'datemonth', 'radio', 'checkbox', 'checkcard', 'fileupload', 'textarea', 'multiselect', 'brafteditor', 'color', 'vercode'].includes(item.type)) return false
 
       if (/^\s+$/.test(item.label)) {
         item.style = item.style || {}
-        item.style.color = 'transparent'
+        item.style.opacity = 0
+        item.style.width = 1
+        item.style.display = 'inline-block'
       }
 
       // 鏁版嵁鑷姩濉厖
@@ -218,7 +221,7 @@
         if (newval === '$empty' && item.initval) {
           newval = moment().subtract(item.initval, 'month').format('YYYY-MM')
         }
-      } else if (item.type === 'switch') { // 寮�鍏冲彧鎺ユ敹鍥哄畾鍊�
+      } else if (item.type === 'switch' || item.type === 'check') { // 寮�鍏冲嬀閫夋鍙帴鏀跺浐瀹氬��
         if (newval !== '$empty' && (newval === item.closeVal || newval === item.openVal)) {
 
         } else if (item.initval === true) {
@@ -995,6 +998,8 @@
           content = (<MKCheckCard config={item} onChange={(val, other) => this.recordChange({[item.field]: val, ...other}, item)}/>)
         } else if (item.type === 'switch') {
           content = (<MKSwitch config={item} onChange={(val) => this.recordChange({[item.field]: val}, item)}/>)
+        } else if (item.type === 'check') {
+          content = (<MKCheck config={item} onChange={(val) => this.recordChange({[item.field]: val}, item)}/>)
         } else if (item.type === 'checkbox') {
           content = (<MKCheckbox config={item} onChange={(val) => this.recordChange({[item.field]: val})}/>)
         } else if (item.type === 'radio') {

--
Gitblit v1.8.0