constantable / odm-document-maker
The ODM Document Maker helps you create Doctrine ODM Documents
Installs: 7
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 0
Type:symfony-bundle
Requires
- php: >=8.0
- doctrine/mongodb-odm-bundle: ^4.4|^5.0
- nikic/php-parser: ^4.11|^5.0
- symfony/config: ^5.4.7|^6.0|^7.0
- symfony/console: ^5.4.7|^6.0|^7.0
- symfony/dependency-injection: ^5.4.7|^6.0|^7.0
- symfony/deprecation-contracts: ^2.2|^3
- symfony/filesystem: ^5.4.7|^6.0|^7.0
- symfony/finder: ^5.4.7|^6.0|^7.0
- symfony/framework-bundle: ^5.4.7|^6.0|^7.0
- symfony/http-kernel: ^5.4.7|^6.0|^7.0
- symfony/maker-bundle: ^1.44
- symfony/process: ^5.4.7|^6.0|^7.0
- symfony/yaml: ^5.4.7|^6.0|^7.0
Requires (Dev)
- symfony/phpunit-bridge: ^5.4|^6.0|^7.0
- twig/twig: ^2.0|^3.0
README
The ODM Document Maker helps you create Symfony Doctrine ODM Documents
Installation
composer require constantable/odm-document-maker
Maker
The constantable:make-document
command creates or updates a document and repository class.
php bin/console constantable:make-document BlogPost
If the argument is missing, the command will ask for the document class name interactively.
You can also mark this class as an API Platform resource. A hypermedia CRUD API will automatically be available for this document class:
php bin/console constantable:make-document --api-resource
You can also generate all the getter/setter/adder/remover methods for the properties of existing documents:
php bin/console constantable:make-document --regenerate
To overwrite any existing methods:
php bin/console constantable:make-document --regenerate --overwrite
You can create an EmbeddedDocument class:
php bin/console constantable:make-document --embedded