From b69b5f6329ca5f87932436b7a6c1ddfc3377e10f Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 16 五月 2024 10:56:41 +0800
Subject: [PATCH] 2024-05-16

---
 src/menu/components/table/normal-table/columns/editColumn/formconfig.jsx |  265 +++++++++++++++++++++++++++++++++++++++-------------
 1 files changed, 198 insertions(+), 67 deletions(-)

diff --git a/src/menu/components/table/normal-table/columns/editColumn/formconfig.jsx b/src/menu/components/table/normal-table/columns/editColumn/formconfig.jsx
index e004eb9..6ad02d3 100644
--- a/src/menu/components/table/normal-table/columns/editColumn/formconfig.jsx
+++ b/src/menu/components/table/normal-table/columns/editColumn/formconfig.jsx
@@ -40,8 +40,17 @@
     value: 'number',
     text: '鏁板瓧'
   }, {
+    value: 'custom',
+    text: '鑷畾涔夊垪'
+  }, {
+    value: 'formula',
+    text: '鍏紡'
+  }, {
     value: 'picture',
     text: '鍥剧墖'
+  }, {
+    value: 'video',
+    text: '瑙嗛'
   }, {
     value: 'link',
     text: '閾炬帴'
@@ -49,26 +58,20 @@
     value: 'textarea',
     text: '澶氳鏂囨湰'
   }, {
-    value: 'custom',
-    text: '鑷畾涔夊垪'
-  }, {
     value: 'colspan',
     text: '鍚堝苟鍒�'
   }, {
-    value: 'formula',
-    text: '鍏紡'
+    value: 'extend',
+    text: '鎵╁睍鍒�'
   }, {
     value: 'index',
     text: '搴忓彿'
   }]
 
-  if (!card.isSub) {
-    options.push({
-      value: 'action',
-      text: '鎿嶄綔'
-    })
+  if (appType === 'mob') {
+    options = options.filter(item => item.value !== 'extend')
   }
-
+  
   if (!card.linkurl && (!card.linkmenu || card.linkmenu.length === 0)) {
     card.perspective = ''
   }
@@ -102,6 +105,8 @@
       key: 'nameField',
       label: '鍚嶇О瀛楁',
       initVal: card.nameField || '',
+      tooltip: '鍚嶇О瀛楁涓洪摼鎺ュ湪鐣岄潰涓樉绀虹殑鍐呭锛屽湪閾炬帴涓互@***@褰㈠紡鎷兼帴鐨勫瓧娈碉紙瀛楁鏉ユ簮浜庡瓧娈甸泦涓紝姝ゅ id銆乤ppkey銆乽serid銆丩oginUID 涓虹郴缁熷瓧娈碉級锛岃烦杞椂灏嗘浛鎹负瀵瑰簲鍊硷紝渚嬪锛歨ttp://sso.mk9h.cn/doc/index.html?appkey=@appkey@&LoginUID=@LoginUID@锛屽叾涓璦ppkey涓嶭oginUID灏嗚鏇挎崲銆�',
+      toolWidth: 350,
       required: false,
       options: [{uuid: 'empty', field: '', label: '绌�'}, ...fields]
     },
@@ -114,20 +119,6 @@
       label: '鍒楀',
       initVal: card.Width || 120,
       required: true
