EasyAdminBundle
EasyAdminBundle copied to clipboard
My question is, does easyadmin allow you to create nested fields?
I have three nested fields to do with easyadmin, when displaying the page, the three are displayed, the first field contains the classes of a college, the second field must display the subjects of the class selected , the third field must display the teachers of the subject, everything will be automatic without submitting the form each time, I used the same system in a symfony form I used jquery and everything worked fine but when I do the same thing at the level of the symfony easyadmin dundle the thing does not work and it puts errors in the console, POST http://localhost:8000/admin?crudAction=new&crudControllerFqcn=Apps%5CAdmin%5CController%5CCrud%5CGenerale%5CProgramme%5CSecondaryProgrammeCrudController 422 (Unprocessable Entity) et aussi jquery-3.7.1.min.js:2
Failed to load XHR: POST "http://localhost:8000/admin?crudAction=new&crudControllerFqcn=Apps%5CAdmin%5CController%5CCrud%5CGenerale%5CProgramme%5CSecondaryProgrammeCrudController&referrer=http://localhost:8000/admin?crudAction%3Dindex%26crudControllerFqcn%3DApps%255CAdmin%255CController%255CCrud%255CGenerale%255CProgramme%255CSecondaryProgrammeCrudController".
here is my javascript code
let $input = $(dataform).find(target);
$(target).replaceWith($input);
},
error: function (jqXHR, textStatus, errorThrown) {
console.error(jqXHR.responseText); // Afficher l'erreur détaillée dans la console
// alert(jqXHR.responseText);
}
});
});