Add deleteSection
This commit is contained in:
parent
4ddf76943d
commit
b26935fc07
|
@ -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])"
|
||||
></event-form>
|
||||
</ui-box>
|
||||
</form>
|
||||
|
@ -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));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue