From 704f82b06befe96e5f739b2dce419f76f5683a6f Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期一, 15 八月 2022 09:27:54 +0800
Subject: [PATCH] Merge branch 'develop'

---
 src/components/normalform/modalform/index.jsx |   33 +++++++++++++++++++++++----------
 1 files changed, 23 insertions(+), 10 deletions(-)

diff --git a/src/components/normalform/modalform/index.jsx b/src/components/normalform/modalform/index.jsx
index 8bc59c5..ce8b71d 100644
--- a/src/components/normalform/modalform/index.jsx
+++ b/src/components/normalform/modalform/index.jsx
@@ -275,16 +275,29 @@
 
       if (!content) return
 
-      fields.push(
-        <Col span={item.span || 12} key={index}>
-          <Form.Item label={label}>
-            {getFieldDecorator(item.field, {
-              initialValue: item.initval,
-              rules: item.rules
-            })(content)}
-          </Form.Item>
-        </Col>
-      )
+      if (item.help) {
+        fields.push(
+          <Col span={item.span || 12} key={index}>
+            <Form.Item label={label} help={<span style={{fontSize: '12px'}}>{item.help}</span>}>
+              {getFieldDecorator(item.field, {
+                initialValue: item.initval,
+                rules: item.rules
+              })(content)}
+            </Form.Item>
+          </Col>
+        )
+      } else {
+        fields.push(
+          <Col span={item.span || 12} key={index}>
+            <Form.Item label={label}>
+              {getFieldDecorator(item.field, {
+                initialValue: item.initval,
+                rules: item.rules
+              })(content)}
+            </Form.Item>
+          </Col>
+        )
+      }
     })
     
     return fields

--
Gitblit v1.8.0