【发布时间】:2019-07-15 16:19:16
【问题描述】:
我正在使用 AWS Appsync 和 Amplify。 我的 GraphQL 架构的 sn-p 如下所示:
type Recipe
@model
@auth(rules: [{allow: owner}])
{
id: ID!
title: String!
key: String!
courses: [Course!]!
}
type Course
@model
@auth(rules: [{allow: owner}])
{
id: ID!
name: String!
}
在放大推送时,它会创建 DynamoDB 表 Recipe 和 Course
阅读了很多教程后,我仍然不明白如何在 GraphiQL 中添加食谱。
如何插入引用课程的新食谱并避免在课程表中重复?
【问题讨论】:
标签: graphql aws-amplify