Improve school dashboard by adding roles and school code#873
Open
zetter-rpf wants to merge 2 commits into
Open
Improve school dashboard by adding roles and school code#873zetter-rpf wants to merge 2 commits into
zetter-rpf wants to merge 2 commits into
Conversation
d6de791 to
be3c457
Compare
Test coverage91.6% line coverage reported by SimpleCov. |
be3c457 to
7fbdca2
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR enhances the Administrate school dashboard to better support non-engineering support workflows by surfacing the school join code and showing key school roles (owner/teacher) with user details.
Changes:
- Added
code(join code) to the School dashboard index and show pages. - Added a custom
SchoolRolesField+ show partial to display owner/teacher roles in a table on the School show page. - Added a request spec covering role display (owner/teacher) and excluding student roles.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| spec/features/admin/schools_spec.rb | Adds request specs for the admin school show page to validate displayed roles. |
| app/views/fields/school_roles_field/_show.html.erb | New Administrate field partial that renders a roles table (role/user/created). |
| app/fields/school_roles_field.rb | New custom Administrate field defining displayed roles and rendering helpers. |
| app/dashboards/school_dashboard.rb | Surfaces code and roles in Administrate School index/show attributes. |
| app/controllers/admin/schools_controller.rb | Adds a helper to batch-fetch user info for roles and expose it to the field partial. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Make it easier to see who is a student and teacher for user support
We sometimes refer to schools by there code or want to send the code to teachers for students to use
7fbdca2 to
0648730
Compare
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.
What's changed?
This is to help us resolve common support queries without needing an engineer.