generate:plugin:validationconstraint
Generate a validation constraint plugin.
वापर:
drupal generate:plugin:validationconstraint [options]
gpvc
उपलब्ध पर्याय
पर्याय | तपशील |
---|---|
--module | मॉड्यूलचे नाव. |
--class | Plugin class name |
--label | Plugin label |
--plugin-id | Plugin id |
--hook | Generate hook to validate a field |
--field-id | Field id |
--bundle | Bundle |
उदाहरणे
Generate a validation constraint plugin specifying the module name, the class, its label, the plugin id, the entity bundle and the field id
drupal generate:plugin:validationconstraint \
--module="modulename" \
--class="ExampleConstraint" \
--label="Example validation constraint" \
-plugin-id="example_validation_constraint" \
--hook \
--field-id="field_exmaple_id" \
--bundle="entity_example_bundle" \
--no-interaction