Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Own layout/theme/assets #4

Open
3 of 6 tasks
highstrike opened this issue Jul 19, 2018 · 2 comments
Open
3 of 6 tasks

Own layout/theme/assets #4

highstrike opened this issue Jul 19, 2018 · 2 comments
Labels
enhancement New feature or request

Comments

@highstrike
Copy link
Contributor

highstrike commented Jul 19, 2018

You must include the assets for the "backend" interface found in /test-helper

This plugin repository is currently lacking:

  • it's own layout.ctp.
  • assets like jquery, font awesome and the modal lib that are being used in the templates.
  • the Flash component should also be loaded by default as it's being used in the controllers.
  • the Flash design elements (Element/Flash/success.ctp and Element/Flash/error.ctp) maybe look at my component and include that in the project as well because it will load the elements from the plugin (once included).
  • the Tools.Format helper should also be loaded by default as it's being used in the views.
  • the TestHelper helper should also be loaded by default

Extra stuff needed to make this plugin work

currently my project's AppController.php looks like this:

class AppController extends Controller
{
    public function initialize() {
        parent::initialize();

        // dereuromark's testhelper
        if($this->request->getParam('plugin') == 'TestHelper') {
            $this->loadComponent('Flash');
        }
    }
}

and my project's AppView.php looks like this:

class AppView extends View
{
    public function initialize() {
        parent::initialize();

        // dereuromark's testhelper
        if($this->request->getParam('plugin') == 'TestHelper') {
            $this->loadHelper('Test'); //// this is my helper that will overwrite the layout in my project
            $this->loadHelper('Tools.Format');
        }
    }
}
@dereuromark
Copy link
Owner

Anything still missing?
Maybe we can draw up a PR?

@dereuromark dereuromark added the enhancement New feature or request label Nov 1, 2019
@ravage84
Copy link

ravage84 commented Mar 9, 2020

I Agree, the plugin (at least for CakePHP 3.x) should come with a theme comtaining a default layout of its own with everything needed to display a workable UI. Could be vanilla Bootstrap or something more simple. Kinda like "Batteries included".

@dereuromark dereuromark changed the title This plugin is missing some stuff Own layout/theme/assets Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants