Working ANTD5 and major updates without DayJS

This commit is contained in:
Patrick Fic
2024-04-18 09:29:00 -07:00
parent e1e29f8a4d
commit 79a0881f5a
45 changed files with 5519 additions and 13202 deletions

View File

@@ -8,7 +8,7 @@ export default function DeleteAllEmsAtom() {
<Popconfirm
title="Are you sure you want to delete all EMS files? This cannot be undone."
onConfirm={() =>
ipcRenderer.send(ipcTypes.default.fileScan.toMain.deleteAllEms)
ipcRenderer.send(ipcTypes.fileScan.toMain.deleteAllEms)
}
>
<Button>Delete All EMS</Button>

View File

@@ -20,7 +20,7 @@ export function DeleteJobAtom({ setSelectedJobId, jobId }) {
const [loading, setLoading] = useState(false);
const handleDelete = async () => {
setLoading(true);
ipcRenderer.send(ipcTypes.default.app.toMain.track, {
ipcRenderer.send(ipcTypes.app.toMain.track, {
event: "DELETE_JOB",
});
const result = await deleteJob({

View File

@@ -8,7 +8,7 @@ export default function ErrorResultAtom({
errorMessage,
tryAgainCallback,
}) {
ipcRenderer.send(ipcTypes.default.app.toMain.track, {
ipcRenderer.send(ipcTypes.app.toMain.track, {
event: "ERROR_RESULT_ATOM_DISPLAYED",
title,
errorMessage,

View File

@@ -11,7 +11,7 @@ export default function IgnoreJobLineAtom({ ignore, lineId, line_desc }) {
const handleChange = async (checked) => {
console.log("handleChange -> checked", checked);
setLoading(true);
ipcRenderer.send(ipcTypes.default.app.toMain.track, {
ipcRenderer.send(ipcTypes.app.toMain.track, {
event: "TOGGLE_IGNORE_LINE",
line_desc: line_desc,
ignore: !checked,

View File

@@ -17,12 +17,12 @@ const mapDispatchToProps = (dispatch) => ({
export function NotificationsToggleAtom({ appSettings }) {
const handleChange = (val) => {
ipcRenderer.send(ipcTypes.default.app.toMain.track, {
ipcRenderer.send(ipcTypes.app.toMain.track, {
event: "TOGGLE_NOTIFICATION",
enabled: val,
});
ipcRenderer.send(ipcTypes.default.store.set, {
ipcRenderer.send(ipcTypes.store.set, {
enableNotifications: val,
});
};

View File

@@ -17,12 +17,12 @@ const mapDispatchToProps = (dispatch) => ({
export function WatcherStartupAtom({ appSettings }) {
const handleChange = (val) => {
ipcRenderer.send(ipcTypes.default.app.toMain.track, {
ipcRenderer.send(ipcTypes.app.toMain.track, {
event: "TOGGLE_WATCHER_ON_STARTUP",
enabled: val,
});
ipcRenderer.send(ipcTypes.default.store.set, {
ipcRenderer.send(ipcTypes.store.set, {
runWatcherOnStartup: val,
});
};