-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add location to team API. #2296
Add location to team API. #2296
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is small enough that we don't need DJ9
Maybe we should not change room to location?
|
You are right. I will think about what we should do |
Fixes DOMjudge#2283. Also rename room to location in database and UI to be more consistent.
753f3bd
to
e8ebbf2
Compare
@@ -854,7 +854,7 @@ public function importTeamsJson(array $data, ?string &$message = null, ?array &$ | |||
'name' => @$team['name'], | |||
'display_name' => @$team['display_name'], | |||
'publicdescription' => $team['public_description'] ?? @$team['members'], | |||
'room' => @$team['room'], | |||
'location' => @$team['location']['description'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a way how we can now just if unset pick the x,y,rot
and put it as a string?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Usually we use the seat number (such as B05) for the location
here, but x, y, rot in the ccs spec represent distance and rotation angle. I don't think they correspond well directly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can already use the description
field, so for your usecase you would put the seat number there (or would you still need more?)
I'm suggesting the situation where that field is not set and the spec is followed. During the ICPC WF we would get the information in DOMjudge without much extra effort so we know where a team would be located in case of problems.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But then if you import + export you get something else, while it would be nice if it's idempotent?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can already use the
description
field, so for your usecase you would put the seat number there (or would you still need more?)
AFAIK, the room
is formally used in built-in printing and balloon service.
Fixes #2283.
Also rename room to location in database and UI to be more consistent.