No columns found.
;
return (
@@ -50,22 +70,26 @@ export function ProductionListTable({
size='small'
pagination={false}
title={() => (
-
+
+
-
)}
- pagination={{ position: "top" }}
columns={columns.map((c) => {
return {
...c,
sortOrder:
state.sortedInfo.columnKey === c.key && state.sortedInfo.order,
+ title: headerItem(c),
};
})}
rowKey='id'
diff --git a/client/src/components/production-list-table/production-list-table.container.jsx b/client/src/components/production-list-table/production-list-table.container.jsx
index 652601a01..e357807f9 100644
--- a/client/src/components/production-list-table/production-list-table.container.jsx
+++ b/client/src/components/production-list-table/production-list-table.container.jsx
@@ -1,21 +1,23 @@
-import { useQuery } from "@apollo/react-hooks";
+import { useSubscription } from "@apollo/react-hooks";
import React from "react";
-import { QUERY_JOBS_IN_PRODUCTION } from "../../graphql/jobs.queries";
+import { SUBSCRIPTION_JOBS_IN_PRODUCTION } from "../../graphql/jobs.queries";
import ProductionListTable from "./production-list-table.component";
export default function ProductionListTableContainer({ columnState }) {
- const { loading, data, refetch } = useQuery(QUERY_JOBS_IN_PRODUCTION, {
- pollInterval: 30000,
- });
+ // const { loading, data, refetch } = useQuery(QUERY_JOBS_IN_PRODUCTION, {
+ // pollInterval: 30000,
+ // });
+
+ const { loading, data } = useSubscription(SUBSCRIPTION_JOBS_IN_PRODUCTION);
return (
-
+
);
}
diff --git a/client/src/graphql/jobs.queries.js b/client/src/graphql/jobs.queries.js
index f303cf909..6ba8fa12f 100644
--- a/client/src/graphql/jobs.queries.js
+++ b/client/src/graphql/jobs.queries.js
@@ -79,6 +79,35 @@ export const QUERY_JOBS_IN_PRODUCTION = gql`
}
`;
+export const SUBSCRIPTION_JOBS_IN_PRODUCTION = gql`
+ subscription SUBSCRIPTION_JOBS_IN_PRODUCTION {
+ productionview {
+ id
+ status
+ ro_number
+ est_number
+ ownr_fn
+ ownr_ln
+ v_model_yr
+ v_model_desc
+ clm_no
+ v_make_desc
+ v_color
+ plate_no
+ actual_in
+ scheduled_completion
+ scheduled_delivery
+ ins_co_nm
+ clm_total
+ ownr_ph1
+ special_coverage_policy
+ production_vars
+ labhrs
+ larhrs
+ }
+ }
+`;
+
export const GET_JOB_BY_PK = gql`
query GET_JOB_BY_PK($id: uuid!) {
jobs_by_pk(id: $id) {
diff --git a/client/src/pages/production-list/production-list.component.jsx b/client/src/pages/production-list/production-list.component.jsx
index dd9b43737..161c02891 100644
--- a/client/src/pages/production-list/production-list.component.jsx
+++ b/client/src/pages/production-list/production-list.component.jsx
@@ -1,12 +1,6 @@
import React from "react";
-import ProductionListColumns from "../../components/production-list-columns/production-list-columns.component";
import ProductionListTable from "../../components/production-list-table/production-list-table.container";
export default function ProductionListComponent({ columnState }) {
- return (
-
- );
+ return
;
}
diff --git a/client/src/translations/en_us/common.json b/client/src/translations/en_us/common.json
index 6ad894fc3..89ba35c18 100644
--- a/client/src/translations/en_us/common.json
+++ b/client/src/translations/en_us/common.json
@@ -528,7 +528,6 @@
"audit": "Audit Trail",
"availablenew": "Available New Jobs",
"availablesupplements": "Available Supplements",
- "bodyhours": "Body Hrs",
"cards": {
"appraiser": "Appraiser",
"customer": "Customer Information",
@@ -566,7 +565,6 @@
"ratetotals": {
"lab": "Body Total"
},
- "refinishhours": "Refinish Hrs",
"vehicle_info": "Vehicle"
},
"successes": {
@@ -722,20 +720,24 @@
},
"production": {
"actions": {
+ "addcolumns": "Add Columns",
"bodypriority-clear": "Clear Body Priority",
"bodypriority-set": "Set Body Priority",
"paintpriority-clear": "Clear Paint Priority",
"paintpriority-set": "Set Paint Priority",
+ "removecolumn": "Remove Column",
"saveconfig": "Save Configuration"
},
"labels": {
"alert": "Alert",
"alertoff": "Remove alert from job",
"alerton": "Add alert to job",
+ "bodyhours": "B",
"bodypriority": "B/P",
"cycletime": "C/T",
"note": "Production Note",
- "paintpriority": "P/P"
+ "paintpriority": "P/P",
+ "refinishhours": "R"
}
},
"profile": {
diff --git a/client/src/translations/es/common.json b/client/src/translations/es/common.json
index 09c47fcbc..131efa2af 100644
--- a/client/src/translations/es/common.json
+++ b/client/src/translations/es/common.json
@@ -528,7 +528,6 @@
"audit": "",
"availablenew": "",
"availablesupplements": "",
- "bodyhours": "",
"cards": {
"appraiser": "Tasador",
"customer": "Información al cliente",
@@ -566,7 +565,6 @@
"ratetotals": {
"lab": ""
},
- "refinishhours": "",
"vehicle_info": "Vehículo"
},
"successes": {
@@ -722,20 +720,24 @@
},
"production": {
"actions": {
+ "addcolumns": "",
"bodypriority-clear": "",
"bodypriority-set": "",
"paintpriority-clear": "",
"paintpriority-set": "",
+ "removecolumn": "",
"saveconfig": ""
},
"labels": {
"alert": "",
"alertoff": "",
"alerton": "",
+ "bodyhours": "",
"bodypriority": "",
"cycletime": "",
"note": "",
- "paintpriority": ""
+ "paintpriority": "",
+ "refinishhours": ""
}
},
"profile": {
diff --git a/client/src/translations/fr/common.json b/client/src/translations/fr/common.json
index abd197d87..79dacbb1a 100644
--- a/client/src/translations/fr/common.json
+++ b/client/src/translations/fr/common.json
@@ -528,7 +528,6 @@
"audit": "",
"availablenew": "",
"availablesupplements": "",
- "bodyhours": "",
"cards": {
"appraiser": "Expert",
"customer": "Informations client",
@@ -566,7 +565,6 @@
"ratetotals": {
"lab": ""
},
- "refinishhours": "",
"vehicle_info": "Véhicule"
},
"successes": {
@@ -722,20 +720,24 @@
},
"production": {
"actions": {
+ "addcolumns": "",
"bodypriority-clear": "",
"bodypriority-set": "",
"paintpriority-clear": "",
"paintpriority-set": "",
+ "removecolumn": "",
"saveconfig": ""
},
"labels": {
"alert": "",
"alertoff": "",
"alerton": "",
+ "bodyhours": "",
"bodypriority": "",
"cycletime": "",
"note": "",
- "paintpriority": ""
+ "paintpriority": "",
+ "refinishhours": ""
}
},
"profile": {