mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 07:03:49 +00:00
rename fetch api method
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { createStore } from 'vuex'
|
||||
import { getHouseholdByPerson, getCoursesByPerson, getRelationship } from './api'
|
||||
import { getHouseholdByPerson, getCoursesByPerson, getRelationshipByPerson } from './api'
|
||||
import { adapt2vis } from './vis-network'
|
||||
|
||||
const debug = process.env.NODE_ENV !== 'production'
|
||||
@@ -208,9 +208,9 @@ const store = createStore({
|
||||
*/
|
||||
fetchRelationship({ commit, getters }, person) {
|
||||
console.log('fetchRelationship', person)
|
||||
getRelationship(person)
|
||||
getRelationshipByPerson(person)
|
||||
.then(relationship => new Promise(resolve => {
|
||||
console.log('getRelationship', relationship)
|
||||
console.log('getRelationshipByPerson', relationship)
|
||||
commit('addRelationship', relationship)
|
||||
resolve()
|
||||
}))
|
||||
|
Reference in New Issue
Block a user