mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-12-20 18:09:30 +00:00
Implemented a treeview element using stimulus
This commit is contained in:
parent
91af024081
commit
8cf131a7d6
3 changed files with 102 additions and 22 deletions
|
|
@ -21,28 +21,7 @@
|
|||
{% block card_content %}
|
||||
<div class="row">
|
||||
<div class="col-sm-4">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-8">
|
||||
<input id="tree-search" type="search" class="form-control" placeholder="{% trans %}search.placeholder{% endtrans %}">
|
||||
</div>
|
||||
<div class="btn-group btn-group-sm col-4" role="group">
|
||||
<button type="button" class="btn btn-outline-secondary" id="tree-expand"
|
||||
title="{% trans %}expandAll{% endtrans %}">
|
||||
<i class="fas fa-plus fa-fw"></i>
|
||||
</button>
|
||||
<button type="button" class="btn btn-outline-secondary" id="tree-reduce"
|
||||
title="{% trans %}reduceAll{% endtrans %}">
|
||||
<i class="fas fa-minus fa-fw"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="treeview-sm mt-2" id="tree" data-tree-data="{{ generateTreeData(entity) }}"
|
||||
data-tree-search="#tree-search" data-tree-expand="#tree-expand" data-tree-reduce="#tree-reduce">
|
||||
|
||||
</div>
|
||||
|
||||
{% include "elements/_tree_view.html.twig" %}
|
||||
</div>
|
||||
|
||||
<div class="col-sm-8">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue