diff --git a/js/controller/CardController.js b/js/controller/CardController.js index 29ce7e9fe..e7904054d 100644 --- a/js/controller/CardController.js +++ b/js/controller/CardController.js @@ -43,6 +43,7 @@ app.controller('CardController', function ($scope, $rootScope, $sce, $location, return $state.params; }, function (params) { $scope.params = params; + $scope.fileservice.reset(); }, true); $scope.params = $state.params; diff --git a/js/service/FileService.js b/js/service/FileService.js index 8248debd0..d35dcb15f 100644 --- a/js/service/FileService.js +++ b/js/service/FileService.js @@ -1,5 +1,5 @@ /* - * @copyright Copyright (c) 2018 Julius Härtl +* @copyright Copyright (c) 2018 Julius Härtl * * @author Julius Härtl * @@ -37,6 +37,10 @@ export default class FileService { this.status = null; } + reset () { + this.status = null; + } + runUpload (fileItem, attachmentId) { this.status = null; fileItem.url = OC.generateUrl('/apps/deck/cards/' + fileItem.cardId + '/attachment?type=deck_file'); @@ -117,4 +121,4 @@ export default class FileService { } -app.service('FileService', FileService); \ No newline at end of file +app.service('FileService', FileService);