This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

octobro
octobro

Hi there,

I am new to developing plugins with october and having some issues with the layout.

I am using php artisan command to generate the plugin which does the job. In my plugins.php I have added in

public function registerNavigation()
{
    return [
    'checks' => [
        'label'       => 'Form Posts',
        'url'         => Backend::url('acme/portal/posts'),
        'icon'        => 'icon-binoculars',
        'permissions' => ['acme.portal.*'],
        'order'       => 500,

        'sideMenu' => [
            'posts' => [
                'label'       => 'Open Forms',
                'icon'        => 'icon-copy',
                'url'         => Backend::url('acme/portal/posts'),
                'permissions' => ['acme.portal.access_posts'],
            ],
            'categories' => [
                'label'       => 'Completed Forms',
                'icon'        => 'icon-list',
                'url'         => Backend::url('acme/portal/categories'),
                'permissions' => ['acme.portal.access_categories']
            ],
        ]

    ]
];

}

I then obviously get a 404 as I have constructed thesiteurl.com/bacend/acme/portal. Is there a way I can build the necessary url?

Last updated

octobro
octobro

I needed to build the model and controller using

php artisan create:model Acme.Portal Post
php artisan create:controller Acme.Portal Post

then it would set up the pages in the backend. Thanks to scottbedard on IRC for the solution.

Last updated

1-2 of 2

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.