Added pagingation to courtesy car detail contracts list BOD-374

This commit is contained in:
Patrick Fic
2020-08-31 10:34:09 -07:00
parent 266b6b0dbb
commit bd3ccc9b38
6 changed files with 74 additions and 36 deletions

View File

@@ -78,7 +78,12 @@ export const QUERY_ALL_CC = gql`
`;
export const QUERY_CC_BY_PK = gql`
query QUERY_CC_BY_PK($id: uuid!) {
query QUERY_CC_BY_PK(
$id: uuid!
$offset: Int
$limit: Int
$order: [cccontracts_order_by!]!
) {
courtesycars_by_pk(id: $id) {
bodyshopid
color
@@ -104,7 +109,12 @@ export const QUERY_CC_BY_PK = gql`
vin
year
mileage
cccontracts {
cccontracts_aggregate {
aggregate {
count(distinct: true)
}
}
cccontracts(offset: $offset, limit: $limit, order_by: $order) {
agreementnumber
id
status