From 5223edbcccfed84a33a706e5637ee65a61f377aa Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 22 十二月 2021 18:00:39 +0800
Subject: [PATCH] 2021-12-22

---
 src/menu/components/share/actioncomponent/formconfig.jsx |   73 +++++++++++++++++++++++++++++-------
 1 files changed, 58 insertions(+), 15 deletions(-)

diff --git a/src/menu/components/share/actioncomponent/formconfig.jsx b/src/menu/components/share/actioncomponent/formconfig.jsx
index 388b4f9..9ee1698 100644
--- a/src/menu/components/share/actioncomponent/formconfig.jsx
+++ b/src/menu/components/share/actioncomponent/formconfig.jsx
@@ -82,7 +82,7 @@
   const isApp = ['pc', 'mob'].includes(appType)
 
   let funTypes = [
-    { value: 'changeuser', text: Formdict['header.form.func.changeuser'] },
+    { value: 'changeuser', text: '鍒囨崲鐢ㄦ埛' },
     { value: 'print', text: '鏍囩鎵撳嵃' },
     { value: 'closetab', text: '鏍囩鍏抽棴' },
   ]
@@ -106,7 +106,7 @@
         { value: 'logout', text: '閫�鍑�' },
         { value: 'mkBinding', text: '寮�閫氭壂鐮佺櫥褰�' },
         { value: 'mkUnBinding', text: '鐢ㄦ埛瑙g粦' },
-        { value: 'reAuth', text: '鍒囨崲绯荤粺' },
+        { value: 'reAuth', text: '鍒囨崲绯荤粺锛堟竻绌虹紦瀛�-灏忕▼搴忥級' },
         { value: 'goBack', text: '杩斿洖' },
       ]
       pageTemps = [
@@ -122,7 +122,7 @@
         { value: 'custom', text: '閾炬帴' }
       ]
       funTypes = [
-        { value: 'changeuser', text: Formdict['header.form.func.changeuser'] },
+        { value: 'changeuser', text: '鍒囨崲鐢ㄦ埛' },
       ]
       opentypes = opentypes.filter(item => item.value !== 'tab')
     }
@@ -136,7 +136,11 @@
   if (viewType === 'popview') { // 寮圭獥鏍囩
     opentypes = opentypes.filter(item => item.value !== 'popview' && item.value !== 'funcbutton')
     refresh.push({
-      value: 'popclose',
+      value: 'closepoptab', // 鍏抽棴寮圭獥鏍囩
+      text: '鍏抽棴寮圭獥'
+    })
+    refresh.push({
+      value: 'popclose',  // 鎵ц寮圭獥鍏抽棴鏃剁殑鍒锋柊
       text: '鍒锋柊婧愮粍浠�'
     })
   }
@@ -157,7 +161,7 @@
     {
       type: 'select',
       key: 'funcType',
-      label: Formdict['header.form.funcType'],
+      label: '鍔熻兘绫诲瀷',
       initVal: card.funcType || '',
       required: true,
       options: funTypes
@@ -360,9 +364,8 @@
       type: 'select',
       key: 'Ot',
       label: Formdict['header.form.isRequired'],
-      initVal: card.Ot || 'requiredSgl',
+      initVal: card.Ot || (card.sqlType === 'insert' ? 'notRequired' : 'requiredSgl'),
       required: true,
-      forbid: card.$type === 'tableButton',
       options: []
     },
     {
@@ -395,7 +398,7 @@
         text: '鍒锋柊涓婄骇缁勪欢 - 琛�'
       }, {
         value: !appType ? 'closetab' : 'goback',
-        text: !appType ? '鍏抽棴寮圭獥' : '杩斿洖锛堜笂涓�涓〉闈級'
+        text: !appType ? '鍏抽棴鏍囩' : '杩斿洖锛堜笂涓�涓〉闈級'
       },
       ...refresh]
     },
@@ -470,6 +473,7 @@
       label: '鏄剧ず涓�',
       initVal: card.show || 'button',
       required: true,
