modify text

This commit is contained in:
MaysWind 2018-11-11 20:53:56 +08:00
parent e42884a50f
commit 65df41f3fd
10 changed files with 57 additions and 57 deletions

View file

@ -15,7 +15,7 @@ Global=全局
New=新建 New=新建
Start=开始任务 Start=开始任务
Pause=暂停任务 Pause=暂停任务
Restart=重试 Retry=重试
Delete=删除任务 Delete=删除任务
Select All=全部选中 Select All=全部选中
Select None=全部不选 Select None=全部不选
@ -112,9 +112,9 @@ Speed=速度
No Data=无数据 No Data=无数据
No connected peers=没有连接到其他节点 No connected peers=没有连接到其他节点
Failed to change some tasks state.=修改一些任务状态时失败. Failed to change some tasks state.=修改一些任务状态时失败.
Confirm Restart=确认重试 Confirm Retry=确认重试
Are you sure you want to restart this task? AriaNg will create a same task after clicking OK.=您是否要重试这个任务? 点击 "确定" 后, AriaNg 将会创建一个相同的任务. Are you sure you want to retry this task? AriaNg will create a same task after clicking OK.=您是否要重试这个任务? 点击 "确定" 后, AriaNg 将会创建一个相同的任务.
Failed to restart this task.=该任务重试失败. Failed to retry this task.=该任务重试失败.
Confirm Remove=确认删除 Confirm Remove=确认删除
Are you sure you want to remove the selected task?=您是否要删除选中的任务? Are you sure you want to remove the selected task?=您是否要删除选中的任务?
Failed to remove some task(s).=删除一些任务时失败. Failed to remove some task(s).=删除一些任务时失败.
@ -158,10 +158,10 @@ Are you sure you want to remove rpc setting "{{rpcName}}"?=您是否要删除 RP
Global Stat Refresh Interval=全局状态刷新间隔 Global Stat Refresh Interval=全局状态刷新间隔
Download Task Refresh Interval=下载任务刷新间隔 Download Task Refresh Interval=下载任务刷新间隔
Action After Creating New Tasks=创建新任务后执行操作 Action After Creating New Tasks=创建新任务后执行操作
Removing Old Task After Restarting=重试任务后删除原任务 Removing Old Task After Retrying=重试任务后删除原任务
Navigate to Task List Page=转到任务列表页面 Navigate to Task List Page=转到任务列表页面
Navigate to Task Detail Page=转到任务详情页面 Navigate to Task Detail Page=转到任务详情页面
Action After Restarting Task=重试任务后执行操作 Action After Retrying Task=重试任务后执行操作
Navigate to Downloading Task List Page=转到正在下载任务列表页面 Navigate to Downloading Task List Page=转到正在下载任务列表页面
Stay on Current Page=留在当前页面 Stay on Current Page=留在当前页面
RPC List Display Order=RPC 列表显示顺序 RPC List Display Order=RPC 列表显示顺序

View file

