]> source.dussan.org Git - nextcloud-server.git/commitdiff
Properly reload file list on share accept 18222/head
authorJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Wed, 4 Dec 2019 10:18:55 +0000 (11:18 +0100)
committerJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Wed, 4 Dec 2019 10:29:04 +0000 (11:29 +0100)
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
apps/files/js/filelist.js

index d2a23283f12bc7e0274f022ebf715fe2246f833b..c97faaa7041dd72c531c87f4332293c6d5ebfb4d 100644 (file)
 
                        this.$el.on('show', this._onResize);
 
+                       // reload files list on share accept
+                       $('body').on('OCA.Notification.Action', function(eventObject) {
+                               if (eventObject.notification.app === 'files_sharing' && eventObject.action.type === 'POST') {
+                                       self.reload()
+                               }
+                       });
+
                        this.updateSearch();
 
                        this.$fileList.on('click','td.filename>a.name, td.filesize, td.date', _.bind(this._onClickFile, this));