For the complete documentation index, see llms.txt. This page is also available as Markdown.

Build an opportunity pipeline board with column totals

Build an opportunity board grouped by stage in a screen flow, with the total and average deal amount at the top of every column.

A sales manager reviews the quarter's deals every Monday. She wants the quarter's opportunities on one screen, one column per stage, and the value in each stage without opening a report. This board groups the cards by Stage, puts a total and an average amount in each column header, and lays the stages out left to right as a path.

Opportunity Kanban in a screen flow, stages along a path, each column headed by a total and an average amount
This quarter's opportunities by stage, with a total and an average per column

Before you start

  • The Avonni Flow Screen Components package is installed and you have its permission set.

  • You have a screen flow open in Flow Builder. The board needs no flow variable: it reads the opportunities itself.

Steps

1

Add the Kanban to a screen

Open a Screen element, drag the Avonni Kanban onto it and click it to open its property editor. Keep the Kanban alone on this screen: a board needs the full width.

2

Query the quarter's opportunities

In the Properties tab, set Data Source to Query and choose the object Opportunity.

Under Filters, click Add Condition: Close Date Equals THIS_FISCAL_QUARTER. The board rolls over to the next quarter on its own, with no edit to the flow.

The Kanban offers Variable and Query only. Query is the better fit for a board: it reads live records each time the screen loads, and the column totals cover every matching opportunity. Query or Variable compares the two.

3

Group the cards by stage

In Data Mappings:

  • Key Field: keep the default, the record Id (shown as Id in the property editor). The board uses it to know which record a card is, so it must be unique.

  • Group Field Name: Stage. On Opportunity the builder fills it in for you.

Each picklist value of Stage becomes a column, in the order set on the field in Setup, including stages that hold no deal yet.

Kanban Data Mappings in the Flow property editor with Key Field, Group Field Name set to Stage and two Group Summaries on Amount
Group Field Name sets the columns, Group Summaries the totals in their headers
4

Choose what each card shows

Still in Data Mappings, open Card:

  • Title: Opportunity Name.

  • Due Date: Close Date.

  • Fields: Amount, then the owner name. The field list opens related objects: expand the Owner to pick its name field.

Under Card Fields Layout, Variant defaults to Label Hidden. Switch it to Label Inline if your reps need to read "Amount" next to the number.

5

Add a total and an average to every column

In Data Mappings, add two entries to Group Summaries:

Setting
First entry
Second entry

Field

Amount

Amount

Aggregate Function

Sum

Average

Prefix

Total

Avg

Display As

Currency

Currency

Under Type Attributes, set Currency Code to your org's currency, for example USD.

Totals count every opportunity that matches the query, including cards not loaded on screen. The property editor preview totals only the sample records it shows, so expect different numbers there.

6

Switch to the Path variant

In the Properties tab, set Variant to Path. The stage names now run along the top as a chevron path, the same shape reps know from the opportunity record page, so the board reads from Prospecting to Closed Won. Base shows each stage as a separate column title, which suits a board whose columns have no natural order, such as Cases by type.

Turn on Show Item Count to add the number of deals beside each stage name. To change the path color, use Path Background Color under Column Header in the Style tab.

7

Keep the stages in pipeline order

Leave Column Order Direction > Direction on Default: the columns follow the order of the Stage picklist. Ascending Order and Descending Order sort the columns by name, which would put Closed Lost before Prospecting. To hide a stage or set your own order, see Filter, search and order a board.

8

Save and test

Save and run the flow. You should see:

  • ten stage columns, from Prospecting to Closed Lost, with this quarter's opportunities as cards;

  • a path along the top with the deal count beside each stage;

  • Total and Avg amounts in each column header.

Cards can be dragged to another stage, and the Kanban saves the new stage on the record. To refuse a move or react to it, follow Move a deal and save it safely. For a board people can look at but not change, turn on Read Only.

Troubleshooting

The column totals do not appear

Check that each Group Summaries entry has a Field: it is required. If the field is set and the headers still show no total at runtime, the totals query failed, and the Kanban hides the totals when that happens. Remove the entries one by one to find the field that breaks it.

The numbers in the preview differ from the running flow

Expected. The property editor preview shows sample records and totals them. The running flow applies your query filters and totals every matching opportunity.

The stages are in alphabetical order

Column Order Direction > Direction is on Ascending Order or Descending Order. Set it back to Default to follow the picklist order.

Last updated

Was this helpful?