-
Notifications
You must be signed in to change notification settings - Fork 116
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
group pinned apps #996
group pinned apps #996
Conversation
#920 indicates configurable branding for these headers. This PR does not include that, but it can. |
So right now this groups by 100% of the time. #920 had the idea of in the pinned_apps configuration being able to specify a single But if |
OK, I'll add that. |
group pinned apps by a configuration allows the app admin to group pinned apps by some known field. This also allows for safety in that OodAppGroup#group_by now accounts for group_by methods that may exist creating a 'not groupable' group.
I've added the functionality to group by known fields (category, subcategory, owner etc). Metadata fields I can have in another PR. Note that this adds a new config |
</div> | ||
|
||
<%- if Configuration.pinned_apps_group_by.present? -%> | ||
<%= render(partial: "/dashboard/pinned_apps/group", collection: OodAppGroup.groups_for(apps: @pinned_apps, group_by: Configuration.pinned_apps_group_by.to_sym)) %> |
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.
Note the structure of these new files in views/dashboard/pinned_apps
(the pinned_apps being the new directory). I figure we're going to get a lot more views as time goes on. Just a heads up that there's a new directory.
Fixes #920
group pinned apps by their original category and add a heading for each section. This is essentially making the
dashboard#index
with pinned apps the same asapps#featured
(i.e., shared apps).It is slightly different in the way the widgets are arranged (how they interact with the MOTD and the XDMOD panels) but the partials to generate the rows in
app/views/dashboard/pinned_apps
are basically carbon copies of similar partials inapp/views/apps/
. (only these headings areh4
instead ofh2
)apps#featured
dashboard#index