Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Odevzdávací Systém MO
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Martin Mareš
Odevzdávací Systém MO
Commits
866602be
Commit
866602be
authored
4 years ago
by
Jiří Setnička
Browse files
Options
Downloads
Patches
Plain Diff
DB: Zavedení stavu účasti 'diskvalifikovaný'
parent
ecf66648
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
db/db.ddl
+2
-1
2 additions, 1 deletion
db/db.ddl
db/upgrade-20210131.sql
+2
-0
2 additions, 0 deletions
db/upgrade-20210131.sql
mo/db.py
+2
-0
2 additions, 0 deletions
mo/db.py
with
6 additions
and
1 deletion
db/db.ddl
+
2
−
1
View file @
866602be
...
...
@@ -124,7 +124,8 @@ CREATE TYPE part_state AS ENUM (
'invited', -- pozván
'refused', -- odmítl účast
'present', -- soutěžil
'absent' -- bez omluvy nedorazil
'absent', -- bez omluvy nedorazil
'disqualified' -- diskvalifikovaný
);
CREATE TABLE participations (
...
...
This diff is collapsed.
Click to expand it.
db/upgrade-20210131.sql
+
2
−
0
View file @
866602be
...
...
@@ -3,3 +3,5 @@ SET ROLE 'mo_osmo';
ALTER
TABLE
solutions
ADD
COLUMN
note
text
NOT
NULL
DEFAULT
''
,
-- komentář pro řešitele
ADD
COLUMN
org_note
text
NOT
NULL
DEFAULT
''
;
-- komentář viditelný jen organizátorům
ALTER
TYPE
part_state
ADD
VALUE
'disqualified'
-- diskvalifikovaný
This diff is collapsed.
Click to expand it.
mo/db.py
+
2
−
0
View file @
866602be
...
...
@@ -306,6 +306,7 @@ class PartState(MOEnum):
refused
=
auto
()
present
=
auto
()
absent
=
auto
()
disqualified
=
auto
()
def
friendly_name
(
self
)
->
str
:
return
part_state_names
[
self
]
...
...
@@ -317,6 +318,7 @@ part_state_names = {
PartState
.
refused
:
'
odmítnutý
'
,
PartState
.
present
:
'
přítomný
'
,
PartState
.
absent
:
'
nepřítomný
'
,
PartState
.
disqualified
:
'
diskvalifikovaný
'
,
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment