feat(about): show client black list item

This commit is contained in:
OldHawk
2017-10-18 18:16:18 +08:00
parent 11cb46636d
commit 5bf57862ff
6 changed files with 66 additions and 15 deletions

View File

@@ -540,18 +540,18 @@ module.exports = {
* @clientBlackList
*
* download client black list
* all the list client can not download the torrent data
* all the list client can not announce or get any data
*
* @name: client software name
*/
clientBlackList: [
{name: 'Transmission/2.93'},
{name: 'Mozilla'},
{name: 'AppleWebKit'},
{name: 'Safari'},
{name: 'Chrome'},
{name: 'Lynx'},
{name: 'Opera'}
{name: 'Transmission/2.93', type: 'client'},
{name: 'Mozilla', type: 'browser'},
{name: 'AppleWebKit', type: 'browser'},
{name: 'Safari', type: 'browser'},
{name: 'Chrome', type: 'browser'},
{name: 'Lynx', type: 'browser'},
{name: 'Opera', type: 'browser'}
],
/**

View File

@@ -5,11 +5,12 @@
.module('about')
.controller('AboutController', AboutController);
AboutController.$inject = ['$scope', '$translate', 'getStorageLangService'];
AboutController.$inject = ['$scope', 'MeanTorrentConfig'];
function AboutController($scope, $translate, getStorageLangService) {
function AboutController($scope, MeanTorrentConfig) {
var vm = this;
vm.lang = getStorageLangService.getLang();
vm.blackListConfig = MeanTorrentConfig.meanTorrentConfig.clientBlackList;
vm.announce = MeanTorrentConfig.meanTorrentConfig.announce;
vm.init = function () {

View File

@@ -0,0 +1,30 @@
@import (reference) "../../../core/client/less/mt-var.less";
.black-list {
.black-item {
position: relative;
border: solid 1px #333;
border-radius: 4px;
background-color: #555;
padding: 10px 0 15px 0;
margin: 20px 0 0 0;
overflow: hidden;
.fa {
font-size: 8em;
}
h4 {
color: #ddd;
}
span {
color: #999;
}
}
.black-icon {
position: absolute;
top: -30px;
right: -30px;
opacity: 0.3;
}
}

View File

@@ -6,6 +6,24 @@
{{'ABOUT.CLIENT_BLACK_LIST' | translate}}
</h3>
</span>
<div class="margin-top-10">
<div class="alert alert-warning" role="alert" style="padding: 10px 50px;">
<span translate="ABOUT.BLACK_TOOLTIP" translate-values="{admin: vm.announce.admin}"></span>
</div>
</div>
<div class="row black-list">
<div class="col-xs-6 col-sm-4 col-md-3" ng-repeat="b in vm.blackListConfig">
<div class="text-center black-item">
<div>
<h4>{{b.name}}</h4>
<span>{{b.type}}</span>
<i class="fa fa-ban text-danger black-icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
</section>

View File

@@ -275,7 +275,7 @@
},
MY_TORRENT_RULES: {
0: 'This torrent file is uploaded by yourself, you have actions bellow.',
1: 'For additional assistance, please contact our administrator: <strong><a href="mailto:#">{{admin}}</a></strong>'
1: 'For additional assistance, please contact our <strong><a href="mailto:{{admin}}">administrator</a></strong>.'
},
TORRENT_SEED_USERS: 'Seed Users',
TORRENT_LEECHER_USERS: 'Leecher Users',
@@ -464,7 +464,8 @@
ABOUT: {
CLIENT_BLACK_LIST: 'Client Black List',
MAKER_GROUP: 'Torrents Maker Group',
MAKER_GROUP_ADMIN: 'Torrents Maker Group Configure'
MAKER_GROUP_ADMIN: 'Torrents Maker Group Configure',
BLACK_TOOLTIP: '<h4>Note:</h4>All the clients in the list was forbidden by server and can not announce or get any torrent data, For more help, please contact our <strong><a href="mailto:{{admin}}">administrator</a></strong>.'
},
//collections views

View File

@@ -275,7 +275,7 @@
},
MY_TORRENT_RULES: {
0: '这个种子文件是由你自己上传的,你可以对其做如下操作.',
1: '如需其它帮助,请与我们的管理员联系:<strong><a href="mailto:#">{{admin}}</a></strong>.'
1: '如需其它帮助,请与我们的 <strong><a href="mailto:{{admin}}">系统管理员</a></strong> 联系.'
},
TORRENT_SEED_USERS: '做种用户列表',
TORRENT_LEECHER_USERS: '下载用户列表',
@@ -464,7 +464,8 @@
ABOUT: {
CLIENT_BLACK_LIST: '禁止客户端列表',
MAKER_GROUP: '资源压制小组',
MAKER_GROUP_ADMIN: '资源压制小组配置管理'
MAKER_GROUP_ADMIN: '资源压制小组配置管理',
BLACK_TOOLTIP: '<h4>提示:</h4>下面列出的所有客户端都已被服务器禁止,使用它们将不能下载到任何数据, 如需其它帮助,请与我们的 <strong><a href="mailto:{{admin}}">系统管理员</a> </strong>联系.'
},
//collections views