From 841c1db54aae0358b723580c51b4c3b478031183 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=8Carodej?= Date: Fri, 22 Oct 2021 16:39:53 +0200 Subject: [PATCH] implemented navigation tree controller for teams --- public/mix-manifest.json | 37 ++++++++++++++++++- .../components/FilesView/DesktopToolbar.vue | 7 ++-- .../js/components/Others/MoveItemPopup.vue | 14 +++++-- resources/js/components/Others/TreeMenu.vue | 7 +++- resources/js/store/modules/teams.js | 17 +++++++++ routes/api.php | 4 +- routes/teams.php | 3 ++ ...oller.php => NavigationTreeController.php} | 21 ++++++++++- .../Controllers/NavigationTreeController.php | 30 +++++++++++++++ .../Controllers/TeamFoldersController.php | 1 + 10 files changed, 128 insertions(+), 13 deletions(-) rename src/Domain/Folders/Controllers/{NavigationFolderTreeController.php => NavigationTreeController.php} (60%) create mode 100644 src/Domain/Teams/Controllers/NavigationTreeController.php diff --git a/public/mix-manifest.json b/public/mix-manifest.json index 825b5610..f782fd0b 100644 --- a/public/mix-manifest.json +++ b/public/mix-manifest.json @@ -59,7 +59,7 @@ "/chunks/plan-subscribers.js": "/chunks/plan-subscribers.js?id=2bdbb5f9141052aaaa3d", "/chunks/plans.js": "/chunks/plans.js?id=a3a16f546521050656fb", "/chunks/platform.js": "/chunks/platform.js?id=07fd139d62a2c60f9468", - "/chunks/platform~chunks/shared.js": "/chunks/platform~chunks/shared.js?id=6da8a930d3ab447dc666", + "/chunks/platform~chunks/shared.js": "/chunks/platform~chunks/shared.js?id=44a689222ea574701715", "/chunks/profile.js": "/chunks/profile.js?id=91ea55260c78ea4e7abd", "/chunks/profile~chunks/settings-password.js": "/chunks/profile~chunks/settings-password.js?id=7b80324eef831d31e3e8", "/chunks/purchase-code.js": "/chunks/purchase-code.js?id=26a3951e09a8862d8dc2", @@ -198,5 +198,38 @@ "/chunks/platform~chunks/shared.cdc982ee462905db2739.hot-update.js": "/chunks/platform~chunks/shared.cdc982ee462905db2739.hot-update.js", "/chunks/platform~chunks/shared.da8714bce7630fc753ba.hot-update.js": "/chunks/platform~chunks/shared.da8714bce7630fc753ba.hot-update.js", "/chunks/platform~chunks/shared.1c7a870b7ada9ad6da18.hot-update.js": "/chunks/platform~chunks/shared.1c7a870b7ada9ad6da18.hot-update.js", - "/chunks/platform~chunks/shared.d6227f7e312ed10fe374.hot-update.js": "/chunks/platform~chunks/shared.d6227f7e312ed10fe374.hot-update.js" + "/chunks/platform~chunks/shared.d6227f7e312ed10fe374.hot-update.js": "/chunks/platform~chunks/shared.d6227f7e312ed10fe374.hot-update.js", + "/chunks/platform.d76ce1c94ec21411e3e6.hot-update.js": "/chunks/platform.d76ce1c94ec21411e3e6.hot-update.js", + "/chunks/platform.91fc2762aeecb9b68055.hot-update.js": "/chunks/platform.91fc2762aeecb9b68055.hot-update.js", + "/chunks/platform~chunks/shared.4ac66e7a23a467dc88d3.hot-update.js": "/chunks/platform~chunks/shared.4ac66e7a23a467dc88d3.hot-update.js", + "/chunks/platform~chunks/shared.8e6d0b4d2084e1081678.hot-update.js": "/chunks/platform~chunks/shared.8e6d0b4d2084e1081678.hot-update.js", + "/chunks/platform~chunks/shared.592d5ab0074b0358355f.hot-update.js": "/chunks/platform~chunks/shared.592d5ab0074b0358355f.hot-update.js", + "/chunks/platform~chunks/shared.16e1adde9f15b40755fc.hot-update.js": "/chunks/platform~chunks/shared.16e1adde9f15b40755fc.hot-update.js", + "/chunks/platform~chunks/shared.83cd81f856a97950cd20.hot-update.js": "/chunks/platform~chunks/shared.83cd81f856a97950cd20.hot-update.js", + "/chunks/platform~chunks/shared.bd5ac3e5e82ebb14bd8d.hot-update.js": "/chunks/platform~chunks/shared.bd5ac3e5e82ebb14bd8d.hot-update.js", + "/chunks/platform~chunks/shared.401339f30a50f43890ad.hot-update.js": "/chunks/platform~chunks/shared.401339f30a50f43890ad.hot-update.js", + "/chunks/platform~chunks/shared.d125f53113f9ae1cf449.hot-update.js": "/chunks/platform~chunks/shared.d125f53113f9ae1cf449.hot-update.js", + "/chunks/platform~chunks/shared.c9fd0f35248a989da1f3.hot-update.js": "/chunks/platform~chunks/shared.c9fd0f35248a989da1f3.hot-update.js", + "/chunks/platform~chunks/shared.3874f1076e2ce25f9a34.hot-update.js": "/chunks/platform~chunks/shared.3874f1076e2ce25f9a34.hot-update.js", + "/chunks/platform~chunks/shared.11630bdf1f3e8a41b885.hot-update.js": "/chunks/platform~chunks/shared.11630bdf1f3e8a41b885.hot-update.js", + "/chunks/platform~chunks/shared.36c3b3e5853ddad4efdd.hot-update.js": "/chunks/platform~chunks/shared.36c3b3e5853ddad4efdd.hot-update.js", + "/chunks/platform~chunks/shared.5b22eff6be7933d5ad4d.hot-update.js": "/chunks/platform~chunks/shared.5b22eff6be7933d5ad4d.hot-update.js", + "/chunks/platform~chunks/shared.5886c4145d57d18b6bce.hot-update.js": "/chunks/platform~chunks/shared.5886c4145d57d18b6bce.hot-update.js", + "/chunks/platform~chunks/shared.e328d6e7026762be3536.hot-update.js": "/chunks/platform~chunks/shared.e328d6e7026762be3536.hot-update.js", + "/js/main.0fd1cc76418860ea6d95.hot-update.js": "/js/main.0fd1cc76418860ea6d95.hot-update.js", + "/js/main.62c1aa41835e5aa8ed25.hot-update.js": "/js/main.62c1aa41835e5aa8ed25.hot-update.js", + "/chunks/platform~chunks/shared.07610295586367a72907.hot-update.js": "/chunks/platform~chunks/shared.07610295586367a72907.hot-update.js", + "/js/main.47277a10039daa292fb9.hot-update.js": "/js/main.47277a10039daa292fb9.hot-update.js", + "/chunks/platform~chunks/shared.4cb51eb3494e8026b18c.hot-update.js": "/chunks/platform~chunks/shared.4cb51eb3494e8026b18c.hot-update.js", + "/chunks/platform~chunks/shared.f1aef11bbf61f935d579.hot-update.js": "/chunks/platform~chunks/shared.f1aef11bbf61f935d579.hot-update.js", + "/js/main.8b25c07409f90dc91691.hot-update.js": "/js/main.8b25c07409f90dc91691.hot-update.js", + "/js/main.6f1239c8df352f98bd78.hot-update.js": "/js/main.6f1239c8df352f98bd78.hot-update.js", + "/js/main.8f75c4926ecb464119ac.hot-update.js": "/js/main.8f75c4926ecb464119ac.hot-update.js", + "/js/main.8b2c7464f9b10f0a4585.hot-update.js": "/js/main.8b2c7464f9b10f0a4585.hot-update.js", + "/chunks/platform~chunks/shared.8b2c7464f9b10f0a4585.hot-update.js": "/chunks/platform~chunks/shared.8b2c7464f9b10f0a4585.hot-update.js", + "/chunks/platform~chunks/shared.0017758920e11a4f3479.hot-update.js": "/chunks/platform~chunks/shared.0017758920e11a4f3479.hot-update.js", + "/chunks/platform~chunks/shared.723db492301d9eea60ed.hot-update.js": "/chunks/platform~chunks/shared.723db492301d9eea60ed.hot-update.js", + "/chunks/platform~chunks/shared.610c925fd4905d8d4ee1.hot-update.js": "/chunks/platform~chunks/shared.610c925fd4905d8d4ee1.hot-update.js", + "/chunks/platform~chunks/shared.f61746f6ddbacb5e3b41.hot-update.js": "/chunks/platform~chunks/shared.f61746f6ddbacb5e3b41.hot-update.js", + "/chunks/platform~chunks/shared.b6b69d2e4330deb163ec.hot-update.js": "/chunks/platform~chunks/shared.b6b69d2e4330deb163ec.hot-update.js" } diff --git a/resources/js/components/FilesView/DesktopToolbar.vue b/resources/js/components/FilesView/DesktopToolbar.vue index be50343e..463025b5 100644 --- a/resources/js/components/FilesView/DesktopToolbar.vue +++ b/resources/js/components/FilesView/DesktopToolbar.vue @@ -69,13 +69,13 @@ - + - - + + @@ -193,6 +193,7 @@ }, canMoveInView() { let routes = [ + 'SharedWithMe', 'RecentUploads', 'MySharedItems', 'Public', diff --git a/resources/js/components/Others/MoveItemPopup.vue b/resources/js/components/Others/MoveItemPopup.vue index 858bc17e..6c760ba5 100644 --- a/resources/js/components/Others/MoveItemPopup.vue +++ b/resources/js/components/Others/MoveItemPopup.vue @@ -130,9 +130,17 @@ this.isLoadingTree = true // Get folder tree and hide spinner - this.$store.dispatch('getFolderTree').then(() => { - this.isLoadingTree = false - }) + if (this.$isThisRoute(this.$route, ['SharedWithMe'])) { + + this.$store.dispatch('getTeamFolderTree').then(() => { + this.isLoadingTree = false + }) + } else { + + this.$store.dispatch('getFolderTree').then(() => { + this.isLoadingTree = false + }) + } // Store picked item if (!this.clipboard.includes(args.item[0])) { diff --git a/resources/js/components/Others/TreeMenu.vue b/resources/js/components/Others/TreeMenu.vue index ea324272..360d6486 100644 --- a/resources/js/components/Others/TreeMenu.vue +++ b/resources/js/components/Others/TreeMenu.vue @@ -2,10 +2,12 @@
-
+
+ + {{ nodes.name }}
@@ -16,7 +18,7 @@