Skip to content

Commit

Permalink
Merge pull request #137 from lcnetdev/bfp-276-missing-summary-field
Browse files Browse the repository at this point in the history
the /edit/ mount action clears the component cache
  • Loading branch information
thisismattmiller authored Nov 21, 2024
2 parents 3f30311 + 820fb7f commit 71c2504
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
7 changes: 7 additions & 0 deletions src/stores/profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,13 @@ export const useProfileStore = defineStore('profile', {
actions: {


resetLocalComponentCache(){
cachePt = {}
cacheGuid = {}
dataChangedTimeout = null
},


/**
* The main first process that takes the raw profiles and processes them for use
*
Expand Down
6 changes: 3 additions & 3 deletions src/views/Edit.vue
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,7 @@
console.log("Mounted called", this.$route.params.action, this.$route.params.recordId )
console.log(this.$route.params)
this.profileStore.resetLocalComponentCache()
if (this.profilesLoaded && this.activeProfile){
if (this.activeProfile.neweId){
Expand All @@ -194,11 +195,10 @@
// otherwise they just got kicked over to the edit screen with an existing record id, load it from the back end to edit
this.profileStore.loadRecordFromBackend(this.$route.params.recordId)
}
}
}
Expand Down

0 comments on commit 71c2504

Please sign in to comment.