feat(dashboard): add price dashboard with Zonneplan integration

This commit is contained in:
2026-08-01 19:53:18 +02:00
parent 49919fef32
commit 1cd905ca4a
29 changed files with 1701 additions and 28 deletions
+19
View File
@@ -1,4 +1,5 @@
import { createInertiaApp } from '@inertiajs/vue3';
import { DefineComponent } from 'vue';
const appName = import.meta.env.VITE_APP_NAME || 'Laravel';
@@ -7,4 +8,22 @@ createInertiaApp({
progress: {
color: '#4B5563',
},
resolve(name) {
const pages = import.meta.glob<DefineComponent>(
['./features/*/pages/*.vue', './pages/*.vue'],
{
eager: true,
},
);
if (name.includes('::')) {
const n = name.split('::');
const domain = n[0];
const page = n[1][0].toUpperCase() + n[1].slice(1).toLowerCase();
return pages[`./features/${domain}/pages/${page}.vue`];
}
return pages[`./pages/${name}.vue`];
},
});
@@ -0,0 +1,3 @@
<script setup lang="ts"></script>
<template></template>
@@ -0,0 +1,3 @@
export default function DashboardViewModel() {
return {};
}
+35
View File
@@ -0,0 +1,35 @@
declare namespace App {
namespace Features {
namespace Dashboard {
namespace DTO {
export type DashboardData = {
electricity: App.Features.Dashboard.DTO.ElectricityData;
gas: App.Features.Dashboard.DTO.GasData;
};
export type ElectricityData = {
startDate: string;
endDate: string;
period: string;
marketPrice: number | null;
totalPriceTaxIncluded: number | null;
priceInclHandlingVat: number | null;
priceTaxWithVat: number | null;
pricingProfile: string | null;
carbonFootprintInGram: number | null;
sustainabilityScore: number | null;
startDateDatetime: string;
};
export type GasData = {
startDate: string;
endDate: string;
period: string;
marketPrice: number;
totalPriceTaxIncluded: number;
priceInclHandlingVat: number;
priceTaxWithVat: number;
startDateDatetime: string;
};
}
}
}
}
@@ -0,0 +1,3 @@
{
"generated.d.ts": "237c6a8a14bec8d9c63d81a00b842cf6"
}