2015-02-05 22:38:39 +01:00
|
|
|
|
<!--
|
|
|
|
|
vim: ts=2 noexpandtab
|
|
|
|
|
-->
|
|
|
|
|
{% extends "index.html" %}
|
2017-12-29 08:03:17 +01:00
|
|
|
|
{% block title %}{{ super() }} - {{ _("Create") }}{% endblock%}
|
2015-02-12 22:06:31 +01:00
|
|
|
|
{% set active_page = "create" %}
|
2015-02-05 22:38:39 +01:00
|
|
|
|
{% block content %}
|
2015-02-15 03:48:39 +01:00
|
|
|
|
<link href="{{ url_for("static", filename="css/create.css") }}" rel="stylesheet">
|
|
|
|
|
<script src="{{ url_for("static", filename="js/create.js") }}"></script>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
<div>
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<h2 class="headline">{{ _("Create new torrent") }}</h2>
|
2015-02-15 04:51:27 +01:00
|
|
|
|
{% if errors %}
|
|
|
|
|
{% for error in errors %}
|
2015-02-14 00:17:40 +01:00
|
|
|
|
<div class="alert alert-danger alert-dismissible" role="alert">
|
|
|
|
|
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
|
2017-12-29 00:31:28 +01:00
|
|
|
|
<span class="message">{{ error|safe }}</span>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
2015-02-15 04:51:27 +01:00
|
|
|
|
{% endfor %}
|
|
|
|
|
{% endif %}
|
2017-12-29 01:47:39 +01:00
|
|
|
|
{% if messages %}
|
|
|
|
|
{% for message in messages %}
|
|
|
|
|
<div class="alert alert-success alert-dismissible" role="alert">
|
|
|
|
|
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
|
|
|
|
|
<span class="message">{{ message|safe }}</span>
|
|
|
|
|
</div>
|
|
|
|
|
{% endfor %}
|
|
|
|
|
{% endif %}
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<form class="form-horizontal torrent-form" action="/create" method="post" enctype="multipart/form-data" onsubmit="return validateForm()">
|
|
|
|
|
<div class="form-group file required">
|
|
|
|
|
<label for="inputTorrentFile" class="col-sm-3 control-label required">{{ _("Torrent file") }}</label>
|
2015-02-17 23:03:19 +01:00
|
|
|
|
<div class="col-sm-9">
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<input name="torrentFile" class="file required" type="file" size="50" maxlength="100000" accept="application/x-bittorrent" onchange="setButtonToFilename(event)">
|
2015-02-15 03:48:39 +01:00
|
|
|
|
</div>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
2015-02-21 04:29:47 +01:00
|
|
|
|
<div class="form-group detectedInfosGroup">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<label for="inputTorrentFile" class="col-sm-3 control-label">{{ _("File info") }}</label>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
<div class="col-sm-9 detectedInfos">
|
|
|
|
|
<div class="detectedGroup sizeGroup">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<h5>{{ _("Size") }}:</h5>
|
2015-02-21 04:29:47 +01:00
|
|
|
|
<p class="detectedSize"></p>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
</div>
|
|
|
|
|
<div class="detectedGroup trackerGroup">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<h5>{{ _("Tracker") }}:</h5>
|
2015-02-21 04:29:47 +01:00
|
|
|
|
<p class="detectedTracker"></p>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
</div>
|
|
|
|
|
<div class="detectedGroup filesGroup">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<h5>{{ _("Detected files") }}:</h5>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
<div class="detectedFiles">
|
|
|
|
|
<ul>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<div class="form-group category required">
|
|
|
|
|
<label for="category" class="col-sm-3 control-label required">{{ _("Category") }}</label>
|
2015-02-17 23:03:19 +01:00
|
|
|
|
<div class="col-sm-9">
|
2015-02-15 04:51:27 +01:00
|
|
|
|
<div class="row row-container">
|
|
|
|
|
<div class="col-md-6 category-column">
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<select class="form-control dropdown required" id="category" name="category">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<option value="-1" selected>--- {{ _("Select Category") }} ---</option>
|
2017-12-29 04:57:37 +01:00
|
|
|
|
{% for category in categories %}
|
|
|
|
|
<option value="{{ category.id }}">{{ category.label }}</option>
|
|
|
|
|
{% endfor %}
|
|
|
|
|
</select>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
2015-02-15 04:51:27 +01:00
|
|
|
|
<div class="col-md-6 subcategory-column">
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<select class="form-control dropdown required" id="subcategory" name="subcategory">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<option value="-1" selected>--- {{ _("Select Subcategory") }} ---</option>
|
2017-12-29 04:57:37 +01:00
|
|
|
|
</select>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<div class="form-group name required">
|
|
|
|
|
<label for="inputName" class="col-sm-3 control-label required">{{ _("Name") }}</label>
|
2015-02-17 23:03:19 +01:00
|
|
|
|
<div class="col-sm-9">
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<input type="text" name="name" class="form-control name required" placeholder="{{ _("e.g. Attack of the Killer Tomatoes") }}" aria-describedby="basic-addon1">
|
2015-02-15 03:48:39 +01:00
|
|
|
|
</div>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<div class="form-group audioquality">
|
|
|
|
|
<label for="audioquality_description" class="col-sm-3 control-label">{{ _("Audio quality") }}</label>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
<div class="col-sm-9">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<input type="text" name="audioquality_description" class="form-control name" placeholder="{{ _("e.g. English, AC-3 @ 384kbps") }}" aria-describedby="basic-addon1">
|
2015-02-21 03:01:47 +01:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<div class="form-group videoquality">
|
|
|
|
|
<label for="videoquality_description" class="col-sm-3 control-label">{{ _("Video quality") }}</label>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
<div class="col-sm-9">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<input type="text" name="videoquality_description" class="form-control name" placeholder="{{ _("e.g. XviD, 720×400 @ 1809 kbps") }}" aria-describedby="basic-addon1">
|
2015-02-21 03:01:47 +01:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<!--
|
2015-02-17 23:03:19 +01:00
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label for="inputName" class="col-sm-3 control-label">Audio-Quality</label>
|
|
|
|
|
<div class="col-sm-9">
|
|
|
|
|
<div class="btn-group quality-box" data-toggle="buttons">
|
|
|
|
|
<label class="btn btn-default">
|
|
|
|
|
<input type="checkbox" autocomplete="off"><span class="glyphicon glyphicon-subtitles" aria-hidden="true"></span> Subs</input>
|
|
|
|
|
</label>
|
|
|
|
|
<label class="btn btn-default">
|
|
|
|
|
<input type="checkbox" autocomplete="off"><span class="glyphicon glyphicon-sound-stereo" aria-hidden="true"></span> Stereo</input>
|
|
|
|
|
</label>
|
|
|
|
|
<label class="btn btn-default">
|
|
|
|
|
<input type="checkbox" autocomplete="off"><span class="glyphicon glyphicon-sound-5-1" aria-hidden="true"></span> 5.1</input>
|
|
|
|
|
</label>
|
|
|
|
|
<label class="btn btn-default">
|
|
|
|
|
<input type="checkbox" autocomplete="off"><span class="glyphicon glyphicon-sound-5-1" aria-hidden="true"></span> 6.1</input>
|
|
|
|
|
</label>
|
|
|
|
|
<label class="btn btn-default">
|
|
|
|
|
<input type="checkbox" autocomplete="off"><span class="glyphicon glyphicon-sound-7-1" aria-hidden="true"></span> 7.1</input>
|
|
|
|
|
</label>
|
|
|
|
|
</div>
|
2015-02-15 03:48:39 +01:00
|
|
|
|
</div>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
2015-02-21 03:01:47 +01:00
|
|
|
|
-->
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<div class="form-group description required">
|
|
|
|
|
<label for="inputName" class="col-sm-3 control-label required">{{ _("Description") }}</label>
|
2015-02-17 23:03:19 +01:00
|
|
|
|
<div class="col-sm-9">
|
2017-12-30 22:28:26 +01:00
|
|
|
|
<textarea name="description" class="form-control description required" rows="10" placeholder="{{ _("Hint: Markdown is supported in this field") }}"></textarea>
|
2015-02-15 03:48:39 +01:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2015-02-17 23:03:19 +01:00
|
|
|
|
<div class="form-group">
|
|
|
|
|
<div class="col-sm-offset-3 col-sm-9">
|
2017-12-29 08:03:17 +01:00
|
|
|
|
<button type="submit" class="btn btn-default"><span class="glyphicon glyphicon-plus" aria-hidden="true"></span> {{ _("Create") }}!</button>
|
2015-02-17 23:03:19 +01:00
|
|
|
|
</div>
|
2015-02-15 04:51:27 +01:00
|
|
|
|
</div>
|
2015-02-15 03:48:39 +01:00
|
|
|
|
</form>
|
2015-02-14 00:17:40 +01:00
|
|
|
|
</div>
|
2015-02-05 22:38:39 +01:00
|
|
|
|
{% endblock content%}
|