Getting following error,

Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException: The "profile" entity type did not specify a "employee" form class. in Drupal\Core\Entity\EntityTypeManager->getFormObject() (line 223 of /Library/WebServer/Documents/profiledemo/web/core/lib/Drupal/Core/Entity/EntityTypeManager.php).

I have research and found the solution for entity types of user and nodes, but not sure of what it can be for the profiles.

function mymodule_entity_type_build(array &$entity_types) {
   $entity_types['user']->setFormClass('step1', "Drupal\user\RegisterForm"); // works for user registration form

note sure what replacement need to be made for


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.