mirror of
https://github.com/misode/misode.github.io.git
synced 2026-05-02 07:55:29 +00:00
Fix not being able to add pools
This commit is contained in:
+2
-2
@@ -31,9 +31,9 @@
|
||||
</nav>
|
||||
<div class="container d-none">
|
||||
<div class="row my-4">
|
||||
<div class="col-12 col-lg-7 mb-3 structure-container">
|
||||
<div class="col-12 col-lg-7 mb-3 structure-container" data-index="table">
|
||||
<div class="input-group">
|
||||
<button type="button" class="btn btn-success d-block mr-3 float-left" onclick="addComponent(this, 'pools')" data-field="table" data-i18n="add_pool"></button>
|
||||
<button type="button" class="btn btn-success d-block mr-3 float-left" onclick="addComponent(this, 'pools')" data-field="table" data-i18n="pool_add"></button>
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text rounded-left" data-i18n="$table.type"></span>
|
||||
</div>
|
||||
|
||||
@@ -148,7 +148,7 @@ function copySource(el) {
|
||||
function getPath(el) {
|
||||
let $node = $(el).closest('[data-index]');
|
||||
let index = $node.attr('data-index');
|
||||
if (index === 'pools') return ['pools'];
|
||||
if (index === 'table') return [];
|
||||
let parent = getPath($node.parent());
|
||||
parent.push(index);
|
||||
return parent;
|
||||
|
||||
Reference in New Issue
Block a user