maleo-foundation 0.3.48__py3-none-any.whl → 0.3.50__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.
- maleo_foundation/enums.py +5 -0
- maleo_foundation/models/schemas/result.py +4 -0
- maleo_foundation/models/table.py +4 -14
- maleo_foundation/models/transfers/results/service/general.py +5 -0
- {maleo_foundation-0.3.48.dist-info → maleo_foundation-0.3.50.dist-info}/METADATA +1 -1
- {maleo_foundation-0.3.48.dist-info → maleo_foundation-0.3.50.dist-info}/RECORD +8 -8
- {maleo_foundation-0.3.48.dist-info → maleo_foundation-0.3.50.dist-info}/WHEEL +0 -0
- {maleo_foundation-0.3.48.dist-info → maleo_foundation-0.3.50.dist-info}/top_level.txt +0 -0
maleo_foundation/enums.py
CHANGED
@@ -167,3 +167,8 @@ class BaseEnums:
|
|
167
167
|
EXP_1WK = int(1 * 7 * 24 * 60 * 60)
|
168
168
|
EXP_2WK = int(2 * 7 * 24 * 60 * 60)
|
169
169
|
EXP_1MO = int(1 * 30 * 24 * 60 * 60)
|
170
|
+
|
171
|
+
class RepositoryDataSource(StrEnum):
|
172
|
+
CACHE = "cache"
|
173
|
+
DATABASE = "database"
|
174
|
+
THIRD_PARTY = "third_party"
|
@@ -1,5 +1,6 @@
|
|
1
1
|
from pydantic import BaseModel, Field
|
2
2
|
from typing import Dict, Optional, Union, Any
|
3
|
+
from maleo_foundation.enums import BaseEnums
|
3
4
|
from maleo_foundation.models.schemas.general import BaseGeneralSchemas
|
4
5
|
from maleo_foundation.types import BaseTypes
|
5
6
|
|
@@ -93,5 +94,8 @@ class BaseResultSchemas:
|
|
93
94
|
..., description="Pagination metadata"
|
94
95
|
)
|
95
96
|
|
97
|
+
class RepositoryGet(BaseModel):
|
98
|
+
source: BaseEnums.RepositoryDataSource = Field(..., description="Data source")
|
99
|
+
|
96
100
|
|
97
101
|
BaseResultSchemas.PaginatedMultipleData.model_rebuild()
|
maleo_foundation/models/table.py
CHANGED
@@ -1,26 +1,16 @@
|
|
1
1
|
from sqlalchemy import Column, Integer, UUID, TIMESTAMP, Enum, func
|
2
|
-
from sqlalchemy.orm import declared_attr
|
2
|
+
from sqlalchemy.orm import declared_attr
|
3
3
|
from uuid import uuid4
|
4
4
|
from maleo_foundation.enums import BaseEnums
|
5
5
|
from maleo_foundation.utils.formatter.case import CaseFormatter
|
6
6
|
|
7
7
|
|
8
|
-
class
|
9
|
-
"""Base class for all SQLAlchemy models in the application.
|
10
|
-
|
11
|
-
This class provides a common base for all models, including
|
12
|
-
automatic table name generation and common data fields.
|
13
|
-
"""
|
14
|
-
|
15
|
-
pass
|
16
|
-
|
17
|
-
|
18
|
-
class BaseTable(Base):
|
8
|
+
class BaseTable:
|
19
9
|
__abstract__ = True
|
20
10
|
|
21
|
-
@declared_attr
|
11
|
+
@declared_attr # type: ignore
|
22
12
|
def __tablename__(cls) -> str:
|
23
|
-
return CaseFormatter.to_snake_case(cls.__name__)
|
13
|
+
return CaseFormatter.to_snake_case(cls.__name__) # type: ignore
|
24
14
|
|
25
15
|
|
26
16
|
class DataMixin:
|
@@ -2,7 +2,7 @@ maleo_foundation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,
|
|
2
2
|
maleo_foundation/authentication.py,sha256=Fo4DYLXOqX3sd-m8Eu0oVeuGN0YYLC8xlneGJClQ5Oc,2725
|
3
3
|
maleo_foundation/authorization.py,sha256=8P1hleBYRv8kda4uQcbHVujHVAlI92YV1Flfzf-oJEU,285
|
4
4
|
maleo_foundation/constants.py,sha256=cgW2TjXYEdQRoYCL3fMk3r5B2Yr-Av67CaEAdY5SZ6o,1529
|
5
|
-
maleo_foundation/enums.py,sha256=
|
5
|
+
maleo_foundation/enums.py,sha256=BuKAF5ysEICcmiROWjc67SZTmNqgD3aZ_7qA98Aq--0,4950
|
6
6
|
maleo_foundation/extended_types.py,sha256=oOAYc5f89WcPt5OWEaNdeceENHiPVr4KDhdttg6bA_w,305
|
7
7
|
maleo_foundation/rest_controller_result.py,sha256=uZxBxZ5hB98q1B4hNyRigHcO0560NYfUjq8L662aOPw,2172
|
8
8
|
maleo_foundation/types.py,sha256=Tq50KOISbnsMslVGBCqlY77lRAQZa-UUFDGqqwRglow,2466
|
@@ -51,14 +51,14 @@ maleo_foundation/middlewares/base.py,sha256=ZXMJTiuDBa6sIbgD_g1MhhlMkszsYkt3Ocl4
|
|
51
51
|
maleo_foundation/middlewares/cors.py,sha256=1QgRXOcURuEhBYMerclqbECgtAE4CFo0EhB4gJXu8Yg,2294
|
52
52
|
maleo_foundation/models/__init__.py,sha256=OlZXaeOhGXz_FppPm87jIOItnr-r179QhIcOWDOORyQ,248
|
53
53
|
maleo_foundation/models/responses.py,sha256=4uIrW8y6gyBQJ5DZRMWKAJcNdamDMCpgCzizwcBHGhw,6081
|
54
|
-
maleo_foundation/models/table.py,sha256=
|
54
|
+
maleo_foundation/models/table.py,sha256=k0-OtahF2KRmvFUL8TborT6PoIhGsyoVrPJBKGg1QbU,1855
|
55
55
|
maleo_foundation/models/schemas/__init__.py,sha256=tmjBCyG4uMRjiTbnbhIjZaR8q7zk0_J_CqnRzsSfoBQ,279
|
56
56
|
maleo_foundation/models/schemas/encryption.py,sha256=S86FGlcBhyGxxZ5ObNSHTjSDwBUlUtLOMoCAKd5wE34,687
|
57
57
|
maleo_foundation/models/schemas/general.py,sha256=jxzBsVGsdKKEiM14MfV47dDiAZalUK4RnTlq8S36Qus,4060
|
58
58
|
maleo_foundation/models/schemas/hash.py,sha256=jthDmu_VTBydffPruAIAiR8l0Xs6IrlgTptaP42zr1M,447
|
59
59
|
maleo_foundation/models/schemas/key.py,sha256=LSEDQpaCxavwp5je2O-ZNyOPtrFW_lXDywF9LK-An1w,622
|
60
60
|
maleo_foundation/models/schemas/parameter.py,sha256=OE1hg100lEa2IlGlT2Zz6PJ-OcC-6ZfDzsTOeJvvEig,3907
|
61
|
-
maleo_foundation/models/schemas/result.py,sha256=
|
61
|
+
maleo_foundation/models/schemas/result.py,sha256=3ssnPYSvxgtTy3ONuPNa-OqR1P8N142oJR-S2p1QUkI,4396
|
62
62
|
maleo_foundation/models/schemas/signature.py,sha256=h0sa91vnCaivmvlbqOd7RLiCz8qAY8gCzEnm0DOBlSg,649
|
63
63
|
maleo_foundation/models/schemas/token.py,sha256=eh4k9rm_MoaCfGV3Nqa7yFH-PH7Ec6WY4RxHhbF4m5U,591
|
64
64
|
maleo_foundation/models/transfers/__init__.py,sha256=V5kdd8wuXqe78bQ7HG3a8vW3Rkke2wTr6mb5lC0IQJg,301
|
@@ -105,7 +105,7 @@ maleo_foundation/models/transfers/results/encryption/__init__.py,sha256=fq8hH7SH
|
|
105
105
|
maleo_foundation/models/transfers/results/encryption/aes.py,sha256=5aNglJqHT3Ufordl_Bfy9thIXVblMw80xtmLs7KiCXI,877
|
106
106
|
maleo_foundation/models/transfers/results/encryption/rsa.py,sha256=dSIshf386TAF9hfokDmj4XKHsR_MQfQLmft8AF2MTZc,748
|
107
107
|
maleo_foundation/models/transfers/results/service/__init__.py,sha256=J2PANZfFCPIE836hqKLj7a7q9AT5YSPQ0_SlYj3OKP0,295
|
108
|
-
maleo_foundation/models/transfers/results/service/general.py,sha256=
|
108
|
+
maleo_foundation/models/transfers/results/service/general.py,sha256=6mnmyDCD_qwaOfosNKMMhWXilAsD-jKKQ-atRoGuHis,1639
|
109
109
|
maleo_foundation/models/transfers/results/service/controllers/__init__.py,sha256=rRt93gFqsJloJXzNWS_2chBC3hJoG4WaN84H2B5UPow,177
|
110
110
|
maleo_foundation/models/transfers/results/service/controllers/rest.py,sha256=YRD_D064BGqHUJeFH-ArOPmSNnhJO_gr_AI4gTqh8Y0,951
|
111
111
|
maleo_foundation/utils/__init__.py,sha256=L9J946_ySumzbJoOIbSBkhGz0tcjWPZ2_g76EXyxKkk,393
|
@@ -131,7 +131,7 @@ maleo_foundation/utils/loaders/credential/__init__.py,sha256=g-cAxkTE2EtHaG8Tv52
|
|
131
131
|
maleo_foundation/utils/loaders/credential/google.py,sha256=GCJl-bsKSSxoE_ERAkIzRrRNIbIEeqYOhHwzFuBr0mk,6576
|
132
132
|
maleo_foundation/utils/loaders/key/__init__.py,sha256=RfqIbUxkdlx1xrbzJZPD_JHiRFNFLRuQs8JoUPCGCv4,108
|
133
133
|
maleo_foundation/utils/loaders/key/rsa.py,sha256=UXcP0rr4QVacTsHLNQuU05wcow5CHWz-JW-zsVxlbPs,4121
|
134
|
-
maleo_foundation-0.3.
|
135
|
-
maleo_foundation-0.3.
|
136
|
-
maleo_foundation-0.3.
|
137
|
-
maleo_foundation-0.3.
|
134
|
+
maleo_foundation-0.3.50.dist-info/METADATA,sha256=qqi0qevNSgRYfuTTh9N6S2j4zN6WU3t9mD7P1EwekWk,4150
|
135
|
+
maleo_foundation-0.3.50.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
136
|
+
maleo_foundation-0.3.50.dist-info/top_level.txt,sha256=_iBos3F_bhEOdjOnzeiEYSrCucasc810xXtLBXI8cQc,17
|
137
|
+
maleo_foundation-0.3.50.dist-info/RECORD,,
|
File without changes
|
File without changes
|