Merge pull request #9878 from mfo/US/fix-not-type-ej-in-api

API: cast le type de champ EJ
This commit is contained in:
mfo 2023-12-22 07:20:13 +00:00 committed by GitHub
commit c4adee6278
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 110 additions and 1 deletions

View file

@ -74,6 +74,7 @@ class API::V2::Schema < GraphQL::Schema
Types::Champs::SiretChampType,
Types::Champs::TextChampType,
Types::Champs::TitreIdentiteChampType,
Types::Champs::EngagementJuridiqueChampType,
Types::GeoAreas::ParcelleCadastraleType,
Types::GeoAreas::SelectionUtilisateurType,
Types::PersonneMoraleType,
@ -118,7 +119,7 @@ class API::V2::Schema < GraphQL::Schema
Types::Champs::Descriptor::TitreIdentiteChampDescriptorType,
Types::Champs::Descriptor::YesNoChampDescriptorType,
Types::Champs::Descriptor::ExpressionReguliereChampDescriptorType,
Types::Champs::Descriptor::EngagementJuridiqueChampDescriptorType
Types::Champs::Descriptor::EngagementJuridiqueChampDescriptorType
def self.unauthorized_object(error)
# Add a top-level error to the response instead of returning nil:

View file

@ -580,6 +580,11 @@ class API::V2::StoredQuery
...DepartementFragment
}
}
... on EngagementJuridiqueChamp {
engagementJuridique {
...EngagementJuridiqueFragment
}
}
}
fragment PersonneMoraleFragment on PersonneMorale {
@ -690,6 +695,11 @@ class API::V2::StoredQuery
}
}
fragment EngagementJuridiqueFragment on EngagementJuridique {
montantEngage
montantPaye
}
fragment PageInfoFragment on PageInfo {
hasPreviousPage
hasNextPage