SubmissionsReader
Corex\Config\Data\SubmissionsReader · interface · Config layer
Reads stored form submissions for the Data screen. Split from SubmissionsSource so the row-shaping is unit-testable with a stub while the WP_Query/meta access stays at the boundary (WpSubmissionsReader).
Public API
Section titled “Public API”page(int $page, int $perPage): array
Section titled “page(int $page, int $perPage): array”total(): int
Section titled “total(): int”query(DataQuery $query): array
Section titled “query(DataQuery $query): array”The records matching a query (search / form filter / sort / pagination), spec 045.
count(DataQuery $query): int
Section titled “count(DataQuery $query): int”The total records matching a query (for pagination).
find(int $id): ?array
Section titled “find(int $id): ?array”One record by id, or null if absent.
fieldKeys(int $sample): array
Section titled “fieldKeys(int $sample): array”The distinct submitted field keys seen across a sample of recent submissions — the basis for the derived schema. Order is first-seen.
dailyCounts(int $days): array
Section titled “dailyCounts(int $days): array”Real submission counts keyed by Y-m-d for the last $days days (sparse — only days that have submissions appear; the caller zero-fills the rest).