> ## Documentation Index
> Fetch the complete documentation index at: https://docs.younegotiate.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Dashboard

> EcoMail Hub users review notice responses by operational status bucket.

## Real-World Example

Maya starts her day on the Dashboard. She opens Pending/Delivery first to see responses that still need creditor matching or delivery work, then checks Delivered/Pending, Completed/Added, Return to Sender, and YN Returned.

Each dashboard tab should show the matching notice responses, allow searching/sorting, and let Maya export the current bucket when needed.

## Visual Flow

```mermaid placement="top-right" actions={true} theme={"system"}
flowchart TD
    A["User opens Dashboard"] --> B["Portal loads status bucket"]
    B --> C["User searches, sorts, or changes bucket"]
    C --> D{"Export requested?"}
    D -->|No| E["Review response list"]
    D -->|Yes| F["Generate CSV for current bucket"]
    classDef default fill:#F8FAFC,stroke:#64748B,stroke-width:1.5px,color:#0F172A;
    classDef actor fill:#E0F2FE,stroke:#0284C7,stroke-width:2px,color:#0C4A6E;
    classDef system fill:#F8FAFC,stroke:#64748B,stroke-width:1.5px,color:#0F172A;
    classDef decision fill:#FEF3C7,stroke:#D97706,stroke-width:2px,color:#78350F;
    classDef risk fill:#FEE2E2,stroke:#DC2626,stroke-width:2px,color:#7F1D1D;
    classDef outcome fill:#DCFCE7,stroke:#16A34A,stroke-width:2px,color:#14532D;
    class A actor;
    class B,C system;
    class D decision;
    class E,F outcome;
    linkStyle default stroke:#94A3B8,stroke-width:2px;
```

## Dashboard Buckets

| Bucket                  | Plain-Language Meaning                                                                     |
| ----------------------- | ------------------------------------------------------------------------------------------ |
| Pending/Delivery        | The notice response still needs delivery or matching work before the creditor can act.     |
| Delivered/Pending       | The response has reached an active creditor/member path but still needs creditor action.   |
| Completed/Added         | The response has been added or completed in the creditor-side flow.                        |
| Closed/Return to Sender | The response was returned or closed because it belongs back with the sender/creditor path. |
| Closed By YN            | YouNegotiate closed the response with an internal reason.                                  |

## Status Abbreviations

The dashboard also shows creditor member/prospect counts beside the notice-response buckets.

| Abbreviation | Full Label            | Meaning                                                           |
| ------------ | --------------------- | ----------------------------------------------------------------- |
| `AM`         | Active Member         | Active companies and profiles linked to active companies.         |
| `PM`         | Pending Member        | Non-active companies and profiles linked to non-active companies. |
| `YP`         | YouNegotiate Prospect | Unlinked creditor profiles owned by EcoMail Hub users.            |
| `CP`         | Consumer Prospect     | Unlinked creditor profiles created from consumer notices.         |

## How It Should Work

* It should show only notice responses that belong in the selected status bucket.
* It should keep search, sort, pagination, and export aligned with the selected bucket.
* It should export a CSV only when the bucket has matching responses.

## How It Should Not Work

* It should not mix completed, pending, returned, and closed responses into one unexplained list.
* It should not export an empty report as if work exists.
* It should not show notice responses that have no consumer relationship.

## Developer Notes

* Dashboard tabs are separate Livewire components backed by shared notice-response service rules.
* Dashboard member/prospect counts come from the creditor profile service, while notice-response bucket counts come from the notice-response service.
* Status bucket logic is more important than the tab label; avoid duplicating this logic casually.

## Related App Areas

* `routes/ecomailhub/index.php`
* `app/Livewire/ConsumerResponseManager/Dashboard`
* `app/Services/ConsumerResponseManager/NoticeResponseService.php`
* `app/Services/ConsumerResponseManager/CreditorProfileService.php`
* `app/Exports/ConsumerResponseManager/DashboardNoticeResponseExport.php`
