Template:ProductTable/ProductLine
Template:ProductTable/ProductLine[edit source]
Sortable product table header for Product Line pages. Provides the column header row only — all data rows are written directly into the page wikitext by the generation script. Omits the Product Line column since the page context already establishes it.
Called inside a wikitable opened and closed on the page:
{| class="wikitable sortable"
{{ProductTable/ProductLine|line=Legacy}}
|}
Columns[edit source]
| Column | Links To | Notes |
|---|---|---|
| Item # | Individual product page | Sorted by default (ascending) |
| Name | Individual product page | Full catalog product name |
| Road Name | Road Name category page | |
| Category | Loco Category page | Steam / Diesel / Electric / Other |
| Loco Type | Loco Type category page | |
| Year | Catalog Year page | Displayed as linked badge |
Omitted Columns[edit source]
- Product Line — redundant, established by page context
- Volume — less relevant here than on Catalog Year pages; can be added if needed
JavaScript Filter Controls[edit source]
When MediaWiki:Common.js contains the RailRosterDB product table script, three filter controls render above the table automatically:
- Text filter — searches Item #, Name, Road Name, and Loco Type
- Category dropdown — only values present in this line's data
- Year dropdown — only years present in this line's data
- Road Name dropdown — only road names present in this line's data
All dropdowns are dynamic — populated from actual data, not a fixed global list. Native MediaWiki sortable column headers remain functional without JavaScript.
Color Reference[edit source]
| Element | Hex |
|---|---|
| Header background | #1E2B7A |
| Header text | #ffffff |
| Alternating rows (even) | #D0D5F0 |
| Alternating rows (odd) | #ffffff |