Skip to content

Commit 59807ef

Browse files
committed
init dataconnect and try to list movies
1 parent adba8c0 commit 59807ef

37 files changed

+10505
-23
lines changed

.firebase/.graphqlrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"schema":["../dataconnect/schema/**/*.gql","../dataconnect/.dataconnect/**/*.gql"],"document":["../dataconnect/connector/**/*.gql"]}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
extend type FavoriteMovie {
2+
"""
3+
✨ Implicit foreign key field based on `FavoriteMovie`.`user`. It must match the value of `User`.`id`. See `@ref` for how to customize it.
4+
"""
5+
userId: String! @fdc_generated(from: "FavoriteMovie.user", purpose: IMPLICIT_REF_FIELD)
6+
"""
7+
✨ Implicit foreign key field based on `FavoriteMovie`.`movie`. It must match the value of `Movie`.`id`. See `@ref` for how to customize it.
8+
"""
9+
movieId: UUID! @fdc_generated(from: "FavoriteMovie.movie", purpose: IMPLICIT_REF_FIELD)
10+
}
11+
extend type MovieActor {
12+
"""
13+
✨ Implicit foreign key field based on `MovieActor`.`movie`. It must match the value of `Movie`.`id`. See `@ref` for how to customize it.
14+
"""
15+
movieId: UUID! @fdc_generated(from: "MovieActor.movie", purpose: IMPLICIT_REF_FIELD)
16+
"""
17+
✨ Implicit foreign key field based on `MovieActor`.`actor`. It must match the value of `Actor`.`id`. See `@ref` for how to customize it.
18+
"""
19+
actorId: UUID! @fdc_generated(from: "MovieActor.actor", purpose: IMPLICIT_REF_FIELD)
20+
}
21+
extend type MovieMetadata {
22+
"""
23+
✨ Implicit primary key field. It's a UUID column default to a generated new value. See `@table` for how to customize it.
24+
"""
25+
id: UUID! @default(expr: "uuidV4()") @fdc_generated(from: "MovieMetadata", purpose: IMPLICIT_KEY_FIELD)
26+
"""
27+
✨ Implicit foreign key field based on `MovieMetadata`.`movie`. It must match the value of `Movie`.`id`. See `@ref` for how to customize it.
28+
"""
29+
movieId: UUID! @fdc_generated(from: "MovieMetadata.movie", purpose: IMPLICIT_REF_FIELD)
30+
}
31+
extend type Review {
32+
"""
33+
✨ Implicit foreign key field based on `Review`.`movie`. It must match the value of `Movie`.`id`. See `@ref` for how to customize it.
34+
"""
35+
movieId: UUID! @fdc_generated(from: "Review.movie", purpose: IMPLICIT_REF_FIELD)
36+
"""
37+
✨ Implicit foreign key field based on `Review`.`user`. It must match the value of `User`.`id`. See `@ref` for how to customize it.
38+
"""
39+
userId: String! @fdc_generated(from: "Review.user", purpose: IMPLICIT_REF_FIELD)
40+
}

0 commit comments

Comments
 (0)