diff --git a/client/src/components/job-detail-cards/job-detail-cards.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.component.jsx
index ee5b0e551..3f32c7a61 100644
--- a/client/src/components/job-detail-cards/job-detail-cards.component.jsx
+++ b/client/src/components/job-detail-cards/job-detail-cards.component.jsx
@@ -1,16 +1,71 @@
import React from "react";
-import JobDetailCardsCustomerContainer from "./job-detail-cards.customer.container";
import { useTranslation } from "react-i18next";
+import { useQuery } from "@apollo/react-hooks";
+import AlertComponent from "../alert/alert.component";
+import { QUERY_JOB_CARD_DETAILS } from "../../graphql/jobs.queries";
+import { Row, Col } from "antd";
+
+import JobDetailCardsCustomerComponent from "./job-detail-cards.customer.component";
+import JobDetailCardsVehicleComponent from "./job-detail-cards.vehicle.component";
+import JobDetailCardsInsuranceComponent from "./job-detail-cards.insurance.component";
+import JobDetailCardsDatesComponent from "./job-detail-cards.dates.component";
+import JobDetailCardsPartsComponent from "./job-detail-cards.parts.component";
+import JobDetailCardsNotesComponent from "./job-detail-cards.notes.component";
+import JobDetailCardsDamageComponent from "./job-detail-cards.damage.component";
+import JobDetailCardsTotalsComponent from "./job-detail-cards.totals.component";
+import JobDetailCardsDocumentsComponent from "./job-detail-cards.documents.component";
+
+import "./job-detail-cards.styles.scss";
export default function JobDetailCards({ selectedJob }) {
+ const { loading, error, data } = useQuery(QUERY_JOB_CARD_DETAILS, {
+ fetchPolicy: "network-only",
+ variables: { id: selectedJob },
+ skip: !selectedJob
+ });
+
const { t } = useTranslation();
if (!selectedJob) {
return
{t("jobs.errors.nojobselected")}
;
}
+
+ if (error) return ;
+
return (
-
-
-
+
);
}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.customer.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.customer.component.jsx
index 8b12d2955..b2a6ee7d3 100644
--- a/client/src/components/job-detail-cards/job-detail-cards.customer.component.jsx
+++ b/client/src/components/job-detail-cards/job-detail-cards.customer.component.jsx
@@ -1,8 +1,29 @@
import React from "react";
import { useTranslation } from "react-i18next";
-import { Card } from "antd";
+import CardTemplate from "./job-detail-cards.template.component";
+import PhoneFormatter from "../../utils/PhoneFormatter";
+
export default function JobDetailCardsCustomerComponent({ loading, data }) {
const { t } = useTranslation();
- return Card has loaded.;
+ return (
+
+ {data ? (
+
+ {`${data?.pit_owner_first_name ??
+ ""} ${data.pit_owner_last_name ?? ""}`}
+
+
{`${data?.pit_owner_phone ?? ""}`}
+
+ {data?.pit_owner_email ? (
+
+ {`${data?.pit_owner_email ?? ""}`}
+
+ ) : null}
+
+ {`${data?.owner.preferred_contact ?? ""}`}
+
+ ) : null}
+
+ );
}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.customer.container.jsx b/client/src/components/job-detail-cards/job-detail-cards.customer.container.jsx
deleted file mode 100644
index 747eb6bc3..000000000
--- a/client/src/components/job-detail-cards/job-detail-cards.customer.container.jsx
+++ /dev/null
@@ -1,15 +0,0 @@
-import React from "react";
-import JobDetailCardsCustomerComponent from "./job-detail-cards.customer.component";
-import { useQuery } from "@apollo/react-hooks";
-import AlertComponent from "../alert/alert.component";
-import { QUERY_JOBS_IN_PRODUCTION } from "../../graphql/jobs.queries";
-
-export default function JobDetailCardsCustomerContainer({ selectedJob }) {
- const { loading, error, data } = useQuery(QUERY_JOBS_IN_PRODUCTION, {
- fetchPolicy: "network-only"
- });
-
- if (error) return ;
-
- return ;
-}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.damage.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.damage.component.jsx
new file mode 100644
index 000000000..861037a34
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.damage.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsDamageComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Damage stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.dates.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.dates.component.jsx
new file mode 100644
index 000000000..2b3188342
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.dates.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsDatesComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Dates stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.documents.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.documents.component.jsx
new file mode 100644
index 000000000..d09d4f241
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.documents.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsDocumentsComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Documents stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.insurance.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.insurance.component.jsx
new file mode 100644
index 000000000..35abacb6a
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.insurance.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsInsuranceComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Insurance stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.notes.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.notes.component.jsx
new file mode 100644
index 000000000..3fc2ccaf7
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.notes.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsNotesComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ notes stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.parts.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.parts.component.jsx
new file mode 100644
index 000000000..77a339ff9
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.parts.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsPartsComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Parts stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.styles.scss b/client/src/components/job-detail-cards/job-detail-cards.styles.scss
new file mode 100644
index 000000000..726e8e82a
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.styles.scss
@@ -0,0 +1,32 @@
+.job-cards {
+ display: flex;
+ flex-wrap: wrap;
+ }
+
+.job-card {
+
+ margin: .5em;
+}
+
+@media screen and (min-width: 40em) {
+ .card {
+ max-width: calc(50% - 1em);
+ }
+}
+
+@media screen and (min-width: 60em) {
+ .card {
+ max-width: calc(25% - 1em);
+ }
+}
+
+.centered {
+ margin: 0 auto;
+ padding: 0 1em;
+}
+
+@media screen and (min-width: 52em) {
+ .centered {
+ max-width: 52em;
+ }
+}
\ No newline at end of file
diff --git a/client/src/components/job-detail-cards/job-detail-cards.template.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.template.component.jsx
new file mode 100644
index 000000000..791ff18fc
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.template.component.jsx
@@ -0,0 +1,20 @@
+import React from "react";
+import { Card } from "antd";
+
+export default function JobDetailCardTemplate({
+ loading,
+ title,
+ ...otherProps
+}) {
+ return (
+
+ {otherProps.children}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.totals.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.totals.component.jsx
new file mode 100644
index 000000000..eb82564e7
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.totals.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsTotalsComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Totals stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/components/job-detail-cards/job-detail-cards.vehicle.component.jsx b/client/src/components/job-detail-cards/job-detail-cards.vehicle.component.jsx
new file mode 100644
index 000000000..86ba32f07
--- /dev/null
+++ b/client/src/components/job-detail-cards/job-detail-cards.vehicle.component.jsx
@@ -0,0 +1,17 @@
+import React from "react";
+import { useTranslation } from "react-i18next";
+import CardTemplate from "./job-detail-cards.template.component";
+
+export default function JobDetailCardsVehicleComponent({ loading, data }) {
+ const { t } = useTranslation();
+
+ return (
+
+ {data ? (
+
+ Vehicle stuff here.
+
+ ) : null}
+
+ );
+}
diff --git a/client/src/graphql/jobs.queries.js b/client/src/graphql/jobs.queries.js
index 284568a6a..99dfa363a 100644
--- a/client/src/graphql/jobs.queries.js
+++ b/client/src/graphql/jobs.queries.js
@@ -153,6 +153,62 @@ export const GET_JOB_BY_PK = gql`
}
`;
+export const QUERY_JOB_CARD_DETAILS = gql`
+ query QUERY_JOB_CARD_DETAILS($id: uuid!) {
+ jobs_by_pk(id: $id) {
+ pit_owner_first_name
+ pit_owner_last_name
+ pit_owner_phone
+ pit_owner_email
+ owner {
+ allow_text_message
+ preferred_contact
+ }
+ vehicle {
+ v_model_yr
+ v_make_desc
+ v_model_desc
+ v_color
+ plate_no
+ }
+ pit_vehicle_plate_no
+ actual_completion
+ actual_delivery
+ actual_in
+ created_at
+ est_number
+ id
+ local_tax_rate
+
+ est_co_nm
+ est_ph1
+ est_ea
+ est_ct_fn
+ est_ct_ln
+ regie_number
+ ro_number
+ scheduled_completion
+ scheduled_in
+ scheduled_delivery
+ job_status {
+ name
+ }
+ updated_at
+ claim_total
+ deductible
+ vehicle {
+ id
+ plate_no
+ v_vin
+ v_model_yr
+ v_model_desc
+ v_make_desc
+ v_color
+ }
+ }
+ }
+`;
+
export const UPDATE_JOB = gql`
mutation UPDATE_JOB($jobId: uuid!, $job: jobs_set_input!) {
update_jobs(where: { id: { _eq: $jobId } }, _set: $job) {
diff --git a/client/src/pages/jobs/jobs.page.jsx b/client/src/pages/jobs/jobs.page.jsx
index 588bffd8f..857b22623 100644
--- a/client/src/pages/jobs/jobs.page.jsx
+++ b/client/src/pages/jobs/jobs.page.jsx
@@ -21,7 +21,6 @@ export default function JobsPage() {
const [selectedJob, setSelectedJob] = useState(null);
if (error) return ;
- console.log(selectedJob);
return (
+ );
+}
diff --git a/hasura/migrations/1578593458608_alter_table_public_jobs_add_column_pit_owner_first_name/down.yaml b/hasura/migrations/1578593458608_alter_table_public_jobs_add_column_pit_owner_first_name/down.yaml
new file mode 100644
index 000000000..5d1fd5850
--- /dev/null
+++ b/hasura/migrations/1578593458608_alter_table_public_jobs_add_column_pit_owner_first_name/down.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" DROP COLUMN "pit_owner_first_name";
+ type: run_sql
diff --git a/hasura/migrations/1578593458608_alter_table_public_jobs_add_column_pit_owner_first_name/up.yaml b/hasura/migrations/1578593458608_alter_table_public_jobs_add_column_pit_owner_first_name/up.yaml
new file mode 100644
index 000000000..85fecb1d7
--- /dev/null
+++ b/hasura/migrations/1578593458608_alter_table_public_jobs_add_column_pit_owner_first_name/up.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" ADD COLUMN "pit_owner_first_name" text NULL;
+ type: run_sql
diff --git a/hasura/migrations/1578593470242_alter_table_public_jobs_add_column_pit_owner_last_name/down.yaml b/hasura/migrations/1578593470242_alter_table_public_jobs_add_column_pit_owner_last_name/down.yaml
new file mode 100644
index 000000000..92261da74
--- /dev/null
+++ b/hasura/migrations/1578593470242_alter_table_public_jobs_add_column_pit_owner_last_name/down.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" DROP COLUMN "pit_owner_last_name";
+ type: run_sql
diff --git a/hasura/migrations/1578593470242_alter_table_public_jobs_add_column_pit_owner_last_name/up.yaml b/hasura/migrations/1578593470242_alter_table_public_jobs_add_column_pit_owner_last_name/up.yaml
new file mode 100644
index 000000000..42100a879
--- /dev/null
+++ b/hasura/migrations/1578593470242_alter_table_public_jobs_add_column_pit_owner_last_name/up.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" ADD COLUMN "pit_owner_last_name" text NULL;
+ type: run_sql
diff --git a/hasura/migrations/1578593496723_alter_table_public_jobs_add_column_pit_owner_phone/down.yaml b/hasura/migrations/1578593496723_alter_table_public_jobs_add_column_pit_owner_phone/down.yaml
new file mode 100644
index 000000000..68d452ba3
--- /dev/null
+++ b/hasura/migrations/1578593496723_alter_table_public_jobs_add_column_pit_owner_phone/down.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" DROP COLUMN "pit_owner_phone";
+ type: run_sql
diff --git a/hasura/migrations/1578593496723_alter_table_public_jobs_add_column_pit_owner_phone/up.yaml b/hasura/migrations/1578593496723_alter_table_public_jobs_add_column_pit_owner_phone/up.yaml
new file mode 100644
index 000000000..bbfd7f753
--- /dev/null
+++ b/hasura/migrations/1578593496723_alter_table_public_jobs_add_column_pit_owner_phone/up.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" ADD COLUMN "pit_owner_phone" text NULL;
+ type: run_sql
diff --git a/hasura/migrations/1578593515552_alter_table_public_jobs_add_column_pit_owner_email/down.yaml b/hasura/migrations/1578593515552_alter_table_public_jobs_add_column_pit_owner_email/down.yaml
new file mode 100644
index 000000000..6344206e2
--- /dev/null
+++ b/hasura/migrations/1578593515552_alter_table_public_jobs_add_column_pit_owner_email/down.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" DROP COLUMN "pit_owner_email";
+ type: run_sql
diff --git a/hasura/migrations/1578593515552_alter_table_public_jobs_add_column_pit_owner_email/up.yaml b/hasura/migrations/1578593515552_alter_table_public_jobs_add_column_pit_owner_email/up.yaml
new file mode 100644
index 000000000..183b64ec9
--- /dev/null
+++ b/hasura/migrations/1578593515552_alter_table_public_jobs_add_column_pit_owner_email/up.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" ADD COLUMN "pit_owner_email" text NULL;
+ type: run_sql
diff --git a/hasura/migrations/1578593666642_alter_table_public_jobs_add_column_pit_vehicle_plate_no/down.yaml b/hasura/migrations/1578593666642_alter_table_public_jobs_add_column_pit_vehicle_plate_no/down.yaml
new file mode 100644
index 000000000..f033f4c0f
--- /dev/null
+++ b/hasura/migrations/1578593666642_alter_table_public_jobs_add_column_pit_vehicle_plate_no/down.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" DROP COLUMN "pit_vehicle_plate_no";
+ type: run_sql
diff --git a/hasura/migrations/1578593666642_alter_table_public_jobs_add_column_pit_vehicle_plate_no/up.yaml b/hasura/migrations/1578593666642_alter_table_public_jobs_add_column_pit_vehicle_plate_no/up.yaml
new file mode 100644
index 000000000..9a1e56500
--- /dev/null
+++ b/hasura/migrations/1578593666642_alter_table_public_jobs_add_column_pit_vehicle_plate_no/up.yaml
@@ -0,0 +1,3 @@
+- args:
+ sql: ALTER TABLE "public"."jobs" ADD COLUMN "pit_vehicle_plate_no" text NULL;
+ type: run_sql
diff --git a/hasura/migrations/1578593710942_update_permission_user_public_table_jobs/down.yaml b/hasura/migrations/1578593710942_update_permission_user_public_table_jobs/down.yaml
new file mode 100644
index 000000000..2b0b72063
--- /dev/null
+++ b/hasura/migrations/1578593710942_update_permission_user_public_table_jobs/down.yaml
@@ -0,0 +1,86 @@
+- args:
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: drop_insert_permission
+- args:
+ permission:
+ check:
+ bodyshop:
+ associations:
+ _and:
+ - user:
+ authid:
+ _eq: X-Hasura-User-Id
+ - active:
+ _eq: true
+ columns:
+ - actual_completion
+ - actual_delivery
+ - actual_in
+ - claim_total
+ - created_at
+ - deductible
+ - est_addr1
+ - est_addr2
+ - est_city
+ - est_co_nm
+ - est_ct_fn
+ - est_ct_ln
+ - est_ctry
+ - est_ea
+ - est_number
+ - est_ph1
+ - est_st
+ - est_zip
+ - federal_tax_rate
+ - id
+ - inproduction
+ - invoice_date
+ - labor_rate_desc
+ - labor_rate_id
+ - local_tax_rate
+ - ownerid
+ - rate_atp
+ - rate_la1
+ - rate_la2
+ - rate_la3
+ - rate_la4
+ - rate_lab
+ - rate_lad
+ - rate_lae
+ - rate_laf
+ - rate_lag
+ - rate_lam
+ - rate_lar
+ - rate_las
+ - rate_lau
+ - rate_ma2s
+ - rate_ma2t
+ - rate_ma3s
+ - rate_mabl
+ - rate_macs
+ - rate_mahw
+ - rate_mapa
+ - rate_mash
+ - rate_matd
+ - regie_number
+ - ro_number
+ - scheduled_completion
+ - scheduled_delivery
+ - scheduled_in
+ - shopid
+ - state_tax_rate
+ - statusid
+ - updated_at
+ - vehicleid
+ localPresets:
+ - key: ""
+ value: ""
+ set: {}
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: create_insert_permission
diff --git a/hasura/migrations/1578593710942_update_permission_user_public_table_jobs/up.yaml b/hasura/migrations/1578593710942_update_permission_user_public_table_jobs/up.yaml
new file mode 100644
index 000000000..297bc3fe8
--- /dev/null
+++ b/hasura/migrations/1578593710942_update_permission_user_public_table_jobs/up.yaml
@@ -0,0 +1,91 @@
+- args:
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: drop_insert_permission
+- args:
+ permission:
+ check:
+ bodyshop:
+ associations:
+ _and:
+ - user:
+ authid:
+ _eq: X-Hasura-User-Id
+ - active:
+ _eq: true
+ columns:
+ - id
+ - created_at
+ - updated_at
+ - shopid
+ - est_number
+ - ro_number
+ - ownerid
+ - vehicleid
+ - labor_rate_id
+ - labor_rate_desc
+ - rate_lab
+ - rate_lad
+ - rate_lae
+ - rate_lar
+ - rate_las
+ - rate_laf
+ - rate_lam
+ - rate_lag
+ - rate_atp
+ - rate_lau
+ - rate_la1
+ - rate_la2
+ - rate_la3
+ - rate_la4
+ - rate_mapa
+ - rate_mash
+ - rate_mahw
+ - rate_ma2s
+ - rate_ma3s
+ - rate_ma2t
+ - rate_mabl
+ - rate_macs
+ - rate_matd
+ - federal_tax_rate
+ - state_tax_rate
+ - local_tax_rate
+ - est_co_nm
+ - est_addr1
+ - est_addr2
+ - est_city
+ - est_st
+ - est_zip
+ - est_ctry
+ - est_ph1
+ - est_ea
+ - est_ct_ln
+ - est_ct_fn
+ - scheduled_in
+ - actual_in
+ - scheduled_completion
+ - actual_completion
+ - scheduled_delivery
+ - actual_delivery
+ - regie_number
+ - invoice_date
+ - claim_total
+ - deductible
+ - inproduction
+ - statusid
+ - pit_owner_first_name
+ - pit_owner_last_name
+ - pit_owner_phone
+ - pit_owner_email
+ - pit_vehicle_plate_no
+ localPresets:
+ - key: ""
+ value: ""
+ set: {}
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: create_insert_permission
diff --git a/hasura/migrations/1578593719835_update_permission_user_public_table_jobs/down.yaml b/hasura/migrations/1578593719835_update_permission_user_public_table_jobs/down.yaml
new file mode 100644
index 000000000..a79eaa1f1
--- /dev/null
+++ b/hasura/migrations/1578593719835_update_permission_user_public_table_jobs/down.yaml
@@ -0,0 +1,84 @@
+- args:
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: drop_select_permission
+- args:
+ permission:
+ allow_aggregations: false
+ columns:
+ - actual_completion
+ - actual_delivery
+ - actual_in
+ - claim_total
+ - created_at
+ - deductible
+ - est_addr1
+ - est_addr2
+ - est_city
+ - est_co_nm
+ - est_ct_fn
+ - est_ct_ln
+ - est_ctry
+ - est_ea
+ - est_number
+ - est_ph1
+ - est_st
+ - est_zip
+ - federal_tax_rate
+ - id
+ - inproduction
+ - invoice_date
+ - labor_rate_desc
+ - labor_rate_id
+ - local_tax_rate
+ - ownerid
+ - rate_atp
+ - rate_la1
+ - rate_la2
+ - rate_la3
+ - rate_la4
+ - rate_lab
+ - rate_lad
+ - rate_lae
+ - rate_laf
+ - rate_lag
+ - rate_lam
+ - rate_lar
+ - rate_las
+ - rate_lau
+ - rate_ma2s
+ - rate_ma2t
+ - rate_ma3s
+ - rate_mabl
+ - rate_macs
+ - rate_mahw
+ - rate_mapa
+ - rate_mash
+ - rate_matd
+ - regie_number
+ - ro_number
+ - scheduled_completion
+ - scheduled_delivery
+ - scheduled_in
+ - shopid
+ - state_tax_rate
+ - statusid
+ - updated_at
+ - vehicleid
+ computed_fields: []
+ filter:
+ bodyshop:
+ associations:
+ _and:
+ - user:
+ authid:
+ _eq: X-Hasura-User-Id
+ - active:
+ _eq: true
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: create_select_permission
diff --git a/hasura/migrations/1578593719835_update_permission_user_public_table_jobs/up.yaml b/hasura/migrations/1578593719835_update_permission_user_public_table_jobs/up.yaml
new file mode 100644
index 000000000..3e20b9803
--- /dev/null
+++ b/hasura/migrations/1578593719835_update_permission_user_public_table_jobs/up.yaml
@@ -0,0 +1,89 @@
+- args:
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: drop_select_permission
+- args:
+ permission:
+ allow_aggregations: false
+ columns:
+ - id
+ - created_at
+ - updated_at
+ - shopid
+ - est_number
+ - ro_number
+ - ownerid
+ - vehicleid
+ - labor_rate_id
+ - labor_rate_desc
+ - rate_lab
+ - rate_lad
+ - rate_lae
+ - rate_lar
+ - rate_las
+ - rate_laf
+ - rate_lam
+ - rate_lag
+ - rate_atp
+ - rate_lau
+ - rate_la1
+ - rate_la2
+ - rate_la3
+ - rate_la4
+ - rate_mapa
+ - rate_mash
+ - rate_mahw
+ - rate_ma2s
+ - rate_ma3s
+ - rate_ma2t
+ - rate_mabl
+ - rate_macs
+ - rate_matd
+ - federal_tax_rate
+ - state_tax_rate
+ - local_tax_rate
+ - est_co_nm
+ - est_addr1
+ - est_addr2
+ - est_city
+ - est_st
+ - est_zip
+ - est_ctry
+ - est_ph1
+ - est_ea
+ - est_ct_ln
+ - est_ct_fn
+ - scheduled_in
+ - actual_in
+ - scheduled_completion
+ - actual_completion
+ - scheduled_delivery
+ - actual_delivery
+ - regie_number
+ - invoice_date
+ - claim_total
+ - deductible
+ - inproduction
+ - statusid
+ - pit_owner_first_name
+ - pit_owner_last_name
+ - pit_owner_phone
+ - pit_owner_email
+ - pit_vehicle_plate_no
+ computed_fields: []
+ filter:
+ bodyshop:
+ associations:
+ _and:
+ - user:
+ authid:
+ _eq: X-Hasura-User-Id
+ - active:
+ _eq: true
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: create_select_permission
diff --git a/hasura/migrations/1578593729177_update_permission_user_public_table_jobs/down.yaml b/hasura/migrations/1578593729177_update_permission_user_public_table_jobs/down.yaml
new file mode 100644
index 000000000..c664ccb26
--- /dev/null
+++ b/hasura/migrations/1578593729177_update_permission_user_public_table_jobs/down.yaml
@@ -0,0 +1,86 @@
+- args:
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: drop_update_permission
+- args:
+ permission:
+ columns:
+ - actual_completion
+ - actual_delivery
+ - actual_in
+ - claim_total
+ - created_at
+ - deductible
+ - est_addr1
+ - est_addr2
+ - est_city
+ - est_co_nm
+ - est_ct_fn
+ - est_ct_ln
+ - est_ctry
+ - est_ea
+ - est_number
+ - est_ph1
+ - est_st
+ - est_zip
+ - federal_tax_rate
+ - id
+ - inproduction
+ - invoice_date
+ - labor_rate_desc
+ - labor_rate_id
+ - local_tax_rate
+ - ownerid
+ - rate_atp
+ - rate_la1
+ - rate_la2
+ - rate_la3
+ - rate_la4
+ - rate_lab
+ - rate_lad
+ - rate_lae
+ - rate_laf
+ - rate_lag
+ - rate_lam
+ - rate_lar
+ - rate_las
+ - rate_lau
+ - rate_ma2s
+ - rate_ma2t
+ - rate_ma3s
+ - rate_mabl
+ - rate_macs
+ - rate_mahw
+ - rate_mapa
+ - rate_mash
+ - rate_matd
+ - regie_number
+ - ro_number
+ - scheduled_completion
+ - scheduled_delivery
+ - scheduled_in
+ - shopid
+ - state_tax_rate
+ - statusid
+ - updated_at
+ - vehicleid
+ filter:
+ bodyshop:
+ associations:
+ _and:
+ - user:
+ authid:
+ _eq: X-Hasura-User-Id
+ - active:
+ _eq: true
+ localPresets:
+ - key: ""
+ value: ""
+ set: {}
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: create_update_permission
diff --git a/hasura/migrations/1578593729177_update_permission_user_public_table_jobs/up.yaml b/hasura/migrations/1578593729177_update_permission_user_public_table_jobs/up.yaml
new file mode 100644
index 000000000..5c79c00a3
--- /dev/null
+++ b/hasura/migrations/1578593729177_update_permission_user_public_table_jobs/up.yaml
@@ -0,0 +1,91 @@
+- args:
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: drop_update_permission
+- args:
+ permission:
+ columns:
+ - inproduction
+ - invoice_date
+ - claim_total
+ - deductible
+ - federal_tax_rate
+ - local_tax_rate
+ - rate_atp
+ - rate_la1
+ - rate_la2
+ - rate_la3
+ - rate_la4
+ - rate_lab
+ - rate_lad
+ - rate_lae
+ - rate_laf
+ - rate_lag
+ - rate_lam
+ - rate_lar
+ - rate_las
+ - rate_lau
+ - rate_ma2s
+ - rate_ma2t
+ - rate_ma3s
+ - rate_mabl
+ - rate_macs
+ - rate_mahw
+ - rate_mapa
+ - rate_mash
+ - rate_matd
+ - state_tax_rate
+ - est_addr1
+ - est_addr2
+ - est_city
+ - est_co_nm
+ - est_ct_fn
+ - est_ct_ln
+ - est_ctry
+ - est_ea
+ - est_number
+ - est_ph1
+ - est_st
+ - est_zip
+ - labor_rate_desc
+ - labor_rate_id
+ - pit_owner_email
+ - pit_owner_first_name
+ - pit_owner_last_name
+ - pit_owner_phone
+ - pit_vehicle_plate_no
+ - regie_number
+ - ro_number
+ - actual_completion
+ - actual_delivery
+ - actual_in
+ - scheduled_completion
+ - scheduled_delivery
+ - scheduled_in
+ - created_at
+ - updated_at
+ - id
+ - ownerid
+ - shopid
+ - statusid
+ - vehicleid
+ filter:
+ bodyshop:
+ associations:
+ _and:
+ - user:
+ authid:
+ _eq: X-Hasura-User-Id
+ - active:
+ _eq: true
+ localPresets:
+ - key: ""
+ value: ""
+ set: {}
+ role: user
+ table:
+ name: jobs
+ schema: public
+ type: create_update_permission