AgentStack
SKILL verified MIT Self-run

Building Cue Rolecenters

skill-emgreppi-business-central-ai-skill-building-cue-rolecenters · by emgreppi

Builds Cue tiles and Activities CardPart pages for Business Central Role Centers, creates FlowField tables with CalcFormula counts, and implements drill-down navigation. Use when adding KPI dashboards, displaying record statistics, creating status indicators, or extending existing Role Centers with custom activity tiles.

No reviews yet
0 installs
5 views
0.0% view→install

Install

$ agentstack add skill-emgreppi-business-central-ai-skill-building-cue-rolecenters

✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

Are you the author of Building Cue Rolecenters? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Skill: AL Cue and Role Center Activities

Validation Gates

  1. After Step 1: Cue table compiles, FlowFields calculate correct counts
  2. After Step 2: Activities page displays tiles, OnDrillDown navigates correctly
  3. Final: Page extension adds part to Role Center, styles render as expected

Prerequisites: Identify source tables, filter criteria, and target Role Center (e.g., Order Processor 9006, Accountant 9027).

Architecture: Role Center Page → Activities CardPart (CueGroups) → Cue Table (FlowFields with CalcFormula counts)

Procedure

Step 1: Create Cue Table

The Cue Table contains FlowFields that calculate counts from source records.

Key patterns:

  • Single Primary Key field (Code[10])
  • FlowFields with CalcFormula = count(...)
  • Editable = false on all FlowFields
  • FieldClass = FlowField
table  "  Cue"
{
    Caption = ' Cue';
    DataClassification = CustomerContent;

    fields
    {
        field(1; "Primary Key"; Code[10])
        {
            Caption = 'Primary Key';
            DataClassification = SystemMetadata;
        }

        field(10; " "; Integer)
        {
            CalcFormula = count("" where(
                "" = const(),
                "" = const()));
            Caption = ' ';
            ToolTip = 'Number of  with status ';
            Editable = false;
            FieldClass = FlowField;
        }

        field(20; " "; Integer)
        {
            CalcFormula = count("" where(
                "" = const(),
                "" = const()));
            Caption = ' ';
            ToolTip = 'Number of  with status ';
            Editable = false;
            FieldClass = FlowField;
        }
        // Add more cue fields as needed...
    }

    keys
    {
        key(PK; "Primary Key")
        {
            Clustered = true;
        }
    }
}

Step 2: Create Activities Page (CardPart)

The Activities page displays the cue tiles and handles drill-down navigation.

Key patterns:

  • PageType = CardPart
  • RefreshOnActivate = true (updates counts when user returns to RC)
  • CueGroup for tile grouping
  • OnDrillDown triggers for navigation
  • Style property for visual emphasis
page  "  Activities"
{
    Caption = '';
    PageType = CardPart;
    RefreshOnActivate = true;
    SourceTable = "  Cue";

    layout
    {
        area(content)
        {
            cuegroup()
            {
                Caption = '';

                field(""; Rec."")
                {
                    ApplicationArea = All;
                    DrillDownPageID = "";
                    ToolTip = '';

                    trigger OnDrillDown()
                    var
                        SourceRec: Record "";
                    begin
                        SourceRec.SetRange("", );
                        SourceRec.SetRange("", );
                        Page.Run(Page::"", SourceRec);
                    end;
                }

                field(""; Rec."")
                {
                    ApplicationArea = All;
                    DrillDownPageID = "";
                    ToolTip = '';
                    Style = Attention;  // Yellow highlight

                    trigger OnDrillDown()
                    // ... similar pattern
                }

                field(""; Rec."")
                {
                    ApplicationArea = All;
                    Style = Favorable;  // Green highlight
                    // ...
                }
            }
        }
    }

    trigger OnOpenPage()
    begin
        Rec.Reset();
        if not Rec.Get() then begin
            Rec.Init();
            Rec.Insert();
        end;
    end;
}

Step 3: Extend Role Center

Add your Activities page to an existing Role Center.

Key patterns:

  • Find the correct anchor control (use F12 to explore Base App RC)
  • Use addafter or addbefore for positioning
  • Add actions to Sections and/or Creation areas
pageextension  "  Ext" extends ""
{
    layout
    {
        addafter()
        {
            part("  Activities"; "  Activities")
            {
                ApplicationArea = All;
                Caption = '';
            }
        }
    }

    actions
    {
        addlast(Sections)
        {
            group(Section)
            {
                Caption = '';
                Image = Setup;

                action()
                {
                    Caption = '';
                    ApplicationArea = All;
                    ToolTip = '';
                    RunObject = Page "";
                }
            }
        }
    }
}

Quick Reference

Cue Styles: Attention (yellow), Favorable (green), Unfavorable (red), Subordinate (gray), Ambiguous (orange)

Common Role Centers: Order Processor (9006), Accountant (9027), Business Manager (9022), Sales Manager (9005), Purchasing Agent (9007)

Best Practices: Efficient CalcFormula filters • OnDrillDown must match CalcFormula filters • Single record table (Primary Key = '') • RefreshOnActivate = true

References

See references/ folder for:

  • cue-patterns.md - Complete code examples

External Documentation

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.