feat: namespace settings archive script setup #2357
No reviewers
Labels
No Label
area/internal-code
changes requested
confirmed
dependencies
duplicate
good first issue
help wanted
hosting
invalid
kind/bug
kind/feature
question
wontfix
No Milestone
No project
No Assignees
3 Participants
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: vikunja/frontend#2357
Loading…
Reference in New Issue
No description provided.
Delete Branch "dpschen/frontend:feature/namespace-settings-archive-script-setup"
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?
Hi dpschen!
Thank you for creating a PR!
I've deployed the changes of this PR on a preview environment under this URL: https://2357-feature-namespace-settings-archi--vikunja-frontend-preview.netlify.app
You can use this url to view the changes live and test them out.
You will need to manually connect this to an api running somehwere. The easiest to use is https://try.vikunja.io/.
Have a nice day!
WIP: feat: namespace settings archive script setupto feat: namespace settings archive script setupLooks like the title is missing now:
vs on try:
5399abb5cc
to49df1324f8
This should work now.
The namespaces were sometimes not loaded thus the title wasn't ready to be read when the component mounted. Seemed like a race condition.
For the future it would be better if we could put the loadSomeRessource mechanisms in the store so that all references to that ressource in the frontend are automatically updated. Right now I copied over the code from the EditNamespace component which loads the namespace again just for the modal.
I didn't find out why this race condition appears now.
When I put in a small setTimout the namespaces would be there but this seems super error-prone.
This includes also an update on the
useTitle
composable which is now a slim wrapper around the vue-use composable with the same name that adds the Vikunja suffixes :)Looks like the title still doesn't work :/
@ -54,0 +54,4 @@
watch(
() => props.namespaceId,
async () => {
Object.assign(namespace, store.getters['namespaces/getNamespaceById'](props.namespaceId))
Shouldn't this work? The namespace is always in store since it is used in the menu. We'll only need the title so it should be enough to get it from store.
As written above:
@ -54,0 +57,4 @@
Object.assign(namespace, store.getters['namespaces/getNamespaceById'](props.namespaceId))
// FIXME: ressouce should be loaded in store
// Object.assign(namespace, await namespaceService.get({id: props.namespaceId}))
Can you remove this commented code? Or uncomment it?
Fixed
49df1324f8
to7860d233d9
Looks good.