-
Notifications
You must be signed in to change notification settings - Fork 129
Student Tutorial Self-Enrollment Feature #79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 9.x
Are you sure you want to change the base?
Student Tutorial Self-Enrollment Feature #79
Conversation
Task 1: Add tutorial self enrolment columns and indexes to task_defin…
…odel_update Student self enrolment active model update
…ty_update Student self enrolment api entity update
API Controller Implementation for student self enrolment
gauravmyana2002
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code looks good and all the features are working.
nouri-devv
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ran this code and it looks good.
ibi420
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, looking through this, it looks good, the code is well implemented and works as expected. Good job on this
Description
This PR implements a comprehensive Student Tutorial Self-Enrollment feature for the OnTrack/Doubtfire API, enabling students to self-enroll in tutorials for specific tasks. This feature enhances user autonomy and reduces administrative overhead while maintaining proper authorization and validation controls.
The implementation consists of four integrated components delivered through a systematic development approach:
1. Database Schema Foundation (Task 1)
20250912012227_add_tutorial_self_enrolment_to_task_definitions.rbtutorial_self_enrolment_enabled(boolean, default: false) - Feature toggle flagtutorial_self_enrolment_stream_id(foreign key to tutorial_streams) - Target stream for enrollment2. ActiveRecord Model Updates (Task 2)
TaskDefinition Model Enhancements:
tutorial_self_enrolment_streamself_enrolment_stream_unit_must_matchtutorial_self_enrolment_enabled?available_tutorials_for_self_enrolmentTutorialStream Model Updates:
Comprehensive Testing: Model validation tests ensure data integrity
3. API Entity Exposure (Task 3)
TaskDefinitionEntity Updates:
Frontend Integration: API entities provide necessary data for frontend implementation
Testing Coverage: API entity tests verify correct field exposure
4. Complete API Controller Implementation (Task 4)
New API Controller: StudentTutorialEnrolmentApi
TaskDefinitionsApi Updates:
Added support for tutorial_self_enrolment_enabled parameter
Added support for tutorial_self_enrolment_stream_abbr parameter
Enhanced upload_requirements handling with improved JSON parsing
Authorization & Validation:
Type of change
How Has This Been Tested?
Comprehensive Test Suite
Model Tests (
test/models/task_definition_test.rb,test/models/task_definition_self_enrolment_test.rb):API Tests (
test/api/student_tutorial_enrolment_api_test.rb,test/api/tasks_api_test.rb):Manual Testing
Database Migration: Successfully runs rails db:migrate with no conflicts
Checklist:
If you have any questions, please contact @macite or @jakerenzella.