-
Notifications
You must be signed in to change notification settings - Fork 16
ENSv2 Find Domain Ordering Support #1595
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
930a910
0a03e2a
cdfa7cc
523a98c
3ab13bf
992a7fe
3ebdb64
55c09e6
5652b14
ee9498c
7132c0f
fefb300
e458e5d
19670c8
932fbc0
eeb2b22
9885464
25d6f65
f4d5625
d941511
eb05617
151b542
b584e51
551cd5e
a3ab5af
618d7a8
1ccb1d7
78ce1fc
799d553
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,6 +17,7 @@ import { rejectAnyErrors } from "@/graphql-api/lib/reject-any-errors"; | |
| import { AccountRef } from "@/graphql-api/schema/account"; | ||
| import { DEFAULT_CONNECTION_ARGS } from "@/graphql-api/schema/constants"; | ||
| import { cursors } from "@/graphql-api/schema/cursors"; | ||
| import { OrderDirection } from "@/graphql-api/schema/order-direction"; | ||
| import { RegistrationInterfaceRef } from "@/graphql-api/schema/registration"; | ||
| import { RegistryRef } from "@/graphql-api/schema/registry"; | ||
| import { ResolverRef } from "@/graphql-api/schema/resolver"; | ||
|
|
@@ -331,3 +332,22 @@ export const AccountDomainsWhereInput = builder.inputType("AccountDomainsWhereIn | |
| name: t.string({ required: true }), | ||
| }), | ||
| }); | ||
|
|
||
| ////////////////////// | ||
| // Ordering | ||
| ////////////////////// | ||
|
|
||
| export const DomainsOrderBy = builder.enumType("DomainsOrderBy", { | ||
| description: "Fields by which domains can be ordered", | ||
| values: ["NAME", "REGISTRATION_TIMESTAMP", "REGISTRATION_EXPIRY"] as const, | ||
| }); | ||
|
|
||
| export type DomainsOrderByValue = typeof DomainsOrderBy.$inferType; | ||
|
|
||
| export const DomainsOrderInput = builder.inputType("DomainsOrderInput", { | ||
| description: "Ordering options for domains query", | ||
|
shrugs marked this conversation as resolved.
Outdated
|
||
| fields: (t) => ({ | ||
| by: t.field({ type: DomainsOrderBy, required: true }), | ||
| dir: t.field({ type: OrderDirection, defaultValue: "ASC" }), | ||
| }), | ||
|
shrugs marked this conversation as resolved.
Comment on lines
+347
to
+352
|
||
| }); | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| import { builder } from "@/graphql-api/builder"; | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. shared OrderDirection enum for future methods |
||
|
|
||
| export const OrderDirection = builder.enumType("OrderDirection", { | ||
| description: "Sort direction", | ||
| values: ["ASC", "DESC"] as const, | ||
| }); | ||
|
|
||
| export type OrderDirectionValue = typeof OrderDirection.$inferType; | ||
Uh oh!
There was an error while loading. Please reload this page.