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

01: Introduction Sulu-Admin-class #1

Open
wants to merge 2 commits into
base: 00-symfony-bundle
from

Conversation

Projects
None yet
2 participants
@wachterjohannes
Copy link
Member

wachterjohannes commented Jan 15, 2016

This part of the tutorial register a new Bundle in the Sulu-Admin and adds a link to the navigation.

Link to the Blog-Post: http://blog.sulu.io/how-to-develop-a-bundle-in-the-sulu-admin-1

use Sulu\Bundle\AdminBundle\Navigation\Navigation;
use Sulu\Bundle\AdminBundle\Navigation\NavigationItem;
class NewsAdmin extends Admin

This comment has been minimized.

@wachterjohannes

wachterjohannes Jan 15, 2016

Member

Registers the bundle in the Sulu-Admin

$section->addChild($global);
$news = new NavigationItem('navigation.news');
$news->setAction('example/news');

This comment has been minimized.

@wachterjohannes

wachterjohannes Jan 15, 2016

Member

The action will be used by the JavaScript application to determine which component should be loaded to display the content for that page.

<service id="example_news.admin" class="Example\NewsBundle\Admin\NewsAdmin">
<argument>%sulu_admin.name%</argument>

<tag name="sulu.admin"/>

This comment has been minimized.

@wachterjohannes

wachterjohannes Jan 15, 2016

Member

This tag will be used by the SuluAdminBundle to find all Bundles

@gusdecool

This comment has been minimized.

Copy link

gusdecool commented May 17, 2016

@wachterjohannes

"Now, when you reload the Sulu-Admin you will see the newly created navigation link "navigation.news"."

I have followed your tutorial but there is no "navigation.news" on admin page. Tested using sulu 1.2.2

@wachterjohannes

This comment has been minimized.

Copy link
Member

wachterjohannes commented May 17, 2016

@gusdecool do you have added the bundle in the AbstractKernel?

I have tried this branch and although is was developed with 1.1 it works for me.

image

@gusdecool

This comment has been minimized.

Copy link

gusdecool commented May 17, 2016

Yes i did added it into abstractkernel. But nothing changes :(

On Tue, May 17, 2016, 5:29 PM Johannes Wachter notifications@github.com
wrote:

@gusdecool https://github.com/gusdecool do you have added the bundle in
the AbstractKernel?

I have tried this branch and although is was developed with 1.1 it works
for me.

[image: image]
https://cloud.githubusercontent.com/assets/1464615/15317632/a10a9674-1c22-11e6-9479-191db388c024.png


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#1 (comment)

Budi Arsana
Mobile: +62 817623397

@wachterjohannes

This comment has been minimized.

Copy link
Member

wachterjohannes commented May 17, 2016

i know it sounds quite "bad" but do you also have cleared the cache and run symfony in dev environment? can you check that sulu enters the constructor of you NewsAdmin?

@gusdecool

This comment has been minimized.

Copy link

gusdecool commented May 18, 2016

@wachterjohannes ah after delete the cache folder, now it showing the menu 👍
Strange how come app/console cache:clear not really "clearning" the cache 😤

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment