refactor(admissions): rename published_admission_number to places_offered
Build and Push Docker Images / Build Backend (FastAPI) (push) Successful in 18s
Build and Push Docker Images / Build Frontend (Next.js) (push) Successful in 46s
Build and Push Docker Images / Build Pipeline (Meltano + dbt + Airflow) (push) Failing after 13s
Build and Push Docker Images / Trigger Portainer Update (push) Has been skipped
Build and Push Docker Images / Build Backend (FastAPI) (push) Successful in 18s
Build and Push Docker Images / Build Frontend (Next.js) (push) Successful in 46s
Build and Push Docker Images / Build Pipeline (Meltano + dbt + Airflow) (push) Failing after 13s
Build and Push Docker Images / Trigger Portainer Update (push) Has been skipped
The staging model aliased EES's total_number_places_offered column as
published_admission_number, but PAN is the school's published capacity
(not exposed by EES at school level) — what we actually have is the
count of places offered in a given admissions round. The misnomer
propagated to the mart, SQLAlchemy model, API response, TS types, and
UI copy ("places per year", "(PAN)").
Rename end-to-end and fix the UI labels:
- "29 places for 42 first-choice applications"
→ "29 places offered for 42 first-choice applications"
- "Reception/Year 7 places per year"
→ "Reception/Year 7 places offered"
- drop the misleading "(PAN)" suffix in the secondary view
Also add a comment in stg_ees_admissions clarifying this is the number
of places offered, not PAN. Requires dbt to rebuild fact_admissions
(marts are materialized as tables) before the backend can start.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -4,7 +4,7 @@ select
|
||||
urn,
|
||||
year,
|
||||
school_phase,
|
||||
published_admission_number,
|
||||
places_offered,
|
||||
total_applications,
|
||||
first_preference_applications,
|
||||
first_preference_offers,
|
||||
|
||||
@@ -18,7 +18,11 @@ renamed as (
|
||||
entry_year,
|
||||
|
||||
-- Places and offers
|
||||
{{ safe_numeric('total_number_places_offered') }}::integer as published_admission_number,
|
||||
-- places_offered: number of places the school actually offered in this
|
||||
-- year's admissions round. NOT the Published Admission Number (PAN),
|
||||
-- which is the school's published capacity — EES does not expose PAN
|
||||
-- at school level, so we use the count of offers as the best proxy.
|
||||
{{ safe_numeric('total_number_places_offered') }}::integer as places_offered,
|
||||
{{ safe_numeric('number_preferred_offers') }}::integer as total_offers,
|
||||
{{ safe_numeric('number_1st_preference_offers') }}::integer as first_preference_offers,
|
||||
{{ safe_numeric('number_2nd_preference_offers') }}::integer as second_preference_offers,
|
||||
|
||||
Reference in New Issue
Block a user