import React from "react";
import { useQuery } from "@apollo/react-hooks";
import JobsDetailPliComponent from "./jobs-detail-pli.component";
import { QUERY_INVOICES_BY_JOBID } from "../../graphql/invoices.queries";
export default function JobsDetailPliContainer({ job }) {
  const invoicesQuery = useQuery(QUERY_INVOICES_BY_JOBID, {
    variables: { jobid: job.id },
    fetchPolicy: "network-only"
  });

  return <JobsDetailPliComponent job={job} invoicesQuery={invoicesQuery} />;
}
