Admin settings when no tags module is enabled

ilo - November 23, 2009 - 18:03
Project:Nodewords
Version:6.x-1.x-dev
Component:User interface
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

I realized that only enabling nodewords module, some messages are shown to the user about enabling modules providing tags, and configure the editing tags for the forms. Good. But this just happens in all admin settings pages but the "Other pages" settings interface, where no advice is set about enabling "editing tags", and a link to add a new page is shown.. if the user clicks that link then is redirected to the "enable editing tags" message.

Images would clarify that..

Note: KiamLaluno.. the wheel starts moving ;)

AttachmentSize
other_pages_ux_nodewords.admin_.inc_.patch3.48 KB
other_pages_after.png18.7 KB
other_pages_before.png18.39 KB

#1

kiamlaluno - November 24, 2009 - 13:22

The two messages that appear in other_pages.png are in contrast with each other.
The first message tells the users they need to enable other modules, in order to enable the meta tags, while the second message tells the users to visit the settings page to enable the meta tags; until the users don't enable the extra modules, the settings page doesn't list any meta tags to be enabled.

#2

kiamlaluno - November 24, 2009 - 13:25

_nodewords_check_enabled_modules() should be changed to return a value that would allow to the form builder function to understand if it should show its message.

#3

ilo - November 24, 2009 - 19:13

The patch just make the 'Other pages' working as the rest of tabs in that settings form (all of them show both messages).

Have this change be done with all calls to the function in the module? I can do that.

IMHO, the _nodewords_check_enabled_modules() is of great help, but only ONCE, on module update or installation, there is no need to check and show it on every tab of every admin page of nodewords. The settings and module decoupling left some "unexpected" use cases, I'd say.. let me explain:

while I was reviewing the user interface I realized there is a checkbox to enable or disable "user meta tags", tags for user profiles (I guess).. why was that the only option? I mean, why can I disable 'user' object tags and can't disable 'node' object tags, or 'view' object tags? Then I thought, mm probably because I have to enable first a meta tags module for views?.. this make sense, but then another question passed through my mind: and why didn't I have to enable a meta tags module for users?

In my first review I've also found that there is no way to use the nodewords module alone.. nor even for a basic meta tags usage. I know that nodewords module is an API module.. well, core "node" module is an API module but provides a default use case with basic node types even being an API. With current split of nodewords helper modules, everything is messed up (FROM MY POV)..

I mean: With a default (only that) nodewords module set up, I can control to enable or not meta tags for user pages, and control if I can use Meta tags for pages not being nodes (let's say: 403, 404, and so..), but can't use it, because I have to enable an additional module. Once I enable the nodewords_basic module, I can use tags for users, error pages and nodes, all at once.. Somehow I feel that the functionality decoupling is not consistent..

so, for a newcomer it could be frustrating that if I can't use user tags nor error page tags, why do I have the options and don't have them for "nodes" or "views" or whatever..

#4

kiamlaluno - November 24, 2009 - 20:37

I agree with your analysis.
Basically, the project has been split in different modules to avoid to load not used code. As result, though, there are some incongruences that have been created.

To resolve this issue, and any other you pointed out, I think that it is be better to return to use a single module as before. If it also possible to avoid to load code that is not necessary, then that would be great.
Obviously, I tried to resolve a problem using the wrong method.

#5

kiamlaluno - November 26, 2009 - 23:39
Status:needs review» fixed

@ilo: I apologize; I forgot to attach the patch for the changes I made. Fortunately (in some way) I re-read what you wrote, and I noticed I misunderstood what you were saying.

The patch I attach now is the follow-up to the previous commit I made; I hope it allows you to understand the changes I made.

I removed the call to the function _nodewords_check_enabled_modules(). The meta tags edit forms don't show fields when there are no meta tags enabled for the editing; the only exception is the settings form that shows an error message about the modules that define meta tags, and which are not enabled.

AttachmentSize
nodewords_090002.patch 7.49 KB

#6

kiamlaluno - November 26, 2009 - 23:40
Title:Admin settings when no tags module is enabled.» Admin settings when no tags module is enabled

#7

System Message - December 10, 2009 - 23:50
Status:fixed» closed

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

 
 

Drupal is a registered trademark of Dries Buytaert.