From 7051e15582aee4163b3c8dd13dc85f4f1e2ce6eb Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 07 二月 2020 02:11:43 +0800 Subject: [PATCH] 2020-02-07 --- src/templates/comtableconfig/index.jsx | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/src/templates/comtableconfig/index.jsx b/src/templates/comtableconfig/index.jsx index 8d41a7a..9946b3d 100644 --- a/src/templates/comtableconfig/index.jsx +++ b/src/templates/comtableconfig/index.jsx @@ -1338,6 +1338,8 @@ // 鏈缃暟鎹簮鎴栨爣绛句笉鍚堟硶鏃讹紝鍚敤鐘舵�佷负false if (_config.setting.interType === 'inner' && !_config.setting.innerFunc && !_config.setting.dataresource) { _config.enabled = false + } else if (!_config.setting.primaryKey) { + _config.enabled = false } else if (_config.tabgroups.length > 1) { _config.tabgroups.forEach(group => { if (_config[group].length === 0) { @@ -2138,6 +2140,12 @@ message: '鑿滃崟灏氭湭璁剧疆鏁版嵁婧愶紝涓嶅彲鍚敤锛�', duration: 10 }) + } else if (!config.setting.primaryKey) { + notification.warning({ + top: 92, + message: '鑿滃崟灏氭湭璁剧疆涓婚敭锛屼笉鍙惎鐢紒', + duration: 10 + }) } else if (!tabinvalid) { notification.warning({ top: 92, -- Gitblit v1.8.0