admin/index currently only shows some admin links, not all of them, making it not really an index. It's also visually extremely similar to admin/config which has had me confused a couple of times.

We absolutely need to do #652122: Fix dashboard as the default /admin local task in the default profile. But for people without dashboard module enabled, it'd be nice for this page to be useful. I'd almost lean towards making it an alphabetical list of every link under admin - i.e. skip the categorization and just have a compact list you can very quickly scan down - since the categorization is handled by admin/config and the other top level categories.

Marking this critical because at the moment, admin/index vs admin/config is a huge and as far as I know untested wtf. afaik admin/index was only supposed to stick around until the dashboard got in, but it's still there. Also becuase I'm about to mark #672252: Restore sanity to the admin menu structure as a duplicate of the sub-issues.

CommentFileSizeAuthor
#307 Desk 1_015.png49.95 KBcatch
#307 Desk 1_014.png17.45 KBcatch
#307 699858-admin-index.patch39.22 KBcatch
#303 admin_index_699848_303.patch38.5 KBDavid_Rothstein
#303 interdiff.286.303.txt9.17 KBDavid_Rothstein
#303 admin-index-all-modules.png318.06 KBDavid_Rothstein
#294 Administration-bartik.png30.82 KBaspilicious
#294 Index-bartik.png66.01 KBaspilicious
#294 Administration-seven.png14 KBaspilicious
#294 Index-seven.png38.82 KBaspilicious
#293 admin_index.jpg224.08 KBbojanz
#293 admin_tasks.jpg50.27 KBbojanz
#289 admin_index_699848_289.patch35.65 KBmfer
#288 admin-index.png318.06 KBDavid_Rothstein
#287 admin-index.png107.3 KBsteinmb
#287 admin-task.png69.22 KBsteinmb
#286 drupal.system-list.286.patch38.67 KBsun
#285 drupal.system-list.285.patch38.67 KBsun
#279 admin_index.jpg459.73 KBbojanz
#279 admin_config.jpg184.35 KBbojanz
#279 admin.jpg70.51 KBbojanz
#277 drupal.system-index.275.patch40.58 KBsun
#271 drupal.system-index.271.patch39.91 KBsun
#267 drupal.system-index.266.patch39.13 KBsun
#265 dashboard.png28.19 KBbojanz
#264 drupal.system-index.264.patch37.07 KBsun
#263 drupal.system-index.262.patch37.07 KBsun
#261 drupal.system-index.259.patch36.27 KBsun
#260 admin.png232.46 KBmikey_p
#260 admin-index.jpeg722.02 KBmikey_p
#260 admin-config.png965.34 KBmikey_p
#258 admin.png73.1 KBbojanz
#258 admin_config_1.png125.22 KBbojanz
#258 admin_config_2.png136.86 KBbojanz
#258 admin_index_1.png108.49 KBbojanz
#258 admin_index_2.png115.51 KBbojanz
#258 admin_index_3.png85.8 KBbojanz
#258 admin_index_4.png92.63 KBbojanz
#258 admin_index_5.png122.65 KBbojanz
#258 admin_index_6.png115.21 KBbojanz
#258 admin_index_7.png69.99 KBbojanz
#258 admin_index_8.png71.61 KBbojanz
#256 drupal.system-index.256.patch33.45 KBsun
#248 drupal.system-index.248.patch33.83 KBsun
#243 drupal.system-index.243.patch33.96 KBsun
#241 drupal.system-index.241.patch33.96 KBsun
#238 admin-index-699848-238-FAIL.patch25.57 KBDavid_Rothstein
#238 admin-index-699848-238-PASS.patch26.61 KBDavid_Rothstein
#235 drupal.system-index.235.patch34.4 KBsun
#233 drupal.system-index.233.patch34.41 KBsun
#231 drupal.system-index.231.patch30.56 KBsun
#228 drupal.system-index.228.patch30.48 KBsun
#227 699848.patch20.12 KBbojanz
#222 699848.patch19.56 KBbojanz
#222 screenshot.png81.88 KBbojanz
#219 admin-index-699848-200.patch18.1 KBronald_istos
#217 admin-index-699848-199.patch18.03 KBronald_istos
#209 admin-index-699848-198.patch18.23 KBronald_istos
#197 admin-index-699848-197.patch20.39 KBDavid_Rothstein
#196 adminadminadmin.png192.07 KByoroy
#195 ehhisthiswhatwewant.png89.99 KBBojhan
#193 admin-index-699848-193.patch19.72 KBDavid_Rothstein
#193 admin_BEFORE.png122.39 KBDavid_Rothstein
#193 admin_by_module_index_page_BEFORE.png137.19 KBDavid_Rothstein
#193 dashboard_BEFORE.png27.81 KBDavid_Rothstein
#193 admin_AFTER.png43.56 KBDavid_Rothstein
#193 admin_by_module_index_page_AFTER.png228.48 KBDavid_Rothstein
#193 dashboard_AFTER.png24.44 KBDavid_Rothstein
#167 1_afterlogin.jpg153.69 KBgiorgio79
#167 2_structure.jpg156.15 KBgiorgio79
#167 3_by-task.jpg426.3 KBgiorgio79
#167 4_dashboard-default.jpg113.46 KBgiorgio79
#156 admin.png29.6 KBDavid_Rothstein
#139 drupal.admin-index.137.patch16.55 KBsun
#138 699858_modules-index_6.patch16.55 KBaaronbauman
#132 699858_modules-index_6.patch17.28 KBaaronbauman
#128 699858_modules-index_5.patch16.9 KBaaronbauman
#124 699858_modules-index_4.patch17.69 KBaaronbauman
#123 699858_modules-index_4.patch17.12 KBaaronbauman
#118 699858_modules-index_2.patch17.28 KBaaronbauman
#115 699858_modules-index_2.patch16.22 KBaaronbauman
#111 699858_modules_index_1.patch16.02 KBmatason
#110 admin-index.png278.32 KByoroy
#108 699858_modules_index.patch16.08 KBgdd
#104 modules-index_2.patch15.89 KBgdd
#102 modules-index_2.patch15.89 KBmatason
#94 admin-index.png275.05 KByoroy
#92 modules-index.patch15.88 KBaaronbauman
#89 modules-index.patch15.66 KBaaronbauman
#66 modules-index.patch12.71 KByoroy
#64 by-module-index.patch13.03 KByoroy
#64 module-index.png314.83 KByoroy
#63 by-module-index.patch13.05 KBcatch
#61 by-module-index.patch12 KBcatch
#61 screenshot_025.png56.06 KBcatch
#59 adminlinks.ods54.12 KByoroy
#39 Administer | Site-Install_1270876071993.png53.51 KBcatch
#26 by-module-index.patch5.6 KBcatch
#25 by-module-index.patch6.27 KBcatch

Comments

catch’s picture

Component: user.module » system.module
Bojhan’s picture

No alphabetical sorting, it should be as it is now - but including the links to all of them.

jacine’s picture

Subscribe. Spent the last hour confused by this myself.

cha0s’s picture

Hrm, I get a 404 at admin/index, am I forgetting something?

jacine’s picture

@cha0s look at /admin vs. admin/config

David_Rothstein’s picture

Status: Active » Closed (duplicate)

#698278: Fix the main admin ("by task") page so it actually makes sense is a couple days older and seems to have a more specific proposal for what to do about this situation.

Bojhan’s picture

Status: Closed (duplicate) » Active

Reversing what @David this, because this is the better issue to do it. Basicly the suggestion in that issue was :

To have /index link the admin/config pages correctly by for example doing :

* System
Site information | Actions | Shortcuts
* Media
File system | Image styles | Image toolkit

Although I think that might be best, we do have to take into account the height and width this might need - ie taking the whole right side of admin/index for admin/config links?

tgeller’s picture

Excuse me for getting all meta on this thread, but...

Shouldn't this be considered a UI issue, and therefore frozen?

catch’s picture

@tgeller: no, this page was stuck in at the last minute and was suppposed to be taken out again once dashboard went in. That hasn't happened, but it's a release blocker due to being worse than the D6 one.

tgeller’s picture

@Catch:

Thanks for the explanation, but I'm afraid I don't understand it. I think you're saying:

1. The page was added just before the UI freeze.
2. It was supposed to be taken out when the Dashboard was ready. (Ergo, it should be gone now.)
3. ??? something something related to D6 ??? (There was no Dashboard in D6, so what's "the D6 one"?)

Thanks,

--Tom

catch’s picture

@tgeller. Drupal 6 only had one admin page full of links - at /admin, and you could at least scan through all items there. in D7 we now have /admin and /admin/config, with slightly different, yet slightly overlapping sets of links. IMO this is a lot worse than D6 in its current state, since I personally can't even tell the difference between the half the time when I browse to the wrong one, so there's no way we should ship Drupal 7 with it the way it is.

David_Rothstein’s picture

Title: Fix admin/index » Change/fix the admin "by task" page so that it properly works as an index

Well, it doesn't really matter what issue we do it in - but so far, this one has mostly consisted of people being confused as to what the issue is about. I was confused too, so trying to change the title to reflect the plan here :) I assume the idea is that part of this will involve changing the URL from admin/by-task to admin/index, which would make sense.

This is an important issue, because currently with the new IA, there is no single page you can go when you know what you want to administer something but don't know where to find it. #102254: Add an administrative search feature would help with that too, but is almost certainly not going to happen for Drupal 7.

Bojhan’s picture

The index its purpose is to server as the traditional by task page. This is what we intended out after long conversations with community members, however the plan as proposed here - would need to tackle one problem. How to properly display the items under admin/config.

Given that, a patch - that we can start trying out things would be most appreciated.

tgeller’s picture

I'm not arguing with the reasoning behind the fix, and can see how it'll make Drupal better. I *am* irritated that I just lost dozens of hours of work because the UI changed substantially after the alleged "UI freeze". But I guess that's another matter.

Will it at least stay as /admin, and not become /dashboard or something like that?

Bojhan’s picture

As far as I am concerned it won't. But the tabs will still change, @tgeller I am sorry that you lost hours over this - its almost unavoidable not to change things that are not release worthy. In contrary to D5/D6 cycles, we have changed so much in the interface part of Drupal that some parts turn out to work worse.

tgeller’s picture

Bojhan: Thanks for your sympathy. Clearly I took the "UI Freeze" too seriously.

You say "the tabs will still change". Which tabs do you mean?

catch’s picture

tgeller - if you have dashboard module installed, it's already admin/dashboard as the default when you visit /admin. The minimal profile has this screen still.

I don't think we should make Drupal 7 inconvenience hundreds of thousands of users, for possibly millions of hours, due to bugs like this, to avoid inconveniencing book authors. Drupal's code freezes have never been tuned to book publishing schedules, and when that changes, you will see me leave the critical issue queue extremely quickly.

I am writing patches which will break APIs which I'm personally using while building a D7 site right this week, because it would also be stupid to release with them as they are, even if that costs me a few hours additional work here or there in the short term to get it right, or inconveniences people writing books dealing with the new APIs. At this point we do not break UI or API just to tidy up, only to deal with critical issues which will seriously impact actual sites being built, or people trying to use Drupal day to day.

No-one should expect a stable UI, or API until RC which is when string freeze happens. And even then release blockers still need to be fixed, this is why they're called release blockers. The changes happening now in D7 are miniscule compared to the changes that happened around the 2nd or 3rd RC for Drupal 6 (when drag and drop was added for about 6 or 7 different major core interfaces), so I'm frankly surprised to see people complaining when we try to fix major issues (rather than trying to stuff in new features at the last minute, which thankfully we're not doing for the past couple of months), especially when i don't see them contributing to reducing the size of the core issue queue elsewhere, which is the only thing which gets us closer to an actually stable release.

Also the UI freeze was pretty well documented as being for new features - not for all text changes, not for critical bugs, and http://drupal.org/project/issues/search/drupal?text=&assigned=&submitted... is available for all to see.

tgeller’s picture

Catch:

I'm not going to argue your post, because I agree with most of it. Clearly these changes are necessary and good for Drupal.

IMHO for D8, Dries et al. need to better define what "freeze" means. I waited through the string freeze and the UI freeze and made what I thought was a reasonable assumption based on, well, the usual meanings of those words. The other problem arose, I think, because I underestimated how much these late behind-the-scenes changes would necessarily affect the interface.

Anyway, this is a side issue. I'm sure you understand my frustration, and I certainly understand yours.

It would have been nice to time the book's release with D7's. Not just for me personally, but to demonstrate Drupal 7's support and readiness from Day 1. Maybe next time.

Thanks for all you're doing.

horncologne’s picture

Subscribing.

Bojhan’s picture

@catch Could you whip up a patch? This issue seems to be stalled, purely on no active patch - the actual issue isn't that huge.

EvanDonovan’s picture

Tracking to come back to later.

catch’s picture

Bojhan. I'd prefer it if we completely got rid of 'by task'. All it does at the moment is duplicate other screens in a horribly confusing way. If we want a proper index here why not nuke it and use by module? I'd roll a patch for that but IMO by index is broken beyond repair at this point

yoroy’s picture

I agree that what we have as 'by task' right now is a mess. 'By task' is kind of the underlying concept for the re-ordered IA as a whole anyway. I'd be fine with dropping it and making 'by module' the one full index.

Bojhan’s picture

Yhea sure, if you feel that's better.

catch’s picture

Status: Active » Needs review
StatusFileSize
new6.27 KB

OK let's try this. Clicked around, didn't run tests.

catch’s picture

StatusFileSize
new5.6 KB

Amazed that tests pass, better patch.

David_Rothstein’s picture

Yeah, just using admin/by-module seems to make a lot of sense - that is already pretty close to an index anyway.

However, there are a number of (important) admin pages that currently do not show up there for whatever reason, because they are somehow missed by the crazy database query that is used to generate that page. I think we need to modify that query to pick them up, in order to make this page a true admin index.

Similarly, I wonder if the "show/hide descriptions" functionality should move to this page also? (One of the main ways I'd use this page is with Ctrl+F in Firefox to search for something on it, and the descriptions are very helpful for that.)

Finally, and perhaps for a separate issue, from the patch I see this:

-  // Check for status report errors.
-  if (system_status(TRUE) && user_access('administer site configuration')) {
-    drupal_set_message(t('One or more problems were detected with your Drupal installation. Check the <a href="@status">status report</a> for more information.', array('@status' => url('admin/reports/status'))), 'error');
-  }

If admin/by-task goes away and this message goes away with it... is there another page where it should be added? The Dashboard (if that module is enabled)? I see it's on the Configuration page now too, but that seems like a historical accident more than anything. A little tricky to figure out where to display this if there is no longer really a single central 'admin' page any longer.

jacine’s picture

If we get rid of admin/by-task, it's going to be really hard to find "appearance" related modules, as admin/config doesn't list them. For example, Skinr is purely an "appearance" related module and its settings belong there IMO, but if we put it there, it ends up being very hard to find.

It seems like a combo of the current admin/config & admin/by-task would be ideal, but maybe I'm missing some of the backstory?

catch’s picture

@Jacine: Those would appear on admin/by-module, and presumably under admin/appearance too no? Isn't two places enough?

@David: there was an issue somewhere to make a status report block available to the dashboard, pretty sure there's no code on it though.

jacine’s picture

@catch, well not exactly... admin/appearance is just the theme listing page. Only way to get it (Skinr) to actually "show" in that section was to make it a tab, which we did, but it feels very awkward and isn't exactly easy to find.

It would appear on by-module though.

catch’s picture

Ohh a tab, yeah that's a bit icky. I haven't used Skinr so can't comment on whether it belongs in appearance or admin/config, but if by-module is OK for findability otherwise then that probably vindicates by-module being enough of an index to work for most other things too.

jacine’s picture

Yeah, personally I think by-module is less than ideal, and would prefer if the appearance group was also listed on admin/config. It just seems like anything under /appearance is a second-class citizen and it's definitely awkward. But, maybe it was done that way on purpose we are not supposed to put anything under appearance?

I definitely don't want to hold this issue up because it needs to be fixed, and the more I think about it, having an appearance listing probably isn't something that should be discussed here.

catch’s picture

But, maybe it was done that way on purpose we are not supposed to put anything under appearance?

I think that was the general idea. Another option would be to put themes admin into an 'appearance' section under admin/config. Personally I never agreed with it being in the toolbar listing in the first place, because theme settings are usually something you set up during development then rarely touch again, unlike content and user administration. Also Leisa admitted somewhere that it was only there for ideological reasons ("we want to promote design") and that it was completely inconsistent with the overall approach to IA.

jacine’s picture

Aha! I suspected this might have been the case, and agree with you about Appearance not deserving such valuable real estate on the toolbar, but in any case thank you for clarifying this.

Another option would be to put themes admin into an 'appearance' section under admin/config.

This would be perfect. It would solve the tab issue and allow the module to be located easily (not to mention it would finally get me some satisfaction since I keep clicking on admin/config over and over again expecting it to be there). ;)

catch’s picture

I've re-opened #536440: Reconsider whether "Appearance" should be a top-level item in the IA where it was moved in the first place, see you over there hopefully.

sun’s picture

Can we before/after screenshots here. I read most parts of this issue, but do not understand the problem/goal as well as the actual changes.

yoroy’s picture

Yeah, multiple topics. We haven't fixed our administrative entrance(s) yet.

- Dashboard is on /admin. /admin always had the full site map of admin links. It doesn't anymore. Configuration page isn't either.
- Then there's 'by task' too, which is also incomplete.
- The need for the full index is squarely in the 20% use case, but of course that's us builders ourselves. I find myself missing it too. The page that has all subs of top level IA items as similar boxes added to the Configuration page, basically.

Catch has a long-standing issue with Appearance as a top level item because it's such a narrow hub, which was triggerd by Jacine's application-design questions :-)

So, 80% UX wise there's no real need for this full index page to exist. Sitemaps work for sites, less so for web operating systems.

We'd rather see module developers try and 'blend in' with what we have now: Toolbar, Dashboard, Configuration, Modules…

From that perspective, this issue is about getting rid of 'by task' and 'by module' without putting up too many new buckets elsewhere. I'm sure the technical summary sounds different!

sun’s picture

Thanks! I'm going to interpret and translate that into: (feel free to correct me)

When considering users who do not install admin_menu, then I can perfectly see the requirement for a fully recursive administrative index. Effectively, admin_menu is exactly that recursive index, but always exposed. Since the new IA hides more than it exposes, users need a way to actually find stuff deeply buried down below /admin. I don't think the 20%/80% numbers are correct with regard to that. Every site administrator is going to need that index.

catch’s picture

StatusFileSize
new53.51 KB

@sun, so my view on this is that /admin as it currently is + admin/config is too much duplication, at least if people want sub-items of admin/config as described earlier here. I personally find having both of them really confusing because there's not enough cues to know which one you're on.

That page mainly exists for people who are using neither the d7ux stuff or admin_menu - or in the case of "where's that damn setting I can't find it anywhere". For the latter, which I agree isn't a 20% case, I've often resorted to hook_menu() or somtimes admin/by-module

We already have a nice index which no-one ever sees at admin/by-module - which is pretty easy to find things on, and by its nature ought to be comprehensive, but it's quite hidden away. David pointed out is it doesn't currently show all admin items, but that could be dealt with.

So my suggestion is that /admin - without the dashboard, gets turned into admin/by-module - and we drop the current one altogether. Here's what it looks like with the current patch.

sun’s picture

For a proper, usable index, we'd have to

1) remove the "Configure permissions" and "Get help" links. The first should already be part of User module, the second already part of Help module (if enabled).

