diff --git a/resources/js/views/formtemplate/FormBuilder.vue b/resources/js/views/formtemplate/FormBuilder.vue index 82101d13..f5c8de5b 100644 --- a/resources/js/views/formtemplate/FormBuilder.vue +++ b/resources/js/views/formtemplate/FormBuilder.vue @@ -40,6 +40,7 @@ @addField="addField($event.detail[0])" @editField="editField($event.detail[0], $event.detail[1])" @deleteField="deleteField($event.detail[0], $event.detail[1])" + @deleteSection="deleteSection($event.detail[0])" > @@ -134,6 +135,10 @@ function addField(sectionIndex) { }; } +function deleteSection(sindex) { + inner.value.config.sections.splice(sindex, 1); +} + function setFieldType(field) { singleField.value.model = JSON.parse(JSON.stringify(field.default)); }