mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-30 00:38:11 +00:00
add contracts overview tab with KPIs, recent contracts, and charts
- Introduced OverviewContractKpisDto and OverviewRecentContractDto for contract metrics. - Implemented OverviewContractsTabDto to structure the contracts tab response. - Added contract-related constants for status groupings and pipeline stages. - Created OverviewContractsTabPanel and OverviewRecentContractsTable components for UI representation. - Updated OverviewService and OverviewRepository to fetch contract data. - Integrated contracts tab into OverviewController and OverviewTabContent. - Added hooks for fetching contracts data in useOverview. - Updated types in the overview module to include contracts. - Enhanced the contract detail page with a "View contract" button for generated PDFs.
This commit is contained in:
@@ -4,6 +4,7 @@ import { URL_CONSTANTS } from "@/constants/URLS";
|
||||
import type {
|
||||
IOverviewBillingTab,
|
||||
IOverviewBookingsTab,
|
||||
IOverviewContractsTab,
|
||||
IOverviewCustomersTab,
|
||||
IOverviewDashboard,
|
||||
IOverviewOperationsTab,
|
||||
@@ -28,6 +29,13 @@ export const overviewService = {
|
||||
return unwrap(response);
|
||||
},
|
||||
|
||||
getContractsTab: async (range?: OverviewRange): Promise<IOverviewContractsTab> => {
|
||||
const response = await client.get<IOverviewContractsTab>(O.CONTRACTS, {
|
||||
params: range ? { range } : undefined,
|
||||
});
|
||||
return unwrap(response);
|
||||
},
|
||||
|
||||
getBillingTab: async (range?: OverviewRange): Promise<IOverviewBillingTab> => {
|
||||
const response = await client.get<IOverviewBillingTab>(O.BILLING, {
|
||||
params: range ? { range } : undefined,
|
||||
|
||||
Reference in New Issue
Block a user