+      forbid: type === 'datacard' && appType === 'mob', // 绉诲姩绔紝婊戝姩鏄剧ず鐨勬寜閽彧鏄剧ず鏂囧瓧
       options: [{
         value: 'icon',
         text: '鍥炬爣'
@@ -485,13 +489,13 @@
       type: 'radio',
       key: 'swipe',
       label: "婊戝姩鏄剧ず",
-      initVal: card.swipe || 'false',
+      initVal: card.swipe === 'false' ? 'left' : (card.swipe || 'left'), // 绉诲姩绔粎淇濈暀婊戝姩鏄剧ず鎸夐挳
       required: false,
       forbid: (type !== 'datacard' || appType !== 'mob'),
       options: [{
-        value: 'false',
-        text: '鍚�'
-      }, {
+      //   value: 'false',
+      //   text: '鍚�'
+      // }, {
         value: 'left',
         text: '宸︽粦'
       }, {
@@ -505,6 +509,7 @@
       label: Formdict['model.icon'],
       initVal: card.icon,
       required: false,
+      forbid: type === 'datacard' && appType === 'mob', // 绉诲姩绔紝婊戝姩鏄剧ず鐨勬寜閽彧鏄剧ず鏂囧瓧
       options: []
     },
     {
@@ -514,7 +519,32 @@
       initVal: card.class,
       tooltip: '姝ら鑹蹭负鎸夐挳鍒濆鍖栭鑹诧紝鍙湪鏍峰紡璋冩暣涓慨鏀广��',
       required: false,
+      forbid: type === 'datacard' && appType === 'mob', // 绉诲姩绔紝婊戝姩鏄剧ず鐨勬寜閽笉璁剧疆閫氱敤棰滆壊
       options: []
+    },
+    {
+      type: 'radio',
+      key: 'color',
+      label: Formdict['model.form.color'],
+      initVal: card.color || 'primary',
+      required: false,
+      forbid: (type !== 'datacard' || appType !== 'mob'), // 绉诲姩绔紝婊戝姩鏄剧ず鐨勬寜閽彧鍙缃浐瀹氶鑹�
+      options: [{
+        value: 'primary',
+        text: '钃�'
+      }, {
+        value: 'danger',
+        text: '绾�'
+      }, {
+        value: 'warning',
+        text: '姗�'
+      }, {
+        value: 'success',
+        text: '缁�'
+      }, {
+        value: 'light',
+        text: '鐏�'
+      }]
     },
     {
       type: 'radio',
@@ -540,7 +570,7 @@
     {
       type: 'radio',
       key: 'pagination',
-      label: Formdict['header.form.pagination'],
+      label: '鍒嗛〉',
       initVal: card.pagination || 'false',
       required: false,
       options: [{
@@ -570,7 +600,7 @@
       key: 'syncComponent',
       label: '鍒锋柊缁勪欢',
       initVal: card.syncComponent || [],
-      tooltip: '鎵ц鎴愬姛鍚庯紝闇�瑕佸悓姝ュ埛鏂扮殑缁勪欢',
+      tooltip: '鎵ц鎴愬姛鍚庯紙鎴栧脊绐楁爣绛惧叧闂椂锛夛紝闇�瑕佸悓姝ュ埛鏂扮殑缁勪欢',
       required: false,
       options: modules
     },
@@ -667,7 +697,6 @@
       key: 'placement',
       label: '鎶藉眽鏂瑰悜',
       initVal: card.placement || 'right',
-      tooltip: '浣跨敤鎶藉眽鏃舵湁鏁堛��',
       required: false,
       options: [{
         value: 'right',
@@ -685,6 +714,20 @@
     },
     {
       type: 'radio',
+      key: 'clickouter',
+      label: '鐐瑰嚮钂欏眰',
+      initVal: card.clickouter || 'unclose',
+      required: false,
+      options: [{
+        value: 'unclose',
+        text: '涓嶅叧闂�'
+      }, {
+        value: 'close',
+        text: '鍏抽棴'
+      }]
+    },
+    {
+      type: 'radio',
       key: 'reload',
       label: '杩斿洖鍚�',
       initVal: card.reload || 'false',

--
Gitblit v1.8.0