I need to modify some fields in my form (label and class), based on whether the entity is the latest published version or not. So I need to be able to inject the entity mana
You created a new ViewType without passing the EntityManager. Get the form type from the dic with
$form = $this->createForm($this->get('gutensite_cms.form.type.view'), $view);
or create a new object with the entity manager as an argument
$form = $this->createForm(new ViewType($this->getDoctrine()->getManager()), $view);