Fix Files not shown when user logged in, if guest user had no permission to view files

This commit is contained in:
Marc Hannappel committed 2016-12-21 09:33:23 +01:00
1 parent a3d4f80599
commit 58ed405c88
1 file changed
+12
@@ -239,6 +239,10 @@ $(function() {
.done(function(response) {
self.fromResponse(response, {focus: self._focus, switchToPath: self._switchToPath});
})
.fail(function() {
self.allItems(undefined);
self.listHelper.updateItems([]);
})
.always(function() {
self._otherRequestInProgress = undefined;
self._focus = undefined;
@@ -759,6 +763,10 @@ $(function() {
if (self.uploadSdButton) {
self.uploadSdButton.fileupload("enable");
}
// After login, request Data,
// if no permission existed to view any files and now exists the file list will be filled
self.requestData();
};
self.onUserLoggedOut = function() {
@@ -766,6 +774,10 @@ $(function() {
if (self.uploadSdButton) {
self.uploadSdButton.fileupload("disable");
}
// After logout, request Data,
// if no permission exists to view any files the files list will be cleared
self.requestData();
};
self.onStartup = function() {