mirror of
https://github.com/syncthing/syncthing.git
synced 2024-11-16 10:28:49 -07:00
This commit is contained in:
parent
fca895a632
commit
8a4b65b937
@ -329,7 +329,7 @@ angular.module('syncthing.core')
|
||||
});
|
||||
|
||||
$scope.$on(Events.FOLDER_ERRORS, function (event, arg) {
|
||||
$scope.model[arg.data.folder].pullErrors = arg.data.errors.length;
|
||||
$scope.model[arg.data.folder].errors = arg.data.errors.length;
|
||||
});
|
||||
|
||||
$scope.$on(Events.FOLDER_SCAN_PROGRESS, function (event, arg) {
|
||||
@ -653,7 +653,7 @@ angular.module('syncthing.core')
|
||||
};
|
||||
|
||||
$scope.refreshFailed = function (page, perpage) {
|
||||
var url = urlbase + '/folder/pullerrors?folder=' + encodeURIComponent($scope.failed.folder);
|
||||
var url = urlbase + '/folder/errors?folder=' + encodeURIComponent($scope.failed.folder);
|
||||
url += "&page=" + page + "&perpage=" + perpage;
|
||||
$http.get(url).success(function (data) {
|
||||
$scope.failed = data;
|
||||
@ -676,7 +676,7 @@ angular.module('syncthing.core')
|
||||
|
||||
$scope.refreshLocalChanged = function (page, perpage) {
|
||||
var url = urlbase + '/db/localchanged?folder=';
|
||||
url += encodeURIComponent($scope.localChanged.folder);
|
||||
url += encodeURIComponent($scope.localChangedFolder);
|
||||
url += "&page=" + page + "&perpage=" + perpage;
|
||||
$http.get(url).success(function (data) {
|
||||
$scope.localChanged = data;
|
||||
@ -2193,7 +2193,7 @@ angular.module('syncthing.core')
|
||||
if (!$scope.model[folder]) {
|
||||
return false;
|
||||
}
|
||||
return $scope.model[folder].pullErrors !== 0;
|
||||
return $scope.model[folder].errors !== 0;
|
||||
};
|
||||
|
||||
$scope.override = function (folder) {
|
||||
@ -2201,7 +2201,7 @@ angular.module('syncthing.core')
|
||||
};
|
||||
|
||||
$scope.showLocalChanged = function (folder) {
|
||||
$scope.localChanged.folder = folder;
|
||||
$scope.localChangedFolder = folder;
|
||||
$scope.localChanged = $scope.refreshLocalChanged(1, 10);
|
||||
$('#localChanged').modal().one('hidden.bs.modal', function () {
|
||||
$scope.localChanged = {};
|
||||
|
@ -12,7 +12,7 @@
|
||||
</table>
|
||||
<dir-pagination-controls on-page-change="refreshFailed(newPageNumber, failed.perpage)" pagination-id="failed"></dir-pagination-controls>
|
||||
<ul class="pagination pull-right">
|
||||
<li ng-repeat="option in [10, 25, 50]" ng-class="{ active: failed.page == option }">
|
||||
<li ng-repeat="option in [10, 25, 50]" ng-class="{ active: failed.perpage == option }">
|
||||
<a href="#" ng-click="refreshFailed(failed.page, option)">{{option}}</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
@ -10,14 +10,14 @@
|
||||
<th translate>Size</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr dir-paginate="file in localChanged.files | itemsPerPage: localChanged.perpage" current-page="localChanged.page" total-items="model[localChanged.folder].receiveOnlyTotalItems" pagination-id="localChanged">
|
||||
<tr dir-paginate="file in localChanged.files | itemsPerPage: localChanged.perpage" current-page="localChanged.page" total-items="model[localChangedFolder].receiveOnlyTotalItems" pagination-id="localChanged">
|
||||
<td>{{file.name}}</td>
|
||||
<td><span ng-hide="file.type == 'DIRECTORY'">{{file.size | binary}}B</span></td>
|
||||
</tr>
|
||||
</table>
|
||||
<dir-pagination-controls on-page-change="refreshLocalChanged(newPageNumber, localChanged.perpage)" pagination-id="localChanged"></dir-pagination-controls>
|
||||
<ul class="pagination pull-right">
|
||||
<li ng-repeat="option in [10, 25, 50]" ng-class="{ active: localChanged.page == option }">
|
||||
<li ng-repeat="option in [10, 25, 50]" ng-class="{ active: localChanged.perpage == option }">
|
||||
<a href="#" ng-click="refreshLocalChanged(localChanged.page, option)">{{option}}</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
Loading…
Reference in New Issue
Block a user