1
0
mirror of https://github.com/janeczku/calibre-web synced 2024-12-29 03:20:30 +00:00

Changed mulitple books upload to single button

This commit is contained in:
OzzieIsaacs 2018-03-26 20:50:04 +02:00
parent ee5677f376
commit ea6a957c05

View File

@ -57,22 +57,13 @@
{% if g.user.role_upload() or g.user.role_admin()%}
{% if g.allow_upload %}
<li>
<form id="form-upload-multi" class="navbar-form" action="{{ url_for('upload') }}" method="post" enctype="multipart/form-data">
<form id="form-upload" class="navbar-form" action="{{ url_for('upload') }}" method="post" enctype="multipart/form-data">
<div class="form-group">
<span class="btn btn-default btn-file">{{_('Upload')}} multiple books<input id="btn-upload-multi" name="btn-upload" type="file" multiple></span>
<span class="btn btn-default btn-file">{{_('Upload')}}<input id="btn-upload" name="btn-upload" type="file" multiple></span>
</div>
</form>
</li>
{% endif %}
{% if g.allow_upload %}
<li>
<form id="form-upload" class="navbar-form" action="{{ url_for('upload') }}" method="post" enctype="multipart/form-data">
<div class="form-group">
<span class="btn btn-default btn-file">{{_('Upload')}} a single book<input id="btn-upload" name="btn-upload" type="file"></span>
</div>
</form>
</li>
{% endif %}
{% endif %}
{% if g.user.role_admin() %}
<li><a id="top_admin" href="{{url_for('admin')}}"><span class="glyphicon glyphicon-dashboard"></span><span class="hidden-sm"> {{_('Admin')}}</span></a></li>
@ -246,10 +237,6 @@
$("#loader").show();
$("#form-upload").submit();
});
$("#btn-upload-multi").change(function () {
$("#loader").show();
$("#form-upload-multi").submit();
});
});
</script>