mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
activity: naming of addSuggestedEntities
This commit is contained in:
parent
b3cd7c5cdb
commit
aae7d2fb2a
@ -12,7 +12,7 @@
|
|||||||
|
|
||||||
<div v-if="getContext === 'accompanyingCourse' && suggestedEntities.length > 0">
|
<div v-if="getContext === 'accompanyingCourse' && suggestedEntities.length > 0">
|
||||||
<ul>
|
<ul>
|
||||||
<li v-for="p in suggestedEntities" @click="addNewPerson(p)">
|
<li v-for="p in suggestedEntities" @click="addSuggestedEntity(p)">
|
||||||
{{ p.text }}
|
{{ p.text }}
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
@ -168,7 +168,7 @@ export default {
|
|||||||
},
|
},
|
||||||
addNewPersons({ selected, modal }) {
|
addNewPersons({ selected, modal }) {
|
||||||
console.log('@@@ CLICK button addNewPersons', selected);
|
console.log('@@@ CLICK button addNewPersons', selected);
|
||||||
selected.forEach(function(item) {
|
selected.forEach((item) => {
|
||||||
this.$store.dispatch('addPersonsInvolved', item);
|
this.$store.dispatch('addPersonsInvolved', item);
|
||||||
}, this
|
}, this
|
||||||
);
|
);
|
||||||
@ -176,7 +176,7 @@ export default {
|
|||||||
modal.showModal = false;
|
modal.showModal = false;
|
||||||
this.setPersonsInBloc();
|
this.setPersonsInBloc();
|
||||||
},
|
},
|
||||||
addNewPerson(person) {
|
addSuggestedEntity(person) {
|
||||||
this.$store.dispatch('addPersonsInvolved', { result: person, type: 'person' });
|
this.$store.dispatch('addPersonsInvolved', { result: person, type: 'person' });
|
||||||
this.setPersonsInBloc();
|
this.setPersonsInBloc();
|
||||||
},
|
},
|
||||||
|
@ -126,7 +126,7 @@ const store = createStore({
|
|||||||
|
|
||||||
// ConcernedGroups
|
// ConcernedGroups
|
||||||
addPersonsInvolved(state, payload) {
|
addPersonsInvolved(state, payload) {
|
||||||
//console.log('### mutation addPersonsInvolved', payload.result.type);
|
console.log('### mutation addPersonsInvolved', payload);
|
||||||
switch (payload.result.type) {
|
switch (payload.result.type) {
|
||||||
case 'person':
|
case 'person':
|
||||||
state.activity.persons.push(payload.result);
|
state.activity.persons.push(payload.result);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user