2) It doesn't look like the current list of links is recursive. I'd like to find all related links for each module. For example, the links for Locale look good, but those for Taxonomy are... moot.

If we'd do those changes, I could even see admin_menu users to find that full index useful (as the menu is "collapsed", and this page would expand everything as overview).

catch’s picture

I could live with removing the permissions and the help links - we'll need the space if this does recursive admin links. I'm not convinced either way on the recursive links - you want taxonomy to show every vocabulary on here?

sun’s picture

We can't do links for dynamic paths in core yet. So Taxonomy actually was a bad example, as that really has this one item only. :) But for everything else, we should "recurse", taking all static paths being either normal items or local tasks (no actions) into account.

gábor hojtsy’s picture

@catch(#39): how would people navigate / get to know that a by-category admin/config exists, which might be a better overview for them? Looks like this would make the admin not explorable for those not running toolbar or a replacement, or am I missing something?

catch’s picture

They would have to use the navigation/management menu - same for admin/structure and others. I don't see a menu block being any more disconnected than the toolbar is.

gábor hojtsy’s picture

@catch: Seven does not have a way to display a menu block in a meaningful way, as it was intended to provide navigation on-page. So I'm not seeing how the management/navigation menu would show up there. So this could cripple the way we could navigate Drupal admin without a toolbar or toolbar replacement module in my view.

sun’s picture

Seven does not have a way to display a menu block in a meaningful way

Does it even deserve the title of a "theme" then? As a themer, I'd consider that as a major bug in the theme, but not in the system. If the theme wasn't designed to work like a proper theme, then it shouldn't be a theme in the first place.

gábor hojtsy’s picture

Yeah, well, I'm saying if the proposed solution is to use blocks, then we need ways to use blocks in Seven. The solution proposed here so far is not compatible with Seven's current state and makes navigation bad in different ways while fixing some admittedly confusing screens.

catch’s picture

I don't think this patch should be affected by the fact that Seven has no space for blocks, it's one of several possible admin themes.

People using the default profile will get Seven + toolbar + overlay + dashboard - so that's not an initial experience issue whatsoever.

You can get into all kinds of fun issues if you disable various combinations of modules and configuration and this is not a bad one especially. The stuff on admin/structure and admin/index will all be accessible from admin/by-module - it'll just be presented differently. IMO that's better than the multiple levels of duplication and confusion we have with current /admin.

rgristroph’s picture

I have applied this patch to CVS HEAD and disabled dashboard and it seems to work. I ran all the system tests and I think it is OK, there were two failures in modules/simpletest/common.test line 1361 and 1374 in the test testDrupalRenderThemeArguments(), but I don't think those tests were related.

catch’s picture

Title: Change/fix the admin "by task" page so that it properly works as an index » Remove admin/by-task and replace it with admin/by-module
Remon’s picture

I applied the patch in #26 against todays drupal 7.x-dev. and no more admin by-task menu :)

Remon’s picture

Status: Needs review » Reviewed & tested by the community
sun’s picture

Status: Reviewed & tested by the community » Needs review

errr, I'm not sure whether we reached a consensus here...?

yoroy’s picture

Dashboard and the By-module page are the two contenders for living at /admin.
By-task can go because the task-driven IA is expressed through dashboard/toolbar/configuration page now
So, lets rename 'by-module' to 'Index', it's a good name. Then:

With dashboard enabled, make it look like this, meaning dashboard lives at /admin.
Only local images are allowed.

Without dashboard, 'Index' becomes the fallback /admin:
Only local images are allowed.

Also, this issue needs cross-ref with #652122: Fix dashboard as the default /admin local task, where I'll post these same two mockups because this needs to be seen as a whole.

Implementation wise, this patch should probably focus on removing admin/by-task, renaming admin/by-module to 'Index', and make sure it is/can be the full module-links index it wants to be.

yoroy’s picture

#26: by-module-index.patch queued for re-testing.

yesct’s picture

Status: Needs review » Needs work

is yoroy in #54 suggesting a different solution than the one in the patch in #26 gives? Is the decision needed here on which direction to go #54 or #26?

yesct’s picture

Status: Needs work » Needs review

#26: by-module-index.patch queued for re-testing.

catch’s picture

The only things here which possibly differ between #56 and #26 are renaming it 'Index' and that we need to confirm which links show up (or should show up and don't) in the by-module index. Since the first is just a string change, someone should take a look at the latter and post the results here - just visit admin/by-module, compare it to the top-level accessible links which you can see from /admin/config, /admin etc. and post the results back here.

yoroy’s picture

StatusFileSize
new54.12 KB

Here's a spreadsheet with:

column A: what's currently on /admin/by-module (to be renamed to /admin/index)
column B: what's currently on /admin/config
column C: what's currently on/under toolbar pages Content, Structure, Appearance etc.

This is with all core modules enabled.

If I understand it correctly, A must show what's on (B + C) combined. Haven't started really comparing the lists yet.

catch’s picture

From that list, it looks like the only pages which don't show up are 'configuration' and 'modules'. I didn't check every single link, but checked a lot.

catch’s picture

StatusFileSize
new56.06 KB
new12 KB

Updated patch:

@yoroy: Renamed to admin/index
@yoroy/David: Shows system compact link and descriptions on the menu items.
@sun - Removes permissions and help links.
@Gabor - now shows links for 'Appearance', 'Modules' and 'Config' under the system module block. Very simple change to get those in.

Status: Needs review » Needs work

The last submitted patch, by-module-index.patch, failed testing.

catch’s picture

Status: Needs work » Needs review
StatusFileSize
new13.05 KB

Notices were in help module.

yoroy’s picture

StatusFileSize
new314.83 KB
new13.03 KB

Nitpicky text change only, changing
"This page shows you all available administration tasks for each module."
to
"All available administration tasks for each module."

Attaching full page screenshot, it's quite the page!

Status: Needs review » Needs work

The last submitted patch, by-module-index.patch, failed testing.

yoroy’s picture

Status: Needs work » Needs review
StatusFileSize
new12.71 KB

You'd think I learned not to edit patch files directly by now…

snorkers’s picture

Reviewed patch #66 - works just fine - thanks @yoroy. Nice UI

mike stewart’s picture

Status: Needs review » Reviewed & tested by the community

Reviewed patch #66 - works as advertised... even has some nice comments in code ;-)

(part of LA Drupal code Sprint #LADrupal)

yoroy’s picture

This could use 1 more person checking the list in #59 though

webchick’s picture

Status: Reviewed & tested by the community » Needs review

Back to 'needs review', per yoroy.

I really hate to ask this, but is there any way to put that spreadsheet in a, er, less open format? :P~ I'm on airport wifi and can't really download NeoOffice to view. :( Maybe a Google spreadsheet that reviewers could just click a link to see?

aspilicious’s picture

Here is your google spreadsheet guy ;)
I imported the .ods in google spreadsheat (you can do this to webchick so you don't need to download any office programme ;) )

http://spreadsheets.google.com/ccc?key=0AnMmC4VjMWMXdDZzRHEzNU1mTzFfM3At...

snorkers’s picture

Status: Needs review » Reviewed & tested by the community

Just went through the spreadsheet at #59. Columns 2 and 3 (admin/config and toolbar) are all fine. admin/index [designate] displays the following with all core modules:

Blocks on Left side:

AGGREGATOR
Feed aggregator
CONTACT
Contact form
FIELD UI
Field list
FORUM
Forums
IMAGE
Image styles
MENU
Menus
PATH
URL aliases
SEARCH
Search settings
Top search phrases
STATISTICS
Recent hits
Statistics
Top pages
Top referrers
Top visitors
TAXONOMY
Taxonomy
TRIGGER
Triggers
USER
Account settings
People
Right Hand Blocks:

BLOCK
Blocks
DATABASE LOGGING
Recent log entries
Top 'access denied' errors
Top 'page not found' errors
FILTER
Text formats
HELP
Help
LOCALE
Languages
Session language detection configuration
Translate interface
URL language detection configuration
NODE
Content types
Content
PROFILE
Profiles
SHORTCUT
Shortcuts
SYSTEM
Actions
Appearance
Clean URLs
Configuration
Date and time
File system
IP address blocking
Image toolkit
Logging and errors
Maintenance mode
Modules
Performance
RSS publishing
Regional settings
Site information
Status report
TESTING
Testing
UPDATE MANAGER
Available updates

Which is different to column 1 of the spreadsheet at #59. However, this is the same listing the current DEV of D7 looks unpatched, so believe the patch is fine.

Changed to RTBC again....

snorkers’s picture

But just following up from #72...

But note that neither 'Configure permissions' nor 'Get help' links are shown at admin/index. This means that none of the following are listed at admin/index in a 'Standard' installation (with only core modules enabled): Book, Comment Content translation, Contextual links, Overlay, PHP filter, Poll, Toolbar, Update manager

yesct’s picture

Status: Reviewed & tested by the community » Needs work

#73 sounds like needs work to me

catch’s picture

Status: Needs work » Reviewed & tested by the community

Nope, previous reviews specifically asked to remove those links. Unless someone thinks these should be added back to the patch, then this remains RTBC, but no-one's yet argued for that.

David_Rothstein’s picture

Status: Reviewed & tested by the community » Needs review

As per #40 and #61, that behavior is intentional - but sounds like it definitely needs some discussion as to whether it is a good idea or not.

snorkers’s picture

The patched admin/index [desig] without the help/permissions (and associated modules) is simple and clean; this is because the admin/index [desig] listing is now only listing features and functionality that can be configured. Help/permissions is not really a functional aspect of the site's features... this is more related to the 'User' piece (as in D6), 'Help' piece and the expanded 'Module' piece (now featuring in D7). My view is that that admin/modules has a much better UI [than D6] for 'everything' and launches straight into related help and permissions for each module - the only thing that will trash this page will be if the projects/packages for D7 contrib modules is a little random (as is the case in D6), leaving Cmd-F the only way to navigate admin/modules.

I'm a little reluctant to RTBC this, as the most recent status changes have been quickly reversed. However, we reviewed this issue among 4 people (talking face-to-face) at a code sprint, which is probably more productive and comprehensive than forum postings. I know we leapt in to this issue late in the day, and we initially negated to formally check off the checklist at #59, but this patch (#66) will make site admin less confusing... and it works.

So if someone else agrees - who maybe has been working on this issue a little longer - then please RTBC to get this patch committed.

yoroy’s picture

Status: Needs review » Reviewed & tested by the community

thanks a lot for that recap snorkers and I agree with your assesment.

David_Rothstein’s picture

Status: Reviewed & tested by the community » Needs work

Yeah, I think that makes sense. An additional reason is that the Help and Permissions links would look very out of place on this page now since they do not come with descriptions but all the real menu items do. (However, if we are relying on the module page for this stuff, that makes the proposed rollback at #293223: Roll back "Hide required core modules" even more important...)

Looking at the actual patch here:

  1. -  // Only continue if provided arguments are expected. This function serves
    -  // as the callback for the top-level admin/ page, so any unexpected arguments
    -  // are likely the result of someone typing in the URL of an administrative
    -  // page that doesn't actually exist; for example, admin/some/random/page.
    -  if (isset($arg) && substr($arg, 0, 3) != 'by-') {
    -    return MENU_NOT_FOUND;
    -  }
    

    As ugly as this code is, I think we need to preserve some version of it. Otherwise, when the dashboard module is turned off, visiting admin/some/page/that/does/not/exist will show you the index whereas we actually want it to return "page not found".

    I think the way the new patch works the new code could be a lot simpler though, hopefully just something like this:

    if (isset($arg)) {
      return MENU_NOT_FOUND;
    }
    

    If we're lucky? :)

  2. -  // Check for status report errors.
    -  if (system_status(TRUE) && user_access('administer site configuration')) {
    -    drupal_set_message(t('One or more problems were detected with your Drupal installation. Check the <a href="@status">status report</a> for more information.', array('@status' => url('admin/reports/status'))), 'error');
    -  }
    

    Do we really want to remove this? D7 currently displays that on the configuration page too, but for a site that isn't using the dashboard, /admin is likely still going to be their main central administration page, so they should possibly get that message there.

    This might be better dealt with in a followup, rather than here.

  3. A side effect of this patch which I don't think is intentional is that in addition to removing the "Configure permissions" link from the index page, it is also removed from the individual module help pages (e.g., admin/help/block, admin/help/filter, etc).

    That needs some discussion - I think by the time you are looking at a module's help page, you are really trying to figure out how it works and see everything it is able to do, and the "Configure permissions" link is an important part of that. I think help.module needs to add that link back in.

  4. -      return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>';
    +    case 'admin/index':
    +      return '<p>' . t('All available administration tasks for each module.') . '</p>';
    

    The new version is not a grammatically complete sentence.

    (And why are we even changing it as part of this patch? The purpose of the page didn't change, so I think rewording/shortening the help link doesn't necessarily have to be part of this issue.)

  5. -      return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>';
    +    case 'admin/index':
    +      return '<p>' . t('All available administration tasks for each module.') . '</p>';
    

    An additional issue here - because we are only checking 'admin/index', this means that people who do not use the Dashboard module won't ever see this help text when they visit the admin page. (On the other hand, we can't simply just add case 'admin' to this list because then it will show up on the Dashboard too, which we don't want.)

    I think we can fix this by adding case 'admin' to the list and then having the Dashboard module use hook_block_list_alter() to prevent the System Help block from displaying on the Dashboard page at all. That's ugly, but probably acceptable. If the solution turns out to be any more complicated than that, though, let's leave it for a followup issue, because the Help module is kind of a mess and we don't really want to rewrite it as part of this issue :)

  6. +        if (!empty($items[$path]['localized_options']['attributes']['title'])) {
    +        $items[$path]['description'] = $items[$path]['localized_options']['attributes']['title'];
    +      unset($items[$path]['localized_options']['attributes']['title']);
    +    }
    

    (minor) Crazy indentation here.

  7. (minor) Grepping the codebase for "by-module" shows one instance still left over, in menu_set_active_trail():
          // The title of a local task is used for the tab, never the page title.
          // Thus, replace it with the item corresponding to the root path to get
          // the relevant href and title. For example, the menu item corresponding
          // to 'admin' is used when on the 'By module' tab at 'admin/by-module'.
    

    We should ideally rewrite that code comment to remove the reference.

sun’s picture

Ping pong from #293223-50: Roll back "Hide required core modules":

Another reason in favor of [displaying required core modules] is that [this patch] is close to going in, and one of the effects of that patch is to remove the "Help" and "Configure permissions" links from the index page at admin/by-module (soon to be renamed admin/index). The theory is that those links are best accessed from the modules page, but that won't work for required modules unless we get this one in too.

As far as that other issue is concerned, the theory sounds wrong to me, since the current help and permission links are located on a page that can be accessed by "site configurators". The modules page requires additional permissions, and actually allows a user to change all available configuration options.

If one needs to RTFM, then that one should rather not deal with module installation/enabling/disabling/etc.

tstoeckler’s picture

Re #80: Well if you are looking for help in the first place, then there is this big 'ole Help link for you to click, where you will currently (but sadly not with the latest patch) find links to the respective permission pages. So there is no net loss for people without access to the modules page (but with access to the site-configuration).

Maxim Rosca’s picture

Status: Needs work » Needs review

#25: by-module-index.patch queued for re-testing.

catch’s picture

Status: Needs review » Needs work

I wrote up a response but a guru ate it.

Quicker version responding to David's review:

1. Yuck but yes we likely need to check arg()
2. Also yuck, also yes, we should be showing this on dashboard if we don't already too.
3. I think we could add permissions back to admin/index too, IMO those links are handy (but should be at the bottom of the list) - so many people get caught out by forgetting to set permissions, just because it's a central screen doesn't mean that separate references aren't useful.
4, 5, 6 yes fine.

I don't think I'm going to have time to re-roll this patch this week, but the above changes are quite easy to make, so anyone else wants to would be great.

Bojhan’s picture

So can anyone fix the issues and roll a new patch? Lets fix this critical

philbar’s picture

Issue tags: +beta blocker

tag

iantresman’s picture

This is bugging me big time. It is hard enough finding modules on the Admin screen in D6. But in D7 some modules are not even listed on the Admin by Task, nor the Admin by Module page. For example:

The Admin by task page does not show

  • (Users) Configure permissions
  • (Users) Account settings

The Admin by modules page does not show

  • Any Reports
  • Modules!!!

There MUST MUST MUST be an "Administer page Index" where EVERY modules is listed on the ONE page. I don't want to take two clicks to get to a module admin page. And where do I find a newly installed module admin page... how many sub-menus must I search through.

The D6 Admin page was fine because it was complete.

yoroy’s picture

Great to see you support the obective of this issue. Could you maybe update the patch to fix the problems you found? Thank you.

iantresman’s picture

I wish I had enough programming know-how to do so. For now, I can only offer usability and testing, and occasional documentation of various modules.

aaronbauman’s picture

StatusFileSize
new15.66 KB

rerolled #66 @ HEAD and addressed the points in #79 and #83

#66 already addresses all the concerns in #86, save "configure perimssions", which is restored by the attached patch.

aaronbauman’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, modules-index.patch, failed testing.

aaronbauman’s picture

Status: Needs work » Needs review
StatusFileSize
new15.88 KB

Fixed notices, links to permissions.

Bojhan’s picture

Looks good, I would argue Configure permissions - should say Configure *module name* permissions. But thats not really something I would keep from this going through.

yoroy’s picture

StatusFileSize
new275.05 KB

Uploading a screenshot of what the patch does.

catch’s picture

+function system_admin_by_module($arg = NULL) {

the new param should be documented.

Per David's review I think we need to add this back in:

-  // Check for status report errors.
-  if (system_status(TRUE) && user_access('administer site configuration')) {
-    drupal_set_message(t('One or more problems were detected with your Drupal installation. Check the <a href="@status">status report</a> for more information.', array('@status' => url('admin/reports/status'))), 'error');
-  }

Apart from that looks good.

yoroy’s picture

Status: Needs review » Needs work

Almost there then but needs work

David_Rothstein’s picture

Regarding @catch's second point I think that is already done in the patch - he removed it from the code in one place but added it back correctly in the other.

Looking at the code, it mostly looks great now - I only see two issues:

  1. +    // Since Dashboard takes over the admin page, unset the help text.
    +    foreach ($blocks as $key => $block) {
    +      if ($block->region == 'help' && $block->delta == 'help' && $block->module == 'system') {
    +        unset($blocks[$key]);
    +      }
    +    }
    

    I don't think we want to check the block region here - the module and delta should be enough. If someone moved the block to a different region, we still don't want to show them the wrong help text in it.

  2. +    case 'admin/index':
    +      return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>';
    +    case 'admin':
           return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>';
    

    Instead of repeating the return statement, the case statements could just be combined like this I think:

      case 'admin':
      case 'admin/index':
        return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>';
    

**********

In terms of the screenshot, I have two comments:

  1. The configure permission links look odd to me at the top of the list - I suspect they would be better at the bottom (where they would look less out of place, especially without a description)? I realize they've always been at the top since at least Drupal 6, but it just looks weirder now with the new page design.
  2. The page title and tab titles look a little odd, no? This is the index page, but the main title on the left says "Dashboard", etc...
matason’s picture

Regarding @catch's comment in #95

the new param should be documented.

I wondered whether the 4 lines of comment already in the patch are sufficient or do we also need an @param in the function header?

+  // Only continue if provided arguments are expected. This function serves
+  // as the callback for the top-level admin/ page, so any unexpected arguments
+  // are likely the result of someone typing in the URL of an administrative
+  // page that doesn't actually exist; for example, admin/some/random/page.

I also agree with @David_Rothstein's comment in #97, the case statements can be combined.

Bojhan’s picture

@David Regarding 2. Yes, lets move them to the bottom - I would recommend adding in *module name* then, if possible.

That the page title is something you probably did wrong :P

iantresman’s picture

  1. Since we now have a full page of modules displayed, can we not also display a link/icon to its
    • Drupal Help page
    • Project home page.
  2. Can we use less technical jargon in places, eg.
    • Field UI --> Fields
    • Nodes -- > Nodes (Content and types)
    • Clean URI --> Clean web addresses
    • Taxonomy --> Taxonomy (categories)
Stevel’s picture

@iantresman: This is out of scope for this issue, so if you want this to be discussed/changed, I suggest you open a new issue for it

matason’s picture

Status: Needs work » Needs review
StatusFileSize
new15.89 KB

I've amended the patch so that it includes some of the suggestions from #97

1. Combined the case statements for admin and admin/index
2. Removed the check for $block->region
3. Moved the Configure permissions links to the bottom of each module section

patrickfgoddard’s picture

Using a clean install of HEAD, patch applied cleanly.

Had to clear cache to see updated Dashboard main page, otherwise I was seeing these errors:

Warning: call_user_func_array(): First argument is expected to be a valid callback, 'system_main_admin_page' was given in menu_execute_active_handler() (line 476 of /home/patrick/projects/personal/d7/includes/menu.inc).

(Not sure if that matters or not...)

Confirmed "Configure Permissions" are on and at bottom of each Module listing, except Database logging, and Update Manager (not applicable, I'm guessing).

From a higher level viewpoint, I'm confused, though, by the "main" Dashboard page being empty, then a tab that says "index". Isn't admin the index page? Can't admin/index just be admin? Maybe I'm missing the point (customized dashboard vs. default), and maybe it's a nomenclature issue (should "index" be renamed to something else), but this is my initial impression.

-pat

gdd’s picture

StatusFileSize
new15.89 KB

Same experience as thund3rbox, had to clear cache but otherwise fine. Removed Dashboard module and all worked as expected. I have attached a new patch with the added documentation for $arg in system_admin_by_module() per #95. I think this is good to go.

Bojhan’s picture

#103, #104 The experience should be :

1. Simple profile, no dashboard installed; admin/index lives on /admin.
2. Disabled dashboard; admin/index lives on /admin

3. Default profile, dashboard installed; admin/index lives as local task of Dashboard which lives on /admin.

gdd’s picture

Yes, all these cases are functioning as specified.

matason’s picture

@heyrocker, the patch on #104 looks identical to that on #102 - wrong patch maybe?

gdd’s picture

StatusFileSize
new16.08 KB

Yes you are correct, thanks.

matason’s picture

I think this is looking good now, ready to be committed?

yoroy’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new278.32 KB

Another screenshot of the full index page. Should there be another re-roll, than bojhans suggestion to rename 'configure permissions' to 'configure permissions is still a good one.

Re; comment 2 in #97: "The page title and tab titles look a little odd, no? This is the index page, but the main title on the left says "Dashboard", etc...
". This happens everywhere. When you choose a not-default local tab, the page title is not updated to that page's title. Is how it goes in D6 and apparently wasn't changed.

Tested this again, and all these scenarios work as intended:

1. Simple profile, no dashboard installed; admin/index lives on /admin.
2. Disabled dashboard; admin/index lives on /admin
3. Default profile, dashboard installed; admin/index lives as local task of Dashboard which lives on /admin.

And 4: Default profile, dashboard disabled: admin/index lives on /admin works as well. I'm going to trust heyrocker and matason on fixing the last code comments and but this rtbc again.

matason’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new16.02 KB

I've re-rolled the patch adding in the module name so that the links now read:

Configure module_name permissions.

These links are also displayed on the admin/help/module_name pages, which I think is fine.

yoroy’s picture

Status: Needs review » Reviewed & tested by the community

Only local images are allowed.

Thank you!

David_Rothstein’s picture

Status: Reviewed & tested by the community » Needs review

Looks to me from a quick glance at the screenshot and code that this is using the machine-readable module name rather than the human-readable one?

If so, this should be needs work - we shouldn't use the machine-readable name here.

aaronbauman’s picture

StatusFileSize
new16.22 KB

Yes, the patch used the module's machine name.
Rerolled #111: replaced module's machine name with human name from system_get_info(), static cached.

matason’s picture

Ah, yes, I've a lot to learn!

catch’s picture

Status: Needs review » Needs work

If we're going to add static caching for system_get_info() could we do that in system_get_info() itself?

aaronbauman’s picture

Status: Needs work » Needs review
StatusFileSize
new17.28 KB

rerolled with catch's suggestion

Status: Needs review » Needs work

The last submitted patch, 699858_modules-index_2.patch, failed testing.

catch’s picture

The $reset argument shouldn't be added here, instead a drupal_static_reset() call should be added to whichever functions update system info - I think there's similar code already to do that for other system static caches.

gdd’s picture

Is this really the right issue to be adding static caching to system_get_info()? Shouldn't that be its own issue? I really feel like this is getting sidetracked.

David_Rothstein’s picture

Is it really worth adding (another) static cache here? I believe one wasn't added originally to this function because it's generally only used on admin pages anyway, like this one....

I think we could optimize it just as well by making the human-readable name a parameter to system_get_module_admin_tasks() and then having the caller call system_get_info() once and pass it in. Maybe a little ugly, but it's not a commonly used function.

(Or just not bother optimizing it at all, honestly? Again, this is an admin page, so it doesn't need to be micro-optimized, in my opinion.)

aaronbauman’s picture

Status: Needs work » Needs review
StatusFileSize
new17.12 KB

removed overzealous $reset param.

no calls to drupal_static_reset() were added.
Only 3 functions call system_get_info(), and none during operations that touch {system}, so that should be OK, right?

aaronbauman’s picture

StatusFileSize
new17.69 KB

cross-posted with David and heyrocker.

Here's a new and improved patch with a more holistic approach (i think).

There are only 2 functions that call system_get_module_admin_tasks():
system_admin_by_module() - which calls system_get_info and iterates over it -- no big change there.
help_page() - this function prints a page listing general help for a module. Currently, this function locates and displays the name of the module by parsing the .info file.

So, in this updated patch I'm killing a few kittens with one stone:

  • rerolled #111 without static cache
  • added $info param to system_get_module_admin_tasks()
  • updated help_page() to get module info from system_get_info() instead of parsing the .info file.
sun’s picture

Status: Needs review » Needs work
+++ modules/dashboard/dashboard.module	26 Jul 2010 20:46:35 -0000
@@ -87,6 +87,14 @@ function dashboard_block_list_alter(&$bl
+  else {
+    // Since Dashboard takes over the admin page, unset the help text.
+    foreach ($blocks as $key => $block) {
+      if ($block->delta == 'help' && $block->module == 'system') {
+        unset($blocks[$key]);
+      }
+    }
+  }

Not related to this issue? (and also, the comment does not really explain anything - I can already read from the code what it does, but have no idea why on earth Dashboard module would want to hi-jack each and every implementation of hook_help() that tries to display help text on a page that contains the dashboard?)

+++ modules/locale/locale.module	26 Jul 2010 20:46:35 -0000
@@ -132,6 +132,7 @@ function locale_menu() {
   $items['admin/config/regional/language/configure/url'] = array(
     'title' => 'URL language detection configuration',
+    'description' => 'Configure URL language detection',

@@ -139,6 +140,7 @@ function locale_menu() {
   $items['admin/config/regional/language/configure/session'] = array(
     'title' => 'Session language detection configuration',
+    'description' => 'Configure session language detection',

These two should be MENU_CALLBACKs actually. They are accessed via individual "Configure" links only. Hence, instead of adding a description, we just want to add 'type' properties. The 'title' is taken over as page title though, so must be kept.

+++ modules/system/system.admin.inc	26 Jul 2010 20:46:35 -0000
@@ -143,8 +79,24 @@ function system_admin_menu_block_page() 
+function system_admin_by_module($arg = NULL) {
...
+  if (isset($arg)) {
+    return MENU_NOT_FOUND;

Would it make sense to rename $arg into $unexpected_argument ?

+++ modules/system/system.module	26 Jul 2010 20:46:36 -0000
@@ -2202,7 +2195,6 @@ function system_update_files_database(&$
  * @param $type
  *   Either 'module' or 'theme'.
- *
  * @return

Please revert. See http://drupal.org/node/1354

+++ modules/system/system.module	26 Jul 2010 20:46:36 -0000
@@ -2210,12 +2202,11 @@ function system_update_files_database(&$
 function system_get_info($type) {
-  $info = array();
   $result = db_query('SELECT name, info FROM {system} WHERE type = :type AND status = 1', array(':type' => $type));
   foreach ($result as $item) {
-    $info[$item->name] = unserialize($item->info);
+    $info[$type][$item->name] = unserialize($item->info);
   }
-  return $info;
+  return $info[$type];
 }

I can only guess that these changes date back to a static cache approach of this patch?

Powered by Dreditor.

matason’s picture

Status: Needs work » Needs review

I've just applied the patch, seems like line 2762 needs to be:

$permissions_menu_item['title'] = t('Configure @module permissions', array('@module' => $info->info['name']));

Instead of the old $info['name']

matason’s picture

Status: Needs review » Needs work

I think my comment inadvertently changed the status set by @sun, setting to "needs work".

aaronbauman’s picture

Status: Needs work » Needs review
StatusFileSize
new16.9 KB

Sorry for the half-baked patch - too many irons in the fires.
In addition to the changes described below, fixed an undefined index array in help_page().

Re: #125:
Thanks for the thorough review.

  1. Dashboard / Help hack - see comment #97, bullet 1. I would love to do this differently, please advise. Leaving in for now.
  2. Locale - removed descriptions from patch, switched to type MENU_CALLBACK
  3. $unexpected_argument - I like this. Updated the variable name.
  4. +++ modules/system/system.module	26 Jul 2010 20:46:36 -0000
    @@ -2202,7 +2195,6 @@ function system_update_files_database(&$
      * @param $type
      *   Either 'module' or 'theme'.
    - *
      * @return
    

    Oops - I was rolling back changes and following the convention used elsewhere in the same file (e.g. system_theme_settings()). Reverted to HEAD.

  5. system_get_info() - yes, you are correct, these are vestigial changes.

Re #126:
Actually the wrong parameter was passed by system_admin_by_module() - should have passed an info array, not an info object.

Last one from me today.

David_Rothstein’s picture

Dashboard / Help hack - see comment #97, bullet 1. I would love to do this differently, please advise. Leaving in for now.

Also see bullet 5 of #79 for the original motivation. I'd love to do this differently too, but couldn't think of a better way.

I am not sure but maybe instead of unsetting the variable we could do something with #access = FALSE to make it easier for another module to override this if it wanted to? (And it sounds from @sun's review that a more verbose code comment would at least be a good idea.)

sun’s picture

#access FALSE sounds nice, but definitely needs a more verbose comment that explains the potential "WTF?" - we can basically copy bullet 5 of #79 and slightly rephrase it.

matason’s picture

Can you elaborate on the suggestion 'do something with #access = FALSE' in #129 and #130?

Are you suggesting there's some way of controlling the display of the block by setting #access = FALSE which would be cleaner because it does not destroy the block as the patch does now?

I am reasonably sure I am misunderstanding this suggestion as I could not see that this was possible. I did however try setting the region to BLOCK_REGION_NONE which seems to achieve the desired result:

function dashboard_block_list_alter(&$blocks) {
  if (!dashboard_is_visible()) {
    foreach ($blocks as $key => $block) {
      if (in_array($block->region, dashboard_regions())) {
        unset($blocks[$key]);
      }
    }
  }
  else {
    // Since Dashboard takes over the admin page, unset the help text.
    foreach ($blocks as $key => $block) {
      if ($block->delta == 'help' && $block->module == 'system') {
        $blocks[$key]->region = BLOCK_REGION_NONE;
      }
    }
  }
}

Forgive me if I am being silly and missing something obvious here, I am just trying to keep up with this issue and help where I can :)

aaronbauman’s picture

StatusFileSize
new17.28 KB

comment 125:

no idea why on earth Dashboard module would want to hi-jack each and every implementation of hook_help() that tries to display help text on a page that contains the dashboard?

Actually, this patch will only hi-jack a single implementation: system module's block with delta "help".
Since (module, delta, theme) are a unique key in {block}, we can rest assured that no other modules' blocks will be overridden.

AFAICT, in order to use #access to hide the block, we'd have to tap into theme_block() since System Help uses the default implementation. Seems like that would be pushing the logic into a layer where it doesn't belong. Documentation for hook_block_list_alter states that setting the block's "content" property will prevent the block's hook_block_view from firing.

So, the attached patch is a reroll of #128 and:

  • sets System Help's block->content = FALSE, instead of the more destructive unset().
  • adds more verbose documentation to explain why this is done:
        // System module defines help text for 'admin' and 'admin/index', since it
        // serves both those URIs when Dashboard is not enabled. When Dashboard
        // module is enabled, 'admin' is served by Dashboard, and System Help is
        // irrelevant. Setting System Help block's content property to FALSE
        // prevents system_block_view from running, effectively hiding the block.
        // @see http://drupal.org/node/699848#comment-3095302
    
sun’s picture

+++ modules/dashboard/dashboard.module	27 Jul 2010 15:57:48 -0000
@@ -87,6 +87,19 @@ function dashboard_block_list_alter(&$bl
+    // System module defines help text for 'admin' and 'admin/index', since it
+    // serves both those URIs when Dashboard is not enabled. When Dashboard
+    // module is enabled, 'admin' is served by Dashboard, and System Help is
+    // irrelevant. Setting System Help block's content property to FALSE
+    // prevents system_block_view from running, effectively hiding the block.
+    // @see http://drupal.org/node/699848#comment-3095302
+    foreach ($blocks as $key => $block) {
+      if ($block->delta == 'help' && $block->module == 'system') {
+        $blocks[$key]->content = FALSE;
+      }
+    }

This hides any help text added via hook_help() on pages that display the dashboard, not just the specific help texts mentioned here, while it intends to only hide System module's help text. That's what I tried to say in #125.

At the very least, we need to document it (the WTF) similar to how I phrased it above, potentially prefixed with @todo. ;)

btw, in comments, all function names should be suffixed with parentheses, i.e., myfunction(), and we only link to drupal.org issues in completely totally weird cases that really need more in-depth essays about why the world is so ugly and bad; in all other cases, code comments should sufficiently explain the problem space for all mankind 2010 A.D. and after.

40 critical left. Go review some!

Status: Needs review » Needs work

The last submitted patch, 699858_modules-index_6.patch, failed testing.

David_Rothstein’s picture

@matason's suggestion in #131 about using BLOCK_REGION_NONE sounds pretty reasonable, although I guess the $block->content = FALSE setting works well too. (I only suggested setting #access = FALSE based on a hunch, because I knew at some point this gets rendered by drupal_render() where anything with #access = FALSE gets skipped, but it sounds from above like that won't work.)

For the @todo, I'm not sure what it would say... "Rewrite the help system so this isn't necessary"? :)

Another option here is to use some kind of arg() check to make sure we are on 'admin' or 'admin/index' before removing the block, and thus we more specifically target the help text which system.module added, addressing at least partly the issue @sun brought up. Then there might not be a @todo at all, as I think there is an implicit @todo about removing all uses of arg() throughout core whenever that becomes possible...

catch’s picture

I prefer $block->content = FALSE;

to set #access you'd need to do hook_block_view_alter() or whatever it's called, different hook.

What's the help text that we're removing? Is it worth looking at just killing it? I know we did a big cull of useless help texts but you never know. Not that that solves the overall problem but would save overengineering things here to save a sentence showing up.

aaronbauman’s picture

The help text is

This page shows you all available administration tasks for each module.

aaronbauman’s picture

Status: Needs work » Needs review
StatusFileSize
new16.55 KB

Here's the patch with the help text removed, for argument's sake.

sun’s picture

StatusFileSize
new16.55 KB
+++ modules/system/system.module	27 Jul 2010 15:57:51 -0000
@@ -87,7 +87,8 @@ function system_help($path, $arg) {
+    case 'admin':
+    case 'admin/index':
       return '<p>' . t('This page shows you all available administration tasks for each module.') . '</p>';

It's this help text that is removed. Doesn't really make sense on a page displaying a dashboard, true.

Counter proposal: Drop this help text entirely. Explains "This is a list." on top of a list, thank you.

P.S.: @todo D8: Tie help closely into menu router to prevent such issues.

Powered by Dreditor.

catch’s picture

Status: Needs review » Reviewed & tested by the community

I think aaron and sun uploaded the same patch. That help text is useless wherever it's displayed, RTBC again.

webchick’s picture

Ok. Here's the summary of this issue as I understand it:

1. The "admin/by-task" page, and the "admin/config" page are two slightly different looking screens that both intend to set up a screen for navigating around the administrative section by general topic. This is weird.
2. It's especially weird, given that if you don't have Dashboard module installed, this becomes your default admin page, so you effectively end up with two top-level navigation items that end up at sort of the same place.
3. The "admin/by-module" page is a useful way of getting access to just about all of the configuration options that modules expose. However, it's buried in a tab called "by module" that no one ever finds.

Solution: Rename "By module" to "Index", remove "By Task", and have "Index" slot in for Dashboard when it's disabled.

I'll take a look at this a bit later today. The only real argument I can think of against it is that the D6-style "cockpit of options" IA really didn't test well at UofM, and "By module" adds even more options, as seen in http://spreadsheets.google.com/ccc?key=0AnMmC4VjMWMXdDZzRHEzNU1mTzFfM3At....

OTOH, they're alphabetically sorted by module name, so it'll probably be easier to find stuff than before, once the user understands what a "module" is.

webchick’s picture

Oh, hrm. Well, and also that the default admin page before, for non superusers, was something you could mostly put in front of content editors and the like; it head headings like "Content management" and links like "Content" and "Comments".

Now, that heading gets changed to "Node" on the default admin index. So will effectively be saying "You either need to use Dashboard or a Dashboard module replacement for your content editors in Drupal 7 if you don't want them exposed to scary words like node." That's also going to be the absolute last place content editors would think look for "comment moderation" links.

yoroy’s picture

This is mostly worrying about the case where dashboard is disabled though. Disabling it is already an act of superuserism and then yes, you get this bigass list. The new, hopefully more sensibly organized cockpit for most functionality is the configuration page. This module-index page is here because people in here (which we can safely assume are 24/7 drupal superusers) insisted on having a single page with access to everything.

So will effectively be saying "You either need to use Dashboard or a Dashboard module replacement for your content editors in Drupal 7

Well, that's been a guiding principle from the start so yes, that is what we're saying :) Toolbar, shortcuts, configuration page were all introduced to give people (a sense of) control without having to expose them to a long list of jargon-ish links.

webchick’s picture

Disabling it is already an act of superuserism and then yes, you get this bigass list.

Er, no. Bear in mind that every single site upgrading from D6 to D7 will not have Dashboard enabled...

yoroy’s picture

And who does this upgrade? Probably not someone who is only a content editor.

webchick’s picture

Right, so... what I'm saying is the person who does that upgrade (user 1, the sysadmin) is going to have to do extra work in order to not get absolutely befuddled e-mails from their clients when they attempt to get to the comment moderation screen from /admin (to which their theme might well have a nice link to automatically).

We can accept that this is an okay tradeoff, and just lump it under the other myriad of things you need to do when you upgrade major core versions, but the point stands that for non-web admins, this change is pretty massively invasive, and directly exposes them to system guts they never previously had insight to without a lot of digging.

If the UX team is ok with that, then I am too. I just want to make sure that the ramifications of this patch for the 80%+ of Drupal 7's first users are clear.

Bojhan’s picture

I find it someone strange to provide buy-in on a bad upgrade user experience, obviously thats not desired. But I think we assumed that we can't enable Dashboard by default for purely technical reasons, hence why we didn't put that as a top priority for this getting in. Even without that, this patch should probably be oke - for people who upgrade, enabling new features is likely to be a first goal?

jacine’s picture

We could help the upgraders along by including a one-time message after the upgrade has finished like:

In order to have the best possible experience administering your Drupal 7 site, enabling the following new modules is recommended:

  • Contextual Links
  • Dashboard
  • Toolbar
  • Shortcut
  • Whatever else I'm missing...
webchick’s picture

Status: Reviewed & tested by the community » Needs work

Ok, I reviewed this patch functionality-wise and am still pretty hrm about it.

I like this general concept a lot:

Only local images are allowed.

Dashboard being the admin landing page, custom-tailored to day-to-day tasks, "Index" being essentially a "site map" for the admin panel.

There are a couple of problems with Index:

Only local images are allowed.

The fact that "Comments" isn't showing up here at all appears to be a bug, at any rate, so needs work for that. But the permissions links add a whole lot of weight to this page that the old "By task" didn't have, with its "relatively" manageable 7 categories of stuff, showing off the new IA front and center. Also, "index" is misleading; despite the fact that we add the permissions links, there are still modules which expose admin pages, that don't show up here.

Frankly, in Drupal 7 we already have a "by module" page with direct links to configuration pages and permissions: it's called the "Modules" page. So in that light, "By module" feels totally redundant, and we still have two screens that show essentially the same information, slightly differently formatted. I'm not sure that this help us out much in solving this challenge, and in fact wonder if we'd be better off dropping the "By module" tab instead.

This puts a large burden on everyone upgrading from Drupal 6 (as well as everyone currently installing with the Minimal profile) to go from having a relatively simple, 7-category(ish) link hierarchy organized according to our new IA, to an infinitely-growing morass of links grouped by module name, when content editors, forum admins, etc. and others with access to this screen almost certainly have absolutely no idea what the heck a module even is. This will thrust a bunch of undue work on site upgraders to deal with this issue for their content editors. Overall, it leaves me feeling like this issue is headed in the wrong direction. :\

Why can't "Index" be "By task" again? Because it's too similar to "Configuration"? I kind of agree, but it has several other important links that are not on Configuration, and unless we're planning on changing that (which I don't think we should), we still need an administrative "index" for "mere mortals". At this point, "By task" feels much better for this.

chx’s picture

Also just because Configuration on 'by task' looks more crowded now, it's not going to stay that way once you beign to switch on contrib. A lot of modules will move themselves into Structure, a lot into Content and so on.

willmoy’s picture

I know that many of my users, if they see a link named 'Index', will expect to see an index of the site's content that they can use for moderation etc. That might actually be quite a sensible tab to have up there, come to think of it, but I agree with webchick's implication that 'Index' ought to change. 'By task' is better.

Bojhan’s picture

@webchick I am not sure, you are saying it needs work but the points you mention are mostly inherent to the by module grouping. By task is basically Drupal 6 sitemap, if you want that sure. But it will probably take a lot of effort to make that page usable, I thought the reason of having this is for those upgrading and developers who need to get quick access to functionally.

Index is definitely better then by task, I have no idea why one would think "by task" is better thats only because you understand that label, any new user or somewhat experienced user has no idea what a "by task" page is. I think you are overstretching the upgrade thing way to much, there is no reason those upgrading this should be the end-all. Content editors should not bother with this page.

Anyways I don't know how to continue on this issue as I am feeling unsure about focusing this on content editors, that was not its intended target audience at all. This was for developers or those with deep understanding finding functionality very fast, the Drupal 6 way. I will leave it up to chx or catch to provide direction here.

catch’s picture

Permissions - these were taken out in earlier patches and just put back in again recently, it's easy to remove them.

Comments - it's a tab, this is why it doesn't appear, not sure how much of a challenge it'd be to add this back.

On the overall patch I have no energy to fight this but I predict massive confusion with the current situation as it is, and this at least removes one part of this, while clearly not fixing everything that's wrong with the IA in general.

sun’s picture

re: Comment administration page: Damien prepared a patch over in #652122: Fix dashboard as the default /admin local task, which technically allows to bit-add MENU_VISIBLE_IN_TREE to any local task (or any other item), so as to make it appear in link trees, and thus, also on this index page.

David_Rothstein’s picture

Jacine in #148:

We could help the upgraders along by including a one-time message after the upgrade has finished like:

In order to have the best possible experience administering your Drupal 7 site, enabling the following new modules is recommended:

Yup, and we are already working on that idea here :)

#774316: Remind users about new Drupal 8 features after migration from D7

David_Rothstein’s picture

StatusFileSize
new29.6 KB

Trying to parse the other recent comments here: So we don't want to make this page be the main place to start navigating your admin screens - but how many people will that be the case for? Even forgetting all the new D7 modules, so many D6 sites use admin_menu for that anyway (which they will upgrade to D7)....

So maybe the main issue is just that we are putting it at /admin, where the URL indicates it has more importance than it should, and also where it is at the root of all breadcrumbs if the dashboard module is disabled?

So one possibility would be to leave it at admin/index mostly as it is (which worked well in D6 for people who knew about it, and that includes the "configure permissions" part), but never show it at /admin (even when Dashboard is disabled). Instead we could show a very simple listing of the top-level admin categories at /admin, just like we do on admin/structure or admin/reports but one level up. In other words, something like the attached screenshot but with the list mirroring the items in the toolbar:

  • Content
    Find and manage content.
  • Structure
    Administer blocks, content types, menus, etc.
  • Appearance
    Select and configure your themes.
  • etc.

Maybe?

webchick’s picture

First, to Bojhan:

@webchick I am not sure, you are saying it needs work but the points you mention are mostly inherent to the by module grouping. By task is basically Drupal 6 sitemap, if you want that sure. But it will probably take a lot of effort to make that page usable, I thought the reason of having this is for those upgrading and developers who need to get quick access to functionally.

My understanding was that the purpose of the Index page is a one-stop shop for all admin links that a user has access to. A "site map" of your admin section, if you will, as opposed to an intentionally limited list of the tasks/views one needs 80% of the time (that's the Dashboard). Am I mistaken?

Index is definitely better then by task, I have no idea why one would think "by task" is better thats only because you understand that label, any new user or somewhat experienced user has no idea what a "by task" page is. I think you are overstretching the upgrade thing way to much, there is no reason those upgrading this should be the end-all. Content editors should not bother with this page."

In case this wasn't clear, I definitely wasn't suggesting to re-title "Index" to "By task". "By task" is a horrible name. "Index" is great. But I was suggesting to make the current patch use the "by task" page instead of the "by module" page for the index, and fix whatever is wrong with the by task page that makes you feel exposing by-module classification to people who have no idea what the hell a module is, is a better solution.

And you say "Content editors should not bother with this page", but by virtue of them having "access administration pages" permissions, which they need to have in order to get into the things they might need to do, they will see (and therefore bother with) the page. Additionally, it will be front and center on any Drupal site that doesn't have Dashboard module installed, which means all Drupal sites that are not fresh installs or have not explicitly turned it on, which will be most of them, at least for the next 1-2 years.

Basically, getting the UX right here is really key, because this is not some "sub-tab FYI user 1" kind of page like it's being treated. At least not with the way the patch works currently, due to this hunk:

@@ -523,7 +522,7 @@ function system_menu() {
   $items['admin'] = array(
     'title' => 'Administer',
     'access arguments' => array('access administration pages'),
-    'page callback' => 'system_main_admin_page',
+    'page callback' => 'system_admin_by_module',
     'weight' => 9,
     'menu_name' => 'management',
     'theme callback' => 'variable_get',

That's a change to system.module, which means every single Drupal site is affected by this change. Compare the initial admin user experience on the minimal profile (which is the same as a D6 upgrade) before/after the patch to understand why I'm raising a red flag here.

webchick’s picture

Now, to catch:

On the overall patch I have no energy to fight this but I predict massive confusion with the current situation as it is, and this at least removes one part of this, while clearly not fixing everything that's wrong with the IA in general.

I don't want you to expend a bunch of energy on this, but one thing that I think would really be helpful (esp. with all the various twists and turns this issue has taken) would be to re-summarize what the massive confusion / IA wrongness is that you feel we need to try and fix with this issue. In the OP, you mention 1. the incompleteness of the link listing, and 2. the fact that it looks too similar to admin/config.

A couple of responses to that:

1. I think it's fine that the "by task" page doesn't show every single link; it shows the admin IA / hierarchy, and IMO that's what's important to convey here. http://www.apple.com/sitemap/ doesn't show every single individual knowledge base article on it, nor does it even provide a link to the knowledge base. But it points me at http://www.apple.com/support/ and from there I can find the right set of documents for my product. It's important to note too that this is a categorical listing of a bunch of links, not links grouped by the filename of whatever Python/PHP/AppleScript script is generating them (roughly analogous to what the "by module" page exposes for non-site-builder people).

2. I do see this argument; admin/structure and admin/config look similar, too. The by task page is slightly variant in that the headings are blue instead of black, but that's pretty subtle:

Only local images are allowed.

Just throwing this out there, what if we hid descriptions from the index, like so:

Only local images are allowed.

Then the index would be more of a true "index", it would look visually distinctive from the rest of admin/*, and that feature to turn off descriptions already exists in core, so we wouldn't have to write much code to get 'er done.

webchick’s picture

And finally, to David, did you maybe upload the wrong screenshot? That just looks like admin/structure to me.

David_Rothstein’s picture

And finally, to David, did you maybe upload the wrong screenshot? That just looks like admin/structure to me.

I uploaded the right screenshot, but my explanation wasn't good enough :) Basically, I am too lazy to make an actual mockup, so the idea of my proposal is that /admin would look like that screenshot, but with different content (which I started to write at the bottom of #156...)

In other words, just like admin/structure currently displays a simple list of the top-level menu items underneath admin/structure, /admin could display a simple list of the top-level menu items underneath /admin. It would basically contain the same exact information that the toolbar does, and would be a starting point for drilling down into the admin area. Dashboard module could still hijack it if it wanted to.

webchick’s picture

Oh, ok. I could see that approach too.

I think what we really need to do here is stop and take inventory of what the actual problems are with "By task" that we need to solve, and solve them, rather than radically altering the default administration landing page in everything but new "default" D7 installations, in order to cater to a very small subset of Drupal's audience. That's a complete no-go for me.

I was talking to Bojhan about it in #drupal-usability, and we were scratching our heads with what is so incredibly bad about By task. I mean, sure, UX-wise it's a big ass list of links to greet people, but in that respect isn't any worse than D6's big-ass list of links. Then he pointed out that given the age of this issue, and thought that maybe it was created back when the "By task" page was missing some very critical links, like to /admin/modules, /admin/appearance and such. Is that it? Are we fighting a legacy problem?

I reviewed aspilicious's spreadsheet up above. If you take out all the permissions/get help links (which I would strenuously argue don't need to be on the default admin landing page - if you're a site builder, you can get to these easily from the modules page or "by module" tab), you're basically left with the sub-links under "Configuration". And the fact that we don't show every single link to every single configuration page on the default /admin landing page is a feature, not a bug, since we saw with our own eyes at the UMN usability lab that that many links is totally and utterly overwhelming to new users. So instead, we communicate the hierarchy of the admin panel on /admin, so that users can subsequently drill down and find what they need to find (same as what apple.com is doing on their site).

I'm really, genuinely lost on why this is a critical, beta-blocking, OMG the world is ending issue. It might be that we're missing a couple of key links on by-task, and if so we should fix this. It might be that we need to make this page look visually separate from other admin panels, and if so, we should fix this.

Can someone help me out here?

EvanDonovan’s picture

@webchick: I agree with you. I always thought that having a page with *all* the links as the default /admin would be overwhelming. We should keep /by-task, as long as there aren't any critical tasks, like changing themes or enabling modules, that you can't do from it.

catch’s picture

My view is it's almost indistinguishable from admin/config (i.e. a lot more indistinguishable from node/add and admin/content/types whose similarity came up in usability testing). When I land on admin/index I end up looking for and not finding links on admin/config and vice-versa. Has it been tested at all?

I like David's idea but I doubt we could get it resolved quickly (not that this doesn't look like it's won't fix now, I'll just refer back to here when people show up massively confused, or not).

webchick’s picture

Title: Remove admin/by-task and replace it with admin/by-module » admin/by-task is confusing since it lacks links to config pages and looks similar to admin/config and friends

The only thing I'm won't fixing is the solution that replaces /admin/by-task with /admin/by-module, for the multitude of reasons so outlined. So, updating the issue title to reflect that, and also the true nature of this issue.

Ok, cool. So it sounds like the problem now is indeed less about the lack of individual links available on /admin/by-task (it looks like most of those concerns have been cleaned up, and where they aren't, we can fix it in a separate, "normal" issue), but more about the following:

- admin/ doesn't contain links to stuff under admin/config, and admin/config doesn't contain links to other areas of the admin panel, like admin/structure.
- Because the pages look so similar, people will lose track of which page they're on and end up befuddled why they saw a link to content types on here at one point and can't find it anymore, only to realize eventually they're actually at /admin/config instead of /admin.

Does that about sum it up?

bleen’s picture

subscribing

David_Rothstein’s picture

Does that about sum it up?

I think that's about 95% of it.

The rest is that the other major thing this patch does is that in the course of making admin/by-module into more of a site index, it adds the menu item descriptions to the listing on that page (rather than just the bare menu item names like in D6).

I think that may be a very nice thing we should keep, because of this which I wrote way above:

This is an important issue, because currently with the new IA, there is no single page you can go when you know what you want to administer something but don't know where to find it. #102254: Add an administrative search feature would help with that too, but is almost certainly not going to happen for Drupal 7.

In other words, that thing everyone does every once in a while on /admin of their D6 sites with 100 contrib modules installed: You use ctrl+F in Firefox and search on the page for the thing you're looking for because you don't know how else to find it :)

In D7, we currently don't have any page that makes that (last resort) sort of action easy, which is why making this page into a real index seems like a good idea (even if it doesn't wind up living at /admin).

Allowing that is not a critical issue but is something to keep in mind.

giorgio79’s picture

StatusFileSize
new113.46 KB
new426.3 KB
new156.15 KB
new153.69 KB

+1 for #166.

Also, I became curious from all the comments and installed D7 taking several screenshots of my experience along the way. Check them out :)

On a personal note, I never used the pages everyone talks about here except Modules in d6, since the fantastic Administration Menu module solved all the issues. With it I dont have to click around in a click bonanza looking for a specific admin link. Also was a bit surprised that it has not gone into core, since it is a massive usability improvement over the standard Drupal admin interface with over 140 000 installs...Every admin option is reachable from every admin page with it. It also distinguishes the admin interface from the default one without needing a separate theme. I don't have to go finding an admin page where I can do stuff.

If the admin page would be accessible for Google, lots of it would get filtered out due to duplication and redundancy. :) Perhaps we would get a penalty as well for operating a link farm :D I think we can take the googlebot view as well, and aim for as little duplication as possible. +1 as well for the #1 post by catch.
Basically we should cut down on a link page linking to another page of links. To me it is extermely frustrating. A single admin link page even if it is long is sufficient to me.

So here come the screenshots.

PS: Just found these
#402058: Requirements for Administration menu in Drupal core
#543914: Administration menu or admin_menu should be in core
"It was the UX team's decision that Administration menu is suitable for advanced users only. I won't (ever) agree with that, but it is their (wrong) assumption."

WTF? Has the UX team taken a look at the stats???? Half of the Drupal sites out there use the awesome module. They surely cannot be wrong.... JUST A BIG WTF

Bojhan’s picture

@David I agree, that there is a use case for such a page, but then again its quite a user hacky use case. I mean I am split on this issue, I can see both use cases and not sure which one is more valid long-term.

@giorgio79 With your arguments, Views should be in core, Pathauto ect. This is not the right place to discuss this either. We already agreed we need "one page" index.

giorgio79’s picture

@bojhan:Usage stats was just a small part of my arguments, but if we come to that while Pathauto and Views is a massive functionality improvement, Administration Menu is a massive usability improvement and I thought D7 is about exactly that, hence it is reasonable to expect admin menu in core. Anyways, if it was agreed to have a 1 page index and remove duplicated functionality, then I think that will be a step forward.

webchick’s picture

We are seriously, seriously not re-hashing that admin menu discussion again here (nor the "why is XXX not in core?" discussions). Feature freeze was 11 months ago. Let's focus on "beta 1 before Copenhagen", folks. When D7 gets released you get to pig-pile whatever features you want into D8.

So, who has suggestions on actionable steps forward, given the constraints?

catch’s picture

I don't want D7 to launch with admin/by-task and admin/config, "link farm linking to another link farm" is a nice way of putting it.

If using by-module is won't fix, then I'd go for David's suggestion of the short list - that's more or less going to end up the same list of links as in the toolbar, which is probably fine.

webchick’s picture

Ok, cool. Let's try that then.

And let's go ahead and carry over the "Index" renaming (which is quite nice) and the improvements to the "By module" tab, and see what we end up with.

aspilicious’s picture

Didn't read anything. But if we end up with a short-list and an index we should include deeply hidden drupal 7 config pages as "roles". In drupal 7 roles is a subpage of permissions. Could'nt find this on the current "by task" or "by module".

If this comment is useless ignore it ;)

catch’s picture

As part of the by-module improvements we could try to add tabs in there, afaik that's only possible with the menu/dashboard/toolbar patch linked above though.

kaakuu’s picture

"We already agreed we need "one page" index."

It will be nice and USEFUL and practical to have this page as overlay / drop-down available at a single click from any admin page ( like Add content is available non-contextually in all pages) so that we get access to this handy at ALL points during the admin and not have to click, re click, grope etc.

In another way of putting it : if we have an "one page" index, it should be available easily and always.
Keeping it as a soft popup / dropdown / thickbox / overlay HELPS in the same way as the "overlay" helps.

matason’s picture

I was away on hols for two weeks so missed out on the recent discussions, I'd be happy to work on a patch based on @webchick's comment in #172, also taking in what @catch says about tabs in #174 too if we feel that's the best way forward?

Bojhan’s picture

Meh, so what are we doing here? @catch You have been incredibly vague on this one, what is that we want to be coded?

David_Rothstein’s picture

I think we are agreeing that we want to keep what the patch did at admin/index, but only show it at that URL, not at /admin.

And at /admin, show the simple listing of the top level items, as I described above.

Does anyone disagree with that? :)

The only remaining question I can think of is if Dashboard is enabled and takes over /admin, is that simple listing page not accessible at all, or via a tab/local-task? (Adding a new tab to the UI there might be weird, but having this page totally disappear from your site might be weird also.)

sun’s picture

#178 makes sense, keep it as separate tab. I'd simply call that tab "Administer", i.e. the original page/link title that Dashboard replaced. Thus, users enabling or disabling Dashboard are not totally lost when searching for "that page that was previously there and called Administer, IIRC..." #drupal-support will love you, thanks.

Bojhan’s picture

No, administer is a bogus word. It has no descriptive value to a user - lets keep it at the agreed upon Index label. Having the index moved to front when the dashboard enabled - as a label adds no more confusion then administer.

Spoke to David to really understand what he is proposing :

Two pages
1. By module/Index (as per patch)
2. By-task

This would mean two tabs on the Dashboard, obviously not acceptable. I don't get why we don't just cut down to one page, name that Index fill it with what a useful index would be like and be done with this issue? I mean that proposal was on the ground for weeks and now got changed again.

David_Rothstein’s picture

To clarify, this from above is what we are focusing on now:

The only remaining question I can think of is if Dashboard is enabled and takes over /admin, is that simple listing page not accessible at all, or via a tab/local-task?

Because that is what affects how many tabs show on the dashboard. Various options are being discussed in IRC :)

Bojhan’s picture

So the option we suggested:

Index

This shows a filter/secondary navigation that links to by-module.

David_Rothstein’s picture

Note that with http://drupal.org/node/652122#comment-3340494 we'd be able to meet the UX goal of avoiding tabs on the Dashboard altogether - the dashboard would just be a page unto itself, not mixed up with other /admin stuff at all, so no tabs would show there.

And then the new (simplified) /admin page we are introducing here in this issue would work perfectly as the root of all admin breadcrumbs, since it's nice and simple and doesn't assault people with a disorganized list of 8,000 links - thereby removing the rationale for Dashboard needing to take over /admin in the first place.

Maybe with that we can finally be done going in circles? :)

Bojhan’s picture

Ok, patch please :) I dont know what you want to show here now - so.

yoroy’s picture

My understanding of this: http://img.skitch.com/20100818-g6crx7a4jbmwsrrpc9aws4iu5q.jpg

Edit to just show the link to the image, not the image itself. Updated mockup below

moshe weitzman’s picture

For the record, I agree with webchick in #166. IMO the current /admin (with dashboard disabled) is decent, and definately not a critical bug. I'd like to see more config links there, but thats a normal priority bug IMO. I'm gonna be humble for once and not waltz in here and demote. But I do think thats accurate.

Bojhan’s picture

Lets get a patch up, I applaud the effort to reduce the critically of issues. But its somewhat misleading, because things like this do need to get fixed for the product release.

yoroy’s picture

Like this but without the dashboard tab? I added some notes expected issues with directly mapping the top level IA + subs on here in a contrasting color :)

Only local images are allowed.

David_Rothstein’s picture

To me that looks a lot like admin/config when the descriptions are hidden... and not too different from the current /admin.

I thought we were leaning towards a solution that really tried to separate the two pages visually, which is why I suggested #156/#160 since that's the only thing I can think of that (a) makes sense at /admin, and (b) looks nothing like admin/config.

Are we all on the same page here? :)

webchick’s picture

yoroy's #188 is basically what I suggested at the bottom #158. The removal of descriptions on /admin I believe fixes the problem of it looking too similar to other admin pages. David's suggestion at #156/160 resolves this as well, but does so by removing most links from the page, which is the exact opposite of what was asked for earlier in the issue, a "one-stop shop" for all admin links.

I don't have a really strong preference either way. It sounds like we have two viable proposals, we probably just need some patches so we can compare/contrast them.

EvanDonovan’s picture

I think yoroy's #188 would make sense to people coming from D6, but should have a different title than "Admin". I don't think something like "Administer Site" would be meaningless - the concept of a site administrator is fairly common.

Since Configuration and Help don't have sub-links the top-level headings should probably be links. I don't think Configuration should be subordinated to modules.

It seems to me that possibly this issue originated in the first place because Configuration was put a level down in the IA - burying things like that might have actually made it less easy to administer a Drupal site than it was in D6.

David_Rothstein’s picture

@webchick, you are right; somehow I missed that even though you had a screenshot (I guess because it was a screenshot underneath another screenshot)...

Either approach results in at least one page on the site that is a "one-stop shop" for admin links, but the difference is in where those pages live and how many they are.

Agreed on the need for a patch - this issue is now having a lot of people talk past each other :) And now is a good time since #652122: Fix dashboard as the default /admin local task was just committed.

I will work on a patch (one of them, at any rate).

***

EvanDonovan: I think the assumption (good or bad, and maybe not even explicit) was that everyone would always be using some kind of toolbar in D7. If you are using a toolbar, then Configuration is just as easy to get to as it was before. A "one-stop shop" is necessary to have somewhere, but the question is whether it should be anywhere near as prominent as in D6.

David_Rothstein’s picture

Status: Needs work » Needs review
StatusFileSize
new24.44 KB
new228.48 KB
new43.56 KB
new27.81 KB
new137.19 KB
new122.39 KB
new19.72 KB

OK, I started with the previous patch (#139) and made the changes I proposed above. The new patch is attached along with before/after screenshots of the two admin tabs and the dashboard.

Some notes about the UI visible in the screenshots:

  1. admin_AFTER.png: The top-level /admin page is now just a standard lead-in to the rest of the IA (similar to the toolbar, admin/structure, etc). No chance of confusing it with admin/config.
    • You can see by comparing the screenshots that I left out the "one or more problems were detected with your Drupal installation" message because it's really not clear what pages that should and shouldn't be on but it didn't quite seem like it belonged on this one (we need another issue maybe).
    • The missing periods on the menu descriptions are killing the grammarian in me - I tracked it down and they appear to have been done that way on purpose in #620616: Fix inconsistencies in menu description labeling so they would look good as tooltips in the toolbar, but we'd need to reconsider that here; sentences should have periods at the end :)
  2. admin_by_module_index_page_AFTER.png: The admin/index page is a spruced-up version of the former admin/by-module page (with descriptions), just like the previous patch. This probably could still look a bit like admin/config (there is inherent tension in that the more we make a page useful as an index, the more it will look like admin/config) but I think this is much less likely to cause confusion because it's hidden on a tab rather than front-and-center and of course the categories are very different.
  3. dashboard_AFTER.png: The dashboard is now without tabs, as promised :)

Some notes on the code:

  1. We don't seem to need the $unexpected_argument stuff anymore (at least I don't think), since just like the current behavior where typing, say, "admin/structure/blocks" (when you meant "admin/structure/block") automatically sends you to "admin/structure" which has a nice listing that quickly lets you click on "Blocks" and go on your merry way, same thing can happen here if you type "admin/contents" when you mean "admin/content"... no difference there, so no longer any reason to be inconsistent and have extra code to show Page Not Found to those people.
  2. With the old /admin page ripped out, we can roll back some complicated code that was added in to system_admin_menu_block() in #550718: admin/people needs to have a default tab (was: Tabs on admin pages are not accessible from overviews and menus) to support showing local tasks in the listing on that page (and in fact, I need to do that or otherwise admin/index would have shown up as one of the items on the list at /admin). We might need to add some of that back elsewhere though, if we want to show a larger, more complete set of links on admin/index as was discussed recently above.

Status: Needs review » Needs work

The last submitted patch, admin-index-699848-193.patch, failed testing.

Bojhan’s picture

StatusFileSize
new89.99 KB

Can webchick chime in that this is oke or not?

yoroy’s picture

StatusFileSize
new192.07 KB

Thank you David. Visual summary of what the latest patch does:

David_Rothstein’s picture

Status: Needs work » Needs review
StatusFileSize
new20.39 KB

Quick fix for the broken test so we can keep this at "needs review" :)

sun’s picture

Status: Needs review » Needs work

Makes sense.

Summary:

- by-task becomes a mirror of links in the toolbar
- by-module becomes the index (though styling is too heavy for a full index)
- dashboard gets no tabs

+++ modules/dashboard/dashboard.module	20 Aug 2010 20:51:02 -0000
@@ -30,9 +30,8 @@ function dashboard_menu() {
-    'type' => MENU_LOCAL_TASK | MENU_NORMAL_ITEM,

This also hides Dashboard from the Toolbar though.... ERR. No, it's a normal item now! Nice! :)

+++ modules/locale/locale.module	20 Aug 2010 20:51:02 -0000
@@ -136,6 +136,7 @@ function locale_menu() {
+    'type' => MENU_CALLBACK,

@@ -143,6 +144,7 @@ function locale_menu() {
+    'type' => MENU_CALLBACK,

Those two need to be removed, since these changes break breadcrumbs.

+++ modules/system/system.module	20 Aug 2010 20:51:03 -0000
@@ -87,7 +87,10 @@ function system_help($path, $arg) {
+    case 'admin/by-task':
+      return '<p>' . t('It feels like we need some text here...') . '</p>';

I don't think so.

+++ modules/system/system.module	20 Aug 2010 20:51:03 -0000
@@ -538,15 +541,12 @@ function system_menu() {
   $items['admin/by-task'] = array(
...
+    'title' => 'This tab needs a new name!',

How about "List" ?

+++ modules/system/system.module	20 Aug 2010 20:51:03 -0000
@@ -2008,6 +2008,16 @@ function system_preprocess_block(&$varia
+  // If we are calling this function for a menu item that corresponds to a
+  // local task (for example, admin/by-task), then we want to retrieve the
+  // parent item's child links, not this item's (since this item won't have
+  // any).
+  // @todo Not sure if this is completely correct.
+  if ($item['tab_root'] != $item['path']) {
+    $item = menu_get_item($item['tab_root']);
+  }

The @todo can basically be removed, but then we have to wait for #576290: Breadcrumbs don't work for dynamic paths & local tasks to land first, so you're able to pass tab_root_href here, because menu_get_item() expects a (translated) href, not a (untranslated/dynamic) path, and tab_root is a untranslated path.

+++ modules/system/system.module	20 Aug 2010 20:51:03 -0000
@@ -2017,26 +2027,12 @@ function system_admin_menu_block($item) 
-    SELECT m.load_functions, m.to_arg_functions, m.access_callback, m.access_arguments, m.page_callback, m.page_arguments, m.delivery_callback, m.title, m.title_callback, m.title_arguments, m.theme_callback, m.theme_arguments, m.type, m.description, m.path, m.weight as router_weight, ml.*
+    SELECT m.load_functions, m.to_arg_functions, m.access_callback, m.access_arguments, m.page_callback, m.page_arguments, m.delivery_callback, m.title, m.title_callback, m.title_arguments, m.theme_callback, m.theme_arguments, m.type, m.description, ml.*

Odd. You're removing $item['path'] here? Note that {menu_links} have a link_path, no path.

+++ modules/system/system.module	20 Aug 2010 20:51:03 -0000
@@ -2783,15 +2774,28 @@ function system_get_module_admin_tasks($
+  $permissions_menu_item = menu_get_item('admin/people/permissions');
+  $permissions_menu_item['description'] = NULL;
+  $permissions_menu_item['title'] = t('Configure @module permissions', array('@module' => $info['name']));

menu_get_item() checks the permission to that path, so $item['access'] may be used instead of existing code to determine whether the user is able to access that link.

Not sure why 'description' is not simply unset() ?

Powered by Dreditor.

giorgio79’s picture

+1 for #195
Otherwise this is a big step forward.

It seems there is a lack of focus due to new naming conventions in D7 vs D6. Like "People" vs "User" , "Appearance" vs "Themes"...

If we combine the new admin_AFTER.png with admin_by_module_index_page_AFTER.png and make it one page the Drupal admin ui would get a massive focus.
The new admin_AFTER.png while contains the new menu structure which is quite poetic with words lke "People" "Appearance" "Structure", yet it essentially links to the same functionality as admin_by_module_index_page_AFTER.png.

The only functionality that the admin_by_module_index_page_AFTER.png is not linking to is "Appearance" aka Themes...

Otherwise they overlap, as both have links to Help, Reports, Configuration,Content etc.

aspilicious’s picture

Yeah from my point of view this needs 2 major things as I pointed out before.

1)

User
- ....
- People (==> two links inside, account settings and IP address blocking)
- Permissions (==> has a secondary tab called roles)
- ....

Should become

User
- ....
- Account settings
- IP address blocking
- People (In this case people link is useless as it only redirects you to a page with 2 links alrdy in this list but maybe there are some top level links with more information inside)
- Permissions
- Roles
- ....

If I'm correct this is what David wants to do (expressed in a less technical way)
I won't be satisfied if it turns out we can't do this. But will accept the technical limits.

2) It needs some basic styling, with basic I mean I think the current page (with "hide descriptions" on) is still not good enough. (you will need to scroll alot)

3) FOR D8: we need to add a filter on this page :), like we were planning to do on the modules page, sometimes I'm like: "let's add a role" ==> "Crap I need to scroll until I find it".

ronald_istos’s picture

subscribing

webchick’s picture

I couldn't find catch here at the summit (I saw him earlier, but now he is gone :\), but the screenshot looks good to me (barring minor labeling issues others have mentioned), and I cleared it with chx who's a prominent user of the minimal profile and he says he's good with it, too. Sounds like the UX team is as well, so WOOT! Progress!

Let's address sun's feedback and get this sucker in!

webchick’s picture

To clarify, I was referring to Bojhan's screenshot in #195.

#200 seems like it's talking about yoroy's suggestion in #188, which we're no longer doing.

yoroy’s picture

I'm quite happy with this approach: a simple list that won't be confused with configuration page and it simply makes sense: It's not the most elegant, but you almost certainly won't feel lost when landing on this screen.

We don't need text along the top. As for this page name, 'Administration' is probably our best bet.

ronald_istos’s picture

Assigned: Unassigned » ronald_istos

I am working on addressing sun's feedback given that everything else seems to be ok

ronald_istos’s picture

I am working on addressing sun's feedback given that everything else seems to be ok

aspilicious’s picture

Amazon asked for my opinion.

I agree we need to get this fixed asap.

I maybe not entirely agree about which links should be on the index BUT
1) That isn't critical at this point.
2) maybe I misunderstood some things, they maybe get clear when I played with it some more when this is in.

So this gets a (soft) green light for me ;).

David_Rothstein’s picture

I agree with @aspilicious that we definitely want to get a bigger set of links on the index page here. That is the only way in which it will really behave like a true index. (And it's related because currently some of those deeper links do show up on the listing at /admin, which we are removing.)

In terms of the tab names, "List" (in addition to "Index") might work although honestly I'm not convinced that either of those are an improvement over just leaving it at "By task" and "By module"? Which at least had the advantage of being explicit :)

The reason I thought we needed some text on the top of /admin maybe had more to do with the way Seven themes this than actually needing some text for the text's sake. We'll see...

From @sun's review:

+++ modules/locale/locale.module 20 Aug 2010 20:51:02 -0000
@@ -136,6 +136,7 @@ function locale_menu() {
+ 'type' => MENU_CALLBACK,

@@ -143,6 +144,7 @@ function locale_menu() {
+ 'type' => MENU_CALLBACK,

Those two need to be removed, since these changes break breadcrumbs.

Does anyone remember (from above) why those changes were included in the first place? I thought it had something to do with getting the correct links to appear on the index page.

+++ modules/system/system.module 20 Aug 2010 20:51:03 -0000
@@ -2017,26 +2027,12 @@ function system_admin_menu_block($item)
- SELECT m.load_functions, m.to_arg_functions, m.access_callback, m.access_arguments, m.page_callback, m.page_arguments, m.delivery_callback, m.title, m.title_callback, m.title_arguments, m.theme_callback, m.theme_arguments, m.type, m.description, m.path, m.weight as router_weight, ml.*
+ SELECT m.load_functions, m.to_arg_functions, m.access_callback, m.access_arguments, m.page_callback, m.page_arguments, m.delivery_callback, m.title, m.title_callback, m.title_arguments, m.theme_callback, m.theme_arguments, m.type, m.description, ml.*

Odd. You're removing $item['path'] here? Note that {menu_links} have a link_path, no path.

Mostly what I was doing there is rolling back the change from #550718-29: admin/people needs to have a default tab (was: Tabs on admin pages are not accessible from overviews and menus), and I think it's OK because we are treating these as pure menu links in the code that follows, but maybe needs to be looked at more closely. Overall, this code is a bit sketchy no matter what since it is basically trying to build up a "fake" menu link rather than loading one the normal way via menu_link_load().

ronald_istos’s picture

Status: Needs work » Needs review
StatusFileSize
new18.23 KB

ok so here is an updated patch addressing sun's main concerns and working against current head.

Name: I've named it "Administration List" because "administration" was too much a repetition of "administer" and too generic

the variable here

$permissions_menu_item['description'] = NULL;

needs to remain null (and not unset) because things fail in various ways if not (theming looks for description). Left the todo in as a reminder.

The rest were dealt with as above.

catch’s picture

I was out sightseeing for a bit this afternoon. Agree with the approach being taken here fwiw, didn't fully review latest patch.

Letharion’s picture

Amazon asked me to review the patch, and I've done so, mainly with regard to sun' #198 comments. I think they have all been addressed, either in the patch, or otherwise in comments.
I'm slightly confused by the #199 comments though, not sure how they should be addressed.

Letharion’s picture

Status: Needs review » Reviewed & tested by the community
Bojhan’s picture

I highly doubt that this is RTBC, it hasn't gotten a thorough code review yet. Also administration list is somewhat overdoing it, I would go with just "administer"

ronald_istos’s picture

I am not going to get into a semantic argument but "Administer" is a verb... and Index (which is next to it) is not.

Sun reviewed the code - my changes are fixes to conform to that review and the poster above you had a further look.

yoroy’s picture

Functionally the patch is done. But the 'Administer' page title is not a good choice imo. All page titles are ( or should be) using nouns, not verbs. Verbs are for actions and links, nouns are for labeling form elements, pages, field sets etc. Seems minor but considering it's location near the actual action links ('add foo') it's worth it to avoid any confusion there.

Let's do 'Administration' (we refer to adminstration pages all over the documentation, right?) for the page title and either use the same term for the tab (no reason to use two different words to indicate the same thing, it adds confusion) or only 'List'. I would suggest 'Administration' on the tab: [Administration] [Index] will make a nice pair that support eachother's meaning, whereas [List] [Index] are too similar and meaningless in comparision.

The overall solution feels great though, glad to see this resolved.

ronald_istos’s picture

Status: Reviewed & tested by the community » Needs work

@yoroy ok - agreed let us to Administration and get this fixed :-) patch following.

ronald_istos’s picture

Status: Needs work » Needs review
StatusFileSize
new18.03 KB

here is the patch once more - with Administration instead of "Administration List" - hopefully this is ok now.

yoroy’s picture

I meant to say use Administration for the actual page title as well so that 'Administration' will also be used in the breadcrumbs etc.
http://skitch.com/yoroy/dugx7/administer-d7

ronald_istos’s picture

StatusFileSize
new18.1 KB

Patch to use Administration both for page title and the tab name as yoroy's suggestion above.

Bojhan’s picture

Alright, makes sense. Can we get a technical review?

sun’s picture

Status: Needs review » Needs work
+++ modules/system/system.module	Mon Aug 23 14:48:41 CEST 2010
@@ -87,7 +87,10 @@
-    case 'admin/by-module':
+    case 'admin':
+    case 'admin/by-task':
+      return '';

Please remove the 'admin' + 'admin/by-task' cases entirely.

+++ modules/system/system.module	Mon Aug 23 14:48:41 CEST 2010
@@ -538,15 +541,12 @@
   $items['admin/by-task'] = array(
...
+    'title' => 'Administration',
...
+  $items['admin/index'] = array(
+    'title' => 'Index',

1) Why is the internal path still admin/by-task? Needs to be updated accordingly.

2) Isn't "Index" the administration index? So "Administration" will get you to your site's administration, but "Index" not? We already clicked on "Administration" (admin). Perhaps "Tasks" (not "by task") wasn't entirely wrong. Tasks + Index would work better for me.

+++ modules/system/system.module	Mon Aug 23 14:48:41 CEST 2010
@@ -2008,6 +2008,15 @@
+  // @todo Not sure if this is completely correct.

Please replace this line with:

@todo Use tab_root_href instead, when made available.

+++ modules/system/system.module	Mon Aug 23 14:48:41 CEST 2010
@@ -2783,15 +2773,28 @@
+  $permissions_menu_item['description'] = NULL;

Still should be unset() ?

Powered by Dreditor.

bojanz’s picture

Status: Needs work » Needs review
StatusFileSize
new81.88 KB
new19.56 KB

I've addressed sun's technical concerns and tried his "Tasks suggestion" the url is now "admin/tasks" and the tab is "Tasks".
It's still "Administration" in the breadcrumb and title though.

Attaching the patch and a screenshot, let me know how you want to proceed.

sun’s picture

Status: Needs review » Reviewed & tested by the community

Lovely! Thank you!

Can we all agree that we're finally done with this now?

Bojhan’s picture

Assigned: ronald_istos » Unassigned

Well, oke then - because you ask it so nicely.

yoroy’s picture

What do you mean 'finally' :)
Yup, looks good.

David_Rothstein’s picture

Status: Reviewed & tested by the community » Needs work
  1. +      // Move 'Configure permissions' links to the bottom of each section.
    +      if (isset($admin_tasks[-1]) && $item = $admin_tasks[-1]) {
    +        unset($admin_tasks[-1]);
    +        $admin_tasks[] = $item;
           }
    -
           // Sort.
           ksort($admin_tasks);
    +      // Move 'Configure permissions' links to the bottom of each section.
    +      if (isset($admin_tasks[-1]) && $item = $admin_tasks[-1]) {
    +        unset($admin_tasks[-1]);
    +        $admin_tasks[] = $item;
    +      }
    

    Why is this code now being duplicated? Also, it doesn't seem to work anymore - with this latest patch the configure permissions are showing at the top, not the bottom.

    Also just realizing that the code is a little strange for a couple of reasons. Can't we just do

      if (isset($admin_tasks[-1])) {
        $admin_tasks[] = $admin_tasks[-1];
        unset($admin_tasks[-1]);
      }
    

    instead?

  2. +  unset($permissions_menu_item['description']);
    

    The comment by @ronald_istos in #209 was correct - this leads to a ton of PHP notices when I visit the index page. We probably should go back to explicitly setting it to NULL (or else fixing the root of the problem in the theme function, if that's where the real problem is).

  3. +        // The link 'description' ? either derived from the hook_menu
    +        // 'description' or entered by the user via menu module ? is saved as
    +        // the title attribute. The title attribute is then unset to reduce
    +        // redundancy in admin pages for screen readers.
    

    Those question marks are supposed to be dashes - looks like a text editor messed them up somewhere along the way?

  4. We need some kind of change to the Locale module in this patch (which was in earlier patches) - because otherwise with the Locale module enabled I get two menu items ("Session language detection configuration" and "URL language detection configuration") showing up on the Index page with no descriptions. I looked back through the issue and it seems like earlier patches in this issue (e.g. #124) added descriptions for those two items, then later patches changed them to MENU_CALLBACKs instead (which probably made them not appear on the index page at all), then later patches removed that :) Do they belong on the index page at all? Maybe we should just go back to adding descriptions for them and leaving it at that?

Otherwise, this is looking great - there are some followups to propose (like especially trying to get more links to show up on the Index page) but I think that can be handled later.

bojanz’s picture

Status: Needs work » Needs review
StatusFileSize
new20.12 KB

Me again. Doesn't address everything, but it's a step forward in any case.

Fixed the mangled comment (dash)
Added a chunk that fixes the notices on Index (isset() in seven_admin_block_content, wasn't sure whether to add it to theme_admin_block_content too). Perhaps the NULL approach was better...
Fixed the reordering of tasks as suggested by David (tested, works).

Is there any reason why the admin index callback is still called system_admin_by_module? The function name and the comment could be updated...

Edit: just saw that I replaced the other dash with a comma instead. That can be fixed in the next iteration, let's agree on the next steps first (David's #4, etc)

sun’s picture

StatusFileSize
new30.48 KB

Thanks, bojanz!

However, studying these functions and their usage a bit more, I'd call them a total mess. Additional changes in this patch:

- Fixed $item['description'] PHP notice.

- Renamed system_admin_by_module() and corresponding theme functions into system_admin_index(), corresponding to the new purpose and link title.

- Moved system_admin_block() into system.admin.inc. This code is needlessly loaded on every single request.

- Use proper db_select queries for better code readability and maintenance.

- Cleaned up theme_admin_block_content() functions.

Status: Needs review » Needs work

The last submitted patch, drupal.system-index.228.patch, failed testing.

David_Rothstein’s picture

Whoa there... Moving those things around just made the patch increase by 50% in size and much harder to review the actual changes. Transferring that function over to system.admin.inc may make sense, but then again, it might not (as can be seen from the patch it now requires the node module to sometimes load the system.admin.inc file which is a bit strange). More important, it has *nothing* to do with this issue. How about creating a separate issue for it?

I also don't see any overwhelming reason to rename system_admin_by_module(), since it still does what it did before - returns a list of admin items organized by module. Updating the PHPDoc may make sense.

I do agree with fixing up the theme functions, though - since in this issue we are trying to do something reasonable with them (pass in menu items that don't have a description) which they currently can't handle. And the workaround of setting the description to be explicitly empty seems to not be complete, since it looks like the theme functions would still be printing out HTML for the non-existent description in that case. So actually, maybe the check added by this patch should be more like !empty($item['description']) rather than isset($item['description'])?

I'll hopefully have time to look at this again tonight (EDT) if you DrupalCon attendees don't get to it first :)

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new30.56 KB

Attached patch should fix the exceptions.

- Node module only needs to manually include system.admin.inc, because the page callback lives in node.pages.inc already and we can only auto-include one file per router item. All other router items are including system.admin.inc already.

- If it's correct to fix the theme function name, then it's also correct the corresponding page callback, as both are tightly connected.

- The theme function(s) are already fixed to properly account for a possibly missing description key.

bojanz’s picture

Much better.
And that function (by-module) needed to be renamed, no doubts about it.

So, what's left?

David's #4?

We need some kind of change to the Locale module in this patch (which was in earlier patches) - because otherwise with the Locale module enabled I get two menu items ("Session language detection configuration" and "URL language detection configuration") showing up on the Index page with no descriptions. I looked back through the issue and it seems like earlier patches in this issue (e.g. #124) added descriptions for those two items, then later patches changed them to MENU_CALLBACKs instead (which probably made them not appear on the index page at all), then later patches removed that :) Do they belong on the index page at all? Maybe we should just go back to adding descriptions for them and leaving it at that?

We're almost there :)

sun’s picture

StatusFileSize
new34.41 KB

yay! That sounds like expectations. I already wondered whether we really don't have any :P

This patch should fail.

Status: Needs review » Needs work

The last submitted patch, drupal.system-index.233.patch, failed testing.

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new34.4 KB

Not the expected failures. :P

Status: Needs review » Needs work

The last submitted patch, drupal.system-index.235.patch, failed testing.

David_Rothstein’s picture

Assigned: Unassigned » David_Rothstein

OK, seriously, please.

Reorganizing system.module and improving some of its weird functions might definitely be a wonderful idea, but it has absolutely nothing to do with this issue - we aren't doing it here.

And I really don't see a great reason to rename any functions at all. Functions should be named based on what they do, and that hasn't changed here. Just because we are displaying it at a different URL doesn't mean all the functions have to be renamed.

I think what we need to do here is go back to the patch by @bojanz in #227, merge in the fixes for the 'description' in the theme function from @sun's patch, as well as the tests (those look awesome, by the way), make the tests pass, and then be done with it :) Anything else should happen in a different issue, not here.

David_Rothstein’s picture

Status: Needs work » Needs review
StatusFileSize
new26.61 KB
new25.57 KB

Here are patches, as per above. One should have only the two test failures we expect, and the other makes the changes to the Locale module so that all tests pass.

I made them pass by going back to the earlier approach of changing those two Locale module paths to be MENU_CALLBACK. It was stated above that this might break breadcrumbs, but it doesn't seem to (these links are "endpoints" - they don't have any children - and therefore already don't appear in the breadcrumb).

However, I think it is likely this still isn't the correct fix. As the tests show, these two items already do not show up on other admin listing pages (e.g., admin/config), so something is wrong with admin/index specifically that it is showing them.

sun’s picture

Status: Needs review » Needs work

We may skip the additional clean-ups & moving of functions, but you didn't take over the improved code for these functions at all. I've spent quite some time with them for #235. At minimum, system_get_module_admin_tasks() needs to be fully taken over, but I've equally improved the other main functions touched by this patch, by improved caching and making the code paths perform better.

Adding MENU_CALLBACK to those Locale menu items is not the proper solution, as that by coincide may work for Locale's sub-configuration forms there, but that's quite uncommon. So it looks like we have to postpone this patch until #576290: Breadcrumbs don't work for dynamic paths & local tasks landed, so as to get a better understanding of possible router items below admin/*/*.

I'm not sure why your tests are suddenly not throwing countless of failures, but I'm glad you fixed them. However, I don't agree with the foreach used in there, since we want to test each of those pages separately in detail there. You already removed two expectations that are no longer asserted now.

David_Rothstein’s picture

I used the foreach() because for now the tests for each page are almost identical, but if we make them different enough I am fine with not having it. I don't think I removed two expectations (at least not intentionally?), although I did remove one:

+    // @todo Should a link to admin/config be contained in the index? It is
+    //   currently.
+    $this->assertLinkByHref('admin/config');

Maybe I shouldn't have removed that though.

Many of the system.module caching and other improvements looked like they were probably very good, but I just don't see why it's related and don't want to spend time doing a detailed review in the context of this critical issue... AFAIK we haven't made any changes in this issue that would hurt performance. Even in system_get_module_admin_tasks(), all we really did is add a menu_get_item() call, but menu_get_item() itself is already cached... so why complicate this? If you file those improvements as separate issues and link back here I do promise to review them :)

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new33.96 KB

== it makes no sense to do improvements in a follow-up. Logical recursion error.

Merged your improvements into #235 and reverted moving of functions into system.admin.inc.

Status: Needs review » Needs work

The last submitted patch, drupal.system-index.241.patch, failed testing.

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new33.96 KB

Status: Needs review » Needs work

The last submitted patch, drupal.system-index.243.patch, failed testing.

webchick’s picture

Hello! Now that we've reached consensus after 200 or so replies, it'd be lovely to get a patch in to clean this up before beta.

philbar’s picture

webchick - Where do we stand on the next alpha/beta release of D7? Wasn't there supposed to be one early august? There are 6 or so beta blocking issues left; Was it decided to wait for those to be fixed?

tstoeckler’s picture

+++ modules/system/system.test	26 Aug 2010 19:58:14 -0000
@@ -1846,21 +1846,103 @@ class ShutdownFunctionsTest extends Drup
+    $this->web_user = $this->drupalCreateUser(array(
+      'access administration pages',
+      'translate interface',
+    ));
...
+    $this->drupalLogin($this->web_user);
+    $this->drupalGet('admin/config');
+    $this->assertResponse(403);

Regarding the failing test:
Why are you asserting 403 when the user actually has access to the administration pages. Am I missing something or is that a bug in the tests?

Powered by Dreditor.

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new33.83 KB

Because this is insane. I naturally expected that 'admin/config' is only accessible if the user has the "administer site configuration" permission, but D7's new IA totally invalidates the meaning of that permission. And that cannot be fixed, because the new IA expects that modules not fitting elsewhere shall simply add their stuff to Configuration, even if their items have nothing to do with configuration. *sigh* Yes, I still recommend to revert the new IA.

Bojhan’s picture

Assigned: David_Rothstein » Unassigned
Category: task » bug

Can someone review?

bojanz’s picture

I see sun's comment above:

So it looks like we have to postpone this patch until #576290: Breadcrumbs don't work for dynamic paths & local tasks landed, so as to get a better understanding of possible router items below admin/*/*.

Is this still valid?

The patch applies cleanly, and works as advertised on a fresh D7 Head.
The things I noticed during my rerolls (function names...) have long since been fixed.

What is left to be done on this issue? Is there anything that can't be done in a follow-up?
Let me know how I can assist.

yoroy’s picture

#248: drupal.system-index.248.patch queued for re-testing.

int’s picture

Issue tags: -beta blocker

in the beta blockers page say that this is beta 2 blocker.

philbar’s picture

Issue tags: +beta blocker

int - I'm not seeing this. It's clearly a beta 1 blocker

moshe weitzman’s picture

Issue tags: -beta blocker

Why? The main special thing about beta is that we try not to make schema changes after that. No schema change here. If anything, this is an RC blocker.

aspilicious’s picture

Stop arguing about the status, please review this damn needed patch and get this in (or say how we have to change it) ...
Please?

Greetzzzz,
Aspilicious

sun’s picture

StatusFileSize
new33.45 KB

Re-rolled against HEAD. Sorry, I'm not able to assign this issue to me, because my personal queue has already reached its limit and is full of RTBCs I've to care for. But nevertheless, will try to tackle this one. If Dries and webchick can care for my RTBCs, I'd have room for this and other issues.

Attached patch takes #907690: Breadcrumbs don't work for dynamic paths & local tasks #2 into account. To move forward here, I need someone of you to apply the patch, enable *all* core modules, and post screenshots of /admin, /admin/index, and /admin/config afterwards. Any takers? (We are looking for stale entries in those lists that should not appear there.)

janusman’s picture

Assigned: Unassigned » janusman

I can take a few screenshots, wait 10 min.

bojanz’s picture

Status: Needs work » Needs review
StatusFileSize
new71.61 KB
new69.99 KB
new115.21 KB
new122.65 KB
new92.63 KB
new85.8 KB
new115.51 KB
new108.49 KB
new136.86 KB
new125.22 KB
new73.1 KB

Applied the patch, installed D7, enabled all core modules.

1) Even though Dashboard is enabled, I don't see it anywhere?
2) admin/index has problems.
Notice the Dashboard block which has three same-named Dashbord links. The first two show the same name & description.
They link to: admin/dashboard/customize, admin/dashboard, admin/structure/dashboard
This is shown on admin_index_1 and admin_index_2
Also, what's up with help?

And the large number of pictures is due to the fact that my screen resolution sucks.

janusman’s picture

Assigned: janusman » Unassigned
Status: Needs review » Needs work

Sorry, there are still some refs. to system_main_admin_page inside system.module's system_menu().

mikey_p’s picture

StatusFileSize
new965.34 KB
new722.02 KB
new232.46 KB

Here's some all-in-one images, sorry for the mixed formats and size.

sun’s picture

StatusFileSize
new36.27 KB

Thanks! Now once again with attached patch.

Ideally, just 3 screenshots showing the entire page, please ;)

bojanz’s picture

The "Help" problem I noticed (a million entries in admin/index) has disappeared with the new patch.
My dashboard question and the "Dashboard" block observation still stand.

sun’s picture

StatusFileSize
new37.07 KB

Sorry, forgot to update for the issues about Dashboard. Unfortunately, we can't make it any better than this patch, which means that the title "Dashboard" appears more than once, linking to different pages, and only the description differs.

sun’s picture

StatusFileSize
new37.07 KB

@bojanz: Hm, right. Seems like we lost Dashboard's local task somehow. This patch should make it re-appear on /admin.

bojanz’s picture

StatusFileSize
new28.19 KB

Awesome response time, sun!

The dashboard block now looks okay (small screenshot attached).

EDIT: Confirmed that the Dashboard tab is back with #264.
EDIT2: Confirmed that there are no mentions of system_main_admin_page() in the latest patch (janusman's #259)

Status: Needs review » Needs work

The last submitted patch, drupal.system-index.264.patch, failed testing.

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new39.13 KB

Someone needs to explain me WTF Dashboard module is trying to do there. I'm not able to make any sense of that code. This patch contains an attempt to fix its router items, which requires to also fix that JavaScript, which in turn doesn't seem to adhere to any of Drupal's JS coding styles/standards. Based on my limited testing, attached patch should work though.

Status: Needs review » Needs work
Issue tags: -Usability, -D7UX

The last submitted patch, drupal.system-index.266.patch, failed testing.

bleen’s picture

Status: Needs work » Needs review
Issue tags: +Usability, +D7UX

#267: drupal.system-index.266.patch queued for re-testing.

bleen’s picture

it looks like testbot has been drinking again

sun’s picture

StatusFileSize
new39.91 KB

Thank god we finally have tests for breadcrumbs :P

Status: Needs review » Needs work
Issue tags: -Usability, -D7UX

The last submitted patch, drupal.system-index.271.patch, failed testing.

catch’s picture

Status: Needs work » Needs review

#271: drupal.system-index.271.patch queued for re-testing.

Status: Needs review » Needs work
Issue tags: +Usability, +D7UX

The last submitted patch, drupal.system-index.271.patch, failed testing.

EvanDonovan’s picture

Reviewed mikey_p's screenshots - they look good, except that all the individual help text pages show up under the Help section on the Index tab. Is that really desirable?

Aside from that, I think that this patch addresses webchick's concerns, while still keeping catch's goal of making the index more comprehensive.

I don't think that the new D7 IA, with configuration "down a level" is an improvement, but I think we're stuck with it at this point.

bojanz’s picture

@EvanDonovan
That has been fixed (now there's only one entry under help).

Someone should post new screenshots (I'll do it when I get online tomorrow evening if nobody does it until then)

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new40.58 KB

Attached patch should pass again.

David_Rothstein’s picture

Hm, only looking at the top of the patch, but I don't understand all those dashboard.module changes. We don't want the "Customize dashboard" link to show up for users with JavaScript turned off, because it doesn't do anything for them.

Instead, seems like we should just set that menu item to a MENU_CALLBACK, so that it doesn't show up listed anywhere?

bojanz’s picture

StatusFileSize
new70.51 KB
new184.35 KB
new459.73 KB

Here are the new screenshots, #277 patch, clean install, all modules enabled.

EvanDonovan’s picture

Thanks, bojanz. The revised Index tab looks like a comprehensive list, and the new Tasks tab looks like it will be helpful when the Toolbar is disabled.

I actually read through the entire patch since David_Rothstein piqued my interest. Looks like the main changes, besides the obviously visible changes to the IA (changing the tab names and what shows up), are to:

1) Simplify the Drupal.behaviors jQuery for dashboard.
2) Convert some administration page queries to DBTNG.
3) Add more tests for the administration pages.

Arguably, the jQuery changes wouldn't be necessary to put in this patch, but I think the others are definitely good since they improve the code for this subsystem of Drupal, which was rather awkward previously.

I'd say let's get this in. The Dashboard link issue from #278 could be handled in a non-critical follow-up, just so we can lay this issue to rest.

aspilicious’s picture

Along time ago I had some problems with the fact that there wasn't a clear visible way to find the link for editing roles and stuff.

The old description for people was: "Configure user accounts"
The new one is: "manage user accounts, roles and permissions"

I tried to find the new string in the patch but couldn't find one, so I guess the description uses some kind of automated way to get all the deeper tasks.
If this is the case ==> awesome!

But either way this patch is good to go for me... No more complaints...

*** for D8 we NEED a search box that filters by keyword (link and permission) ***
"Smart" people like me are alrdy using Ctrl-F ;)

steinmb’s picture

Rolled #277 on a clean dev. install and got the same visual result as in #279.
Comments:
Also confused by the Dashboard link issue mention in #278.
Not 100% sure what #280(1) are referring to but if it is "only" clean up then we should perhaps split it out in a separate issue as suggested then it is not critical and get this baby in :)

catch’s picture

I think we should change that dashboard link to a MENU_CALLBACK if there's no value to having it show up in listings, enough people have pointed out the duplicate title that it's enough to stop this being RTBC.

Read through the patch quickly again and didn't spot anything too obvious to complain about (except that it's 40k, and a lot of that 40k is cleanup rather than necessary to fix the critical, but it looks like good cleanup so I won't nitpick otherwise that'd hold the patch up further).

David_Rothstein’s picture

Status: Needs review » Needs work

My point in #278 was that the Dashboard module + JavaScript changes in this patch introduce a bug. The "Customize dashboard" local action only is supposed to display for users with JavaScript turned on (because it doesn't do anything otherwise). This patch made it appear for all users.

The bug (and those changes) were introduced, I think, to keep the "Customize dashboard" link from showing up at admin/index. My suggestion is that if we make it a MENU_CALLBACK instead, it will probably achieve the same goal without introducing the bug.

The double "Dashboard" link in the list at admin/index is a separate issue; I am not sure how to fix that without renaming menu items...

Also, from the screenshots there appears to be another regression - why is "Dashboard" showing up as one of the local tasks on the top right, along with "Tasks" and "Index"? The earlier patches/screenshots in this issue removed that, and that was intentional (the UX discussion concluded that the Dashboard should not be a local task, because the other local tasks are distracting and unrelated to it - i.e., when you are viewing the Dashboard itself, it is best if there are no local tasks so that you focus on the dashboard itself). It looks like somewhere around comment #260 that was added back, but it should be removed.

No time for more right now - maybe I'll try to review for real later. My interest in spending lots more of my free time on this issue began to decline once the patch reached 40k :(

sun’s picture

Status: Needs work » Needs review
StatusFileSize
new38.67 KB

So Dashboard intentionally breaks the theme system and hardcodes assumptions of a few core themes in its JavaScript. One more reason to not use it. Normally we use code comments to explain WTFs like that, but obviously, no one is interested in Dashboard's code.

sun’s picture

StatusFileSize
new38.67 KB

Sorry. Typo. Otherwise, RTBC.

steinmb’s picture

StatusFileSize
new69.22 KB
new107.3 KB

@David_Rothstein: did not have any double "Dashboard" when I rolled #278. Did not notice that in the screenshot.
Rolled #286 and a clean dev. install and I think it is RTBC.

David_Rothstein’s picture

Status: Needs review » Needs work
StatusFileSize
new318.06 KB

I gave this a good run-through, both the code and via clicking around, and I think it's pretty close to ready. Probably we can get it committed before this hits 300 comments...

I'm also attaching a full-page screenshot of admin/index with the latest patch (and with all core modules enabled).

I only found these issues:

  1. @@ -98,6 +98,7 @@ function profile_menu() {
         'page callback' => 'drupal_get_form',
         'page arguments' => array('profile_field_form'),
         'access arguments' => array('administer users'),
    +    'type' => MENU_LOCAL_ACTION,
         'file' => 'profile.admin.inc',
       );
    

    This causes an "Add field" local action to appear on the profile configuration page, which gives a 404 error when you click on it.

    Probably this change is a good idea in theory and profile.module weirdness is what makes it break :) But we can't have a prominent link like that be broken, so we need to do something else here.

  2. +    $cache['link_permissions'] = menu_get_item('admin/people/permissions');
    +    $cache['link_permissions']['link_path'] = $cache['link_permissions']['href'];
    +    unset($cache['link_permissions']['description']);
    

    Since menu_get_item() is itself statically cached, what is the point of having the additional 'link_permissions' key in the static cache in this function? It doesn't seem like it's worth the extra trouble.

  3. +    $this->assertLinkByHref('admin/config/regional/settings');
    +    $this->assertLinkByHref('admin/config/regional/date-time');
    +    $this->assertLinkByHref('admin/config/regional/language');
    +    $this->assertNoLinkByHref('admin/config/regional/language/configure/session');
    +    $this->assertNoLinkByHref('admin/config/regional/language/configure/url');
    +    $this->assertLinkByHref('admin/config/regional/translate');
    

    This code block is repeated about 3 times in the test, so I don't understand the rationale for separating it out anymore vs just doing it in a foreach() loop like I had in #238?

    It also looks like this lost some assertions from #238 that are worth having in there; #238 separately tested the admin user and regular user's access to each of the three admin pages, and also verified the appearance of the "Configure permissions" link on admin/index, etc.

  4. +    // Go to Index.
    +    $this->drupalLogin($this->admin_user);
    +    $this->drupalGet('admin/index');
    

    (minor) Here and in a couple other places in the test, it looks like the admin user is being logged in even though they are already the current logged-in user.

mfer’s picture

Status: Needs work » Needs review
StatusFileSize
new35.65 KB

Addressing the comments by David_Rothstein....

  1. This is fixed in the attached patch.
  2. By caching locally in system_get_module_admin_tasks we save 14 calls to unset and 14 calls $cache['link_permissions']['link_path'] = .. in the standard profile. We also get the value off an array rather than calling a function each time which is faster. So, there is a slight performance boost to caching it here but this function is only called on admin pages and will rarely ever be used. If someone is adamant about removing the caching we can do it.
  3. I agree that the tests should be in a foreach loop. The attached patch does just that.
  4. Removed the extra calls to login the already logged in admin user. This was actually done as part of the previous one.
bojanz’s picture

Thanks, mfer!

David, you're the best person to RTBC this, can you please give it another review?

catch’s picture

On #2 I don't see any real benefit to the caching there, that kind of ultra-local caching should be confined to things right in the critical path, and we even took it out of functions like url(). If the menu_get_item() calls are a concern, I'd rather see that function converted to use the $drupal_static_fast pattern, then anything calling menu_get_item() a lot gets the benefit.

chx’s picture

A quick clarification please, which screenshot is /admin when the minimal profile is used?

bojanz’s picture

StatusFileSize
new50.27 KB
new224.08 KB

Here you go.
Latest patch, minimal install, no additional modules enabled.

aspilicious’s picture

StatusFileSize
new38.82 KB
new14 KB
new66.01 KB
new30.82 KB

This one needs a reroll I needed to edit the patched files by hand while testing the minimal profile for chx.
Will post my adjustments soon, but I'm not 100% sure I did everything correct.
Attached the screenshots for the minimal profile.

(full hd res pictures, srry for that)

aspilicious’s picture

Hmm why don't I see descriptions on my screenshots o_O

chx’s picture

That looks OK. It does not get more minimal than that. And it definitely takes away a lot of confusion.

aspilicious’s picture

#289: admin_index_699848_289.patch queued for re-testing.

bojanz’s picture

@aspilicious: #289 applied for me, although with a few offsets.

aspilicious’s picture

@bojanz ok fine for me than... Can someone give 289 a final review?

mfer’s picture

Should we remove the internal caching as David_Rothstein and catch suggest?

bojanz’s picture

That's probably the last thing blocking the issue from being RTBC (and David or catch are the ones who can RTBC it), so let's do that.

catch’s picture

Read through the patch and there's one more thing I'd like to see apart from the local caching, then this is RTBC for me:

+      // Move 'Configure permissions' links to the bottom of each section.
+      if (isset($admin_tasks[-1])) {
+        $admin_tasks[] = $admin_tasks[-1];
+        unset($admin_tasks[-1]);
       }
+  // Append link for permissions.
+  if ($cache['link_permissions']['access'] && module_hook($module, 'permission')) {
+    $task = $cache['link_permissions'];
+    $task['title'] = t('Configure @module permissions', array('@module' => $info['name']));
+    $task['localized_options']['fragment'] = 'module-' . $module;
+    $admin_tasks[-1] = $task;
+  }
+

I had to ctrl-f the patch to find where this -1 was being set. That's a magic number in two different functions - should be a constant - SYSTEM_PERMISSIONS_LINK or something would do fine. I don't think this is any worse than the code that was already there though, so would be fine with a minor followup issue posted instead to get this in.

David_Rothstein’s picture

StatusFileSize
new318.06 KB
new9.17 KB
new38.5 KB

Rerolled the patch - the changes from #289 are:

  1. Removed the cache of the menu_get_item('admin/people/permissions') result, as discussed above.
  2. Completed the fix for the profile module "Add field" issue (just reverting the MENU_LOCAL_ACTION change wasn't enough because then the "Add field" link showed up at admin/index which is just as bad; instead I fixed this using MENU_VISIBLE_IN_BREADCRUMB which seemed to be the right choice to hide it everywhere).
  3. Added back the tests that checked for the presence of the "Configure permissions" link on admin/index (we had them before and know they passed, so seems a waste not to include them also, especially since that link is added via somewhat custom code that could be expected to break someday).
  4. Fixed the issue with -1 that @catch noted above, though instead of defining a constant it seemed simpler to just use a meaningful array key instead (all the others elements of that array are keyed by the $path, so -1 was very inconsistent anyway; I therefore used admin/people/permissions#module-$module as the array key).

I'm also attaching the interdiff between patch #286 and this one (i.e., the combined changes that @mfer and I made after the last reviews), as well as a final screenshot of admin/index with all core modules enabled.

Hopefully RTBC? :)

catch’s picture

Status: Needs review » Reviewed & tested by the community

Very happy with the -1 change, this is RTBC for me. Only just past the 300 mark too.

webchick’s picture

Status: Reviewed & tested by the community » Needs review

This doesn't necessarily need to hold off an RTBC now that we're at 300+ replies, but something that's consistently annoyed me...

1. "Content" shows up under "Node". But "Comments" doesn't show up under "Comment". This is actually pretty bad, because that's the most important link there. Can we fall back to picking up .info files' admin_path indexes or whatever it's called?
2. "Dashboard" is listed twice under "Dashboard". I understand why that is, but it looks like a bug.

Apologies if this was already covered earlier. I'm skimming a bit.

webchick’s picture

Oops. Cross-posted. Still. David, could you touch on those? Are they easy to fix?

catch’s picture

StatusFileSize
new39.22 KB
new17.45 KB
new49.95 KB

Comments didn't appear because it was only a MENU_LOCAL_TASK. Changing the definition to MENU_LOCAL_TASK | MENU_NORMAL_ITEM puts it there. Note I'm not entirely up to speed on the recent menu system changes about what gets shown where under which circumstances however screenshot shows this gets it picked up, and is still where it's supposed to be otherwise.

catch’s picture

I think dashboard link naming should be in a (normal) followup issue.

webchick’s picture

Status: Needs review » Fixed

Ok, I can get behind that!

Committed to HEAD!!! Thanks so much for sticking with this, folks.

catch’s picture

David_Rothstein’s picture

Yay! We didn't quite make it before 300 comments, but we came close.

Yeah, the things @webchick mentioned were discussed at some point in this issue and I had them in my head to file followup issues for them (as well as a couple others) after this was committed, as they are probably indeed better dealt with as followups. Here's the complete list:

I don't have time to post patches for any of those at the moment but did figure it was worth taking a few minutes to create the issues before I forgot :)

EvanDonovan’s picture

And there was much rejoicing! Thanks all - beta feels so much closer now :)

Status: Fixed » Closed (fixed)
Issue tags: -Usability, -D7UX

Automatically closed -- issue fixed for 2 weeks with no activity.