Skip to content
This repository has been archived by the owner on Aug 16, 2022. It is now read-only.

feat: add totalCount field to DatasetSchema type of GraphQL schema #154

Merged
merged 5 commits into from Jun 3, 2022

Conversation

keiya01
Copy link
Member

@keiya01 keiya01 commented May 29, 2022

Overview

I fixed reearth/reearth#267.

What I've done

  • add CountBySchema method to count dataset by schema id.
  • add totalCount resolver to DatasetSchema struct

What I haven't done

How I tested

  1. run reearth-backend and reearth-web
  2. add dataset
  3. check dataset count

Which point I want you to review particularly

Memo

@keiya01 keiya01 requested a review from rot1024 as a code owner May 29, 2022 06:52
@keiya01 keiya01 self-assigned this May 29, 2022
@codecov
Copy link

codecov bot commented May 29, 2022

Codecov Report

Merging #154 (cebf885) into main (e444e4e) will decrease coverage by 0.03%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #154      +/-   ##
==========================================
- Coverage   34.84%   34.81%   -0.04%     
==========================================
  Files         351      351              
  Lines       31868    31901      +33     
==========================================
  Hits        11105    11105              
- Misses      19751    19784      +33     
  Partials     1012     1012              
Impacted Files Coverage Δ
internal/adapter/gql/loader_dataset.go 0.00% <0.00%> (ø)
internal/adapter/gql/resolver_dataset_schema.go 0.00% <0.00%> (ø)
internal/infrastructure/memory/dataset.go 0.00% <0.00%> (ø)
internal/infrastructure/mongo/dataset.go 0.00% <0.00%> (ø)
internal/usecase/interactor/dataset.go 0.00% <0.00%> (ø)
internal/usecase/repo/dataset.go 0.00% <ø> (ø)

@keiya01
Copy link
Member Author

keiya01 commented May 29, 2022

I ran go generate ./... to generate some gql code, but this generated too many code in this commit.
chore: generate gql

Is this way correct?
Or is there another way to generate gql code?

@rot1024 rot1024 changed the title fix: fix to count dataset rows, closes reearth/reearth#267 fix: fix to count dataset rows May 31, 2022
@rot1024 rot1024 changed the title fix: fix to count dataset rows fix: count of dataset rows May 31, 2022
@keiya01 keiya01 force-pushed the feature/fix-dataset-count branch from 37eb6bb to 7fcc08f Compare June 2, 2022 12:04
@keiya01 keiya01 force-pushed the feature/fix-dataset-count branch from d2d8008 to d3ea8f5 Compare June 2, 2022 12:30
internal/infrastructure/memory/dataset.go Outdated Show resolved Hide resolved
internal/infrastructure/mongo/dataset.go Outdated Show resolved Hide resolved
@rot1024 rot1024 changed the title fix: count of dataset rows feat: add totalCount field to DatasetSchema type in GraphQL Jun 3, 2022
@rot1024 rot1024 changed the title feat: add totalCount field to DatasetSchema type in GraphQL feat: add totalCount field to DatasetSchema type of GraphQL schema Jun 3, 2022
keiya01 and others added 2 commits June 3, 2022 19:32
Co-authored-by: rot1024 <aayhrot@gmail.com>
Co-authored-by: rot1024 <aayhrot@gmail.com>
@keiya01 keiya01 merged commit ab6334a into main Jun 3, 2022
@keiya01 keiya01 deleted the feature/fix-dataset-count branch June 3, 2022 13:12
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants