From f446297dca0a087b55adb51ecc585bba0884074b Mon Sep 17 00:00:00 2001 From: luyuan <1162963624@qq.com> Date: Wed, 14 Oct 2020 09:10:40 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=97=A5=E5=8E=86=E8=BF=94?= =?UTF-8?q?=E5=9B=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/date.ts | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/src/utils/date.ts b/src/utils/date.ts index 36d0dbe..06c18c9 100644 --- a/src/utils/date.ts +++ b/src/utils/date.ts @@ -1,6 +1,19 @@ import dayjs from 'dayjs' -export function getdate(yue?: number){ +interface Date{ + day?: number; + list?: Array; +} + +interface GetDate{ + date: Array>; + year: number; + yue: number; + day: number; + zhou: number; +} + +export function getdate(yue?: number): GetDate{ let now = dayjs() if(yue != undefined){ now = now.month(now.month() + yue); @@ -19,10 +32,7 @@ export function getdate(yue?: number){ let i = 0; let w = 0; - interface Date{ - day?: number; - list?: Array; - } + const date: Array> = [[]]; while(i < month){