Revert "달력에서 카테고리 필터 적용"

This reverts commit 0c278597c0.
This commit is contained in:
caadiq 2026-01-21 11:54:12 +09:00
parent 0c278597c0
commit f797736f8e
2 changed files with 4 additions and 10 deletions

View file

@ -686,13 +686,9 @@ function MobileSchedule() {
const day = String(date.getDate()).padStart(2, '0'); const day = String(date.getDate()).padStart(2, '0');
const dateStr = `${year}-${month}-${day}`; const dateStr = `${year}-${month}-${day}`;
// ( 3, ) // ( 3)
const daySchedules = schedules const daySchedules = schedules
.filter(s => { .filter(s => s.date?.split('T')[0] === dateStr)
const matchesDate = s.date?.split('T')[0] === dateStr;
const matchesCategory = selectedCategories.length === 0 || selectedCategories.includes(s.category_id);
return matchesDate && matchesCategory;
})
.slice(0, 3); .slice(0, 3);
return ( return (

View file

@ -804,13 +804,11 @@ function Schedule() {
const dayOfWeek = (firstDay + i) % 7; const dayOfWeek = (firstDay + i) % 7;
const isToday = new Date().toDateString() === new Date(year, month, day).toDateString(); const isToday = new Date().toDateString() === new Date(year, month, day).toDateString();
// ( , 3, ) // ( , 3)
const daySchedules = schedules.filter(s => { const daySchedules = schedules.filter(s => {
const scheduleDate = s.date ? s.date.split('T')[0] : ''; const scheduleDate = s.date ? s.date.split('T')[0] : '';
const dateStr = `${year}-${String(month + 1).padStart(2, '0')}-${String(day).padStart(2, '0')}`; const dateStr = `${year}-${String(month + 1).padStart(2, '0')}-${String(day).padStart(2, '0')}`;
const matchesDate = scheduleDate === dateStr; return scheduleDate === dateStr;
const matchesCategory = selectedCategories.length === 0 || selectedCategories.includes(s.category_id);
return matchesDate && matchesCategory;
}).slice(0, 3); }).slice(0, 3);
return ( return (