From 69d23c6f69dd416351b8e143297a80000333ed74 Mon Sep 17 00:00:00 2001 From: zhulj <1643600218@qq.com> Date: Wed, 18 Sep 2024 15:48:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D:=20=E6=9B=B4=E6=96=B0import?= =?UTF-8?q?=5Fexport.py=E4=BB=A5=E8=BF=87=E6=BB=A4=E7=A9=BA=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/dvadmin/utils/import_export.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/dvadmin/utils/import_export.py b/backend/dvadmin/utils/import_export.py index 2bd6e1e8a5..a3bccd95e6 100644 --- a/backend/dvadmin/utils/import_export.py +++ b/backend/dvadmin/utils/import_export.py @@ -86,4 +86,5 @@ def import_to_data(file_url, field_data, m2m_fields=None): else: array[key] = cell_value tables.append(array) - return tables + data = [i for i in tables if len(i) != 0] + return data -- Gitee