From 5ebdb381f12a8a680ec674f016aa7f0847797fc2 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Tue, 16 Jul 2024 03:12:18 +0200 Subject: [PATCH] [File UI] Persist the path on the URI. --- .../backend/http/webapp/src/components/File/Browser.vue | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/platypush/backend/http/webapp/src/components/File/Browser.vue b/platypush/backend/http/webapp/src/components/File/Browser.vue index dc41e1db39..4e7eabb1ca 100644 --- a/platypush/backend/http/webapp/src/components/File/Browser.vue +++ b/platypush/backend/http/webapp/src/components/File/Browser.vue @@ -134,6 +134,7 @@ export default { try { this.files = await this.request('file.list', {path: this.path}) this.$emit('path-change', this.path) + this.setUrlArgs({path: decodeURIComponent(this.path)}) } finally { this.loading = false } @@ -165,8 +166,16 @@ export default { }, mounted() { + const args = this.getUrlArgs() + if (args.path) + this.path = args.path + this.refresh() }, + + unmounted() { + this.setUrlArgs({path: null}) + }, }