diff --git a/.env.production b/.env.production index 313cb63..79ed23a 100644 --- a/.env.production +++ b/.env.production @@ -1,3 +1,3 @@ REACT_APP_FIREBASE_CONFIG={ "apiKey": "AIzaSyCXg148Ma82Qa7dK-2EL4sE0tJhKVnh1rY", "authDomain": "rps-prod-b53c8.firebaseapp.com", "databaseURL": "https://rps-prod-b53c8.firebaseio.com", "projectId": "rps-prod-b53c8", "storageBucket": "rps-prod-b53c8.appspot.com", "messagingSenderId": "361220226954", "appId": "1:361220226954:web:bf3a38d196e4fd8c921273", "measurementId": "G-W3BHH420EC"} -REACT_APP_GRAPHQL_ENDPOINT=https://rps.bodyshop.app/v1/graphql -REACT_APP_GRAPHQL_ENDPOINT_WS=wss://rps.bodyshop.app/v1/graphql \ No newline at end of file +REACT_APP_GRAPHQL_ENDPOINT=https://db.rps.imex.online/v1/graphql +REACT_APP_GRAPHQL_ENDPOINT_WS=wss://db.rps.imex.online/v1/graphql \ No newline at end of file diff --git a/electron/file-watcher/file-watcher.js b/electron/file-watcher/file-watcher.js index 4b3d96b..ba2522b 100644 --- a/electron/file-watcher/file-watcher.js +++ b/electron/file-watcher/file-watcher.js @@ -94,14 +94,16 @@ function onWatcherReady() { } async function StopWatcher() { - await watcher.close(); - log.info("Watcher stopped."); - const b = BrowserWindow.getAllWindows()[0]; - b.webContents.send(ipcTypes.default.fileWatcher.toRenderer.stopSuccess); - NewNotification({ - title: "RPS Watcher Stopped", - body: "Estimates will not be automatically uploaded.", - }); + if (watcher) { + await watcher.close(); + log.info("Watcher stopped."); + const b = BrowserWindow.getAllWindows()[0]; + b.webContents.send(ipcTypes.default.fileWatcher.toRenderer.stopSuccess); + NewNotification({ + title: "RPS Watcher Stopped", + body: "Estimates will not be automatically uploaded.", + }); + } } exports.StartWatcher = StartWatcher; diff --git a/hasura/migrations/1603740763642_run_sql_migration/down.yaml b/hasura/migrations/1603740763642_run_sql_migration/down.yaml new file mode 100644 index 0000000..fe51488 --- /dev/null +++ b/hasura/migrations/1603740763642_run_sql_migration/down.yaml @@ -0,0 +1 @@ +[] diff --git a/hasura/migrations/1603740763642_run_sql_migration/up.yaml b/hasura/migrations/1603740763642_run_sql_migration/up.yaml new file mode 100644 index 0000000..731c40e --- /dev/null +++ b/hasura/migrations/1603740763642_run_sql_migration/up.yaml @@ -0,0 +1,6 @@ +- args: + cascade: true + read_only: false + sql: "create trigger calculate_updated_job_line_insert\r\nbefore\r\ninsert\r\n + \ on\r\n public.joblines for each row execute function calculate_job_line();" + type: run_sql diff --git a/src/components/molecules/jobs-lines-table/jobs-lines-table.molecule.jsx b/src/components/molecules/jobs-lines-table/jobs-lines-table.molecule.jsx index 1bfc583..6aabfe4 100644 --- a/src/components/molecules/jobs-lines-table/jobs-lines-table.molecule.jsx +++ b/src/components/molecules/jobs-lines-table/jobs-lines-table.molecule.jsx @@ -154,17 +154,19 @@ export default function JobLinesTableMolecule({ loading, job }) { x: true, y: "20rem", }} - footer={() => ( -