Closed briri closed 6 years ago
Added 3 predefined filters/scopes that work with pagination:
the filters are great @briri , but some behavior is wonky. first general comments:
things that don't work as expected:
when I click "Published" in both tabs as a Super Admin I get the expected list, but if I click the View all link to expand the list it seems to revert back to displaying All templates
as an Admin I should see 1 Published template (screenshot) for Univ of Edinburgh but it doesn't appear in the count or when I click "Published"
when I click "Unpublished" in both tabs I get a mixed list that appears to contain All templates, with published and unpublished things. It's a different list from "All" but I'm not sure what the logic is for displaying things here.
the counts are weird/incorrect for Funder templates (screenshot - there are obviously Published templates but the count is "0"). the numbers should be calculated regardless of my affiliation as a Super Admin.
Hi @stephaniesimms @briri. I don't remember discussing adding this functionality and I'm not sure that we should as it's a bit confusing and the validations seem buggy currently. In all other tables, the filters re-order what is in any given column or allow a search. Why are we doing something different here by adding additional published filters above? Would we not just be best to use the status column and search?
It seems that published templates are often being recorded as unpublished - e.g. all 18 funder templates showing as unpublished despite the status in the table saying 'published'. I'm also unclear where the status "Funder version is un-published" in Steph's screengrab 1 comes from. I don't recall ever seeing this label before. Is it new? It seems counter-intuitive to let an org customise an unpublished template so perhaps it's better to remove it from the table view when unpublished instead? Unless this is to give institutions access to a legacy customisation?
@stephaniesimms asks "we also need to clarify somehow that for Org Admins "Published/Unpublished" refers to their customizations on a funder template as opposed to the template status itself (screenshot). @sjDCC thoughts?" How did you get this view? I can't replicate it on my account so perhaps I need a secondary one that doesn't have super-admin privileges so I can view things as a standard org admin? I only see 'Org templates' and 'Funder templates' not a Customisation one. The funder tab doesn't give any customisation actions when I'm linked to a standard org - only template editing actions when my affiliation is one of the funders.
Looking at DMPonline, it seems the 3 statuses we have related to customisations currently are:
I think the easiest switch language wise (if the table accommodates it) is adding the word customisation i.e. "Customisation published" and "Customisation unpublished" Alternatively, we could have a note at the top of this table view denoting that the status refers to the institutional customisation, as all funder templates are published.
Given that the main utility of this feature is for super-admins with hundreds of templates to navigate, I'd focus on it post MVP and ensure the main features are ready for release instead. For standard admin users, they're never really having to browse through too many templates so shouldn't need this.
Hey @sjDCC and @stephaniesimms,
The filters are indeed a bit confusing (especially on the customizable tab) due in a large part to the current user's permission level. If the user is an Org Admin what constitutes as 'published'? Is it the customizations of those funder templates? Then what counts as published if the user is a super admin. The addition of the 'all templates' tab in #900 helps reduce the confusion there since the customizable table is no longer doing double duty.
I would suggest two options. A) wait until #900 has ben reviewed and deployed to see if the addition of the filters makes more sense (perhaps its only valuable on the all templates tab for example). B) Remove the filters and wait for the work being done on #815 to fix the sort/search functionality which will at least allow the results to be sorted by status thus grouping the published/unpublished templates together. Let us know how you want to proceed.
The "Funder version is un-published" status is indeed new, and deals with the scenario when a funder has no published version of a template (changing the publication status doesn't create a new version). If the org has already customized that template they would see this new status. This will be clearer once the 'All templates' tab is deployed.
Sounds good @briri Probably best for work to be done on both #900 and #815 then review what makes most sense here. If we can avoid having another way of filtering I'd prefer it for usability and consistency reasons, but being able to restrict the view to only published templates may be useful.
I agree that the 'all templates' tab in #900 should help. My understanding is that the status on the 'Customizable tab' should refer to the specific unis customisations, but it does raise a question of what status a super-admin sees. I guess we'll always see this page as a defined org or funder due the affiliation switcher. I was trying to figure out earlier what org I'd need to select to view pages as a super-admin, but I'm not sure there is one as you always need to edit as a specific org so that new content inherits this affiliation.
Thanks for clarifying the new "Funder version is unpublished" status. That makes sense if it's a legacy customisation as we don't want admins to lose access to any content they've added. It should probably always be superseded by "Original funder template has changed!" as they're likely to release a new version instead of unpublishing their templates completely, but good to have in case of that eventuality.
@sjDCC this was meant to be a simple usability improvement for the templates table - aimed at Super Admins but also DMPTool Org Admins who have to navigate 43+ funder templates. I didn't anticipate there would be so many complicating factors - my apologies for taking us down this rabbit hole - but I still think it's important for users to be able to quickly identify total numbers of templates and which are Published. I need as many cues as possible to remind me to take the action to publish.
many thanks to @briri and @xsrust for devising this approach. All Templates - Org Templates - Customizable Templates tabs for Super Admins is much easier for editing funder templates and creates more consistency between Org Admin and Super Admin template functionality. There does seem to be a persistent issue with the counts reflecting what is actually published or not (see screenshot).
And if it's easy to do @briri please modify the language at the top of the Customizable Templates table to say "All," "Customisation published," and "Customisation unpublished."
If problems persist, I'm happy to wait for the standardized table functionality to be implemented #815 - that should probably be sufficient for Org Admin users and we can revisit this post MVP for Super Admins.
Agree with @stephaniesimms that we need to modify the language on the "Customisable Templates" tab to make clear that what is (un)published is the customisation not the template.
It would be a very rare case when we present an unpublished funder template to the org-admins i.e. only if the funder unpublishes their template completely and doesn't replace it with a new version. When a new version of a funder template is released the customisation published status moves to "Original funder template has changed!" Effectively the customisation is still published and valid for any existing plans created with the old version of the funder template, but it won't be visible on the new version of the funder template until the user transfers it, check/edits as needed and republishes. See explanation of workflow in user guide
The three-tab approach looks much better now and is easy to navigate. I spotted two minor issues with this:
Funders shouldn't see the 'Customisable Templates' tab. It doesn't really make sense for them to add guidance and examples to other funder templates as they don't have their own users. The only exception to this might be the hybrid orgs like USGS and DOT, but their users are answering internal templates not other funder ones. And if I understand things right from #665 you've now decided to have two entries for these orgs?
Second very minor point is that I think unpublished should be one word not hyphenated. Is that right @stephaniesimms?
i agree w/ @sjDCC on above points. so to summarize @briri :
One remaining issue is that none of the filters at the top registers anything as "Published" - all are zero despite the tables containing published items:
Hi @stephaniesimms I didn't ask this question earlier, but how does a superadmin change their privileges to be an org admin. I assume we have to remove the additional permissions which, unless I'm missing something, would then mean we couldn't add them back on ourselves as we've effectively downgraded the account.
I've ensured I have two accounts - one as super admin and one as org admin for test / demo purposes. I change the org affiliation on the test account via superadmin controls as changing org directly from within this account will lose admin rights and mean they need to be regranted.
I think super admins should see the 'Customisable Templates' tab but only for the org they are affiliated with via the switcher above the table. If this is set as a normal org they'll see it, if it's set as a funder they won't. I'm not sure why we'd want to lose this?
No user, including Super Admins, is able to change their own privileges. The solution for us is to have separate accounts as you noted above, and this is what I do currently for DMPTool.
@briri noted that it may be easier to keep the Customizable templates tab anyway rather than introduce logic to display for Org Admin but not for Super Admin. in this case, Super Admins will be able to add customizations or change their org and edit others' customizations - I just couldn't imagine why I would ever need to do this but it sounds like it's better to keep it for the reasons you and brian raised.
The text change of un-published to unpublished seems to be fixed but all templates are still be recorded as unpublished in calculations
Quick update to this. I've just published one of the previously unpublished templates and now have: All (7) Published (1) Unpublished (6)
Do we need a rake task or some migration to ensure old values are recording properly?
this seems to be working now. closing issue.
Yes, great to see these working now - thanks @briri
If there's anything we need to do as part of the data migration to get this to work please flag it via a call or slack (and I guess we'd need to add instructions to migration path guidelines too)
Removing from board now
Once #815 is complete, Add 3 predefined filters above the funder and normal template tables on the templates page. The following filters should be clickable links that provide a record count and apply only to the specific table (similar to the screenshot below):