Problem when previewing and displaying the form.
When previewing or displaying the user to fill in the form, only these fields appear.

I have 8 different questions in my form, and I just tried to create a new blank one and I have the same problem.

Hi
Do you have errors in glpi/files/_log/php-errors.log or sql-errors.log (same folder) ?
Also, you can directly export the form into its JSON representation to let me try to reproduce.
Here are the errors, which appear in the log file in question.

And here is the json export of my form. export_formcreator_20220209_1638.zip
Please, next time, copy / paste log with text. It is much more readable.
Oh, yes sorry, I totally understand.
Here is the more readable version : `[2022-02-09 15:12:08] glpiphplog.CRITICAL: *** Uncaught Exception Error: Call to undefined method PluginFormcreatorForm::getFromDBByQuestion() in /var/www$ Backtrace : ...rmcreator/inc/field/dropdownfield.class.php:481 GlpiPlugin\Formcreator\Field\DropdownField->buildParams() ...ins/formcreator/inc/abstractfield.class.php:102 GlpiPlugin\Formcreator\Field\DropdownField->getRenderedHtml() plugins/formcreator/inc/question.class.php:300 PluginFormcreatorAbstractField->show() .../twig/twig/src/Extension/CoreExtension.php:1597 PluginFormcreatorQuestion->getRenderedHtml() ...f396b6e8ad8590e2032ef1b7dd8c618dceb54d8.php:200 twig_get_attribute() vendor/twig/twig/src/Template.php:394 __TwigTemplate_72dd827079aa661d49e0937e89753989fad0384f1dcac784876dccd0c0abd56c->doDisplay() vendor/twig/twig/src/Template.php:367 Twig\Template->displayWithErrorHandling() vendor/twig/twig/src/TemplateWrapper.php:47 Twig\Template->display() src/Application/View/TemplateRenderer.php:177 Twig\TemplateWrapper->display() plugins/formcreator/inc/form.class.php:1036 Glpi\Application\View\TemplateRenderer->display() plugins/formcreator/front/formdisplay.php:75 PluginFormcreatorForm->displayUserForm()
[2022-02-09 15:12:08] glpiphplog.CRITICAL: *** Uncaught Exception Error: Call to undefined method PluginFormcreatorForm::getFromDBByQuestion() in /var/www$ Backtrace : ...rmcreator/inc/field/dropdownfield.class.php:481 GlpiPlugin\Formcreator\Field\DropdownField->buildParams() ...ins/formcreator/inc/abstractfield.class.php:102 GlpiPlugin\Formcreator\Field\DropdownField->getRenderedHtml() plugins/formcreator/inc/question.class.php:300 PluginFormcreatorAbstractField->show() .../twig/twig/src/Extension/CoreExtension.php:1597 PluginFormcreatorQuestion->getRenderedHtml() ...f396b6e8ad8590e2032ef1b7dd8c618dceb54d8.php:200 twig_get_attribute() vendor/twig/twig/src/Template.php:394 __TwigTemplate_72dd827079aa661d49e0937e89753989fad0384f1dcac784876dccd0c0abd56c->doDisplay() vendor/twig/twig/src/Template.php:367 Twig\Template->displayWithErrorHandling() vendor/twig/twig/src/TemplateWrapper.php:47 Twig\Template->display() src/Application/View/TemplateRenderer.php:177 Twig\TemplateWrapper->display() plugins/formcreator/inc/form.class.php:1036 Glpi\Application\View\TemplateRenderer->display() plugins/formcreator/front/formdisplay.php:75 PluginFormcreatorForm->displayUserForm()
[2022-02-09 16:38:19] glpiphplog.CRITICAL: *** Uncaught Exception Error: Call to undefined method PluginFormcreatorForm::getFromDBByQuestion() in /var/www$ Backtrace : ...rmcreator/inc/field/dropdownfield.class.php:481 GlpiPlugin\Formcreator\Field\DropdownField->buildParams() ...ins/formcreator/inc/abstractfield.class.php:102 GlpiPlugin\Formcreator\Field\DropdownField->getRenderedHtml() plugins/formcreator/inc/question.class.php:300 PluginFormcreatorAbstractField->show() .../twig/twig/src/Extension/CoreExtension.php:1597 PluginFormcreatorQuestion->getRenderedHtml() ...f396b6e8ad8590e2032ef1b7dd8c618dceb54d8.php:200 twig_get_attribute() vendor/twig/twig/src/Template.php:394 __TwigTemplate_72dd827079aa661d49e0937e89753989fad0384f1dcac784876dccd0c0abd56c->doDisplay() vendor/twig/twig/src/Template.php:367 Twig\Template->displayWithErrorHandling() vendor/twig/twig/src/TemplateWrapper.php:47 Twig\Template->display() src/Application/View/TemplateRenderer.php:177 Twig\TemplateWrapper->display() plugins/formcreator/inc/form.class.php:1036 Glpi\Application\View\TemplateRenderer->display() plugins/formcreator/inc/form.class.php:548 PluginFormcreatorForm->displayUserForm() src/CommonGLPI.php:687 PluginFormcreatorForm::displayTabContentForItem() ajax/common.tabs.php:107 CommonGLPI::displayStandardTab() `
It indicates an error line 218 in the file: dropdownfield.class.php
I'll give you a quick patch, just a minute
No worries, don't worry, I'm in no hurry ^^
I'm a bit angry to see this error not happening for so long. Great thanks for testing the plugin
Below a link to a commit which adds the lost method. Append .diff to the URL to get the raw patch file. Use the patch tool to apply it to the plugin as usual.
https://github.com/pluginsGLPI/formcreator/commit/0aa8a1fe8f41c50b2da179882c5c972940d16864
Ok, it's normal ^^ I'll come back to you tomorrow morning to confirm or not the fix for this, and thanks to you ^^
Hi, I may have made a mistake when applying the bug, but it doesn't seem to correct my problem. It seems that I can't display my forms anymore.
Hi
I may have made a mistake when applying the bug
I think you applied a fix, instead of a bug :)
If you applied the fix by hands this is the wrong and error prone way. You must use git or the patch tool to do it properly.
Indeed it can come from there, what patching tools do you use?
I use patch : https://man7.org/linux/man-pages/man1/patch.1.html
Hello, I come back to you with a little delay, I applied your patch but it does not solve my problem and even prevents the display of forms on the administration side.
Hi
Remove your copy of the plugin and add this one instead. Let me know if this solve your problem.
When installing the plugin with the command :
php bin/console glpi:plugin:install formcreator -u glpi -f -p force-upgrade
It ends with this error :
Uncaught Exception Error: Callto undefined method DBConnection::getDefaultPrimaryKeySignOption() in /var/www/html/glpi/plugins/formcreator/install/upgrade_to_2.13.php at line 226
I guess your copy of GLPI is not up to date. This method has been added approximatively 1 month ago.
What do you mean by my GLPI is not up to date? I have the last version released on the repo of the GLPI project.
You're probably using GLPI 10.0-beta. You need to upgrade to GLPI 10.0-rc1 or the latest revision of the master branch
After migration to GLPI 10.0.0-rc1, and reinstallation of the formcreator that you have provided it still does not seem to correct my problem.
I tried the export you shared here: https://github.com/pluginsGLPI/formcreator/issues/2582#issuecomment-1033940072
and the form looks complete. I see the last question of type file.
Check again your logs to see if you have some error.
For you this method of correction works? I must be doing it wrong in this case...
I suspected that you did not applied the patch properly. That's why I sent you a build. It contains the patch already as the problem was obvious (and someone else reported it 1 or 2 days ago).
As you still report the form is incomplete, then I need you to find php / sql errors to get a clue of where thigs go wrong.
You may also check the developer tools of the browser, and see when you reproduce the problem if you have bad HTTP response codes (>= 300)