diff --git a/CHANGELOG.md b/CHANGELOG.md index b8d5f99..50a47ab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,11 @@ The application version is maintained in `package.json` and displayed in the adm No changes recorded yet. +## 1.84.1 + +- **House of RC:** a driver you added to the race by hand who later enters on House of RC is now linked to that entry by **đ Fetch changes from House of RC** ("Already racing â linked to the entry"), so their results are sent too. Before, they were skipped and their results never reached House of RC. +- **Race wizard:** the field *Qualifying rounds* had the help text for the heat length ("Length of each qualifying heat in minutes"). It now says how many rounds are made; the length comes from the format and is changed under Manage â Format. + ## 1.84.0 - **Create finals from Race Day:** when the last qualifying heat of a race has run (or its practice, when the finals are seeded from practice) and it has no finals yet, Race Day shows **đ All qualifying run â create finals** next to the heat controls. It does the same as Manage â Format â Create finals from qualifying and takes you to the first final. diff --git a/package-lock.json b/package-lock.json index ab760a6..4bfbedb 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "rc-racecore", - "version": "1.84.0", + "version": "1.84.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "rc-racecore", - "version": "1.84.0", + "version": "1.84.1", "hasInstallScript": true, "dependencies": { "better-sqlite3": "^12.11.1", diff --git a/package.json b/package.json index afe6f33..d81d222 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "rc-racecore", - "version": "1.84.0", + "version": "1.84.1", "private": true, "description": "RC RaceCore live timing and race control with AMMC ingest and SQLite persistence", "engines": { diff --git a/src/app.js b/src/app.js index 9297af1..f621bdc 100644 --- a/src/app.js +++ b/src/app.js @@ -2222,6 +2222,7 @@ const TRANSLATIONS = { "houseofrc.entries_class": "Klass hos oss", "houseofrc.entries_hor_class": "Klass pĂ„ House of RC", "houseofrc.refresh_button": "HĂ€mta Ă€ndringar frĂ„n House of RC", + "houseofrc.refresh_link_only": "Kör redan â kopplas till anmĂ€lan", "houseofrc.results_button": "Skicka resultat till House of RC", "houseofrc.results_hint": "Förhandsgranska och skicka resultatet till {name}", "houseofrc.results_title": "Skicka resultat till House of RC", @@ -2336,6 +2337,7 @@ const TRANSLATIONS = { "events.qualifying_scoring_best": "BĂ€sta runda / rank", "events.qualifying_rounds": "Antal kvalrundor", "events.qualifying_rounds_hint": "Hur mĂ„nga kvalomgĂ„ngar som ska skapas totalt.", + "events.wizard_use_qualifying_hint": "Kvalet ger placeringen in i finalerna. LĂ€ngd och startsĂ€tt kommer frĂ„n formatet och kan Ă€ndras i Hantera â Format.", "events.cars_per_heat": "Förare per kvalheat", "events.cars_per_heat_hint": "Hur mĂ„nga förare som placeras i varje kvalheat.", "events.qual_duration": "Kvaltid (min)", @@ -4463,6 +4465,7 @@ const TRANSLATIONS = { "houseofrc.entries_class": "Our class", "houseofrc.entries_hor_class": "Class on House of RC", "houseofrc.refresh_button": "Fetch changes from House of RC", + "houseofrc.refresh_link_only": "Already racing â linked to the entry", "houseofrc.results_button": "Send results to House of RC", "houseofrc.results_hint": "Preview and send the results to {name}", "houseofrc.results_title": "Send results to House of RC", @@ -4577,6 +4580,7 @@ const TRANSLATIONS = { "events.qualifying_scoring_best": "Best round / rank", "events.qualifying_rounds": "Qualifying rounds", "events.qualifying_rounds_hint": "How many qualifying rounds should be generated in total.", + "events.wizard_use_qualifying_hint": "Qualifying decides who goes into which final. Length and start mode come from the format and can be changed in Manage â Format.", "events.cars_per_heat": "Drivers per qualifying heat", "events.cars_per_heat_hint": "How many drivers go into each qualifying heat.", "events.qual_duration": "Qualifying duration (min)", diff --git a/src/houseofrc_logic.js b/src/houseofrc_logic.js index 5674513..44a3e0c 100644 --- a/src/houseofrc_logic.js +++ b/src/houseofrc_logic.js @@ -141,7 +141,7 @@ export function rememberHouseOfRcClass(classes = [], classId = "", name = "") { // Re-fetch for a race made from House of RC: which entries of its class are new, and which of // our participants' entries are gone (withdrawn or moved to the waiting list - the server -// leaves those out). Participants added by hand (no entry id) are never touched. +// leaves those out). Participants added by hand (no entry id) are never taken out. export function diffHouseOfRcEntries(event, entries = [], drivers = []) { const link = event?.houseOfRc || {}; const entryIds = link.entryIds || {}; @@ -149,7 +149,10 @@ export function diffHouseOfRcEntries(event, entries = [], drivers = []) { const classEntries = entries.filter((entry) => link.classId == null || entry.classId === link.classId); const known = new Set(Object.entries(entryIds).filter(([driverId]) => participants.has(driverId)).map(([, entryId]) => entryId)); const plan = planHouseOfRcEntries(classEntries, drivers, event?.classId || ""); - const added = plan.filter((row) => !known.has(row.entry.entryId) && !(row.driverId && participants.has(row.driverId) && entryIds[row.driverId] == null)); + // A participant added by hand who has now entered on House of RC is linked to the entry + // (linkOnly: already racing, so only the entry id is recorded, for the results). + const added = plan.filter((row) => !known.has(row.entry.entryId)) + .map((row) => (row.driverId && participants.has(row.driverId) ? { ...row, linkOnly: true } : row)); const current = new Set(classEntries.map((entry) => entry.entryId)); const withdrawn = Object.entries(entryIds) .filter(([driverId, entryId]) => participants.has(driverId) && !current.has(entryId)) diff --git a/src/houseofrc_view.js b/src/houseofrc_view.js index 18bd013..233570d 100644 --- a/src/houseofrc_view.js +++ b/src/houseofrc_view.js @@ -330,7 +330,7 @@ export async function openHouseOfRcEntryRefresh({ event, state, t, escapeHtml, m
| ${escapeHtml(row.entry.name)} | ${escapeHtml(row.entry.club || "â")} | ${escapeHtml(row.entry.car || "â")} | ${escapeHtml(row.transponder || "â")} | -${escapeHtml(t(`houseofrc.entry_${row.status}`))} | +${escapeHtml(t(row.linkOnly ? "houseofrc.refresh_link_only" : `houseofrc.entry_${row.status}`))} |