IO-1613 add suspended days to jobs.

This commit is contained in:
Patrick Fic
2022-01-04 12:33:20 -08:00
parent fc023367cc
commit 6457acc61e
18 changed files with 170 additions and 24 deletions

View File

@@ -212,7 +212,9 @@ export const QUERY_APPOINTMENTS_BY_JOBID = gql`
`;
export const QUERY_SCHEDULE_LOAD_DATA = gql`
query QUERY_SCHEDULE_LOAD_DATA($start: timestamptz!, $end: timestamptz!) {
prodJobs: jobs(where: { inproduction: { _eq: true } }) {
prodJobs: jobs(
where: { inproduction: { _eq: true }, suspended: { _eq: false } }
) {
id
labhrs: joblines_aggregate(
where: { mod_lbr_ty: { _neq: "LAR" }, removed: { _eq: false } }
@@ -235,9 +237,14 @@ export const QUERY_SCHEDULE_LOAD_DATA = gql`
}
compJobs: jobs(
where: {
_or: [
{ scheduled_completion: { _gte: $start, _lte: $end } }
{ actual_completion: { _gte: $start, _lte: $end } }
_and: [
{ suspended: { _eq: false } }
{
_or: [
{ scheduled_completion: { _gte: $start, _lte: $end } }
{ actual_completion: { _gte: $start, _lte: $end } }
]
}
]
}
) {
@@ -264,7 +271,12 @@ export const QUERY_SCHEDULE_LOAD_DATA = gql`
}
}
}
arrJobs: jobs(where: { scheduled_in: { _gte: $start, _lte: $end } }) {
arrJobs: jobs(
where: {
scheduled_in: { _gte: $start, _lte: $end }
suspended: { _eq: false }
}
) {
id
scheduled_in
ro_number

View File

@@ -42,6 +42,7 @@ export const QUERY_ALL_ACTIVE_JOBS = gql`
status
updated_at
ded_amt
suspended
}
}
`;
@@ -290,6 +291,7 @@ export const QUERY_JOBS_IN_PRODUCTION = gql`
employee_refinish
employee_prep
employee_csr
suspended
labhrs: joblines_aggregate(
where: {
_and: [{ mod_lbr_ty: { _neq: "LAR" } }, { removed: { _eq: false } }]
@@ -654,6 +656,7 @@ export const GET_JOB_BY_PK = gql`
voided
ca_bc_pvrt
ca_customer_gst
suspended
joblines(where: { removed: { _eq: false } }, order_by: { line_no: asc }) {
id
alt_partm
@@ -828,6 +831,7 @@ export const QUERY_JOB_CARD_DETAILS = gql`
ca_gst_registrant
owner_owing
special_coverage_policy
suspended
available_jobs {
id
}
@@ -1034,6 +1038,7 @@ export const UPDATE_JOB = gql`
ro_number
production_vars
lbr_adjustments
suspended
}
}
}