-    },
-    {
-      type: 'radio',
-      key: 'joint',
-      label: '鎷兼帴鍙傛暟',
-      initVal: card.joint || 'true',
-      required: true,
-      options: [{
-        value: 'true',
-        text: '鏄�'
-      }, {
-        value: 'false',
-        text: '鍚�'
-      }]
     },
     {
       type: 'radio',
@@ -147,7 +138,7 @@
       type: 'radio',
       key: 'IsSort',
       label: '鎺掑簭',
-      initVal: card.IsSort || (card.isSub ? 'false' : 'true'),
+      initVal: card.IsSort || (card.isSub || card.type === 'custom' ? 'false' : 'true'),
       required: true,
       options: [{
         value: 'true',
@@ -155,6 +146,32 @@
       }, {
         value: 'false',
         text: '鍚�'
+      }]
+    },
+    {
+      type: 'select',
+      key: 'sortField',
+      label: '鎺掑簭瀛楁',
+      initVal: card.sortField || '',
+      required: true,
+      options: fields
+    },
+    {
+      type: 'radio',
+      key: 'eval',
+      label: '瑙f瀽鏂瑰紡',
+      initVal: card.eval || 'false',
+      tooltip: '褰撳叕寮忓唴瀹规秹鍙婅绠楁椂璇烽�夋嫨鈥滆绠椻�濓紝褰撳叕寮忓唴瀹逛负瀛楁鎷兼帴鏃惰閫夋嫨鈥滃瓧娈垫浛鎹⑩�濓紝浣跨敤鍑芥暟鏃跺叆鍙備负data锛堟暟缁勶級銆�',
+      required: false,
+      options: [{
+        value: 'false',
+        text: '瀛楁鏇挎崲'
+      }, {
+        value: 'true',
+        text: '璁$畻'
+      }, {
+        value: 'func',
+        text: '鍑芥暟'
       }]
     },
     {
@@ -176,25 +193,119 @@
     },
     {
       type: 'radio',
+      key: 'colUnit',
+      label: '鍗曚綅',
+      initVal: card.colUnit || 'day',
+      required: true,
+      options: [{
+        value: 'day',
+        text: '澶�'
+      }, {
+        value: 'hour',
+        text: '灏忔椂'
+      }]
+    },
+    {
+      type: 'number',
+      key: 'shift',
+      label: '鍋忕Щ閲�',
+      initVal: card.shift || 0,
+      min: -1000,
+      max: 1000,
+      decimal: 0,
+      required: true
+    },
+    {
+      type: 'number',
+      key: 'quota',
+      label: '鎸囨爣鏁�',
+      initVal: card.quota || 7,
+      min: 1,
+      max: 1000,
+      decimal: 0,
+      required: true
+    },
+    {
+      type: 'select',
+      key: 'dayFormat',
+      label: '鏍煎紡鍖�',
+      initVal: card.dayFormat || 'M/DD',
+      required: true,
+      options: [{
+        value: 'M/DD',
+        label: 'M/DD锛�4/29锛�'
+      }, {
+        value: 'M-DD',
+        label: 'M-DD锛�4-29锛�'
+      }, {
+        value: 'M鏈圖D鏃�',
+        label: 'M鏈圖D鏃ワ紙4鏈�29鏃ワ級'
+      }, {
+        value: 'M/DD week',
+        label: 'M/DD week锛�4/29 鏄熸湡涓�锛�'
+      }, {
+        value: 'M-DD week',
+        label: 'M-DD week锛�4-29 鏄熸湡涓�锛�'
+      }, {
+        value: 'M鏈圖D鏃� week',
+        label: 'M鏈圖D鏃� week锛�4鏈�29鏃� 鏄熸湡涓�锛�'
+      }]
+    },
+    {
+      type: 'select',
+      key: 'hourFormat',
+      label: '鏍煎紡鍖�',
+      initVal: card.hourFormat || 'H:00',
+      required: true,
+      options: [{
+        value: 'H:00',
+        label: 'H:00锛�15:00锛�'
+      }, {
+        value: 'H point',
+        label: 'H锛�15鐐癸級'
+      }, {
+        value: 'h:00',
+        label: 'h:00锛�3:00 pm锛�'
+      }]
+    },
+    {
+      type: 'text',
+      key: 'supField',
+      label: '涓婄骇瀛楁',
+      initVal: card.supField || '',
+      tooltip: '鏉ユ簮浜庝笂绾х粍浠剁殑瀛楁闆嗭紙涓婄骇缁勪欢涓虹┖鏃朵粠url鍙傛暟涓�夊彇锛夛紝璇ュ瓧娈靛�硷紙鐢ㄩ�楀彿鍒嗛殧锛夊彲鎺у埗鎵╁睍鍒楃殑鍒楀悕銆�',
+      required: false,
+      rules: [{
+        pattern: /^[0-9a-zA-Z_]*$/ig,
+        message: '瀛楁鍚嶅彧鍏佽鍖呭惈鏁板瓧銆佸瓧姣嶄互鍙奯'
+      }]
+    },
+    {
+      type: 'number',
+      key: 'startTime',
+      precision: 0,
+      label: '寮�濮嬫椂闂�',
+      initVal: card.startTime || 0,
+      tooltip: '瑙嗛寮�濮嬫挱鏀剧殑鏃堕棿锛岀敤浜庤皟鏁磋棰戝垵濮嬪寲灞曠ず鐨勭晫闈€��',
+      required: false
+    },
+    {
+      type: 'select',
+      key: 'aspectRatio',
+      label: '闀垮姣�',
+      initVal: card.aspectRatio || '16:9',
+      required: true,
+      options: [
+        { value: '4:3', text: '4:3' },
+        { value: '16:9', text: '16:9' }
+      ]
+    },
+    {
+      type: 'radio',
       key: 'rowspan',
       label: '琛屽悎骞�',
       initVal: card.rowspan || 'false',
       tooltip: '鐩搁偦琛屼俊鎭浉鍚屾椂锛屽崟鍏冩牸鍚堝苟銆�',
-      required: false,
-      options: [{
-        value: 'true',
-        text: '鏄�'
-      }, {
-        value: 'false',
-        text: '鍚�'
-      }]
-    },
-    {
-      type: 'radio',
-      key: 'sum',
-      label: '鏄剧ず鍚堣',
-      initVal: card.sum || 'false',
-      tooltip: '鍚堣淇℃伅鍙湪浣跨敤绯荤粺鏁版嵁婧愭椂鏈夋晥銆�',
       required: false,
       options: [{
         value: 'true',
@@ -211,7 +322,7 @@
       max: 18,
       decimal: 0,
       label: '灏忔暟浣�',
-      initVal: card.decimal || 0,
+      initVal: card.decimal,
       required: false
     },
     {
@@ -308,6 +419,18 @@
     },
     {
       type: 'radio',
+      key: 'backgroundSize',
+      label: '鍥惧儚澶у皬',
+      initVal: card.backgroundSize || 'cover',
+      required: false,
+      options: [
+        { value: 'cover', text: '瑕嗙洊' },
+        { value: 'contain', text: '鍖呭惈' },
+        { value: 'auto', text: '鑷�傚簲' },
+      ]
+    },
+    {
+      type: 'radio',
       key: 'scale',
       label: '鐐瑰嚮缂╂斁',
       initVal: card.scale || 'true',
@@ -319,6 +442,18 @@
         value: 'false',
         text: '鍚�'
       }]
+    },
+    {
+      type: 'radio',
+      key: 'lostTip',
+      label: '鍥剧墖缂哄け',
+      initVal: card.lostTip || 'true',
+      tooltip: '鍥剧墖鍦板潃涓嶅瓨鍦ㄦ椂锛屾槸鍚︽彁绀哄浘鐗囦涪澶便��',
+      required: false,
+      options: [
+        { value: 'true', text: '鎻愮ず' },
+        { value: 'false', text: '涓嶆彁绀�' }
+      ]
     },
     {
       type: 'radio',
@@ -335,7 +470,7 @@
         value: 'linkurl',
         text: '閾炬帴'
       }],
