Add bill ref to job lines table. IO-582
This commit is contained in:
@@ -22,3 +22,26 @@ export const INSERT_NEW_BILL_LINES = gql`
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export const QUERY_BILLS_BY_JOB_REF = gql`
|
||||
query QUERY_BILLS_BY_JOB_REF($jobId: uuid!) {
|
||||
billlines(
|
||||
where: { bill: { jobid: { _eq: $jobId } } }
|
||||
limit: 1
|
||||
order_by: { bill: { date: desc } }
|
||||
) {
|
||||
id
|
||||
quantity
|
||||
actual_cost
|
||||
actual_price
|
||||
joblineid
|
||||
bill {
|
||||
id
|
||||
vendor {
|
||||
id
|
||||
name
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user