update scheduling

This commit is contained in:
salirezav
2025-09-19 12:46:03 -04:00
parent 4e0e9f9d3f
commit 0ba385eebc

View File

@@ -434,7 +434,7 @@ function AvailabilityCalendar({ user }: { user: User }) {
const newEvent = { const newEvent = {
id: Date.now(), id: Date.now(),
title: newTimeSlot.title, title: 'Available',
start: startDateTime, start: startDateTime,
end: endDateTime, end: endDateTime,
resource: 'available' resource: 'available'
@@ -476,10 +476,6 @@ function AvailabilityCalendar({ user }: { user: User }) {
<div className="w-3 h-3 bg-green-500 rounded mr-2"></div> <div className="w-3 h-3 bg-green-500 rounded mr-2"></div>
<span className="text-sm text-gray-600 dark:text-gray-400">Available</span> <span className="text-sm text-gray-600 dark:text-gray-400">Available</span>
</div> </div>
<div className="flex items-center">
<div className="w-3 h-3 bg-red-500 rounded mr-2"></div>
<span className="text-sm text-gray-600 dark:text-gray-400">Unavailable</span>
</div>
</div> </div>
</div> </div>
@@ -541,18 +537,6 @@ function AvailabilityCalendar({ user }: { user: User }) {
/> />
</div> </div>
<div>
<label className="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2">
Description (Optional)
</label>
<input
type="text"
value={newTimeSlot.title}
onChange={(e) => setNewTimeSlot({ ...newTimeSlot, title: e.target.value })}
placeholder="e.g., Available - Morning, Available - Afternoon"
className="w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-blue-500 dark:bg-gray-700 dark:text-white"
/>
</div>
</div> </div>
{/* Show existing time slots for this date */} {/* Show existing time slots for this date */}
@@ -597,7 +581,8 @@ function AvailabilityCalendar({ user }: { user: User }) {
startAccessor="start" startAccessor="start"
endAccessor="end" endAccessor="end"
style={{ height: '100%' }} style={{ height: '100%' }}
defaultView={Views.MONTH} view={currentView}
onView={setCurrentView}
views={[Views.MONTH, Views.WEEK, Views.DAY]} views={[Views.MONTH, Views.WEEK, Views.DAY]}
selectable selectable
onSelectSlot={handleSelectSlot} onSelectSlot={handleSelectSlot}