This commit is contained in:
2025-09-25 17:39:03 +08:00
parent 4686812653
commit 19a51fc679
3 changed files with 413 additions and 312 deletions

View File

@@ -1,7 +1,7 @@
import React, { useState, useEffect } from "react";
import { View, Text, Button } from "@tarojs/components";
import Taro, { useDidShow } from "@tarojs/taro";
import dayjs from 'dayjs'
import dayjs from "dayjs";
import "./index.scss";
import { DialogCalendarCard } from "@/components/index";
@@ -40,6 +40,13 @@ const DownloadBill: React.FC = () => {
};
const selectDateRange = (range: string) => {
if (dateType === range) {
if (range === "custom") {
setVisible(true);
return;
}
return;
}
switch (range) {
case "week":
setDateType("week");
@@ -56,7 +63,9 @@ const DownloadBill: React.FC = () => {
break;
}
};
const [currentTimeValue, setCurrentTimeValue] = useState<Date | Date[]>(new Date());
const [currentTimeValue, setCurrentTimeValue] = useState<Date | Date[]>(
new Date()
);
const handleConfirm = (val: Date[]) => {
setCurrentTimeValue(val);
const [start, end] = val;