webui-aria2/index.html

338 lines
11 KiB
HTML
Raw Normal View History

<!doctype html>
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title></title>
<meta name="description" content="">
<meta name="author" content="">
<meta name="viewport" content="width=device-width">
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/bootstrap.css">
<script src="js/libs/modernizr-2.5.3.min.js"></script>
<script src="js/libs/jquery-1.7.2.js"></script>
<script src="js/libs/bootstrap.js"></script>
2012-06-04 16:08:46 +02:00
<script src="js/libs/mustache.js"></script>
<script src="js/aria2_settings.js"></script>
2012-06-04 16:08:46 +02:00
<style>
.button_set {
float: right;
margin-bottom: 5px;
}
</style>
<!--{{{ active downloads template start -->
2012-06-05 11:44:54 +02:00
<script type="text/mustache" id="download_active_template">
<div class="row download_active_item" data-gid="{{gid}}">
<div class="span3" style="overflow: hidden;">
<b style="font-size: 14px;" class="name">{{name}}</b>
2012-06-05 07:25:57 +02:00
</div>
2012-06-05 14:53:52 +02:00
<div class="span6">
<div class="pull-right">
<span class="label label-success">Remaining: <span class="remaining">{{remaining}}</span></span> |
<span class="label label-success">Progress: <span class="percentage">{{percentage}}</span>%</span> |
<span class="label label-success">Speed: <span class="down">{{down}}</span></span> |
<span class="label label-success">Time left: <span class="eta">{{eta}}</span></span>
</div>
2012-06-05 11:44:54 +02:00
</div>
<div class="span3">
<div class="button_set">
2012-06-05 11:44:54 +02:00
<button class="btn btn-mini download_pause"><i class="icon-pause"></i>Pause</button>
<button class="btn btn-mini btn-info" data-toggle="collapse" data-target="[data-gid={{gid}}] .more_info">More Info</button>
<button class="btn btn-mini btn-danger download_remove"><i class="icon-remove"></i> Remove</button>
2012-06-05 11:44:54 +02:00
</div>
2012-06-05 07:25:57 +02:00
</div>
<br>
<div class="span12 progress progress-striped active">
2012-06-05 14:53:52 +02:00
<div class="bar" style="width: {{percentage}}%;"></div>
2012-06-05 07:25:57 +02:00
</div>
<br>
2012-06-07 10:12:26 +02:00
<div class="span12 more_info collapse">More info here!!!</div>
2012-06-05 07:25:57 +02:00
</div>
2012-06-05 07:25:57 +02:00
</script>
<!-- active downloads template end }}}-->
<!--{{{ waiting downloads template start -->
2012-06-05 11:44:54 +02:00
<script type="text/mustache" id="download_waiting_template">
<div class="row download_waiting_item" data-gid="{{gid}}">
2012-06-05 14:53:52 +02:00
<div class="span4" style="overflow: hidden;">
<b style="font-size: 14px;">{{name}}</b>
2012-06-05 11:44:54 +02:00
</div>
2012-06-05 14:53:52 +02:00
<div class="span6">
<span class="badge badge-warning">Status: {{status}}</span>
<div class="pull-right">
2012-06-05 16:12:01 +02:00
<span class="label label-warning">Size: {{size}}</span> |
<span class="label label-warning">Remaining: {{remaining}}</span> |
2012-06-05 16:12:01 +02:00
<span class="label label-warning">Progress: {{percentage}}%</span>
</div>
2012-06-05 11:44:54 +02:00
</div>
2012-06-05 14:53:52 +02:00
<div class="span2">
<div class="button_set">
2012-06-05 11:44:54 +02:00
<button class="btn btn-mini download_play"><i class="icon-play"></i> Play</button>
<button class="btn btn-mini btn-danger download_remove"><i class="icon-fire"></i> Purge</button>
2012-06-05 11:44:54 +02:00
</div>
</div>
<br>
2012-06-05 11:44:54 +02:00
<div class="span12 progress progress-striped">
2012-06-05 14:53:52 +02:00
<div class="bar" style="width: {{percentage}}%; background-color:#FBB450"></div>
2012-06-05 11:44:54 +02:00
</div>
</div>
</script>
<!-- waiting downloads template end }}}-->
<!--{{{ stopped downloads template start -->
2012-06-05 11:44:54 +02:00
<script type="text/mustache" id="download_stopped_template">
<div class="row download_stopped_item" data-gid="{{gid}}">
2012-06-05 14:53:52 +02:00
<div class="span4" style="overflow: hidden;">
<b style="font-size: 14px;">{{name}}</b>
2012-06-05 11:44:54 +02:00
</div>
2012-06-05 14:53:52 +02:00
<div class="span6">
<span class="badge badge-important">Status: {{status}}</span>
<div class="pull-right">
2012-06-05 16:12:01 +02:00
<span class="label label-important">Size: {{size}}</span> |
<span class="label label-important">Downloaded: {{downloaded}}</span> |
2012-06-05 16:12:01 +02:00
<span class="label label-important">Progress: {{percentage}}%</span>
</div>
2012-06-05 11:44:54 +02:00
</div>
2012-06-05 14:53:52 +02:00
<div class="span2">
<div class="button_set">
<button class="btn btn-mini download_restart"><i class="icon-repeat"></i> Restart</button>
<button class="btn btn-mini btn-danger download_remove"><i class="icon-fire"></i> Purge</button>
2012-06-05 11:44:54 +02:00
</div>
</div>
<br>
2012-06-05 11:44:54 +02:00
<div class="span12 progress progress-striped">
2012-06-05 14:53:52 +02:00
<div class="bar" style="width: {{percentage}}%; background-color:#EE5F5B"></div>
2012-06-05 11:44:54 +02:00
</div>
</div>
</script>
<!-- stopped downloads template end }}}-->
2012-06-05 11:44:54 +02:00
2012-06-06 14:08:24 +02:00
<!--{{{ start global settings item template -->
<script type="text/mustache" id="global_general_settings_template">
{{#settings}}
<fieldset>
<legend>{{name}}</legend>
<div class="control-group">
{{#values}}
<label class="control-label" for="input_settings_{{name}}">{{name}}</label>
<div class="controls">
{{^options}}
{{#has_value}}
<input typ="text" class="input-xlarge" id="input_settings_{{name}}" value="{{value}}"/>
{{/has_value}}
{{^has_value}}
<input typ="text" class="input-xlarge" placeholder="default" id="input_settings_{{name}}"/>
{{/has_value}}
{{/options}}
{{#option}}
{{#has_value}}
<select id="input_settings_{{name}}">
{{/has_value}}
{{^has_value}}
<select id="input_settings_{{name}}">
<option value="no_val">Default</option>
{{/has_value}}
{{/option}}
{{#options}}
{{#has_value}}
<option value="{{& val}}">{{disp}}</option>
{{/has_value}}
{{^has_value}}
<option value="{{& .}}">{{.}}</option>
{{/has_value}}
{{/options}}
{{#option}}
</select>
{{/option}}
<p class="help-block">{{desc}}</p>
<br><br>
</div>
{{/values}}
</div>
</fieldset>
{{/settings}}
2012-06-06 14:08:24 +02:00
</script>
<!-- global settings template end }}}-->
2012-06-04 16:08:46 +02:00
<style>
body {
padding-top: 60px;
}
</style>
</head>
2012-06-04 16:08:46 +02:00
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<a class="brand" href="#">Aria2 Web-Client</a>
<div class="nav-collapse">
<ul class="nav">
<li class="active"><a href="#">Active Downloads</a></li>
<!-- <li><a href="#watiting_downloads">Passive Downloads</a></li> -->
<li><a href="#" onclick="custom_aria2_connect()">Aria2 connection settings</a></li>
2012-06-06 14:08:24 +02:00
<li><a href="#" onclick="custom_global_settings()">Aria2 global settings</a></li>
2012-06-04 16:08:46 +02:00
<li><a id="newDownload" href="#">Add Download</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</div>
</div>
<div role="main" class="container">
2012-06-05 07:25:57 +02:00
<!-- Download items here -->
2012-06-05 11:44:54 +02:00
<div id="active_downloads"></div>
<div id="waiting_downloads"></div>
<div id="stopped_downloads"></div>
2012-06-05 07:25:57 +02:00
</div>
2012-06-05 11:44:54 +02:00
<!--{{{ Hidden dialogs and out of screen HTML elements -->
2012-06-04 16:08:46 +02:00
<!--{{{ error connection template -->
<div class="modal hide" id="error_connect">
<div class="modal-header">
<button class="close" data-dismiss="modal">x</button>
<h3>Connection to Aria failed :( </h3>
</div>
<div class="modal-body">
<p>
Make sure that aria2c is running and rpc is enabled.
aria2c --enable-rpc
</p>
</div>
<div class="modal-footer">
2012-06-04 16:08:46 +02:00
<a href="#" onclick="window.location.reload(true)" class="btn">Retry</a>
<a href="#" onclick="custom_aria2_connect()" class="btn btn-primary">Use custom IP and port settings</a>
</div>
</div>
<!-- error connection end }}}-->
2012-06-04 16:08:46 +02:00
<!--{{{ change aria2 rpc host and port template -->
<div class="modal hide" id="change_conf">
2012-06-04 16:08:46 +02:00
<div class="modal-header">
<button class="close" data-dismiss="modal">x</button>
<h3>Please enter the aria2 RPC port and host</h3>
</div>
<div class="modal-body">
<form class="form-horizontal">
<fieldset>
<div class="control-group">
<label class="control-label" for="input_host">Enter the host:</label>
<div class="controls">
<div class="input-prepend"><span class="add-on">http://</span><input type="text" class="input-xlarge" id="input_host" placeholder="localhost"/></div>
<p class="help-block">Enter the ip or dns name of the server on which the rpc for aria2 is running (default = localhost)</p>
</div>
<label class="control-label" for="input_port">Enter the port:</label>
<div class="controls">
<input type="text" class="input-xlarge" placeholder="6800" id="input_port"/>
<p class="help-block">Enter the port of the server on which the rpc for aria2 is running (default = 6800)</p>
</div>
<label class="control-label" for="input_user">Enter the username (optional):</label>
<div class="controls">
<input type="text" class="input-xlarge" id="input_user"/>
<p class="help-block">Enter the username of the server on which the rpc for aria2 is running (empty if authentication not enabled)</p>
</div>
<label class="control-label" for="input_pass">Enter the password (optional):</label>
<div class="controls">
<input type="text" class="input-xlarge" id="input_pass"/>
<p class="help-block">Enter the password of the server on which the rpc for aria2 is running (empty if authentication not enabled)</p>
</div>
2012-06-04 16:08:46 +02:00
</div>
</fieldset>
</form>
</div>
<div class="modal-footer">
<a href="#" onclick="window.location.reload(true)" class="btn">Retry with default configuration</a>
<a href="#" onclick="update_server_conf()" class="btn btn-primary">Use custom IP and port settings</a>
</div>
</div>
<!-- change aria2 rpc host and port template }}}-->
2012-06-04 16:08:46 +02:00
<!--{{{ add new Download template -->
<div class="modal hide" id="newDownload_modal">
2012-06-04 16:08:46 +02:00
<div class="modal-header">
<button class="close" data-dismiss="modal">x</button>
<h3>Add a new Download</h3>
</div>
<div class="modal-body">
<form class="form-horizontal">
<fieldset>
<div class="control-group">
<label class="control-label" for="newDownload_url">Enter url for the Download:</label>
<div class="controls">
<input type="text" class="input-xlarge" id="newDownload_url" placeholder="http://example.com"/>
<button class="btn" id="multiple_uris"><i class="icon-plus-sign"></i></button>
2012-06-05 07:25:57 +02:00
<span class="help-block">URI can be HTTP(S)/FTP/BitTorrent Magnet URI</span>
<ol class="download_urls"></ol>
2012-06-04 16:08:46 +02:00
</div>
</div>
</fieldset>
</form>
</div>
<div class="modal-footer">
<button id="addNewDownload" class="btn">Add Download</button>
</div>
</div>
<!-- add new Download template end }}}-->
<!--{{{ global settings template start -->
<div class="modal hide" id="global_settings_modal">
<div class="modal-header">
<button class="close" data-dismiss="modal">x</button>
<h3>Global Settings</h3>
</div>
<div class="modal-body">
<form class="form-horizontal" id="dynamic_global_settings">
<!-- dynamic settings injection here -->
</form>
</div>
<div class="modal-footer">
<button id="save_global_settings" class="btn btn-success">Save</button>
</div>
</div>
<!-- global settings template end }}}-->
2012-06-05 11:44:54 +02:00
<!-- }}} hidden modals end -->
<script src="js/plugins.js"></script>
<script src="js/script.js"></script>
</body>
</html>