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

@@ -6,6 +6,7 @@ from sqlalchemy import (
6
6
  DateTime,
7
7
  UniqueConstraint,
8
8
  ForeignKey,
9
+ Boolean,
9
10
  )
10
11
  from datetime import datetime
11
12
 
@@ -53,6 +54,8 @@ class PatentModel(Base):
53
54
  espace_url = Column(String(500))
54
55
  docdb_family_id = Column(Integer)
55
56
  inpadoc_family_id = Column(Integer)
57
+ is_orange_book = Column(Boolean, nullable=True)
58
+ is_purple_book = Column(Boolean, nullable=True)
56
59
 
57
60
  updated_at = Column(
58
61
  DateTime,
@@ -45,6 +45,8 @@ class PatentResourceSchema(Schema):
45
45
  espace_url = fields.String(allow_none=True)
46
46
  docdb_family_id = fields.Integer(allow_none=True)
47
47
  inpadoc_family_id = fields.Integer(allow_none=True)
48
+ is_orange_book = fields.Boolean(allow_none=True)
49
+ is_purple_book = fields.Boolean(allow_none=True)
48
50
 
49
51
  updated_at = fields.DateTime()
50
52
 
@@ -4,6 +4,7 @@ from sqlalchemy import (
4
4
  String,
5
5
  Text,
6
6
  DateTime,
7
+ Boolean,
7
8
  UniqueConstraint,
8
9
  )
9
10
  from datetime import datetime
@@ -30,6 +31,8 @@ class PatentApplicationModel(Base):
30
31
  title = Column(String(500))
31
32
  docdb_family_id = Column(Integer, nullable=True)
32
33
  inpadoc_family_id = Column(Integer, nullable=True)
34
+ is_orange_book = Column(Boolean, nullable=True)
35
+ is_purple_book = Column(Boolean, nullable=True)
33
36
 
34
37
  updated_at = Column(
35
38
  DateTime,
@@ -27,6 +27,8 @@ class PatentApplicationResourceSchema(Schema):
27
27
  app_sub_class = fields.String(allow_none=True)
28
28
  docdb_family_id = fields.Integer(allow_none=True)
29
29
  inpadoc_family_id = fields.Integer(allow_none=True)
30
+ is_orange_book = fields.Boolean(allow_none=True)
31
+ is_purple_book = fields.Boolean(allow_none=True)
30
32
  updated_at = fields.DateTime(dump_only=True)
31
33
 
32
34
  @pre_load
File without changes
@@ -0,0 +1,30 @@
1
+ from datetime import datetime
2
+
3
+ from sqlalchemy import (
4
+ Column,
5
+ Integer,
6
+ DateTime,
7
+ String,
8
+ )
9
+
10
+ from ...database import Base
11
+
12
+
13
+ class PurpleBookPatentModel(Base):
14
+ __tablename__ = "purple_book_patents"
15
+
16
+ id = Column(Integer, primary_key=True)
17
+ bla_number = Column(String(128), nullable=False, index=True)
18
+ applicant_name = Column(String(191), nullable=False, index=True)
19
+ proprietary_name = Column(String(191), nullable=False, index=True)
20
+ proper_name = Column(String(191), nullable=False, index=True)
21
+ patent_number = Column(String(128), nullable=False, index=True)
22
+ expiration_date = Column(DateTime, nullable=True)
23
+ updated_at = Column(
24
+ DateTime,
25
+ nullable=False,
26
+ index=True,
27
+ # https://stackoverflow.com/questions/58776476/why-doesnt-freezegun-work-with-sqlalchemy-default-values
28
+ default=lambda: datetime.utcnow(),
29
+ onupdate=lambda: datetime.utcnow(),
30
+ )
@@ -0,0 +1,18 @@
1
+ from marshmallow import (
2
+ Schema,
3
+ fields,
4
+ validate,
5
+ )
6
+
7
+
8
+ class PurpleBookPatentResourceSchema(Schema):
9
+ not_blank = validate.Length(min=1, error='Field cannot be blank')
10
+
11
+ id = fields.Integer(dump_only=True)
12
+ bla_number = fields.String(required=True)
13
+ applicant_name = fields.String(required=True)
14
+ proprietary_name = fields.String(required=True)
15
+ proper_name = fields.String(required=True)
16
+ patent_number = fields.String(required=True)
17
+ expiration_date = fields.DateTime(allow_none=True)
18
+ 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.613
3
+ Version: 0.0.614
4
4
  Summary: MySQL db models
5
5
  Home-page: https://github.com/mindgram/cs-models
6
6
  Author: Shrey Verma
@@ -676,12 +676,12 @@ cs_models/resources/PartnershipOutbox/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCe
676
676
  cs_models/resources/PartnershipOutbox/models.py,sha256=qPmi1vPXFnKvQOgic9fUc74G-2E2ou8vI2pSED3xumY,1306
677
677
  cs_models/resources/PartnershipOutbox/schemas.py,sha256=TnBksGVoZCT84sT6VmKwoKxFW8k2RXSYiLaED3Bj6NI,1064
678
678
  cs_models/resources/Patent/__init__.py,sha256=2L-VuSiBinED9bucqcHENeixfazN-n4l8O5Vs02UbfY,5373
679
- cs_models/resources/Patent/models.py,sha256=UoAYNhQvV0gSXWUfo7bSgitXe2UQ2uGjLmaEEt9iggM,1991
680
- cs_models/resources/Patent/schemas.py,sha256=eeF1E_24Ojz2NdaPr1-GQniAAx-DyiqMNiXuy6A2ITE,4164
679
+ cs_models/resources/Patent/models.py,sha256=8PneFixaE-QTWJgXDcp43u3bw7XDJ6wk1wTqLjIhIuc,2108
680
+ cs_models/resources/Patent/schemas.py,sha256=-ivQYU7bezG6DOn09uUoJ2v58v-06bWpyHHYqxz8mFc,4270
681
681
  cs_models/resources/Patent/test_patent.py,sha256=Y9Hwtb-eeP3q_xZ1GGQhZVibXBDhv-a3XYKQQeM3Enw,7754
682
682
  cs_models/resources/PatentApplication/__init__.py,sha256=FSl_P3_ySv1IOqKf2kQAMzWalGeYezWqMBmImVDiaQA,4896
683
- cs_models/resources/PatentApplication/models.py,sha256=jlq6qG2dT-tFbo50asY1v3EKuM0d6vAChWnhcnxId3s,1404
684
- cs_models/resources/PatentApplication/schemas.py,sha256=WAkPlShnPVFNkaVEVNJ1Tz7-RSRhMITOtAdj9Y5MDE8,1668
683
+ cs_models/resources/PatentApplication/models.py,sha256=TD_8cbzabx-jhL9x7o3uc6Ot2HQx2COSkv1TcsBH23o,1521
684
+ cs_models/resources/PatentApplication/schemas.py,sha256=YoERip26QHjuYEUL11utHU3qGih4e1ZLnX8Cw3FaDdQ,1774
685
685
  cs_models/resources/PatentApplication/test_patent_application.py,sha256=uv51TNds23LrbKrif4SMde6qJaDmzj27QyRVKbRniYo,4604
686
686
  cs_models/resources/PatentApplicationCondition/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
687
687
  cs_models/resources/PatentApplicationCondition/models.py,sha256=weXZPsXqWr5_YcWmowrrfnghh-YXWqPaxdnE9fvXSyM,987
@@ -790,6 +790,9 @@ cs_models/resources/PubmedTarget/schemas.py,sha256=fY6t6JwzSgc95WVPXJUKJz5kYNZoL
790
790
  cs_models/resources/PubmedUpdateLedger/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
791
791
  cs_models/resources/PubmedUpdateLedger/models.py,sha256=3roSR67RZbpxo5sQ-ZSfYItHInrJaT1lMbSKr95JjOw,744
792
792
  cs_models/resources/PubmedUpdateLedger/schemas.py,sha256=rlXKvQNfcBUjcsYZtxbd6xBrAQslNHD5lfaLKpL2rvw,445
793
+ cs_models/resources/PurpleBookPatent/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
794
+ cs_models/resources/PurpleBookPatent/models.py,sha256=PJ8xqjt8_OU75YjU9E1KMzyRFoW32K9izfu7LdeXZ-o,947
795
+ cs_models/resources/PurpleBookPatent/schemas.py,sha256=x2oFaUPqXCJO0RxD-BOlaLAqFtNmZLKd1kiMo7jIXJU,573
793
796
  cs_models/resources/RegulatoryApprovalOutbox/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
794
797
  cs_models/resources/RegulatoryApprovalOutbox/models.py,sha256=TMMPIvz13fhqr7Ktv8uefX6OJwn0LktxSVarNhQjahQ,1092
795
798
  cs_models/resources/RegulatoryApprovalOutbox/schemas.py,sha256=e7k0IuQb_ch_cqRklfTOymOexYNwRmnhWuB0_h9CJW8,935
@@ -1015,7 +1018,7 @@ cs_models/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
1015
1018
  cs_models/utils/alchemy.py,sha256=fhINGFn41owJ2DLXQKXAAtLqeZ1BRzD_qU0wPK_bsGQ,1598
1016
1019
  cs_models/utils/utils.py,sha256=bY623DuzycfPQiaOQT2AxfANeWfwr5w76dBuQ813-ns,3664
1017
1020
  cs_models/utils/profiling/__init__.py,sha256=N-73vb0M92C975fxgXyBCBjCPELl8Oh21ZY_-tzDnns,569
1018
- cs_models-0.0.613.dist-info/METADATA,sha256=ywGxoWK8LfrRQgZOIPlaTyO3Z43X_f1im5C7No_pkeQ,792
1019
- cs_models-0.0.613.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
1020
- cs_models-0.0.613.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
1021
- cs_models-0.0.613.dist-info/RECORD,,
1021
+ cs_models-0.0.614.dist-info/METADATA,sha256=Tr8N1xE1JdTROjfjy0jMKKQw_uiq3Zkad4KC7ffVyDY,792
1022
+ cs_models-0.0.614.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
1023
+ cs_models-0.0.614.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
1024
+ cs_models-0.0.614.dist-info/RECORD,,