parent
c6d76d18c4
commit
388bf4a194
@ -1,19 +1,20 @@
|
||||
export default{
|
||||
emits: ['editTeam'],
|
||||
props: {
|
||||
id: Number,
|
||||
nom: String,
|
||||
description: String
|
||||
},
|
||||
methods: {
|
||||
myfun: function() {
|
||||
console.log('to do')
|
||||
edit: function() {
|
||||
this.$emit("editTeam", new Team(this.id,this.nom,this.description))
|
||||
}
|
||||
},
|
||||
template: `
|
||||
<br>
|
||||
<div id="teamCard">
|
||||
<span>{{id}} {{nom}} description: {{description}}</span>
|
||||
<span @click="myfun" style="cursor: pointer"> - éditer</span>
|
||||
<span @click="edit" style="cursor: pointer"> - éditer</span>
|
||||
</div>
|
||||
`
|
||||
}
|
||||
|
Loading…
Reference in new issue