Explorar o código

!1326 修复日程信息回显
Merge pull request !1326 from IMaster/next

zuohuaijun %!s(int64=2) %!d(string=hai) anos
pai
achega
41813ea2ba
Modificáronse 1 ficheiros con 9 adicións e 1 borrados
  1. 9 1
      Web/src/views/home/widgets/components/schedule.vue

+ 9 - 1
Web/src/views/home/widgets/components/schedule.vue

@@ -88,7 +88,7 @@ const handleQuery = async () => {
 // 按天查询
 const handleQueryByDate = async (date: any) => {
 	state.queryParams.startTime = FormatDateDelHMS(date);
-	state.queryParams.endTime = FormatDateDelHMS(date);
+	state.queryParams.endTime = FormatDateEndHMS(date);
 	let params = Object.assign(state.queryParams);
 	var res = await getAPI(SysScheduleApi).apiSysSchedulePagePost(params);
 	state.TodayScheduleData = res.data.result ?? [];
@@ -139,6 +139,14 @@ function FormatDateDelHMS(date: any) {
 	return newDate;
 }
 
+function FormatDateEndHMS(date: any) {
+	var newDate = new Date(date);
+	newDate.setHours(23);
+	newDate.setMinutes(59);
+	newDate.setSeconds(59);
+	return newDate;
+}
+
 // 格式化日期
 function FormatDate(date: any) {
 	return dayjs(date).format('YYYY-MM-DD');