mirror of
https://github.com/Hestia-Homes/assessment-model.git
synced 2026-06-30 12:55:02 +00:00
adding measures button
This commit is contained in:
parent
727728d40c
commit
58834324e1
1 changed files with 36 additions and 17 deletions
|
|
@ -145,12 +145,42 @@ export function ReportingClientArea({
|
|||
|
||||
return (
|
||||
<>
|
||||
<ScenarioSelectorWrapper
|
||||
scenarios={scenarios}
|
||||
portfolioId={portfolioId}
|
||||
selectedScenarioId={selectedScenarioId}
|
||||
setSelectedScenarioId={setSelectedScenarioId}
|
||||
/>
|
||||
<div className="flex items-center justify-between gap-4">
|
||||
{/* LEFT: Scenario selector */}
|
||||
<ScenarioSelectorWrapper
|
||||
scenarios={scenarios}
|
||||
portfolioId={portfolioId}
|
||||
selectedScenarioId={selectedScenarioId}
|
||||
setSelectedScenarioId={setSelectedScenarioId}
|
||||
/>
|
||||
|
||||
{/* RIGHT: Actions (only when scenario selected) */}
|
||||
{selectedScenarioId && (
|
||||
<div className="flex items-center gap-2">
|
||||
<button
|
||||
onClick={() => {
|
||||
// placeholder – wire this up to your measures UI
|
||||
console.log("Show measures for scenario", selectedScenarioId);
|
||||
}}
|
||||
className="rounded-md border px-3 py-2 text-sm font-medium hover:bg-hoverblue bg-brandblue text-gray-100"
|
||||
>
|
||||
Show measures
|
||||
</button>
|
||||
|
||||
<button
|
||||
onClick={() => {
|
||||
window.open(
|
||||
`/portfolio/${portfolioId}/reporting/pdf?scenarioId=${selectedScenarioId}`,
|
||||
"_blank"
|
||||
);
|
||||
}}
|
||||
className="rounded-md border px-3 py-2 text-sm font-medium hover:bg-gray-50"
|
||||
>
|
||||
Download PDF
|
||||
</button>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* LOADING + ERROR STATES */}
|
||||
{isLoading && selectedScenarioId && (
|
||||
|
|
@ -161,17 +191,6 @@ export function ReportingClientArea({
|
|||
Could not load scenario data.
|
||||
</div>
|
||||
)}
|
||||
<button
|
||||
onClick={() => {
|
||||
window.open(
|
||||
`/portfolio/${portfolioId}/reporting/pdf?scenarioId=${selectedScenarioId}`,
|
||||
"_blank"
|
||||
);
|
||||
}}
|
||||
className="rounded-md border px-3 py-2 text-sm font-medium hover:bg-gray-50"
|
||||
>
|
||||
Download PDF
|
||||
</button>
|
||||
|
||||
{/* --- RETROFIT SECTION --- */}
|
||||
<SectionDivider
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue