Skip to content

Conversation

@otahirs
Copy link
Member

@otahirs otahirs commented Jan 17, 2025

this adds basic support for Nationality (country code)
the motivation is to have national flags shown on oresults.eu, as quickevent lacks those in the exports in comparison to meos or kramer

Geting nationality data

normal events

normal events gets nationality info from ORIS as the endpoint https://oris.orientacnisporty.cz/API/?format=json&method=getEventEntries&eventid=%1 contains Nationality data, even thought they need to be converted into IOC format https://github.com/international-orienteering-federation/datastandard-v3/blob/24eb108e4c6b5e2904e5f8f0e49142e45e2c5230/IOF.xsd#L4224

relay

relay endpoint for syncing entries does not have nationality data, so no automatic support there yet for importing it

Export / Import

implemented for normal/relay iof xml import and exports
xmlimporter also touched

@otahirs otahirs requested a review from fvacek January 17, 2025 18:48
#include <QMap>
#include <QString>

QMap<QString, QString> isoAlpha2ToIoc = {
Copy link
Collaborator

@arnost00 arnost00 Jan 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know, fixed list of codes in the source. How will we deal with it if there is any correction or modification of the codes?
Country names evolve over time.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suppose we dont use any packaging system in this c++ project that would handle this. Git submodule for such a small thing would be overkill. The countries participating in orienteering are hardly going to change to have a meaningful impact, but I am open to suggesting how to handle this better.

@arnost00
Copy link
Collaborator

@otahirs, do I need to go through the code for the races from Eventor?

@arnost00
Copy link
Collaborator

@otahirs, how did you write it to the database? I don't see any change in the db definition (DbSchema.qml). But from the code it seems to me that you added some columns.

@otahirs
Copy link
Member Author

otahirs commented Jan 17, 2025

should I be targeting qe3 instead of master?

@arnost00
Copy link
Collaborator

@otahirs, you need to increase the DB version in : quickevent\app\quickevent\src\application.cpp method Application::dbVersion()

@arnost00
Copy link
Collaborator

should I be targeting qe3 instead of master?

I'm still creating new features for both master and qe3

@fvacek
Copy link
Collaborator

fvacek commented Jan 19, 2025

should I be targeting qe3 instead of master?

yes please

@arnost00
Copy link
Collaborator

arnost00 commented Feb 9, 2025

But also, the import of registration from ORIS does not contain data on nationality, so manual entry to the event will also be without nationality, so we will achieve another data inconsistency.

But without expanding the api export format (registration) from ORIS, this probably can't be solved any better.

@fvacek fvacek merged commit be9e7bc into Quick-Box:master Feb 28, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants