Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
hey out there,
i've written a plugin that extends the the log viewer that ships umbraco 8.
ideally i'd like to either hide or remove the log viewer entry in the settings tree:
is this possible? it feels like that something that could possibly be done via a composer:
however i can't find anything that would remove an item...
is this possible?!
any suggestions would be grand ;)
cheers,
jake
Hey Jake, Not tried this myself but could you do something like : https://our.umbraco.com/documentation/extending/section-trees/trees#treenodesrendering
And target if the node starts with Log then remove it. Once you have done that then you could add your own custom one?
you sir, are a genius ;)
this is what i ended up doing:
public class TreeEvents : IComponent { public void Initialize() { TreeControllerBase.RootNodeRendering += TreeControllerBase_RootNodeRendering; } public void Terminate() { } void TreeControllerBase_RootNodeRendering(TreeControllerBase sender, TreeNodeRenderingEventArgs e) { if (sender.TreeAlias == "logViewer") { e.Node.CssClasses.Add("hide-section-tree"); } } }
the umbraco css does have a .hide class however adding it to the css classes for the node doesn't actually hide the item:
.hide
so i added my own css file with the following class:
.hide-section-tree { display: none !important; }
and bingo, we have a winner!
the crazy thing is i swear i'd looked at that page a 100 times and not twigged that bit of code...
thanks again for the suggestion, have a good one ;)
Brilliant - glad you were able to find a way to make it work. Looking forward to seeing what your updated logger does :)
O.
i've just finished the last items - the repo is available here:
https://github.com/ribsdigital/UmbLogExporter/tree/develop
it's a log viewer replacement which adds an export to excel function and a few other tweaks.
there's still a bit of testing to go but i think it should be releasable tomorrow ;)
Nice and great to see it's open source too. I'll check it out :) Great work.
h5yr!
There is an extension method to remove tree nodes, This is working perfectly fine without the need for css. Also, It will not render this tree item at all.
i want to remove item from setion menu
i want to remove workflow item from sections menu for all groups even admin
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
removing a tree node from the settings section in the backoffice?
hey out there,
i've written a plugin that extends the the log viewer that ships umbraco 8.
ideally i'd like to either hide or remove the log viewer entry in the settings tree:
is this possible? it feels like that something that could possibly be done via a composer:
however i can't find anything that would remove an item...
is this possible?!
any suggestions would be grand ;)
cheers,
jake
Hey Jake, Not tried this myself but could you do something like : https://our.umbraco.com/documentation/extending/section-trees/trees#treenodesrendering
And target if the node starts with Log then remove it. Once you have done that then you could add your own custom one?
you sir, are a genius ;)
this is what i ended up doing:
the umbraco css does have a
.hide
class however adding it to the css classes for the node doesn't actually hide the item:so i added my own css file with the following class:
and bingo, we have a winner!
the crazy thing is i swear i'd looked at that page a 100 times and not twigged that bit of code...
thanks again for the suggestion, have a good one ;)
jake
Brilliant - glad you were able to find a way to make it work. Looking forward to seeing what your updated logger does :)
O.
i've just finished the last items - the repo is available here:
https://github.com/ribsdigital/UmbLogExporter/tree/develop
it's a log viewer replacement which adds an export to excel function and a few other tweaks.
there's still a bit of testing to go but i think it should be releasable tomorrow ;)
Nice and great to see it's open source too. I'll check it out :) Great work.
h5yr!
There is an extension method to remove tree nodes, This is working perfectly fine without the need for css. Also, It will not render this tree item at all.
i want to remove item from setion menu
i want to remove workflow item from sections menu for all groups even admin
is working on a reply...