danielrasmuson
08/01/2018, 7:39 PMmutation{
createTeam(data:{
name:"hi",
}){
id
name
createdBy{
email
}
}
}
prisma-binding call
return context.db.mutation.createTeam({
data: {
name: args.data.name,
organization: {
connect: {
id: context.organizationId
}
},
createdBy: {
connect: {
id: context.userId
}
}
}
}, info)
I could use
context.db.mutation.createTeam({data: {...}}, `{id, name, createdBy{ email }}`)
But I don't know what fields will be used in the selectiondivyendu
08/01/2018, 7:56 PMdanielrasmuson
08/01/2018, 10:17 PMdanielrasmuson
08/02/2018, 2:01 AM{id, name, createdBy{ email }}
depending on the needed selectionmatic
08/02/2018, 6:59 AMfragments
? I think this could solve your problem from my understanding of your issue.
Check this out https://www.prisma.io/forum/t/append-to-info-to-get-additional-fields-back/3972/2