cs-models 0.0.563__py3-none-any.whl → 0.0.565__py3-none-any.whl
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.
Potentially problematic release.
This version of cs-models might be problematic. Click here for more details.
- cs_models/resources/AssistantCommand/models.py +1 -0
- cs_models/resources/Digest/__init__.py +0 -0
- cs_models/resources/Digest/models.py +33 -0
- cs_models/resources/Digest/schemas.py +17 -0
- cs_models/resources/DigestNotification/__init__.py +0 -0
- cs_models/resources/DigestNotification/models.py +33 -0
- cs_models/resources/DigestNotification/schemas.py +14 -0
- {cs_models-0.0.563.dist-info → cs_models-0.0.565.dist-info}/METADATA +1 -1
- {cs_models-0.0.563.dist-info → cs_models-0.0.565.dist-info}/RECORD +11 -5
- {cs_models-0.0.563.dist-info → cs_models-0.0.565.dist-info}/WHEEL +0 -0
- {cs_models-0.0.563.dist-info → cs_models-0.0.565.dist-info}/top_level.txt +0 -0
|
File without changes
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
from datetime import datetime
|
|
2
|
+
|
|
3
|
+
from sqlalchemy import (
|
|
4
|
+
Column,
|
|
5
|
+
Integer,
|
|
6
|
+
DateTime,
|
|
7
|
+
ForeignKey,
|
|
8
|
+
String,
|
|
9
|
+
)
|
|
10
|
+
|
|
11
|
+
from ...database import Base
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DigestModel(Base):
|
|
15
|
+
__tablename__ = "digests"
|
|
16
|
+
|
|
17
|
+
id = Column(Integer, primary_key=True)
|
|
18
|
+
saved_search_id = Column(
|
|
19
|
+
Integer,
|
|
20
|
+
ForeignKey('user_saved_searches.id'),
|
|
21
|
+
nullable=False,
|
|
22
|
+
)
|
|
23
|
+
type = Column(String(128), nullable=False)
|
|
24
|
+
description = Column(String(256), nullable=False)
|
|
25
|
+
created_at = Column(DateTime, nullable=True)
|
|
26
|
+
sent_at = Column(DateTime, nullable=True)
|
|
27
|
+
updated_at = Column(
|
|
28
|
+
DateTime,
|
|
29
|
+
nullable=False,
|
|
30
|
+
# https://stackoverflow.com/questions/58776476/why-doesnt-freezegun-work-with-sqlalchemy-default-values
|
|
31
|
+
default=lambda: datetime.utcnow(),
|
|
32
|
+
onupdate=lambda: datetime.utcnow(),
|
|
33
|
+
)
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
from marshmallow import (
|
|
2
|
+
Schema,
|
|
3
|
+
fields,
|
|
4
|
+
validate,
|
|
5
|
+
)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class DigestResourceSchema(Schema):
|
|
9
|
+
not_blank = validate.Length(min=1, error='Field cannot be blank')
|
|
10
|
+
|
|
11
|
+
id = fields.Integer(dump_only=True)
|
|
12
|
+
saved_search_id = fields.Integer(required=True)
|
|
13
|
+
type = fields.String(required=True)
|
|
14
|
+
description = fields.String(required=True)
|
|
15
|
+
created_at = fields.DateTime()
|
|
16
|
+
sent_at = fields.DateTime()
|
|
17
|
+
updated_at = fields.DateTime()
|
|
File without changes
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
from datetime import datetime
|
|
2
|
+
|
|
3
|
+
from sqlalchemy import (
|
|
4
|
+
Column,
|
|
5
|
+
Integer,
|
|
6
|
+
DateTime,
|
|
7
|
+
ForeignKey,
|
|
8
|
+
)
|
|
9
|
+
|
|
10
|
+
from ...database import Base
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class DigestNotificationModel(Base):
|
|
14
|
+
__tablename__ = "digest_notifications"
|
|
15
|
+
|
|
16
|
+
id = Column(Integer, primary_key=True)
|
|
17
|
+
digest_id = Column(
|
|
18
|
+
Integer,
|
|
19
|
+
ForeignKey('digests.id'),
|
|
20
|
+
nullable=False,
|
|
21
|
+
)
|
|
22
|
+
notification_id = Column(
|
|
23
|
+
Integer,
|
|
24
|
+
ForeignKey('notifications.id'),
|
|
25
|
+
nullable=False,
|
|
26
|
+
)
|
|
27
|
+
updated_at = Column(
|
|
28
|
+
DateTime,
|
|
29
|
+
nullable=False,
|
|
30
|
+
# https://stackoverflow.com/questions/58776476/why-doesnt-freezegun-work-with-sqlalchemy-default-values
|
|
31
|
+
default=lambda: datetime.utcnow(),
|
|
32
|
+
onupdate=lambda: datetime.utcnow(),
|
|
33
|
+
)
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
from marshmallow import (
|
|
2
|
+
Schema,
|
|
3
|
+
fields,
|
|
4
|
+
validate,
|
|
5
|
+
)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class DigestNotificationResourceSchema(Schema):
|
|
9
|
+
not_blank = validate.Length(min=1, error='Field cannot be blank')
|
|
10
|
+
|
|
11
|
+
id = fields.Integer(dump_only=True)
|
|
12
|
+
digest_id = fields.Integer(required=True)
|
|
13
|
+
notification_id = fields.Integer(required=True)
|
|
14
|
+
updated_at = fields.DateTime()
|
|
@@ -21,7 +21,7 @@ cs_models/resources/Assignee/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NM
|
|
|
21
21
|
cs_models/resources/Assignee/models.py,sha256=_f0_UwzF1gbOlU0t0l-9UIi0E4vaIS5VsHeOxc698SE,617
|
|
22
22
|
cs_models/resources/Assignee/schemas.py,sha256=N4_upICR1Cd_B45LHpOly7FEwWhAB1fXUP4y60OiezE,269
|
|
23
23
|
cs_models/resources/AssistantCommand/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
24
|
-
cs_models/resources/AssistantCommand/models.py,sha256=
|
|
24
|
+
cs_models/resources/AssistantCommand/models.py,sha256=0UItcqiK9acz1s3QgqYrjpz7BrPf_QspIkixSxJA0Y8,1882
|
|
25
25
|
cs_models/resources/AssistantCommand/schemas.py,sha256=7mS-WTHwPsu8Kd_0FLgJqYwrg0qVJUp7iioWqPT1ZBE,3695
|
|
26
26
|
cs_models/resources/AssistantCommandEdge/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
27
27
|
cs_models/resources/AssistantCommandEdge/models.py,sha256=3blYNPb6zH6ewfj-VK7z77bbtvO9Ly6os4NL2vh4wIg,1372
|
|
@@ -212,6 +212,12 @@ cs_models/resources/Designation/schemas.py,sha256=CEsHYT0DX9PJq8I879aglG_JEWiUxi
|
|
|
212
212
|
cs_models/resources/DesignationOutbox/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
213
213
|
cs_models/resources/DesignationOutbox/models.py,sha256=UpJZs_JQxVr7wxMLexO-yc8Hc26-btiXZnAAuLcmT9g,919
|
|
214
214
|
cs_models/resources/DesignationOutbox/schemas.py,sha256=qMvxAvy4dcUoB1-yhUAYtCAGGvJixTfviROjI91VcC0,493
|
|
215
|
+
cs_models/resources/Digest/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
216
|
+
cs_models/resources/Digest/models.py,sha256=m95Knoddoib8MESk3txzGH1LpXwKMz3a2cr2Qe8AlE0,847
|
|
217
|
+
cs_models/resources/Digest/schemas.py,sha256=hg_DBRuZgb2CwmCiSTrWScRkq14hYJ7W3iEX9AmXosI,456
|
|
218
|
+
cs_models/resources/DigestNotification/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
219
|
+
cs_models/resources/DigestNotification/models.py,sha256=9zNVi4Hsjl_ove6aReQivP7ocJy4dxr-SUoF9XI-X90,763
|
|
220
|
+
cs_models/resources/DigestNotification/schemas.py,sha256=n7jih5IiRGRwD8fQr5UfEHb0NRJuWp7HOBGXcHEWXEs,360
|
|
215
221
|
cs_models/resources/DocEmbedding/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
216
222
|
cs_models/resources/DocEmbedding/models.py,sha256=8nkbhp2GE-sZjtg6t6ABHGpRhw5W30BSB-77VvZ8h8k,760
|
|
217
223
|
cs_models/resources/DocEmbedding/schemas.py,sha256=jaQCgkk-hj2HEaadOrRzkZqtwbuqw8bniZ-Vp85o88c,448
|
|
@@ -910,7 +916,7 @@ cs_models/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
|
910
916
|
cs_models/utils/alchemy.py,sha256=fhINGFn41owJ2DLXQKXAAtLqeZ1BRzD_qU0wPK_bsGQ,1598
|
|
911
917
|
cs_models/utils/utils.py,sha256=bY623DuzycfPQiaOQT2AxfANeWfwr5w76dBuQ813-ns,3664
|
|
912
918
|
cs_models/utils/profiling/__init__.py,sha256=N-73vb0M92C975fxgXyBCBjCPELl8Oh21ZY_-tzDnns,569
|
|
913
|
-
cs_models-0.0.
|
|
914
|
-
cs_models-0.0.
|
|
915
|
-
cs_models-0.0.
|
|
916
|
-
cs_models-0.0.
|
|
919
|
+
cs_models-0.0.565.dist-info/METADATA,sha256=cqW4m8QIE5qX_-ktMn1XSRutn-RvQlosqqCo8mpO_Oc,791
|
|
920
|
+
cs_models-0.0.565.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
|
|
921
|
+
cs_models-0.0.565.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
|
|
922
|
+
cs_models-0.0.565.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|