Add additonal query limits and restrictors for performance.

This commit is contained in:
Patrick Fic
2023-09-18 16:08:20 -07:00
parent 64851047bf
commit 06c35a4ff8
7 changed files with 11 additions and 7 deletions

View File

@@ -1242,7 +1242,7 @@ export const SEARCH_JOBS_FOR_AUTOCOMPLETE = gql`
) {
search_jobs(
args: { search: $search }
limit: 50
limit: 25
where: {
_and: {
converted: { _eq: $isConverted }

View File

@@ -36,7 +36,7 @@ export const SEARCH_OWNERS_FOR_AUTOCOMPLETE = gql`
query SEARCH_OWNERS_FOR_AUTOCOMPLETE($search: String) {
search_owners(
args: { search: $search }
limit: 50
limit: 25
order_by: { ownr_ln: desc_nulls_last }
) {
id

View File

@@ -184,7 +184,7 @@ export const SEARCH_VEHICLES_BY_ID_FOR_AUTOCOMPLETE = gql`
`;
export const SEARCH_VEHICLES_FOR_AUTOCOMPLETE = gql`
query SEARCH_VEHICLES_FOR_AUTOCOMPLETE($search: String) {
search_vehicles(args: { search: $search }, limit: 50) {
search_vehicles(args: { search: $search }, limit: 25) {
id
v_vin
v_model_yr