Class SummaryTabController
- java.lang.Object
-
- com.palmer.billingstatementgenerator.views.controllers.BaseController
-
- com.palmer.billingstatementgenerator.views.controllers.SummaryTabController
-
public class SummaryTabController extends BaseController
Controller for the Summary tab, displayed as the final tab before PDF generation. Presents a read-only overview of all selected line items grouped by category, along with calculated totals. The down payment field is editable; the grand total updates reactively as the user enters a value. Each section header and line item is clickable, navigating the user back to the corresponding data entry tab. Refreshes automatically when the tab is shown.
-
-
Field Summary
-
Fields inherited from class com.palmer.billingstatementgenerator.views.controllers.BaseController
clearButton, DOLLAR_FORMATTER, nextButton
-
-
Constructor Summary
Constructors Constructor Description SummaryTabController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javafx.scene.control.ScrollPanebuildView(java.util.function.Consumer<java.lang.Integer> onJumpToTab)Builds the summary tab view and returns it wrapped in aScrollPane.voidonShow()Refreshes the summary content when the tab becomes active.voidrefresh()Rebuilds the summary content from the currentStatementContext.-
Methods inherited from class com.palmer.billingstatementgenerator.views.controllers.BaseController
bindIntegerTextField, buildCheckBox, buildPriceField, buildPriceLabel, buildTextField, clearAll, configTextFieldForInts, configureClearButton, hasInvalidSelections, onClearButtonSet, onHide, onNextButtonSet, refreshTotal, reset, setClearButton, setNextButton, wireTextFieldToCheckBox
-
-
-
-
Method Detail
-
buildView
public javafx.scene.control.ScrollPane buildView(java.util.function.Consumer<java.lang.Integer> onJumpToTab)
Builds the summary tab view and returns it wrapped in aScrollPane.- Parameters:
onJumpToTab- aConsumeraccepting a tab index, invoked when the user clicks a clickable label to jump to that tab- Returns:
- a
ScrollPanecontaining the full summary layout
-
refresh
public void refresh()
Rebuilds the summary content from the currentStatementContext. Called on tab activation viaonShow()and after a reset.
-
onShow
public void onShow()
Refreshes the summary content when the tab becomes active.- Overrides:
onShowin classBaseController
-
-