f3-data-models 0.5.10__tar.gz → 0.5.11__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/PKG-INFO +32 -1
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/README.md +32 -1
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/f3_data_models/models.py +4 -0
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/pyproject.toml +8 -1
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/f3_data_models/__init__.py +0 -0
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/f3_data_models/testing.py +0 -0
- {f3_data_models-0.5.10 → f3_data_models-0.5.11}/f3_data_models/utils.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: f3-data-models
|
3
|
-
Version: 0.5.
|
3
|
+
Version: 0.5.11
|
4
4
|
Summary: The data schema and models for F3 Nation applications.
|
5
5
|
License: MIT
|
6
6
|
Author: Evan Petzoldt
|
@@ -81,3 +81,34 @@ poetry run python -m http.server --directory _build/html
|
|
81
81
|
|
82
82
|
> [!TIP]
|
83
83
|
> Adding new fields as nullable (ie `Optional[]`) has the best chance of reducing breaking changes to the apps.
|
84
|
+
|
85
|
+
# Entity Overview
|
86
|
+
|
87
|
+
```mermaid
|
88
|
+
---
|
89
|
+
config:
|
90
|
+
look: handDrawn
|
91
|
+
theme: dark
|
92
|
+
---
|
93
|
+
|
94
|
+
erDiagram
|
95
|
+
USERS ||--|{ ATTENDANCE : have
|
96
|
+
ATTENDANCE }|--|| EVENT_INSTANCES: at
|
97
|
+
ATTENDANCE }|..|{ ATTENDANCE_TYPES : "are of type(s)"
|
98
|
+
EVENT_INSTANCES }|..|| EVENTS : "part of series"
|
99
|
+
EVENT_INSTANCES }|..|{ EVENT_TYPES : "with type(s)"
|
100
|
+
EVENTS }|..|{ EVENT_TYPES : "with type(s)"
|
101
|
+
EVENT_INSTANCES }|--|| ORGS : "belong to"
|
102
|
+
EVENT_INSTANCES }|..|| LOCATIONS : "at"
|
103
|
+
EVENTS }|--|| ORGS : "belong to"
|
104
|
+
EVENTS }|..|| LOCATIONS : "at"
|
105
|
+
SLACK_SPACES ||..|| ORGS : "are connected to"
|
106
|
+
USERS ||..|{ SLACK_USERS : "have one or more"
|
107
|
+
SLACK_USERS }|--|| SLACK_SPACES : "belong to"
|
108
|
+
USERS }|..|{ ACHIEVEMENTS : "earn"
|
109
|
+
USERS }|..|{ ROLES : "have"
|
110
|
+
ROLES ||..|{ PERMISSIONS : "have"
|
111
|
+
ROLES }|..|{ ORGS : "in"
|
112
|
+
USERS }|..|{ POSITIONS : "hold"
|
113
|
+
POSITIONS }|..|{ ORGS : "in"
|
114
|
+
```
|
@@ -50,4 +50,35 @@ poetry run python -m http.server --directory _build/html
|
|
50
50
|
```
|
51
51
|
|
52
52
|
> [!TIP]
|
53
|
-
> Adding new fields as nullable (ie `Optional[]`) has the best chance of reducing breaking changes to the apps.
|
53
|
+
> Adding new fields as nullable (ie `Optional[]`) has the best chance of reducing breaking changes to the apps.
|
54
|
+
|
55
|
+
# Entity Overview
|
56
|
+
|
57
|
+
```mermaid
|
58
|
+
---
|
59
|
+
config:
|
60
|
+
look: handDrawn
|
61
|
+
theme: dark
|
62
|
+
---
|
63
|
+
|
64
|
+
erDiagram
|
65
|
+
USERS ||--|{ ATTENDANCE : have
|
66
|
+
ATTENDANCE }|--|| EVENT_INSTANCES: at
|
67
|
+
ATTENDANCE }|..|{ ATTENDANCE_TYPES : "are of type(s)"
|
68
|
+
EVENT_INSTANCES }|..|| EVENTS : "part of series"
|
69
|
+
EVENT_INSTANCES }|..|{ EVENT_TYPES : "with type(s)"
|
70
|
+
EVENTS }|..|{ EVENT_TYPES : "with type(s)"
|
71
|
+
EVENT_INSTANCES }|--|| ORGS : "belong to"
|
72
|
+
EVENT_INSTANCES }|..|| LOCATIONS : "at"
|
73
|
+
EVENTS }|--|| ORGS : "belong to"
|
74
|
+
EVENTS }|..|| LOCATIONS : "at"
|
75
|
+
SLACK_SPACES ||..|| ORGS : "are connected to"
|
76
|
+
USERS ||..|{ SLACK_USERS : "have one or more"
|
77
|
+
SLACK_USERS }|--|| SLACK_SPACES : "belong to"
|
78
|
+
USERS }|..|{ ACHIEVEMENTS : "earn"
|
79
|
+
USERS }|..|{ ROLES : "have"
|
80
|
+
ROLES ||..|{ PERMISSIONS : "have"
|
81
|
+
ROLES }|..|{ ORGS : "in"
|
82
|
+
USERS }|..|{ POSITIONS : "hold"
|
83
|
+
POSITIONS }|..|{ ORGS : "in"
|
84
|
+
```
|
@@ -399,6 +399,7 @@ class Org(Base):
|
|
399
399
|
instagram (Optional[str]): The organization's Instagram handle.
|
400
400
|
last_annual_review (Optional[date]): The date of the last annual review.
|
401
401
|
meta (Optional[Dict[str, Any]]): Additional metadata for the organization.
|
402
|
+
ao_count (int): The number of AOs associated with the organization. Defaults to 0, will be updated by triggers.
|
402
403
|
created (datetime): The timestamp when the record was created.
|
403
404
|
updated (datetime): The timestamp when the record was last updated.
|
404
405
|
|
@@ -427,6 +428,7 @@ class Org(Base):
|
|
427
428
|
instagram: Mapped[Optional[str]]
|
428
429
|
last_annual_review: Mapped[Optional[date]]
|
429
430
|
meta: Mapped[Optional[Dict[str, Any]]]
|
431
|
+
ao_count: Mapped[Optional[int]] = mapped_column(Integer, default=0, nullable=True)
|
430
432
|
created: Mapped[dt_create]
|
431
433
|
updated: Mapped[dt_update]
|
432
434
|
|
@@ -471,6 +473,7 @@ class EventType(Base):
|
|
471
473
|
acronym (Optional[str]): Acronyms associated with the event type.
|
472
474
|
event_category (Event_Category): The category of the event type (first_f, second_f, third_f).
|
473
475
|
specific_org_id (Optional[int]): The ID of the specific organization.
|
476
|
+
is_active (bool): Whether the event type is active. Default is True.
|
474
477
|
created (datetime): The timestamp when the record was created.
|
475
478
|
updated (datetime): The timestamp when the record was last updated.
|
476
479
|
""" # noqa: E501
|
@@ -483,6 +486,7 @@ class EventType(Base):
|
|
483
486
|
acronym: Mapped[Optional[str]]
|
484
487
|
event_category: Mapped[Event_Category]
|
485
488
|
specific_org_id: Mapped[Optional[int]] = mapped_column(ForeignKey("orgs.id"))
|
489
|
+
is_active: Mapped[bool] = mapped_column(Boolean, default=True, nullable=False)
|
486
490
|
created: Mapped[dt_create]
|
487
491
|
updated: Mapped[dt_update]
|
488
492
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
[tool.poetry]
|
2
2
|
name = "f3-data-models"
|
3
|
-
version = "0.5.
|
3
|
+
version = "0.5.11"
|
4
4
|
description = "The data schema and models for F3 Nation applications."
|
5
5
|
authors = ["Evan Petzoldt <evan.petzoldt@protonmail.com>"]
|
6
6
|
readme = "README.md"
|
@@ -10,6 +10,9 @@ license = "MIT"
|
|
10
10
|
repository = "https://github.com/F3-Nation/f3-data-models"
|
11
11
|
documentation = "https://github.io/F3-Nation/f3-data-models"
|
12
12
|
|
13
|
+
[tool.poetry.group.dev.dependencies]
|
14
|
+
poethepoet = "^0.34.0"
|
15
|
+
|
13
16
|
[tool.ruff]
|
14
17
|
line-length = 120
|
15
18
|
|
@@ -50,6 +53,10 @@ sqlmodel = "^0.0.22"
|
|
50
53
|
alembic-postgresql-enum = "^1.6.1"
|
51
54
|
sqlalchemy-citext = "^1.8.0"
|
52
55
|
|
56
|
+
[tool.poe.tasks]
|
57
|
+
install-js = "npm install"
|
58
|
+
build-js = "npm run build"
|
59
|
+
install-mermaid-js = "npm install --save-dev @mermaid-js/mermaid-cli"
|
53
60
|
|
54
61
|
[build-system]
|
55
62
|
requires = ["poetry-core"]
|
File without changes
|
File without changes
|
File without changes
|