Hyo
12/07/2018, 3:40 AMHyo
12/07/2018, 3:40 AMRoman
12/07/2018, 8:13 AMtype Mutation {
signup(email: String!, password: String!): AuthPayload!
login(email: String!, password: String!): AuthPayload!
}
type AuthPayload {
token: String!
human: Human!
}
Errors:
Errors:
Mutation
✖ The relation field `signup` must specify a `@relation` directive: `@relation(name: "MyRelation")`
✖ The relation field `login` must specify a `@relation` directive: `@relation(name: "MyRelation")`
Don't understand what it wants ...Roman
12/07/2018, 8:45 AMRoman
12/07/2018, 8:46 AMRoman
12/07/2018, 8:46 AMenum
definition. It will not change from data model to schema definition.Hyo
12/07/2018, 8:50 AMHyo
12/07/2018, 8:52 AMHyo
12/07/2018, 8:53 AMprisma.graphql
in generated
is not updating how can I make this updated? I’ve tried prisma deploy
.Hyo
12/07/2018, 12:27 PMHyo
12/08/2018, 7:55 AMsignup: async (_, args, context, info) => {
const result = await context.prisma.mutation.createUser(
{
data: {
email: args.email,
},
},
info,
);
return result;
When I change above query to below, Error: Cannot return null for non-nullable field User.id.
error is always throwing. No idea why this is happening.
signup: async (_, args, context, info) => {
const token = jwt.sign({ userId: args.id }, SECRET);
console.log('token: ' + token); // token always has a value!!
const result = await context.prisma.mutation.createUser(
{
data: {
email: args.email,
},
},
info,
);
return {
token,
result,
};
}
Could anyone guide me to this problem?Hyo
12/08/2018, 7:56 AMHyo
12/08/2018, 8:14 AMforum
. https://www.prisma.io/forum/t/passing-another-variable-in-mutation-query/5282/2. Thank you.dot
12/09/2018, 12:03 PMJames Tran
12/10/2018, 6:01 AMmuhajir
12/11/2018, 3:14 AMDateTime
or just Int
. I read that prisma DateTime
uses ISO 8601 . Which support Duration https://en.wikipedia.org/wiki/ISO_8601#Durations . But when I try duration 10 minutes
PT10M
. It doesn't seems to work.Serhii Kyrychenko
12/11/2018, 11:46 AMpllumh
12/12/2018, 7:43 AMpllumh
12/12/2018, 7:45 AMAlejandro Estrada
12/13/2018, 1:55 PMsapkra
12/14/2018, 2:09 AMKaushal
12/18/2018, 10:38 PMKaushal
12/18/2018, 11:10 PMBacharSaleh
12/23/2018, 3:42 PMBacharSaleh
12/23/2018, 3:43 PMLuis Acerv
12/23/2018, 3:43 PMprisma reset
command first or delete your containers and then running all again?Luis Acerv
12/23/2018, 3:45 PMBacharSaleh
12/23/2018, 3:48 PMLuis Acerv
12/23/2018, 3:49 PMBacharSaleh
12/23/2018, 3:51 PM