feat: Implement Geolocation-Based Smart Attendance Verification (#3917)#3951
Open
knoxiboy wants to merge 1 commit into
Open
feat: Implement Geolocation-Based Smart Attendance Verification (#3917)#3951knoxiboy wants to merge 1 commit into
knoxiboy wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Is your feature request related to a problem? Please describe.
Students can mark attendance from outside the classroom, which makes proxy attendance possible and weakens trust in attendance records. This issue needs a geolocation gate so attendance can only be validated near the configured classroom location. (Resolves #3917)
Describe the solution you'd like
I added geolocation support to the attendance settings flow and normalized the backend schema so classroom location data can be stored and returned consistently. The attendance validation flow now uses a shared
useGeolocationhelper for current-position checks and distance calculations, keeping the client-side verification aligned with the backend settings payload.Describe alternatives you've considered
An alternative was to keep the geolocation logic entirely inside the attendance component, but extracting the shared helper makes the location behavior easier to reuse and keeps the validation flow easier to maintain.
Additional Context
The PR keeps the existing passcode-based validation intact and only adds the geolocation verification path plus the related settings persistence needed for the feature.