1
+ import prologue
2
+ import times
3
+
4
+ # Custom Settings
5
+ const database* = " db.sqlite3"
6
+ const DEBUG * : bool = true
7
+ const ACCESS_TOKEN_LIFETIME * : TimeInterval = hours (1 ) # 1h in seconds
8
+ const REFRESH_TOKEN_LIFETIME * : TimeInterval = days (100 ) # 100 days in seconds
9
+
10
+ # Prologue Settings
11
+ let coreSettings* : Settings = loadSettings (" ./settings.json" )
12
+
13
+ const SECRET_KEY * : string = " MyBeautifulSecretKey"
14
+ const AUTHORIZATION_HEADER * : string = " Authorization"
15
+
16
+
17
+ # Constants
18
+ const PRIMARY_DB_TIME_FORMAT * = " yyyy-MM-dd HH:mm:ss'.'ffffff" # Datetime format as Django stores it in DB
19
+ const SECONDARY_DB_TIME_FORMAT * = " yyyy-MM-dd HH:mm:ss" # Datetime format as Django sometimes stores it in DB
20
+ const OUTPUT_TIME_FORMAT * = " yyyy-MM-dd'T'HH:mm:ss'.'ffffff'Z'"
21
+
22
+ # ##TABLE NAMES
23
+ # Auth
24
+ const GROUP_TABLE * = " auth_group"
25
+ const GROUP_PERMISSION_TABLE * = " auth_group_permission"
26
+ const PERMISSION_TABLE * = " auth_permission"
27
+ const USER_TABLE * = " auth_user"
28
+ const USER_GROUP_TABLE * = " auth_user_groups"
29
+ const USER_USERPERMISSIONS_TABLE * = " auth_user_user_permissions"
30
+
31
+ const TOKEN_TABLE * = " authtoken_token"
32
+ const TOKEN_BLACKLIST_TABLE * = " token_blacklist_blacklistedtoken"
33
+ const TOKEN_OUTSTANDING_TABLE * = " token_blacklist_outstandingtoken"
34
+
35
+ # Django
36
+ const DJ_ADMIN_LOG_TABLE * = " django_admin_log"
37
+ const DJ_CONTENT_TYPE_TABLE * = " django_content_type"
38
+ const DJ_MIGRATION_TABLE * = " django_migrations"
39
+ const DJ_SESSION_TABLE * = " django_session"
40
+
41
+ const DJ_GROUPOBJECTPERMISSION * = " guardian_groupobjectpermission"
42
+ const DJ_USEROBJECTPERMISSION * = " guardian_userobjectpermission"
43
+
44
+ # Wikientries
45
+ const CAMPAIGN_TABLE * = " wikientries_campaign"
46
+ const CHARACTER_TABLE * = " wikientries_character"
47
+ const CHARACTER_PLAYERCLASS_TABLE * = " wikientries_characterplayerclassconnection"
48
+ const CREATURE_TABLE * = " wikientries_creature"
49
+ const DIARYENTRY_TABLE * = " wikientries_diaryentry"
50
+ const ENCOUNTER_TABLE * = " wikientries_encounter"
51
+ const ENCOUNTER_CHARACTER_TABLE * = " wikientries_encounterconnection"
52
+ const IMAGE_TABLE * = " wikientries_image"
53
+ const ITEM_TABLE * = " wikientries_item"
54
+ const LOCATION_TABLE * = " wikientries_location"
55
+ const ORGANIZATION_TABLE * = " wikientries_organization"
56
+ const PLAYERCLASS_TABLE * = " wikientries_playerclass"
57
+ const QUEST_TABLE * = " wikientries_quest"
58
+ const QUOTE_TABLE * = " wikientries_quote"
59
+ const QUOTE_CHARACTER_TABLE * = " wikientries_quoteconnection"
60
+ const RULES_TABLE * = " wikientries_rules"
61
+ const SESSION_TABLE * = " wikientries_session"
62
+ const SPELL_TABLE * = " wikientries_spell"
63
+ const SPELL_PLAYERCLASS_TABLE * = " wikientries_spellclassconnection"
64
+
65
+ # Fileserver
66
+ const SESSIONAUDIO_TABLE * = " fileserver_sessionaudio"
67
+ const TIMESTAMP_TABLE * = " fileserver_sessionaudiotimestamp"
68
+
69
+ # Map
70
+ const MAP_TABLE * = " map_map"
71
+ const MARKER_TABLE * = " map_marker"
72
+ const MARKERTYPE_TABLE * = " map_markertype"
73
+
74
+ # Search
75
+ const SEARCH_TABLE * = " search_article_content"
76
+ const EMPTY_SEARCH_RESPONSE_TABLE * = " wikientries_emptysearchresponse"
77
+
78
+ # Sqlite
79
+ const SQLITE_SEQUENCE_TABLE * = " sqlite_sequence"
80
+
81
+ # Views
82
+ const V_ALL_ARTICLES_TABLE * = " v_all_articles"
0 commit comments