Skip to content

Commit 7b0607a

Browse files
authored
Merge pull request #153 from hypercerts-org/fix/filter_on_sales_attestations_count
fix(types): counts as ints not floats
2 parents 59c9653 + 95f8fc7 commit 7b0607a

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

schema.graphql

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ type Hypercert {
450450
attestations: GetAttestationsResponse
451451

452452
"""Count of attestations referencing this hypercert"""
453-
attestations_count: Float
453+
attestations_count: Int
454454

455455
"""The contract that the hypercert is associated with"""
456456
contract: Contract
@@ -484,7 +484,7 @@ type Hypercert {
484484
sales: GetSalesResponse
485485

486486
"""Count of sales of fractions that belong to this hypercert"""
487-
sales_count: Float
487+
sales_count: Int
488488

489489
"""The token ID of the hypercert"""
490490
token_id: EthBigInt
@@ -498,7 +498,7 @@ type Hypercert {
498498

499499
type HypercertBaseType {
500500
"""Count of attestations referencing this hypercert"""
501-
attestations_count: Float
501+
attestations_count: Int
502502

503503
"""The UUID of the contract as stored in the database"""
504504
contracts_id: ID
@@ -520,7 +520,7 @@ type HypercertBaseType {
520520
metadata: Metadata
521521

522522
"""Count of sales of fractions that belong to this hypercert"""
523-
sales_count: Float
523+
sales_count: Int
524524

525525
"""The token ID of the hypercert"""
526526
token_id: EthBigInt

src/graphql/schemas/typeDefs/baseTypes/hypercertBaseType.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Field, ID, ObjectType } from "type-graphql";
1+
import { Field, ID, ObjectType, Int } from "type-graphql";
22
import { BasicTypeDef } from "./basicTypeDef.js";
33
import { EthBigInt } from "../../../scalars/ethBigInt.js";
44
import { Metadata } from "../metadataTypeDefs.js";
@@ -52,13 +52,13 @@ class HypercertBaseType extends BasicTypeDef {
5252
@Field(() => EthBigInt, { nullable: true })
5353
last_update_block_timestamp?: bigint | number | string;
5454

55-
@Field({
55+
@Field(() => Int, {
5656
nullable: true,
5757
description: "Count of attestations referencing this hypercert",
5858
})
5959
attestations_count?: number;
6060

61-
@Field({
61+
@Field(() => Int, {
6262
nullable: true,
6363
description: "Count of sales of fractions that belong to this hypercert",
6464
})

src/types/graphql-env.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2183,7 +2183,7 @@ export type introspection = {
21832183
"name": "attestations_count",
21842184
"type": {
21852185
"kind": "SCALAR",
2186-
"name": "Float",
2186+
"name": "Int",
21872187
"ofType": null
21882188
},
21892189
"args": []
@@ -2312,7 +2312,7 @@ export type introspection = {
23122312
"name": "sales_count",
23132313
"type": {
23142314
"kind": "SCALAR",
2315-
"name": "Float",
2315+
"name": "Int",
23162316
"ofType": null
23172317
},
23182318
"args": []
@@ -2355,7 +2355,7 @@ export type introspection = {
23552355
"name": "attestations_count",
23562356
"type": {
23572357
"kind": "SCALAR",
2358-
"name": "Float",
2358+
"name": "Int",
23592359
"ofType": null
23602360
},
23612361
"args": []
@@ -2448,7 +2448,7 @@ export type introspection = {
24482448
"name": "sales_count",
24492449
"type": {
24502450
"kind": "SCALAR",
2451-
"name": "Float",
2451+
"name": "Int",
24522452
"ofType": null
24532453
},
24542454
"args": []

0 commit comments

Comments
 (0)