-
Notifications
You must be signed in to change notification settings - Fork 149
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
Unable to use layout :( #237
Comments
I don't have a SF 3.4 installation to give it a try, so please check if
gives you the same result |
@kevinpapst @avanzu ,
And it gives to me this error : There is a big gab in the documentation because I have done all that is speficied and nothing works ... I give all the command to start a blank project... Can you try with all the command that I give to start a blank project ? @kevinpapst |
Actually I am only a user of this bundle as well. Currently the focus of this bundle seems to be towards backward compatibility, but not being compatible with the newest versions of Symfony (unfortunately). BUT: You can see from your error message that you are one step further! But the problem is, that this bundle uses an invalid (deprecated) syntax for loading twig templates. So you have to adapt all shipped templates in this theme. @shakaran I can split my PR if you want, only addressing the wrong twig loading syntax. |
I have done all the modification that you have made on your PR #216 for the compatibility but there is another problem about routing ...
in vendor\avanzu\admin-theme-bundle\Resources\views\layout\default-layout.html.twig (line 42)
|
So you have no route welcome. Then overwrite the block:
|
@kevinpapst its a blank SF 3.4 project. Is that why I have no route ? This Bundle doesn't work with no route as a "welcome" page ? I don't understand what I have exactly to overwrite ? is it to remove the block ? |
Just place this block in your own layout twig file. |
By adding this block in my twig layout it works 😄 But why it's not describe in the documentation ? The documentation is not correct ... 😢 Where have you find that ? do you have any documentation ? |
Glad it works now! Try & Error is what I normally do. Also I am using Symfony for a longer time now, so I find my way around these little bugs ;-) And no: there is no documentation, as this bundle is AFAIK not officially compatible with 3.4 and upwards. |
I don't understand too the variable "route_alias" how can I deal with it ? @kevinpapst you doesn't have the same issue in your layout ? is there any documentation that explain how to use all the AdminLTE layout functionnality ? I don't understand the advantages of using a bundle of AdminLTE ? what is the best improvment by using AdminLTE as Bundle ? and what are these (they contains some php code and I don't understand why php code is needed to use AdminLTE functionnality) : |
I had several issues with this bundle, but thats to be expected. Its a general purpose bundle that tries to make it easy for everyone, but it can't deal with all the possible use-cases. And yes, there are some problems as well - for example the route_alias is unnecessary from my pov but I see why it was introduced. You know: thats what open source is for. Contribute if you find spots that you think should be improved! This bundle makes it easier to include AdminLTE in your app. Go ahead and play with it for 1-2 days and you will quickly see how it can help you and if it fits your needs. |
@shakaran , @kevinpapst ,
I create another issue because this bundle is very hard to use and the documentation is very weird.
I follow each step of the documentation to use this Bundle based on dev-master branch and it's always wrong...
I got the following error message :
Unable to find template "AvanzuAdminThemeBundle:layout:default-layout.html.twig" (looked into: C:\wamp64\www\project\app/Resources/views, C:\wamp64\www\project\vendor\symfony\symfony\src\Symfony\Bridge\Twig/Resources/views/Form) in base.html.twig at line 1
Test case to reproduce :
1/ symfony new <project_name> lts
2/ cd <project_name>
3/ composer update
4/ composer require avanzu/admin-theme-bundle dev-master
5/ Add new Avanzu\AdminThemeBundle\AvanzuAdminThemeBundle(), to AppKernel.php
6/ php bin/console avanzu:admin:initialize
7/ php bin/console assets:install --symlink
8/ php bin/console avanzu:admin:fetch-vendor
9/ add this {% extends 'AvanzuAdminThemeBundle:layout:default-layout.html.twig' %} to my base.html.twig under app/Resources/views
What I am doing wrong ??? and it's also the same with the version 1.3.x ....
Debug info
The text was updated successfully, but these errors were encountered: