cs-models 0.0.687__py3-none-any.whl → 0.0.689__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.

@@ -25,6 +25,7 @@ class UserSavedSearchModel(Base):
25
25
  instant_notification = Column(Boolean, nullable=True)
26
26
  daily_digest = Column(Boolean, nullable=True)
27
27
  weekly_digest = Column(Boolean, nullable=True)
28
+ questions = Column(Text, nullable=True)
28
29
  updated_at = Column(
29
30
  DateTime,
30
31
  nullable=False,
@@ -16,4 +16,5 @@ class UserSavedSearchResourceSchema(Schema):
16
16
  instant_notification = fields.Boolean(allow_none=True)
17
17
  daily_digest = fields.Boolean(allow_none=True)
18
18
  weekly_digest = fields.Boolean(allow_none=True)
19
+ questions = fields.String(allow_none=True)
19
20
  updated_at = fields.DateTime(dump_only=True)
File without changes
@@ -0,0 +1,36 @@
1
+ from sqlalchemy import (
2
+ Column,
3
+ Integer,
4
+ String,
5
+ DateTime,
6
+ Boolean,
7
+ ForeignKey,
8
+ )
9
+ from datetime import datetime
10
+
11
+ from ...database import Base
12
+
13
+
14
+ class UserSavedSearchDigestModel(Base):
15
+ __tablename__ = 'user_saved_search_digests'
16
+
17
+ id = Column(Integer, primary_key=True)
18
+ user_id = Column(String(128), nullable=False, index=True)
19
+ saved_search_id = Column(
20
+ Integer,
21
+ ForeignKey('user_saved_searches.id'),
22
+ nullable=False,
23
+ )
24
+ assistant_user_query_id = Column(
25
+ Integer,
26
+ ForeignKey('assistant_user_queries.id'),
27
+ nullable=False,
28
+ )
29
+ is_deleted = Column(Boolean, nullable=True)
30
+ updated_at = Column(
31
+ DateTime,
32
+ nullable=False,
33
+ # https://stackoverflow.com/questions/58776476/why-doesnt-freezegun-work-with-sqlalchemy-default-values
34
+ default=lambda: datetime.utcnow(),
35
+ onupdate=lambda: datetime.utcnow(),
36
+ )
@@ -0,0 +1,16 @@
1
+ from marshmallow import (
2
+ Schema,
3
+ fields,
4
+ validate,
5
+ )
6
+
7
+
8
+ class WatchlistDigestResourceSchema(Schema):
9
+ not_blank = validate.Length(min=1, error="Field cannot be blank")
10
+
11
+ id = fields.Integer(dump_only=True)
12
+ user_id = fields.String(required=True, validate=not_blank)
13
+ saved_search_id = fields.Integer(required=True)
14
+ assistant_user_query_id = fields.Integer(required=True)
15
+ is_deleted = fields.Boolean(allow_none=True)
16
+ updated_at = fields.DateTime(dump_only=True)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: cs-models
3
- Version: 0.0.687
3
+ Version: 0.0.689
4
4
  Summary: MySQL db models
5
5
  Home-page: https://github.com/mindgram/cs-models
6
6
  Author: Shrey Verma
@@ -987,11 +987,14 @@ cs_models/resources/UserOrganization/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeu
987
987
  cs_models/resources/UserOrganization/models.py,sha256=CWhvuIWxQYKdFP7_54yFSy3npWyf5FKlgUms-O8V7MU,726
988
988
  cs_models/resources/UserOrganization/schemas.py,sha256=oJEzvjbnkJFsYwb00uHj_9kDvqc9G9MtfTdEDxi6_0o,332
989
989
  cs_models/resources/UserSavedSearch/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
990
- cs_models/resources/UserSavedSearch/models.py,sha256=3xqXAS-IcLQ_EV9KppG9xpdrRVSQ7md_dbj1KING4rs,1071
991
- cs_models/resources/UserSavedSearch/schemas.py,sha256=n8_F6j5vm3JX_fJokOZMRGf6TEXPdBRrUDOQjCrvWsY,686
990
+ cs_models/resources/UserSavedSearch/models.py,sha256=X-TPYNq8q1YuSDtg506aFHdHbISisiOVpwVMf2sbiN4,1115
991
+ cs_models/resources/UserSavedSearch/schemas.py,sha256=avoz-DNONjbtPtjZZYKQnp5aNCw0L8WlRPtgHxIhsco,733
992
992
  cs_models/resources/UserSavedSearchAccess/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
993
993
  cs_models/resources/UserSavedSearchAccess/models.py,sha256=mMbMvvMnKMTTfjGR0_z4o42tfUI6lylx9NWK192-77g,966
994
994
  cs_models/resources/UserSavedSearchAccess/schemas.py,sha256=p7zykn8OsYpGHhfsy5aTxYFX1IYojaFcOC7HPURhxwg,605
995
+ cs_models/resources/UserSavedSearchDigest/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
996
+ cs_models/resources/UserSavedSearchDigest/models.py,sha256=alX7owQynkde0zZO2nk3Qz8M_gmDWgbfRj4pTIZGWzA,940
997
+ cs_models/resources/UserSavedSearchDigest/schemas.py,sha256=IN4Le_mtuL1lRF99FD9UgGlz8fq6qzp_9scUbSUF9Ag,497
995
998
  cs_models/resources/UserSearchHistoryItem/__init__.py,sha256=VAR16vegIC2J7P3s7EoILHGN1WtkSwABRkxajmlmPoc,2864
996
999
  cs_models/resources/UserSearchHistoryItem/models.py,sha256=GdNZsTEett2x_gU92iPbRFpozimmFWn_p9liUtXWRTk,532
997
1000
  cs_models/resources/UserSearchHistoryItem/schemas.py,sha256=e68GcY-1KV75VWwWCGryTufWXHL09h7b48UhxieoaUQ,747
@@ -1141,7 +1144,7 @@ cs_models/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
1141
1144
  cs_models/utils/alchemy.py,sha256=fhINGFn41owJ2DLXQKXAAtLqeZ1BRzD_qU0wPK_bsGQ,1598
1142
1145
  cs_models/utils/utils.py,sha256=bY623DuzycfPQiaOQT2AxfANeWfwr5w76dBuQ813-ns,3664
1143
1146
  cs_models/utils/profiling/__init__.py,sha256=N-73vb0M92C975fxgXyBCBjCPELl8Oh21ZY_-tzDnns,569
1144
- cs_models-0.0.687.dist-info/METADATA,sha256=PXS-r915dnRugLdc3Lb52hLTT_Bu5lpkkdiXoIGOfD0,792
1145
- cs_models-0.0.687.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
1146
- cs_models-0.0.687.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
1147
- cs_models-0.0.687.dist-info/RECORD,,
1147
+ cs_models-0.0.689.dist-info/METADATA,sha256=NrNLTy2FOoM9-ZEdLOEnXSMW78hK92gFfm0wuWkSshg,792
1148
+ cs_models-0.0.689.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
1149
+ cs_models-0.0.689.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
1150
+ cs_models-0.0.689.dist-info/RECORD,,