From 79e1455e4ba4f4a7d04a483dda1a354e53921a69 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期三, 04 十一月 2020 19:04:14 +0800 Subject: [PATCH] 2020-11-04 --- src/menu/components/card/data-card/index.jsx | 15 ++------------- 1 files changed, 2 insertions(+), 13 deletions(-) diff --git a/src/menu/components/card/data-card/index.jsx b/src/menu/components/card/data-card/index.jsx index 029154a..1b161aa 100644 --- a/src/menu/components/card/data-card/index.jsx +++ b/src/menu/components/card/data-card/index.jsx @@ -33,20 +33,9 @@ } UNSAFE_componentWillMount () { - const { card, menu } = this.props + const { card } = this.props if (card.isNew) { - let dataName = '' - - if (card.floor === 1) { - while (!dataName) { - let _dataName = Utils.getdataName() - if (menu.components.filter(com => com.dataName === _dataName).length === 0) { - dataName = _dataName - } - } - } - let subcards = null if (card.config) { @@ -87,7 +76,7 @@ format: 'array', // 缁勪欢灞炴�� - 鏁版嵁鏍煎紡 pageable: true, // 缁勪欢灞炴�� - 鏄惁鍙垎椤� switchable: true, // 缁勪欢灞炴�� - 鏁版嵁鏄惁鍙垏鎹� - dataName: dataName, + dataName: card.dataName || '', width: 24, name: card.name, subtype: card.subtype, -- Gitblit v1.8.0