[fix] form is for all the panels at once otherwise we don't send everything

This commit is contained in:
Laurent Peuch 2019-06-25 05:38:58 +02:00
parent 97836d7c5b
commit a87ecb7d8d

View file

@ -16,6 +16,7 @@
{{#config_panel}} {{#config_panel}}
<h2>{{../app_name}} configuration panel</h2> <h2>{{../app_name}} configuration panel</h2>
<hr> <hr>
<form class="form-horizontal" action="#/apps/{{../app_id}}/config" method="POST">
{{#panel}} {{#panel}}
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading" role="tab" id="heading-{{ @index }}"> <div class="panel-heading" role="tab" id="heading-{{ @index }}">
@ -28,7 +29,6 @@
</div> </div>
<div id="collapse-{{ @index }}" class="panel-collapse collapse {{#if (eq @index 0)}}in{{/if}}" role="tabpanel" aria-labelledby="heading-{{ @index }}"> <div id="collapse-{{ @index }}" class="panel-collapse collapse {{#if (eq @index 0)}}in{{/if}}" role="tabpanel" aria-labelledby="heading-{{ @index }}">
<div class="panel-body"> <div class="panel-body">
<form class="form-horizontal" action="#/apps/{{../../app_id}}/config" method="POST">
{{#sections}} {{#sections}}
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"><h3 class="panel-title">{{name}} <small>{{help}}</small></h3></div> <div class="panel-heading"><h3 class="panel-title">{{name}} <small>{{help}}</small></h3></div>
@ -85,13 +85,13 @@
</div> </div>
{{/sections}} {{/sections}}
<br>
<div><button class="btn btn-primary" type="submit">Save</button></div>
</form>
</div> </div>
</div> </div>
</div> </div>
{{/panel}} {{/panel}}
<br>
<div><button class="btn btn-primary" type="submit">Save</button></div>
</form>
{{/config_panel}} {{/config_panel}}
</div> </div>