mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-25 16:55:59 +03:00
[PR #4368] [MERGED] feat: extend duplicate collection to personal workspace in SH #4772
Labels
No labels
CodeDay
a11y
browser limited
bug
bug fix
cli
core
critical
design
desktop
discussion
docker
documentation
duplicate
enterprise
feature
feature
fosshack
future
good first issue
hacktoberfest
help wanted
i18n
invalid
major
minor
need information
need testing
not applicable to hoppscotch
not reproducible
pull-request
question
refactor
resolved
sandbox
self-host
spam
stale
testmu
wip
wont fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hoppscotch#4772
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/hoppscotch/hoppscotch/pull/4368
Author: @jamesgeorge007
Created: 9/20/2024
Status: ✅ Merged
Merged: 9/30/2024
Merged by: @jamesgeorge007
Base:
next← Head:feat/extend-duplicate-collection-sh📝 Commits (2)
2a01a87feat: extend duplicate collection to personal workspace in SHa42d886chore: sync collection platform definitions tosh-desktop📊 Changes
12 files changed (+604 additions, -275 deletions)
View changed files
📝
packages/hoppscotch-common/src/components/collections/Collection.vue(+1 -21)📝
packages/hoppscotch-common/src/components/collections/graphql/Collection.vue(+1 -17)📝
packages/hoppscotch-common/src/components/collections/graphql/Folder.vue(+1 -17)📝
packages/hoppscotch-common/src/platform/index.ts(+0 -6)📝
packages/hoppscotch-selfhost-desktop/src/api/subscriptions/UserCollectionCreated.graphql(+1 -0)➕
packages/hoppscotch-selfhost-desktop/src/api/subscriptions/UserCollectionDuplicated.graphql(+15 -0)📝
packages/hoppscotch-selfhost-desktop/src/platform/collections/collections.api.ts(+49 -42)📝
packages/hoppscotch-selfhost-desktop/src/platform/collections/collections.platform.ts(+298 -38)➕
packages/hoppscotch-selfhost-web/src/api/subscriptions/userCollectionDuplicated.graphql(+15 -0)📝
packages/hoppscotch-selfhost-web/src/main.ts(+0 -1)📝
packages/hoppscotch-selfhost-web/src/platform/collections/collections.api.ts(+7 -0)📝
packages/hoppscotch-selfhost-web/src/platform/collections/collections.platform.ts(+216 -133)📄 Description
This PR extends the ability to duplicate REST/GQL collection under personal workspace in SH as a follow-up of #4211. The BE requirement regarding the addition of a dedicated GQL subscription for duplication action is added in #4358.
Closes HFE-596.
What's changed
UserCollecitionDuplicatedGQL subscription document.duplicateCollectionDisabledInPersonalWorkspacetemporary feature flag and enable duplicate collection action under personal workspace in SH.~/collections.platform.tsaccounting for the new GQL subscription:idending with the-duplicatesuffix and add the above entry where relevant transformations are applied to constructfolders&requestsfields.transformDuplicatedCollections()&transformDuplicatedRequests()helper functions to apply necessary transformations on the data received via the subscriptions converting them to the respective internal representations.issueBackendIDToDuplicatedCollection()helper function.selfhost-webtosh-desktop.Note to reviewers
Please ensure to rebuild the BE container accounting for the GQL subscription addition and verify the following flows:
Authorization/headersat the collection level and they are retained in the duplicated collection.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.