mirror of https://github.com/portainer/portainer
fix(templates): fix an issue with the maximum number of templates displayed (#883)
parent
3356fd9815
commit
0f3fcb2917
|
@ -250,7 +250,7 @@
|
|||
<rd-widget-body classes="padding template-widget-body">
|
||||
<div class="template-list">
|
||||
<!-- template -->
|
||||
<div dir-paginate="tpl in templates | filter:state.filters:true | itemsPerPage: state.pagination_count" class="template-container" id="template_{{ tpl.index }}" ng-click="selectTemplate(tpl.index, $index)">
|
||||
<div ng-repeat="tpl in templates | filter:state.filters:true" class="template-container" id="template_{{ tpl.index }}" ng-click="selectTemplate(tpl.index, $index)">
|
||||
<div class="template-main">
|
||||
<!-- template-image -->
|
||||
<span class="">
|
||||
|
@ -289,7 +289,7 @@
|
|||
<div ng-if="!templates" class="text-center text-muted">
|
||||
Loading...
|
||||
</div>
|
||||
<div ng-if="(templates | filter:state.filters:true | itemsPerPage: state.pagination_count).length == 0" class="text-center text-muted">
|
||||
<div ng-if="(templates | filter:state.filters:true).length == 0" class="text-center text-muted">
|
||||
No templates available.
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -5,7 +5,6 @@ function ($scope, $q, $state, $stateParams, $anchorScroll, $filter, Config, Cont
|
|||
selectedTemplate: null,
|
||||
showAdvancedOptions: false,
|
||||
hideDescriptions: $stateParams.hide_descriptions,
|
||||
pagination_count: Pagination.getPaginationCount('templates'),
|
||||
formValidationError: '',
|
||||
filters: {
|
||||
Categories: '!',
|
||||
|
@ -18,10 +17,6 @@ function ($scope, $q, $state, $stateParams, $anchorScroll, $filter, Config, Cont
|
|||
name: ''
|
||||
};
|
||||
|
||||
$scope.changePaginationCount = function() {
|
||||
Pagination.setPaginationCount('templates', $scope.state.pagination_count);
|
||||
};
|
||||
|
||||
$scope.addVolume = function () {
|
||||
$scope.state.selectedTemplate.Volumes.push({ containerPath: '', name: '', readOnly: false, type: 'auto' });
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue