Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
type=ref,event=branch

- name: Build and push Docker image (amd64 only)
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
context: .
file: ./Dockerfile
Expand Down Expand Up @@ -89,7 +89,7 @@ jobs:
type=raw,value=latest

- name: Build and push Docker image (multi-arch)
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
context: .
file: ./Dockerfile
Expand Down
24 changes: 12 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,21 @@
},
"devDependencies": {
"@eslint/js": "^9.39.2",
"@internationalized/date": "^3.10.0",
"@lucide/svelte": "^0.544.0",
"@internationalized/date": "^3.10.1",
"@lucide/svelte": "^0.562.0",
"@sveltejs/adapter-node": "^5.4.0",
"@sveltejs/kit": "^2.49.2",
"@sveltejs/vite-plugin-svelte": "^6.2.1",
"@tailwindcss/forms": "^0.5.10",
"@tailwindcss/forms": "^0.5.11",
"@tailwindcss/typography": "^0.5.19",
"@tailwindcss/vite": "^4.1.18",
"@tanstack/table-core": "^8.21.3",
"@testing-library/svelte": "^5.2.9",
"@types/node": "^25.0.1",
"@types/node": "^25.0.3",
"@types/supertest": "^6.0.3",
"@typescript-eslint/eslint-plugin": "^8.49.0",
"@typescript-eslint/parser": "^8.49.0",
"@vitest/coverage-v8": "^4.0.15",
"@typescript-eslint/eslint-plugin": "^8.50.0",
"@typescript-eslint/parser": "^8.50.0",
"@vitest/coverage-v8": "^4.0.16",
"bits-ui": "^2.14.4",
"clsx": "^2.1.1",
"concurrently": "^9.2.1",
Expand All @@ -57,23 +57,23 @@
"jsdom": "^27.3.0",
"layerchart": "2.0.0-next.27",
"prettier": "^3.7.4",
"prettier-plugin-svelte": "^3.4.0",
"prettier-plugin-svelte": "^3.4.1",
"prettier-plugin-tailwindcss": "^0.7.2",
"supertest": "^7.1.4",
"svelte": "^5.46.0",
"svelte-awesome-color-picker": "^4.1.0",
"svelte-check": "^4.3.4",
"svelte-eslint-parser": "^1.4.1",
"svelte-sonner": "^1.0.7",
"sveltekit-superforms": "^2.28.1",
"sveltekit-superforms": "^2.29.1",
"tailwind-merge": "^3.4.0",
"tailwind-variants": "^3.2.2",
"tailwindcss": "^4.1.18",
"tsx": "^4.21.0",
"tw-animate-css": "^1.4.0",
"typescript": "^5.9.3",
"vite": "^7.2.7",
"vitest": "^4.0.15"
"vite": "^7.3.0",
"vitest": "^4.0.16"
},
"dependencies": {
"@faker-js/faker": "^10.1.0",
Expand All @@ -97,6 +97,6 @@
"mode-watcher": "^1.1.0",
"multer": "^2.0.2",
"winston": "^3.19.0",
"zod": "^4.1.13"
"zod": "^4.2.1"
}
}
501 changes: 231 additions & 270 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/lib/components/feature/fuel/FuelLogTab.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<TabContainer
title="Fuel Logs"
addAction={() => sheetStore.openSheet(FuelLogForm, 'Add Fuel Log', '', vehicleStore.selectedId)}
addAction={() => sheetStore.openSheet(FuelLogForm, 'Add Fuel Log', '')}
addActionDisabled={!vehicleStore.selectedId}
>
<FuelLogList />
Expand Down
4 changes: 1 addition & 3 deletions src/lib/components/feature/insurance/InsuranceTab.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@
<TabContainer
title="Insurance Details"
addAction={() => {
sheetStore.openSheet(InsuranceForm, 'Add Insurance', '', {
vehicleId: vehicleStore.selectedId
});
sheetStore.openSheet(InsuranceForm, 'Add Insurance', '');
}}
addActionDisabled={!vehicleStore.selectedId}
>
Expand Down
4 changes: 4 additions & 0 deletions src/lib/components/feature/maintenance/MaintenanceForm.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@
}
processing = false;
});
} else {
toast.error(
'Please fix the errors in the form before submitting.' + JSON.stringify(f.errors)
);
}
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@
<TabContainer
title="Maintenance History"
addAction={() => {
sheetStore.openSheet(MaintenanceForm, 'Add Maintenance Log', '', {
vehicleId: vehicleStore.selectedId
});
sheetStore.openSheet(MaintenanceForm, 'Add Maintenance Log', '');
}}
addActionDisabled={!vehicleStore.selectedId}
>
Expand Down
4 changes: 1 addition & 3 deletions src/lib/components/feature/pollution/PollutionTab.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@
<TabContainer
title={'Pollution Certificate Details'}
addAction={() => {
sheetStore.openSheet(PollutionCertificateForm, 'Add Pollution Certificate', '', {
vehicleId: vehicleStore.selectedId
});
sheetStore.openSheet(PollutionCertificateForm, 'Add Pollution Certificate', '');
}}
addActionDisabled={!vehicleStore.selectedId}
>
Expand Down
2 changes: 1 addition & 1 deletion src/lib/helper/format.helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const formatDate = (date: Date | string): string => {
try {
return formatInTimeZone(dateObj, configs.timezone, configs.dateFormat);
} catch (e) {
return date.toString();
return '';
}
};

Expand Down
4 changes: 2 additions & 2 deletions src/routes/api/vehicles/[id]/maintenance-logs/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ export const POST: RequestHandler = async (event) => {
const body = event.locals.requestBody || (await event.request.json());

// Basic validation for maintenance log data
if (!body.type || !body.description || !body.date) {
throw error(400, 'Type, description, and date are required');
if (!body.odometer || !body.serviceCenter || !body.date || !body.cost) {
throw error(400, 'Odometer, serviceCenter, date, and cost are required');
}

// Validate date
Expand Down
Loading