From 03a22ec6f9ad7303d10b4c65bb5bc6fa5cbd448a Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期六, 22 十月 2022 23:21:42 +0800
Subject: [PATCH] 2022-10-22

---
 src/menu/components/card/cardcellcomponent/formconfig.jsx |   16 +++++++++++++---
 1 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/src/menu/components/card/cardcellcomponent/formconfig.jsx b/src/menu/components/card/cardcellcomponent/formconfig.jsx
index 02e8d29..4e0739a 100644
--- a/src/menu/components/card/cardcellcomponent/formconfig.jsx
+++ b/src/menu/components/card/cardcellcomponent/formconfig.jsx
@@ -1,9 +1,11 @@
+import MenuUtils from '@/utils/utils-custom.js'
+
 /**
  * @description 鑾峰彇鍏冪礌閰嶇疆淇℃伅
  * @param {*} card
  * @param {*} type
  */
-export function getCardCellForm (card, type, subtype, cardCell, anchors) {
+export function getCardCellForm (card, cards, cardCell) {
   let _options = [
     { value: 'text', text: '鏂囨湰'},
     { value: 'number', text: '鏁板��'},
@@ -18,7 +20,14 @@
     { value: 'formula', text: '鍏紡'},
   ]
 
-  if (type === 'table' || (type === 'card' && subtype === 'datacard')) {
+  let anchors = []
+  if (window.GLOB.customMenu.Template === 'BaseTable') {
+    anchors = null
+  } else {
+    anchors = MenuUtils.getAnchors(window.GLOB.customMenu.components, cards.uuid) || []
+  }
+
+  if (cards.type === 'table' || (cards.type === 'card' && cards.subtype === 'datacard')) {
     _options.push({value: 'sequence', text: '搴忓彿'})
   } else if (card.eleType === 'sequence') { // 鎷栨嫿娣诲姞绫诲瀷杞崲
     card.eleType = 'text'
@@ -364,7 +373,8 @@
       initVal: card.anchors || [],
       tooltip: sessionStorage.getItem('appType') === 'mob' ? '娉細灏忕▼搴忎腑鏃犳晥' : '',
       required: false,
-      options: anchors
+      options: anchors,
+      forbid: !anchors
     },
     {
       type: 'number',

--
Gitblit v1.8.0