alterphp / easyadminmongoodmbundle Goto Github PK
View Code? Open in Web Editor NEWProvides support of Doctrine ODM documents in EasyAdmin
License: MIT License
Provides support of Doctrine ODM documents in EasyAdmin
License: MIT License
Unable to find file "@EasyAdminExtensionBundle/Controller/MongoOdmEasyAdminController.php" in
@EasyAdminExtensionBundle/Controller/MongoOdmEasyAdminController.php (which is being imported from
"/Applications/XAMPP/xamppfiles/htdocs/ebolution/014mx-ebolution-bot_ma-web-api/config/routes/easy_admin.yaml").
Make sure the "EasyAdminExtensionBundle" bundle is correctly registered and loaded in the application kernel class. If the bundle is registered, make sure the bundle path
"@EasyAdminExtensionBundle/Controller/MongoOdmEasyAdminController.php" is not empty.
Tengo un problema al intentar usar el bundle
Hi, i try to install this bundle on empty project and got some errors.
I have created and configured a few documents, but i haven't any ORM Entity in my project.
My packages config:
#packages/easy_admin.yaml
easy_admin:
design:
menu:
- { label: History, route: easyadmin_mongo_odm, params: { document: History } }
- { label: Video, route: easyadmin_mongo_odm, params: { document: Video } }
- { label: Article, route: easyadmin_mongo_odm, params: { document: Article } }
#packages/easy_admin_mongo_odm.yaml
easy_admin_mongo_odm:
documents:
- App\Document\History
- App\Document\Video
- App\Document\Article
And default routing config for EasyAdmin:
#routes/easy_admin.yaml
easy_admin_bundle:
resource: '@EasyAdminBundle/Controller/AdminController.php'
prefix: /admin
type: annotation
At this step i got first error from vendor/easycorp/easyadmin-bundle/src/Controller/AdminController.php line 96
:
The backend is empty because you haven't configured any Doctrine entity to manage.
After that i try to change controller parameter in my routes:
#routes/easy_admin.yaml
easy_admin_bundle:
resource: '@EasyAdminMongoOdmBundle/Controller/AdminController.php'
prefix: /admin
type: annotation
At this step i got next two errors:
Undefined class constant 'TO_MANY' at vendor/alterphp/easyadmin-mongo-odm-bundle/src/Configuration/MetadataConfigPass.php line 87
:
Possible solution: replace & ClassMetadata::TO_MANY
to && ClassMetadata::REFERENCE_MANY
constant at that line (FQCN Doctrine\ODM\MongoDB\Mapping\ClassMetadata)?
If manually fix the first error i got the second one:
Attempted to call an undefined method named "redirectToBackendHomepage" of class "AlterPHP\EasyAdminMongoOdmBundle\Controller\AdminController".
from vendor/alterphp/easyadmin-mongo-odm-bundle/src/Controller/AdminController.php line 38
Possible solution: class AlterPHP\EasyAdminMongoOdmBundle\Controller\AdminController
should extend EasyCorp\Bundle\EasyAdminBundle\Controller
or that method must be implemented with some redirect?
Package versions:
doctrine/mongodb - 1.6.3
doctrine/mongodb-odm - 1.2.5
doctrine/mongodb-odm-bundle - 3.4.4
easycorp/easyadmin-bundle - v1.17.14
alterphp/easyadmin-extension-bundle - v1.2.10
alterphp/easyadmin-mongo-odm-bundle - dev-master d89751a
Will be glad to any advice, thanks.
Hello, fellow French developper !
I just started a Symfony 4 app with MongoDB ODM configured on it (the doc for it is horrible by the way), and I wanted to put an EasyAdmin on top of it. Problem is, I saw the GitHub issue there and a bit below, your answer.
I gave it a shot, installed it successfully but then, Symfony gives me this error :
The backend is empty because you haven't configured any Doctrine entity to manage. Solution: edit your configuration file (e.g. "config/packages/easy_admin.yaml") and configure the backend under the "easy_admin" key.
I already modified the easy_admin.yaml file to put the config of easy_admin_mongo_odm, but no luck.
Here is my easy_admin.yaml file :
easy_admin_mongo_odm:
documents:
User:
class: App\Entity\User
easy_admin:
design:
menu:
- { label: User, route: easyadmin_mongo_odm, params: { document: User } }
(Don't mind the App\Entity, I have my mongo Documents under src/Entity and so I kept the naming, but it's an actual document)
I also have this in my composer.json :
"alterphp/easyadmin-extension-bundle": "^2.0@dev",
"alterphp/easyadmin-mongo-odm-bundle": "dev-master",
"easycorp/easyadmin-bundle": "^2.0@dev",
Do you know what could be the problem ?
Thanks in advance.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.