Dougiefresh's Reorganized Admin Area (SMF 2.0.x Only)

Started by dougiefresh, December 01, 2014, 05:50:20 PM

Previous topic - Next topic

dougiefresh

Link to Mod



DOUGIEFRESH'S REORGANIZED ADMIN AREA V1.3
By Dougiefresh => Link to Mod



Introduction
This mod makes a variety of changes to the Admin area in order to more logically order the mods installed into the Admin area.  Most were dumped into the Configuration area by the mod authors, which was fine, but it creates a big mess that I really got tired off.

Admin Alterations
> Package Manager is now in its own section!
> Search section was created, using the Search area from Configuration and Search Engines from Main.
>>> If Optimus Brave is installed, it is moved to the Search area.
> Security section has been created, using Security and Moderations area from Configurations
>>> httpBL, Forum Firewall and Bad Behavior have been moved to the Security section
>>> If SMF 2.1-style Admin Area is installed, the Anti-Spam area is moved to the Security section.
> Configuration tab has been restored back to unmodified condition, with exception of Security and Moderations
> Modifications now have a Mods section, dedicated to everything that doesn't belong in Configuration!
>>> EMail Inactive Users has been moved to the Maintenance area.
>>> Related Topics has been moved to the Forums area.
>>> Like Posts has been moved to the Forums area.
>>> Akismet Spam Protection has been moved out of Modifications Settings and placed under Security
>>> Mentions has has been moved out of Modifications Settings and placed under Forum
>>> Block e-mail usernames has has been moved out of Modifications Settings and placed under Members
>>> All other modifications in the Configuration tab were moved into a new Mods section
> Forum => Calendar was moved to the Configuration area.
> Members => Paid Subscriptions was moved to the Configuration area.
> SMF Gallery area was merged with the Mods area.
> SimpleAds area was merged with the Mods area.
> SA Facebook Integration area was merged with the Mods area.
> Maintenance => Reports was moved to the Main area.
> Attachments and Avatars section renamed to Attachments
> Attachments and Avatars => Avatars Settings moved to Members => Avatars
>>> Attachments and Avatars => Browse Files => Avatars moved to Members => Avatars => Browse Files
>>> Default Avatar options in Modification Settings moved to Members => Avatars => Miscellaneous
>>> Avatar for Banned Members option in Modification Settings moved to Members => Avatars => Miscellaneous
> Permissions section removed from Members into it's own area.

Compatibility Notes
This mod was tested on SMF 2.0.9, but should work on earlier versions of SMF 2.0.x.  SMF 1.x is not and will not be supported.

Other Notes
The reorganization of the Admin menu takes place AFTER the processing of the hooks....

SMF 2.1-style Admin Area should be installed prior to this mod.

This mod was part of the Real Tabs for Admin & Moderator Menus mod (version 2.x line) and has been expanded upon.

This mod does not install any other mods in order to use, so if the specified mod is not installed, no menu change will be made.

Changelog
The changelog has been removed and can be seen at XPtsp.com.

License
Copyright (c) 2015, Douglas Orend
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Steve

DO NOT pm me for support!

Steve

Sorry to double post ...

Question ... I have your Lazy Admin Menu installed, does this mod incorporate that or should I keep it installed while I have this one installed?
DO NOT pm me for support!

Gryzor

Can you explain a bit what "The reorganization of the Admin menu takes place AFTER the processing of the hooks...." means? Because I installed it and am not seeing any changes... When are hooks processed?

Thanks!

Arantor

Hooks are processed after the main menu is built in the admin area. This mod intercepts things after hook processing, I'm guessing.

Gryzor

Ah, I see. Anyway I can find out why it's not working despite installing successfully?

Arantor


Gryzor


Arantor

So, *everything* is unchanged?

Hmm. I see it is using a hook; I wouldn't use a hook in this situation - at least not unless I was periodically checking that my hook was called *last*.

Gryzor

No, nothing is changed indeed. It's as if I didn't install it...

---no wait, it did. It's just that you must, hm, how to put it, "expand" the Admin area with the two little arrows at the top left, then it's as described... Hope you understand what I mean :)

margarett

Isn't your Package Manager moving from the left-most menu (or from the top menu, if you don't have it "expanded") to a menu of his own, right to "Configuration" (or below "Configuration")?

@Arantor: nevertheless, the changes to SMF "core" menus should be running. He is using a hook that adds a temporary hook every time, so it is added by SMF at the end of the list of "permanent" hooks. Works fine here...
Se forem conduzir, não bebam. Se forem beber... CHAMEM-ME!!!! :D

QuoteOver 90% of all computer problems can be traced back to the interface between the keyboard and the chair

Arantor

You mean sidebar vs dropdown menus? This is a core SMF feature.

Both are built from the same base code so the changes would function the same between the two, just presented differently to much confusion. Fortunately in 2.1 this has been changed and there's only one method now (just the dropdown menus)

@margarett: I didn't look at what was going on there, but I certainly recognise the mentality having done similar myself ;)

Gryzor

Quote from: margarett on December 02, 2014, 12:10:36 PM
Isn't your Package Manager moving from the left-most menu (or from the top menu, if you don't have it "expanded") to a menu of his own, right to "Configuration" (or below "Configuration")?

Yes, it does, as soon as I do what I described above :)

dougiefresh

#13
Uploaded v1.1 - December 2nd, 2014
o Changed hook code back to original code edit in Sources/Admin.php
o Removed Team Page from the list of areas in the Configuration section...

:o Crap... I thought I had solved that particular issue, but I installed the mod on a clean install and it didn't make any changes.   So I changed the code back to the way it was when I had submitted it to the Customization Site, which included the file and called the function directly from Sources/Admin.php.  This fixes the issue reported by Gryzor.  I apologize to everybody that downloaded version 1.0....

Quote from: Steve on December 01, 2014, 08:15:20 PM
Question ... I have your Lazy Admin Menu installed, does this mod incorporate that or should I keep it installed while I have this one installed?
Each mod does something different, so they are compatible to have both installed on the same forum.  This mod directly alters the Admin menu, reorganizing it to make it less "messy" looking.  The Lazy Admin Menu pulls the Admin menu and rebuilds the top menu to reflect the current layout of the Admin menu....  I hope this answers your question.

Steve

DO NOT pm me for support!

dougiefresh

@Steve: In case you're wondering, you can also run my SMF 2.1-style Admin Area mod to further alter your Admin menu.  There is no conflict between all three mods.  This mod is "aware" of the changes that my SMF 2.1-style Admin Area mod makes and will properly move the sections around without issue.....  However, that mod should be installed first, then this mod....

EDIT: Updated mod description to reflect the preferred mod install order.....

Steve

Cool ... will do that tomorrow when I've not had so much Christmas cheer. ;)
DO NOT pm me for support!

Gryzor

Thanks, works flawlessly though again you have to click on the expand-like little arrows for the effect to appear :)

Colin

Great mod! Thank you for all of the work you have put into it.
"If everybody is thinking alike, then somebody is not thinking." - Gen. George S. Patton Jr.

Colin

dougiefresh

Quote from: Arantor on December 02, 2014, 12:04:24 PM
Hmm. I see it is using a hook; I wouldn't use a hook in this situation - at least not unless I was periodically checking that my hook was called *last*.
Just so you know, the initial release of the mod to the Customization Site didn't have a temporary hook.  It had a single edit to Sources/Admin.php in order to make sure the reorganization was performed last...  Customization Team wanted it as a hook in order to approve it.  Still don't understand why....  but whatever....  Not gonna stress over it!  :P

Advertisement: