From 3fb80ac0f627d8776c2fe34e95b9e31a93513e71 Mon Sep 17 00:00:00 2001 From: cuiwenlong7 Date: Mon, 13 Dec 2021 11:05:44 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=97=B6=E9=97=B4=E6=88=B3string?= =?UTF-8?q?=E5=A4=84=E7=90=86=E4=B8=BAnumber=E6=A0=BC=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/tableColumns/datetime/index.tsx | 3 ++- src/components/tableColumns/datetimeRange/index.tsx | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/components/tableColumns/datetime/index.tsx b/src/components/tableColumns/datetime/index.tsx index 8c34006..672ec3e 100644 --- a/src/components/tableColumns/datetime/index.tsx +++ b/src/components/tableColumns/datetime/index.tsx @@ -27,7 +27,8 @@ export default class DatetimeColumn extends Column 0 && list.forEach((val: string, index: number) => { - rsValue += index < list.length - 1 ? `${moment(val).format(format)}${split}` : moment(val).format(format) + let _val = /^\d+$/.test(val) ? parseInt(val) : val + rsValue += index < list.length - 1 ? `${moment(_val).format(format)}${split}` : moment(_val).format(format) }) return rsValue -- Gitee