Problem/Motivation
Extracted from todo.txt :
simplenews_help: work over
Proposed resolution
Update hook help arguments, it receives route now, not path. See other examples. Update the code, e.g. user_access() so it works. Enable the help module in the administration test, place the help block and make sure it shows up on the relevant pages.
Remaining tasks
User interface changes
API changes
| Comment | File | Size | Author |
|---|---|---|---|
| #10 | update_hook_help-2410247-10.patch | 14.03 KB | johnchque |
| #10 | interdiff-2410247-8-10.txt | 3.05 KB | johnchque |
| #8 | update_hook_help-2410247-8.patch | 14.14 KB | johnchque |
| #8 | interdiff-2410247-6-8.txt | 8.52 KB | johnchque |
| #6 | update_hook_help-2410247-6.patch | 9.92 KB | tduong |
Comments
Comment #1
miro_dietikerComment #2
berdirComment #3
tduong commentedDiscussed/Working with @yongt9412 and @Arla, in this patch we've tried to edit what is in "Proposed solution", but we're not sure how to specify two path cases ('admin/config/services/simplenews/settings/newsletter' and 'admin/structure/types/manage/article/display'). Any suggestion?
Comment #5
berdirThis is not the same. node.add is the page that lists the node types. This is an argument, so you need to combine it with $route_match, which has the arguments for it.
I'm actually wondering if we shouldn't move this text here to the help property of the node type. That should also show up on that page. We can't have dynamic access checks and links in there, so we might need to simplify it a bit.
this should be fine.
We should update this to include Swiftmailer as well, which is what we use now in D8. Those other two afaik have no D8 port yet.
Same here. This is a combination of route name (See RouteSubscriber in field_ui, should be "entity.entity_form_display.node.form_mode" + you have a form_mode_name argument in route match that is then simplenews_issue.
Note that simplenews_issue is just a default type. Others could have it too. We might want to check that with simplenews_check_node_types()
this doesn't match. you enable the module only in AdministrationTest (which is correct) but place the block here, for all tests. Move this to AdministrationTest as well.
Additionally, go through hook_help() and try to find one case where that page is visited in the administration page. If so, add an assertText() for atleast part of the help message.
Comment #6
tduong commentedDone #5.1-4.
As discussed with @Berdir, for #5.1 is fine enough
Test coming soon.
Comment #8
johnchqueAdded test cases. Patch attached. Added interdiff between last patch and current patch.
Comment #9
berdirwhat is this for?
Check comment coding standards. Space after //, . at the end.
Comment #10
johnchqueAdded patch based on comment #9. Added interdiff.
Comment #11
berdirGreat. Changing to a major bug since this wasn't working at all. Core considers missing help critical :)