Skip to content

[FEATURE] Study Session Scheduling #9

@sahoo-tech

Description

@sahoo-tech

name: Feature request
about: Suggest an idea for this project
title: '[FEATURE] Study Session Scheduling'
labels: enhancement, feature
assignees: ''

📝 Feature Description

Add a Study Session Scheduling feature that allows users to schedule, manage, and track study sessions within study rooms. This feature will enable students to plan collaborative study time with their study partners, set reminders, and view upcoming sessions in a calendar format.

🎯 Problem Statement

Currently, StudyBuddy allows users to create/join study rooms and chat with other students, but there is no way to schedule actual study sessions. Students need to:

  • Coordinate study times outside the platform
  • Manually track when to meet with study partners
  • Have no visibility into upcoming study commitments

This limits the platform's effectiveness as a study partner coordination tool.

💡 Proposed Solution

Implement a comprehensive Study Session Scheduling system with the following components:

Core Features

Feature Description
Create Sessions Schedule study sessions with date, time, duration, and description
Session Management Update, cancel, and manage scheduled sessions
Calendar View Visual calendar showing upcoming study sessions
Session Reminders Email/in-app notifications before sessions start
Recurring Sessions Support for weekly/daily recurring study meetups
Session History Track past study sessions for progress awareness

Technical Implementation

1. New Model - StudySession

class StudySession(models.Model):
    room = models.ForeignKey(Room, on_delete=models.CASCADE, related_name='sessions')
    title = models.CharField(max_length=200)
    description = models.TextField(null=True, blank=True)
    scheduled_time = models.DateTimeField()
    duration = models.DurationField(default=timedelta(hours=1))
    created_by = models.ForeignKey(User, on_delete=models.CASCADE, related_name='created_sessions')
    attendees = models.ManyToManyField(User, related_name='attending_sessions', blank=True)
    is_recurring = models.BooleanField(default=False)
    recurrence_pattern = models.CharField(max_length=50, null=True, blank=True)  # daily, weekly, etc.
    created = models.DateTimeField(auto_now_add=True)
    updated = models.DateTimeField(auto_now=True)

2. New Views

  • createSession - Create a new study session
  • updateSession - Update session details
  • deleteSession - Cancel a session
  • sessionDetail - View session details and attendees
  • sessionCalendar - Calendar view of all sessions
  • mySession - User's upcoming sessions

3. New Templates

  • session_form.html - Create/edit session form
  • session_detail.html - Session details page
  • session_calendar.html - Calendar view
  • session_list.html - List of sessions
  • session_component.html - Reusable session card component

4. URL Routes

path('session/create/<str:pk>/', views.createSession, name='create-session'),
path('session/<str:pk>/', views.sessionDetail, name='session'),
path('session/update/<str:pk>/', views.updateSession, name='update-session'),
path('session/delete/<str:pk>/', views.deleteSession, name='delete-session'),
path('sessions/', views.sessionCalendar, name='sessions'),
path('my-sessions/', views.mySessions, name='my-sessions'),

📋 Tasks

Backend

  • Create StudySession model with all required fields
  • Create and run database migrations
  • Implement SessionForm for creating/editing sessions
  • Create views for session CRUD operations
  • Create view for calendar display
  • Add URL routes for all session-related endpoints
  • Add session-related methods to Room model (if needed)

Frontend

  • Create session_form.html template
  • Create session_detail.html template
  • Create session_calendar.html template with calendar UI
  • Create session_list.html for listing sessions
  • Create reusable session_component.html
  • Add session creation button to room page
  • Add "My Sessions" link to navigation
  • Style all new templates to match existing design

Integration

  • Add sessions display to room detail page
  • Add upcoming sessions to user profile
  • Add sessions count to home page activity

Notifications (Optional - Phase 2)

  • Configure email backend in settings
  • Create email templates for session reminders
  • Implement reminder notification system
  • Add in-app notification for upcoming sessions

Testing

  • Write unit tests for StudySession model
  • Write tests for session views
  • Write tests for session forms
  • Test calendar functionality

🔗 Additional Context

UI/UX Considerations

  • Calendar should be responsive and work on mobile devices
  • Session cards should show key info at a glance (time, room, attendees count)
  • Easy one-click join/leave for sessions
  • Color coding for different session statuses (upcoming, ongoing, past)

Dependencies

  • Consider using a JavaScript library like FullCalendar for the calendar view
  • May need django-celery for scheduled reminder notifications

Related Files

  • base/models.py - Add new StudySession model
  • base/views.py - Add new view functions
  • base/urls.py - Add new URL patterns
  • base/forms.py - Add SessionForm
  • base/templates/base/ - Add new templates

Priority

High - This is a core feature that directly supports the main purpose of StudyBuddy (helping students coordinate study sessions with partners).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions