143 lines
6.5 KiB
HTML
143 lines
6.5 KiB
HTML
<!--
|
||
vim: ts=2 noexpandtab
|
||
-->
|
||
{% extends "index.html" %}
|
||
{% block title %}{{ super() }} - {{ getLocalString(language, "create") }}{% endblock%}
|
||
{% set active_page = "create" %}
|
||
{% block content %}
|
||
<link href="{{ url_for("static", filename="css/create.css") }}" rel="stylesheet">
|
||
<script src="{{ url_for("static", filename="js/create.js") }}"></script>
|
||
<div>
|
||
<h2 class="headline">{{ getLocalString(language, "create_new_torrent") }}</h2>
|
||
{% if errors %}
|
||
{% for error in errors %}
|
||
<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>
|
||
<span class="message">{{ error|safe }}</span>
|
||
</div>
|
||
{% endfor %}
|
||
{% endif %}
|
||
{% 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 %}
|
||
<form class="form-horizontal" action="/create" method="post" enctype="multipart/form-data" onsubmit="return validateForm()">
|
||
<div class="form-group">
|
||
<label for="inputTorrentFile" class="col-sm-3 control-label">{{ getLocalString(language, "torrent_file") }}</label>
|
||
<div class="col-sm-9">
|
||
<input name="torrentFile" class="file" type="file" size="50" maxlength="100000" accept="application/x-bittorrent" onchange="setButtonToFilename(event)">
|
||
</div>
|
||
</div>
|
||
<div class="form-group detectedInfosGroup">
|
||
<label for="inputTorrentFile" class="col-sm-3 control-label">File info</label>
|
||
<div class="col-sm-9 detectedInfos">
|
||
<div class="detectedGroup sizeGroup">
|
||
<h5>{{ getLocalString(language, "size") }}:</h5>
|
||
<p class="detectedSize"></p>
|
||
</div>
|
||
<div class="detectedGroup trackerGroup">
|
||
<h5>{{ getLocalString(language, "tracker") }}:</h5>
|
||
<p class="detectedTracker"></p>
|
||
</div>
|
||
<div class="detectedGroup filesGroup">
|
||
<h5>{{ getLocalString(language, "detected_files") }}:</h5>
|
||
<div class="detectedFiles">
|
||
<ul>
|
||
</ul>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label for="inputCategory" class="col-sm-3 control-label">{{ getLocalString(language, "category") }}</label>
|
||
<div class="col-sm-9">
|
||
<div class="row row-container">
|
||
<div class="col-md-6 category-column">
|
||
<div class="dropdown">
|
||
<button class="btn btn-default dropdown-toggle" type="button" id="dropdownMenu1" data-toggle="dropdown" aria-expanded="true">
|
||
<span class="text">{{ getLocalString(language, "category") }}</span>
|
||
<span class="caret"></span>
|
||
<input type="hidden" name="category" class="category">
|
||
</button>
|
||
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu1">
|
||
{% for category in sorted(categories.keys()) %}
|
||
<li role="presentation"><a role="menuitem" tabindex="-1" href="#">{{ getLocalString(language, category) }}</a></li>
|
||
{% endfor %}
|
||
</ul>
|
||
</div>
|
||
</div>
|
||
<div class="col-md-6 subcategory-column">
|
||
<div class="dropdown">
|
||
<button class="btn btn-default dropdown-toggle" type="button" id="dropdownMenu1" data-toggle="dropdown" aria-expanded="true" disabled>
|
||
<span class="text">{{ getLocalString(language, "subcategory") }}</span>
|
||
<span class="caret"></span>
|
||
<input type="hidden" name="subcategory" class="subcategory">
|
||
</button>
|
||
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu1">
|
||
</ul>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label for="inputName" class="col-sm-3 control-label">{{ getLocalString(language, "name") }}</label>
|
||
<div class="col-sm-9">
|
||
<input type="text" name="name" class="form-control name" placeholder="e.g. Attack of the Killer Tomatoes" aria-describedby="basic-addon1">
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label for="inputName" class="col-sm-3 control-label">{{ getLocalString(language, "audio_quality") }}</label>
|
||
<div class="col-sm-9">
|
||
<input type="text" name="audioquality_description" class="form-control name" placeholder="e.g. English, AC-3 at 384kbps" aria-describedby="basic-addon1">
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label for="inputName" class="col-sm-3 control-label">{{ getLocalString(language, "video_quality") }}</label>
|
||
<div class="col-sm-9">
|
||
<input type="text" name="videoquality_description" class="form-control name" placeholder="e.g. XviD, 720×400 at 1809 kbps" aria-describedby="basic-addon1">
|
||
</div>
|
||
</div>
|
||
<!--
|
||
<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>
|
||
</div>
|
||
</div>
|
||
-->
|
||
<div class="form-group">
|
||
<label for="inputName" class="col-sm-3 control-label">{{ getLocalString(language, "description") }}</label>
|
||
<div class="col-sm-9">
|
||
<textarea name="description" class="form-control description" rows="10" placeholder="Hint: Markdown is supported in this field"></textarea>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<div class="col-sm-offset-3 col-sm-9">
|
||
<button type="submit" class="btn btn-default"><span class="glyphicon glyphicon-plus" aria-hidden="true"></span> {{ getLocalString(language, "create") }}!</button>
|
||
</div>
|
||
</div>
|
||
</form>
|
||
</div>
|
||
{% endblock content%}
|