@ -15,7 +15,7 @@ Global=全域
New=新增 New=新增
Start=開始工作 Start=開始工作
Pause=暫停工作 Pause=暫停工作
Restart=重試 Retry=重試
Delete=刪除工作 Delete=刪除工作
Select All=全部選中 Select All=全部選中
Select None=全部不選 Select None=全部不選
@ -112,9 +112,9 @@ Speed=速度
No Data=無資料 No Data=無資料
No connected peers=沒有連線到其他節點 No connected peers=沒有連線到其他節點
Failed to change some tasks state.=修改一些工作狀態時失敗. Failed to change some tasks state.=修改一些工作狀態時失敗.
Confirm Restart=確認重試 Confirm Retry=確認重試
Are you sure you want to restart this task? AriaNg will create a same task after clicking OK.=您是否要重試這個工作? 點選 "確定" 後, AriaNg 將會建立一個相同的工作. Are you sure you want to retry this task? AriaNg will create a same task after clicking OK.=您是否要重試這個工作? 點選 "確定" 後, AriaNg 將會建立一個相同的工作.
Failed to restart this task.=該工作重試失敗. Failed to retry this task.=該工作重試失敗.
Confirm Remove=確認刪除 Confirm Remove=確認刪除
Are you sure you want to remove the selected task?=您是否要刪除選中的工作? Are you sure you want to remove the selected task?=您是否要刪除選中的工作?
Failed to remove some task(s).=刪除一些工作時失敗. Failed to remove some task(s).=刪除一些工作時失敗.
@ -158,10 +158,10 @@ Are you sure you want to remove rpc setting "{{rpcName}}"?=您是否要刪除 RP
Global Stat Refresh Interval=全域狀態重新整理間隔 Global Stat Refresh Interval=全域狀態重新整理間隔
Download Task Refresh Interval=下載工作重新整理間隔 Download Task Refresh Interval=下載工作重新整理間隔
Action After Creating New Tasks=建立新工作後執行操作 Action After Creating New Tasks=建立新工作後執行操作
Removing Old Task After Restarting=重試工作後刪除原工作 Removing Old Task After Retrying=重試工作後刪除原工作
Navigate to Task List Page=轉到工作清單頁面 Navigate to Task List Page=轉到工作清單頁面
Navigate to Task Detail Page=轉到工作詳情頁面 Navigate to Task Detail Page=轉到工作詳情頁面
Action After Restarting Task=重試工作後執行操作 Action After Retrying Task=重試工作後執行操作
Navigate to Downloading Task List Page=轉到正在下載工作清單頁面 Navigate to Downloading Task List Page=轉到正在下載工作清單頁面
Stay on Current Page=留在目前頁面 Stay on Current Page=留在目前頁面
RPC List Display Order=RPC 清單顯示順序 RPC List Display Order=RPC 清單顯示順序

View file

@ -37,8 +37,8 @@
downloadTaskRefreshInterval: 1000, downloadTaskRefreshInterval: 1000,
rpcListDisplayOrder: 'recentlyUsed', rpcListDisplayOrder: 'recentlyUsed',
afterCreatingNewTask: 'task-list', afterCreatingNewTask: 'task-list',
removeOldTaskAfterRestarting: false, removeOldTaskAfterRetrying: false,
afterRestartingTask: 'task-list-downloading', afterRetryingTask: 'task-list-downloading',
displayOrder: 'default:asc', displayOrder: 'default:asc',
fileListDisplayOrder: 'default:asc', fileListDisplayOrder: 'default:asc',
peerListDisplayOrder: 'default:asc' peerListDisplayOrder: 'default:asc'

View file

@ -19,7 +19,7 @@
'New': 'New', 'New': 'New',
'Start': 'Start', 'Start': 'Start',
'Pause': 'Pause', 'Pause': 'Pause',
'Restart': 'Restart', 'Retry': 'Retry',
'Delete': 'Delete', 'Delete': 'Delete',
'Select All': 'Select All', 'Select All': 'Select All',
'Select None': 'Select None', 'Select None': 'Select None',
@ -116,9 +116,9 @@
'No Data': 'No Data', 'No Data': 'No Data',
'No connected peers': 'No connected peers', 'No connected peers': 'No connected peers',
'Failed to change some tasks state.': 'Failed to change some tasks state.', 'Failed to change some tasks state.': 'Failed to change some tasks state.',
'Confirm Restart': 'Confirm Restart', 'Confirm Retry': 'Confirm Retry',
'Are you sure you want to restart this task? AriaNg will create a same task after clicking OK.': 'Are you sure you want to restart this task? AriaNg will create a same task after clicking OK.', 'Are you sure you want to retry this task? AriaNg will create a same task after clicking OK.': 'Are you sure you want to retry this task? AriaNg will create a same task after clicking OK.',
'Failed to restart this task.': 'Failed to restart this task.', 'Failed to retry this task.': 'Failed to retry this task.',
'Confirm Remove': 'Confirm Remove', 'Confirm Remove': 'Confirm Remove',
'Are you sure you want to remove the selected task?': 'Are you sure you want to remove the selected task?', 'Are you sure you want to remove the selected task?': 'Are you sure you want to remove the selected task?',
'Failed to remove some task(s).': 'Failed to remove some task(s).', 'Failed to remove some task(s).': 'Failed to remove some task(s).',
@ -162,10 +162,10 @@
'Global Stat Refresh Interval': 'Global Stat Refresh Interval', 'Global Stat Refresh Interval': 'Global Stat Refresh Interval',
'Download Task Refresh Interval': 'Download Task Refresh Interval', 'Download Task Refresh Interval': 'Download Task Refresh Interval',
'Action After Creating New Tasks': 'Action After Creating New Tasks', 'Action After Creating New Tasks': 'Action After Creating New Tasks',
'Removing Old Task After Restarting': 'Removing Old Task After Restarting', 'Removing Old Task After Retrying': 'Removing Old Task After Retrying',
'Navigate to Task List Page': 'Navigate to Task List Page', 'Navigate to Task List Page': 'Navigate to Task List Page',
'Navigate to Task Detail Page': 'Navigate to Task Detail Page', 'Navigate to Task Detail Page': 'Navigate to Task Detail Page',
'Action After Restarting Task': 'Action After Restarting Task', 'Action After Retrying Task': 'Action After Retrying Task',
'Navigate to Downloading Task List Page': 'Navigate to Downloading Task List Page', 'Navigate to Downloading Task List Page': 'Navigate to Downloading Task List Page',
'Stay on Current Page': 'Stay on Current Page', 'Stay on Current Page': 'Stay on Current Page',
'RPC List Display Order': 'RPC List Display Order', 'RPC List Display Order': 'RPC List Display Order',

