Skip to content

Commit

Permalink
fix: properly load user annotations into stores (#1197)
Browse files Browse the repository at this point in the history
  • Loading branch information
stolpeo authored Nov 1, 2023
1 parent 1ea4ef4 commit 6bc4172
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 8 deletions.
8 changes: 5 additions & 3 deletions svs/vueapp/src/components/SvFilterApp.vue
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,11 @@ const refreshStores = async () => {
appContext,
)
.then(() => {
svResultSetStore.initialize(appContext.csrf_token).then(async () => {
await svResultSetStore.loadResultSetViaQuery(svQueryStore.queryUuid)
})
svResultSetStore
.initialize(appContext.csrf_token, true)
.then(async () => {
await svResultSetStore.loadResultSetViaQuery(svQueryStore.queryUuid)
})
}),
])
}
Expand Down
10 changes: 7 additions & 3 deletions variants/vueapp/src/components/FilterApp.vue
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ const refreshStores = async () => {
props.caseUuid,
)
await Promise.all([
Promise.all([
variantFlagsStore.initialize(
appContext.csrf_token,
appContext.project?.sodar_uuid,
Expand All @@ -166,8 +166,12 @@ const refreshStores = async () => {
props.caseUuid,
appContext,
),
variantResultSetStore.initialize(appContext.csrf_token),
])
variantResultSetStore.initialize(appContext.csrf_token, true),
]).then(async () => {
await variantResultSetStore.loadResultSetViaQuery(
variantQueryStore.queryUuid,
)
})
}
// Initialize (=refresh) stores when mounted.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const pathoEnabledWrapper = declareWrapper(props, 'pathoEnabled', emit)
const pathoScoreWrapper = declareWrapper(props, 'pathoScore', emit)
const prioEnabledWarning = () => {
return !prioEnabledWrapper.value && prioHpoTermsWrapper.value.length > 0
return !prioEnabledWrapper.value && prioHpoTermsWrapper.value?.length > 0
}
const v$ = useVuelidate()
Expand Down
2 changes: 1 addition & 1 deletion variants/vueapp/src/stores/variantQuery.js
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ export const useVariantQueryStore = defineStore('variantQuery', () => {
})
// 2.3 fetch the HPO names from the query settings for the HPO terms, if any
.then(() => {
if (querySettings.value?.prio_hpo_terms.length > 0) {
if (querySettings.value?.prio_hpo_terms?.length > 0) {
hpoNames.value = fetchHpoTerms(
csrfToken.value,
querySettings.value.prio_hpo_terms,
Expand Down

0 comments on commit 6bc4172

Please sign in to comment.