This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.
Yes, it's quite easy to override the backend partials.
In your own controller, create the partial adding the prefix of the backend controller you want to overwrite, for example, to override the "_manage_list" partial in the RelationController: "_relation_manage_list".
Thanks to a recent commit, the proper variables are sent to the overwritten partial, so I would recommend to just copy/paste the code of the original partial and modify it for your needs.
This doesn't work for overriding the backend layout. (/modules/backend/layouts/default.htm
, _head.htm
, etc.)
The only way I've found to change them is to edit line 130
in /modules/backend/classes/Controller.php
. From $this->layoutPath = ['modules/backend/layouts'];
to $this->layoutPath = ['plugins/yourvendor/yourplugin/layouts'];
And then copy the layout to that directory and edit it. That file might revert after updating. You can make an assets folder in your plugin and use URL::asset('plugins/ ... /assets')
to add your own scripts or styles.
I figure that a future update will set layoutPath
to load from a config (this is what the Skin
class and backendSkin
config is meant to be for?), but it hasn't been implemented yet.
Just leaving this here in case someone is searching for how to change the backend layout and doesn't mind changing a line or two to make it work until it's actually supported.
Last updated
I know that it's a very old thread, but I had the same problem and I have just found the solucion, so for future references to newbies like me:
To change the backend layout system, there's a file in config called cms.php
that has an array with a index called backendSkin
, that index references the base file where it's defined the layout directory under the method getLayoutPaths
. The class its: Backend\Skins\Standard
.
You only have to extend that class in another directory, change that method to whatever the new layout system you want and you can even send as second array data the original one if you are planning to only extend the basic layout instead of changing all of it. It works like charm.
This helped a bunch, thanks patroklo.
I ended up extending Standard class, changing getLayoutPaths to a folder where where I copied all the current layout files, and then changed the cms.php 'backendSkin' to link to the new class.
Hi everyone,
I m creating a plugin that you can change your custom backend. The Plugin is almost done. And I will comment it here if it already done.
Hi
I just created a new plugin, that you can create your own backend skin, not only by css, you can also change the whole ui even the assets.
https://octobercms.com/plugin/cyd293-backendskin
Thanks
Last updated
1-8 of 8