|
@@ -285,7 +285,7 @@ const _debounce = require('lodash/debounce')
|
|
|
|
|
|
export default {
|
|
export default {
|
|
name: "ModalCard",
|
|
name: "ModalCard",
|
|
- props: ['item'],
|
|
|
|
|
|
+ props: ['item', 'addNoteId'],
|
|
mixins: [cardMixins],
|
|
mixins: [cardMixins],
|
|
components: {
|
|
components: {
|
|
LinkedMaterialCard
|
|
LinkedMaterialCard
|
|
@@ -335,7 +335,7 @@ export default {
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
...mapActions({
|
|
...mapActions({
|
|
- refreshItem: 'Search/refreshItem',
|
|
|
|
|
|
+ // refreshItem: 'Search/refreshItem',
|
|
createFlagColl: 'User/createFlagColl',
|
|
createFlagColl: 'User/createFlagColl',
|
|
flagUnflag: 'User/flagUnflag'
|
|
flagUnflag: 'User/flagUnflag'
|
|
}),
|
|
}),
|
|
@@ -467,8 +467,11 @@ export default {
|
|
console.log('createNote REST data', data)
|
|
console.log('createNote REST data', data)
|
|
this.note_nid = data.nid[0].value
|
|
this.note_nid = data.nid[0].value
|
|
// call search results refresh of the item to display that note is now existing for this item
|
|
// call search results refresh of the item to display that note is now existing for this item
|
|
- // TODO: do the same for article linked materials
|
|
|
|
- this.refreshItem({id: this.item.id})
|
|
|
|
|
|
+ // this.refreshItem({id: this.item.id})
|
|
|
|
+ // no needs to refresh the entire item via searchresults
|
|
|
|
+ // plus if we are in article, there is not searchresults
|
|
|
|
+ // instead call the callbackfunction from teh parent to add directly the note id
|
|
|
|
+ this.addNoteId(this.note_nid)
|
|
})
|
|
})
|
|
.catch(error => {
|
|
.catch(error => {
|
|
console.warn('Issue with createNote', error)
|
|
console.warn('Issue with createNote', error)
|