sid bhatta
04/12/2019, 7:05 AMJames
04/12/2019, 7:05 AMsid bhatta
04/12/2019, 7:06 AMJames
04/12/2019, 7:07 AMJames
04/12/2019, 7:08 AMsid bhatta
04/12/2019, 7:09 AMsid bhatta
04/12/2019, 7:10 AMsid bhatta
04/12/2019, 7:11 AMsid bhatta
04/12/2019, 7:12 AMJames
04/12/2019, 7:12 AMJames
04/12/2019, 7:12 AMsid bhatta
04/12/2019, 7:12 AMJames
04/12/2019, 7:13 AMsid bhatta
04/12/2019, 7:16 AMFabiano Bonomini
04/12/2019, 1:55 PMNovalis
04/12/2019, 2:33 PMaldarund
04/12/2019, 7:23 PMaldarund
04/12/2019, 7:26 PMtype Consultancy {
id: ID! @id
organization: Organization @relation(name: "OrganizationConsultancy")
}
type Organization {
id: ID! @id
consultancy: Consultancy @relation(link: INLINE, name: "OrganizationConsultancy")
}
And then i want
prisma.updateConsultancy({
data: {
...
},
where: { organization: {id: id}
})
But it seems that generated client have only id in where, without organizationaldarund
04/12/2019, 8:40 PMJohn Aagaard
04/12/2019, 8:57 PMNathan Rice
04/12/2019, 10:35 PMNathan Rice
04/12/2019, 10:36 PMNathan Rice
04/12/2019, 10:40 PMNathan Rice
04/12/2019, 10:41 PMNathan Rice
04/12/2019, 10:43 PMNathan Rice
04/12/2019, 10:43 PMPankaja
04/13/2019, 1:05 PMtype Wallet {
id: ID! @unique
name: String!
balance: Float! @default(value: "0.0")
user: User!
}
type Income {
id: ID! @unique
name: String
createdOn: DateTime!
value: Float!
wallet: Wallet!
category: Category!
isSettled: Boolean! @default(value: "true")
}
type Expense {
id: ID! @unique
name: String
createdOn: DateTime!
value: Float!
wallet: Wallet!
category: Category!
isSettled: Boolean! @default(value: "true")
}
This is working so far. However now I need to add a wallet to wallet transfer. So, I tried adding toWallet: Wallet to type Expense and fromWallet to type Income. But when I run prisma deploy, I'm getting an error like this
`Errors:
Income
:heavy_multiplication_x: The relation field 'wallet' must specify a '@relation' directive: '@relation(name: "MyRelation")'
:heavy_multiplication_x: The relation field 'fromWallet' must specify a '@relation' directive: '@relation(name: "MyRelation")'
Expense
:heavy_multiplication_x: The relation field 'wallet' must specify a '@relation' directive: '@relation(name: "MyRelation")'
:heavy_multiplication_x: The relation field 'toWallet' must specify a '@relation' directive: 'relation(name: "MyRelation")'
How can I fix this ? Any help would be appreciated.
Thanksahebwa49
04/13/2019, 1:46 PMPRISMA_MANAGEMENT_API_SECRET
as in the image below. How do i go about this?ahebwa49
04/13/2019, 1:53 PMPrakarsh Gupta
04/13/2019, 2:25 PM