mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2026-09-20 14:27:42 +00:00
Refactor activity names to use an enum instead of a string to avoid typos #147
This commit is contained in:
+2
-2
@@ -1,6 +1,6 @@
|
||||
from dataclasses import dataclass, field
|
||||
|
||||
from core.enums import ActivityRefType, ActivityType
|
||||
from core.enums import ActivityName, ActivityRefType, ActivityType
|
||||
|
||||
|
||||
@dataclass
|
||||
@@ -15,7 +15,7 @@ class Activity:
|
||||
match what references (such as parks and summits) look like for that programme."""
|
||||
|
||||
# Activity name as used in the UI and API, e.g. "Towers"
|
||||
name: str
|
||||
name: ActivityName
|
||||
# Description, e.g. "Towers on the Air"
|
||||
description: str
|
||||
# Type, either Worldwide, Regional or Event. Used for sorting in the web UI.
|
||||
|
||||
Reference in New Issue
Block a user