View file

@ -138,26 +138,26 @@
}, (gids.length > 1)); }, (gids.length > 1));
}; };
$scope.restart = function (task) { $scope.retryTask = function (task) {
ariaNgLocalizationService.confirm('Confirm Restart', 'Are you sure you want to restart this task? AriaNg will create a same task after clicking OK.', 'info', function () { ariaNgLocalizationService.confirm('Confirm Retry', 'Are you sure you want to retry this task? AriaNg will create a same task after clicking OK.', 'info', function () {
$rootScope.loadPromise = aria2TaskService.restartTask(task.gid, function (response) { $rootScope.loadPromise = aria2TaskService.retryTask(task.gid, function (response) {
if (!response.success) { if (!response.success) {
ariaNgLocalizationService.showError('Failed to restart this task.'); ariaNgLocalizationService.showError('Failed to retry this task.');
return; return;
} }
refreshGlobalStat(true); refreshGlobalStat(true);
var actionAfterRestartingTask = ariaNgSettingService.getAfterRestartingTask(); var actionAfterRetryingTask = ariaNgSettingService.getAfterRetryingTask();
if (response.success && response.data) { if (response.success && response.data) {
if (actionAfterRestartingTask === 'task-list-downloading') { if (actionAfterRetryingTask === 'task-list-downloading') {
if ($location.path() !== '/downloading') { if ($location.path() !== '/downloading') {
$location.path('/downloading'); $location.path('/downloading');
} else { } else {
$route.reload(); $route.reload();
} }
} else if (actionAfterRestartingTask === 'task-detail') { } else if (actionAfterRetryingTask === 'task-detail') {
$location.path('/task/detail/' + response.data); $location.path('/task/detail/' + response.data);
} else { } else {
$route.reload(); $route.reload();

View file

@ -169,12 +169,12 @@
ariaNgSettingService.setAfterCreatingNewTask(value); ariaNgSettingService.setAfterCreatingNewTask(value);
}; };
$scope.setRemoveOldTaskAfterRestarting = function (value) { $scope.setRemoveOldTaskAfterRetrying = function (value) {
ariaNgSettingService.setRemoveOldTaskAfterRestarting(value); ariaNgSettingService.setRemoveOldTaskAfterRetrying(value);
}; };
$scope.setAfterRestartingTask = function (value) { $scope.setAfterRetryingTask = function (value) {
ariaNgSettingService.setAfterRestartingTask(value); ariaNgSettingService.setAfterRetryingTask(value);
}; };
$scope.showImportSettingsModal = function () { $scope.showImportSettingsModal = function () {

View file

@ -614,7 +614,7 @@
callback: callback callback: callback
}); });
}, },
restartTask: function (gid, callback, silent) { retryTask: function (gid, callback, silent) {
var deferred = $q.defer(); var deferred = $q.defer();
var methods = [ var methods = [
@ -629,12 +629,12 @@
silent: !!silent, silent: !!silent,
callback: function (response) { callback: function (response) {
if (!callback) { if (!callback) {
ariaNgLogService.warn('[aria2TaskService.restartTask] callback is null'); ariaNgLogService.warn('[aria2TaskService.retryTask] callback is null');
return; return;
} }
if (!response.success) { if (!response.success) {
ariaNgLogService.warn('[aria2TaskService.restartTask] response is not success', response); ariaNgLogService.warn('[aria2TaskService.retryTask] response is not success', response);
deferred.reject(response); deferred.reject(response);
callback(response); callback(response);
return; return;
@ -650,23 +650,23 @@
if (!task || !options || !task.files || task.files.length !== 1 || task.bittorrent) { if (!task || !options || !task.files || task.files.length !== 1 || task.bittorrent) {
if (!task) { if (!task) {
ariaNgLogService.warn('[aria2TaskService.restartTask] task is null'); ariaNgLogService.warn('[aria2TaskService.retryTask] task is null');
} }
if (!options) { if (!options) {
ariaNgLogService.warn('[aria2TaskService.restartTask] options is null'); ariaNgLogService.warn('[aria2TaskService.retryTask] options is null');
} }
if (!task.files) { if (!task.files) {
ariaNgLogService.warn('[aria2TaskService.restartTask] task file is null'); ariaNgLogService.warn('[aria2TaskService.retryTask] task file is null');
} }
if (task.files.length !== 1) { if (task.files.length !== 1) {
ariaNgLogService.warn('[aria2TaskService.restartTask] task file length is not equal 1'); ariaNgLogService.warn('[aria2TaskService.retryTask] task file length is not equal 1');
} }
if (task.bittorrent) { if (task.bittorrent) {
ariaNgLogService.warn('[aria2TaskService.restartTask] task is bittorrent'); ariaNgLogService.warn('[aria2TaskService.retryTask] task is bittorrent');
} }
deferred.reject(gid); deferred.reject(gid);
@ -693,19 +693,19 @@
silent: !!silent, silent: !!silent,
callback: function (response) { callback: function (response) {
if (!response.success) { if (!response.success) {
ariaNgLogService.warn('[aria2TaskService.restartTask] addUri response is not success', response); ariaNgLogService.warn('[aria2TaskService.retryTask] addUri response is not success', response);
deferred.reject(response); deferred.reject(response);
callback(response); callback(response);
return; return;
} }
if (ariaNgSettingService.getRemoveOldTaskAfterRestarting()) { if (ariaNgSettingService.getRemoveOldTaskAfterRetrying()) {
aria2RpcService.removeDownloadResult({ aria2RpcService.removeDownloadResult({
gid: gid, gid: gid,
silent: true, silent: true,
callback: function (response) { callback: function (response) {
if (!response.success) { if (!response.success) {
ariaNgLogService.warn('[aria2TaskService.restartTask] removeDownloadResult response is not success', response); ariaNgLogService.warn('[aria2TaskService.retryTask] removeDownloadResult response is not success', response);
} }
} }
}); });

View file

@ -360,17 +360,17 @@
setAfterCreatingNewTask: function (value) { setAfterCreatingNewTask: function (value) {
setOption('afterCreatingNewTask', value); setOption('afterCreatingNewTask', value);
}, },
getRemoveOldTaskAfterRestarting: function () { getRemoveOldTaskAfterRetrying: function () {
return getOption('removeOldTaskAfterRestarting'); return getOption('removeOldTaskAfterRetrying');
}, },
setRemoveOldTaskAfterRestarting: function (value) { setRemoveOldTaskAfterRetrying: function (value) {
setOption('removeOldTaskAfterRestarting', value); setOption('removeOldTaskAfterRetrying', value);
}, },
getAfterRestartingTask: function () { getAfterRetryingTask: function () {
return getOption('afterRestartingTask'); return getOption('afterRetryingTask');
}, },
setAfterRestartingTask: function (value) { setAfterRetryingTask: function (value) {
setOption('afterRestartingTask', value); setOption('afterRetryingTask', value);
}, },
getCurrentRpcDisplayName: function () { getCurrentRpcDisplayName: function () {
var options = getOptions(); var options = getOptions();

View file

@ -48,7 +48,7 @@
<a ng-href="#!/task/detail/{{task.gid}}" title="{{'Click to view task detail' | translate}}"> <a ng-href="#!/task/detail/{{task.gid}}" title="{{'Click to view task detail' | translate}}">
<span ng-if="task.files" ng-bind="('format.settings.file-count' | translate: {count: task.selectedFileCount})"></span> <span ng-if="task.files" ng-bind="('format.settings.file-count' | translate: {count: task.selectedFileCount})"></span>
</a><i class="icon-error fa fa-times" ng-if="task && task.status === 'error' && task.errorDescription" title="{{task.errorDescription | translate}}"></i><i class="icon-seeder fa fa-arrow-up" ng-if="task && task.status === 'active' && task.seeder" title="{{'Seeding' | translate}}"></i> </a><i class="icon-error fa fa-times" ng-if="task && task.status === 'error' && task.errorDescription" title="{{task.errorDescription | translate}}"></i><i class="icon-seeder fa fa-arrow-up" ng-if="task && task.status === 'active' && task.seeder" title="{{'Seeding' | translate}}"></i>
<a ng-if="task && task.status === 'error' && task.errorDescription && !task.bittorrent" ng-click="restart(task)" title="{{'Restart' | translate}}" translate>Restart</a> <a ng-if="task && task.status === 'error' && task.errorDescription && !task.bittorrent" ng-click="retryTask(task)" title="{{'Retry' | translate}}" translate>Retry</a>
</div> </div>
</div> </div>
<div class="col-md-2 col-sm-3 col-xs-12"> <div class="col-md-2 col-sm-3 col-xs-12">

View file

@ -142,22 +142,22 @@
</div> </div>
<div class="row"> <div class="row">
<div class="setting-key setting-key-without-desc col-sm-4"> <div class="setting-key setting-key-without-desc col-sm-4">
<span translate>Removing Old Task After Restarting</span> <span translate>Removing Old Task After Retrying</span>
</div> </div>
<div class="setting-value col-sm-8"> <div class="setting-value col-sm-8">
<select class="form-control" style="width: 100%;" ng-model="context.settings.removeOldTaskAfterRestarting" <select class="form-control" style="width: 100%;" ng-model="context.settings.removeOldTaskAfterRetrying"
ng-change="setRemoveOldTaskAfterRestarting(context.settings.removeOldTaskAfterRestarting)" ng-change="setRemoveOldTaskAfterRetrying(context.settings.removeOldTaskAfterRetrying)"
ng-options="option.value as (option.name | translate) for option in context.trueFalseOptions"> ng-options="option.value as (option.name | translate) for option in context.trueFalseOptions">
</select> </select>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="setting-key setting-key-without-desc col-sm-4"> <div class="setting-key setting-key-without-desc col-sm-4">
<span translate>Action After Restarting Task</span> <span translate>Action After Retrying Task</span>
</div> </div>
<div class="setting-value col-sm-8"> <div class="setting-value col-sm-8">
<select class="form-control" style="width: 100%;" ng-model="context.settings.afterRestartingTask" <select class="form-control" style="width: 100%;" ng-model="context.settings.afterRetryingTask"
ng-change="setAfterRestartingTask(context.settings.afterRestartingTask)"> ng-change="setAfterRetryingTask(context.settings.afterRetryingTask)">
<option value="task-list-downloading" translate>Navigate to Downloading Task List Page</option> <option value="task-list-downloading" translate>Navigate to Downloading Task List Page</option>
<option value="task-detail" translate>Navigate to Task Detail Page</option> <option value="task-detail" translate>Navigate to Task Detail Page</option>
<option value="stay-on-current" translate>Stay on Current Page</option> <option value="stay-on-current" translate>Stay on Current Page</option>