dachcom-digital / pimcore-formbuilder

Pimcore Formbuilder - create forms easily!
Other
92 stars 47 forks source link

Unable to initialize Dynamic Multi File Upload field #244

Closed hxhelm closed 3 years ago

hxhelm commented 3 years ago
Q A
Bug report? yes
Feature request? no
BC Break report? no
RFC? no

I can't seem to get the Multi File Upload working. I followed the instructions in the Implementation section for the File Upload: https://github.com/dachcom-digital/pimcore-formbuilder/blob/master/docs/80_FileUpload.md#implementation But the Upload field remains empty, with no javascript errors. Bildschirmfoto von 2020-10-20 11-50-35 Here's the current layout for my form:

<link rel="stylesheet" href="{{ asset('bundles/formbuilder/css/fineuploader/fine-uploader-new.min.css') }}" />
<section class="area area-generic-form">
    <div class="container">
        {% block form_builder_layout %}
        {% endblock %}
    </div>
</section>
<script type="text/javascript" src="{{ asset('bundles/formbuilder/js/frontend/plugins/jquery.fb.core.form-builder.js') }}"></script>
<script type="text/javascript" src="{{ asset('bundles/formbuilder/js/frontend/vendor/fineuploader/jquery.fine-uploader.min.js') }}"></script>

Do I have to configure the fine-uploader separately, or is this supposed to work out of the box?

solverat commented 3 years ago

You also need to initialize the core manager:


var $forms = $('form.formbuilder'),
    $ajaxForms = $('form.formbuilder.ajax-form');

$ajaxForms.formBuilderAjaxManager();

see https://github.com/dachcom-digital/pimcore-formbuilder/blob/master/docs/91_Javascript.md#core-extension