-      forbidden: appType === 'mob'
+      forbid: appType === 'mob'
     },
     {
       type: appType === 'pc' ? 'select' : 'cascader',
@@ -344,24 +479,17 @@
       initVal: card.linkmenu || (appType === 'pc' ? '' : []),
       required: true,
       options: menulist,
-      forbidden: appType === 'mob'
+      forbid: appType === 'mob'
     },
     {
       type: 'textarea',
       key: 'linkurl',
       label: '閾炬帴鍦板潃',
       initVal: card.linkurl || '',
+      tooltip: '鍦ㄩ摼鎺ヤ腑浠***@褰㈠紡鎷兼帴鐨勫瓧娈碉紙瀛楁鏉ユ簮浜庡瓧娈甸泦涓紝姝ゅ id銆乤ppkey銆乽serid銆丩oginUID 涓虹郴缁熷瓧娈碉級锛岃烦杞椂灏嗘浛鎹负瀵瑰簲鍊硷紝渚嬪锛歨ttp://sso.mk9h.cn/doc/index.html?appkey=@appkey@&LoginUID=@LoginUID@锛屽叾涓璦ppkey涓嶭oginUID灏嗚鏇挎崲銆�',
+      toolWidth: 350,
       required: true,
-      forbidden: appType === 'mob'
-    },
-    {
-      type: 'multiselect',
-      key: 'linkfields',
-      label: '鍏宠仈瀛楁',
-      initVal: card.linkfields || [],
-      required: false,
-      options: fields,
-      forbidden: appType === 'mob'
+      forbid: appType === 'mob'
     },
     {
       type: 'radio',
@@ -376,18 +504,6 @@
       ]
     },
     {
-      type: 'radio',
-      key: 'eval',
-      label: '瑙f瀽',
-      initVal: card.eval || 'true',
-      tooltip: '褰撳叕寮忓唴瀹规秹鍙婅绠楁椂璇烽�夋嫨鈥滄槸鈥濓紝褰撳叕寮忓唴瀹逛负瀛楁鎷兼帴鏃惰閫夋嫨鈥滃惁鈥濄��',
-      required: false,
-      options: [
-        { value: 'true', text: '鏄�' },
-        { value: 'false', text: '鍚�' }
-      ]
-    },
-    {
       type: 'textarea',
       key: 'formula',
       label: '鍏紡',
@@ -397,13 +513,28 @@
       required: true
     },
     {
+      type: 'radio',
+      key: 'noValue',
+      label: '绌哄��',
+      initVal: card.noValue || 'show',
+      tooltip: '鏁板�间负 0 鎴栨椂闂村皬浜� 1949-10-02 鏃讹紝鏄惁鏄剧ず',
+      required: false,
+      options: [{
+        value: 'show',
+        text: '鏄剧ず'
+      }, {
+        value: 'hide',
+        text: '闅愯棌'
+      }]
+    },
+    {
       type: 'multiselect',
       key: 'blacklist',
       label: '榛戝悕鍗�',
       initVal: card.blacklist || [],
       required: false,
       options: roleList,
-      forbidden: appType === 'mob'
+      forbid: appType === 'mob'
     }
   ]
 }

--
Gitblit v1.8.0