# ListStorageLocations

## Overview

ListStorageLocations lists storage locations filtered by site or status. Results are ordered by name ascending.

## Business Rules

- Accepts optional filters (at least one required):
  - `siteId` — filter by site
  - `status` — filter by location status (e.g., Active, Inactive)
- Returns StorageLocation records **without** nested stock levels
- Results are ordered by `name` ascending
- Returns an empty list if no matching records exist

## Process Flow

```mermaid
flowchart TD
    A[Receive filter criteria] --> B{At least one filter provided?}
    B -->|No| C[Return error: NO_FILTER_PROVIDED]
    B -->|Yes| D[Build query from provided filters]
    D --> E[Apply siteId, status filters as provided]
    E --> F[Order by name ascending]
    F --> G{Records found?}
    G -->|Yes| H[Return list of StorageLocation records]
    G -->|No| I[Return empty list]
```

## External Dependencies

- None

## Error Scenarios

- **NO_FILTER_PROVIDED**: At least one filter must be specified
- Returns empty list if no matching records exist

## Test Cases

- lists storage locations by site
- lists storage locations by status
- returns empty list when no matches
- returns error when no filter is provided
