amsdal 0.3.6__cp312-cp312-macosx_10_13_universal2.whl → 0.4.0__cp312-cp312-macosx_10_13_universal2.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 amsdal might be problematic. Click here for more details.
- amsdal/__about__.py +1 -1
- amsdal/__migrations__/0000_initial.py +34 -25
- amsdal/__migrations__/0001_datetime_type.py +4 -4
- amsdal/__migrations__/0002_fixture_order.py +7 -3
- amsdal/__migrations__/0003_schema_type_in_class_meta.py +3 -15
- amsdal/cloud/__init__.cpython-312-darwin.so +0 -0
- amsdal/cloud/client.cpython-312-darwin.so +0 -0
- amsdal/cloud/constants.cpython-312-darwin.so +0 -0
- amsdal/cloud/enums.cpython-312-darwin.so +0 -0
- amsdal/cloud/models/__init__.cpython-312-darwin.so +0 -0
- amsdal/cloud/models/base.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/__init__.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/__init__.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/add_allowlist_ip.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/add_basic_auth.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/add_dependency.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/add_secret.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/base.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/create_deploy.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/create_env.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/create_session.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/delete_allowlist_ip.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/delete_basic_auth.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/delete_dependency.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/delete_env.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/delete_secret.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/destroy_deploy.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/expose_db.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/get_basic_auth_credentials.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/get_monitoring_info.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/list_dependencies.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/list_deploys.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/list_envs.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/list_secrets.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/manager.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/signup_action.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/actions/update_deploy.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/__init__.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/base.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/credentials.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/credentials.pyi +0 -1
- amsdal/cloud/services/auth/manager.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/signup_service.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/token.cpython-312-darwin.so +0 -0
- amsdal/cloud/services/auth/token.pyi +0 -1
- amsdal/configs/main.py +23 -19
- amsdal/configs/main.pyi +12 -15
- amsdal/contrib/__init__.cpython-312-darwin.so +0 -0
- amsdal/contrib/auth/lifecycle/consumer.py +10 -10
- amsdal/contrib/auth/migrations/0000_initial.py +41 -7
- amsdal/contrib/auth/models/login_session.py +66 -0
- amsdal/contrib/auth/models/login_session.pyi +33 -0
- amsdal/contrib/auth/models/permission.py +23 -0
- amsdal/contrib/auth/models/permission.pyi +18 -0
- amsdal/contrib/auth/models/user.py +106 -0
- amsdal/contrib/auth/models/user.pyi +46 -0
- amsdal/contrib/frontend_configs/conversion/convert.py +47 -15
- amsdal/contrib/frontend_configs/conversion/convert.pyi +0 -1
- amsdal/contrib/frontend_configs/lifecycle/consumer.py +32 -13
- amsdal/contrib/frontend_configs/lifecycle/consumer.pyi +1 -1
- amsdal/contrib/frontend_configs/migrations/0000_initial.py +15 -14
- amsdal/contrib/frontend_configs/models/__init__.py +0 -0
- amsdal/contrib/frontend_configs/models/__init__.pyi +0 -0
- amsdal/contrib/frontend_configs/models/frontend_activator_config.py +22 -0
- amsdal/contrib/frontend_configs/models/frontend_activator_config.pyi +12 -0
- amsdal/contrib/frontend_configs/models/frontend_config_async_validator.py +11 -0
- amsdal/contrib/frontend_configs/models/frontend_config_async_validator.pyi +7 -0
- amsdal/contrib/frontend_configs/models/frontend_config_control_action.py +54 -0
- amsdal/contrib/frontend_configs/models/frontend_config_control_action.pyi +32 -0
- amsdal/contrib/frontend_configs/models/frontend_config_group_validator.py +21 -0
- amsdal/contrib/frontend_configs/models/frontend_config_group_validator.pyi +11 -0
- amsdal/contrib/frontend_configs/models/frontend_config_option.py +12 -0
- amsdal/contrib/frontend_configs/models/frontend_config_option.pyi +8 -0
- amsdal/contrib/frontend_configs/models/frontend_config_skip_none_base.py +17 -0
- amsdal/contrib/frontend_configs/models/frontend_config_skip_none_base.pyi +8 -0
- amsdal/contrib/frontend_configs/models/frontend_config_slider_option.py +13 -0
- amsdal/contrib/frontend_configs/models/frontend_config_slider_option.pyi +9 -0
- amsdal/contrib/frontend_configs/models/frontend_config_text_mask.py +14 -0
- amsdal/contrib/frontend_configs/models/frontend_config_text_mask.pyi +10 -0
- amsdal/contrib/frontend_configs/models/frontend_config_validator.py +28 -0
- amsdal/contrib/frontend_configs/models/frontend_config_validator.pyi +15 -0
- amsdal/contrib/frontend_configs/models/frontend_control_config.py +87 -0
- amsdal/contrib/frontend_configs/models/frontend_control_config.pyi +35 -0
- amsdal/contrib/frontend_configs/models/frontend_model_config.py +14 -0
- amsdal/contrib/frontend_configs/models/frontend_model_config.pyi +9 -0
- amsdal/errors.py +0 -3
- amsdal/errors.pyi +0 -1
- amsdal/fixtures/__init__.cpython-312-darwin.so +0 -0
- amsdal/fixtures/manager.cpython-312-darwin.so +0 -0
- amsdal/fixtures/manager.pyi +72 -123
- amsdal/fixtures/utils.cpython-312-darwin.so +0 -0
- amsdal/fixtures/utils.pyi +9 -0
- amsdal/manager.cpython-312-darwin.so +0 -0
- amsdal/manager.pyi +4 -96
- amsdal/mixins/__init__.cpython-312-darwin.so +0 -0
- amsdal/mixins/class_versions_mixin.cpython-312-darwin.so +0 -0
- amsdal/models/__init__.py +0 -0
- amsdal/models/__init__.pyi +0 -0
- amsdal/models/core/__init__.py +0 -0
- amsdal/models/core/__init__.pyi +0 -0
- amsdal/models/core/class_object.py +37 -0
- amsdal/models/core/class_object.pyi +24 -0
- amsdal/models/core/class_object_meta.py +26 -0
- amsdal/models/core/class_object_meta.pyi +15 -0
- amsdal/models/core/class_property.py +19 -0
- amsdal/models/core/class_property.pyi +10 -0
- amsdal/models/core/class_property_meta.py +15 -0
- amsdal/models/core/class_property_meta.pyi +10 -0
- amsdal/models/core/file.py +156 -0
- amsdal/models/core/file.pyi +104 -0
- amsdal/models/core/fixture.py +25 -0
- amsdal/models/core/fixture.pyi +14 -0
- amsdal/models/core/option.py +11 -0
- amsdal/models/core/option.pyi +8 -0
- amsdal/models/core/validator.py +12 -0
- amsdal/models/core/validator.pyi +8 -0
- amsdal/models/types/__init__.py +0 -0
- amsdal/models/types/__init__.pyi +0 -0
- amsdal/models/types/object.py +26 -0
- amsdal/models/types/object.pyi +16 -0
- amsdal/schemas/core/file/properties/validate_data.py +1 -1
- amsdal/schemas/interfaces.py +25 -0
- amsdal/schemas/interfaces.pyi +20 -0
- amsdal/schemas/manager.cpython-312-darwin.so +0 -0
- amsdal/schemas/manager.py +0 -116
- amsdal/schemas/manager.pyi +0 -65
- amsdal/schemas/mixins/__init__.py +0 -0
- amsdal/schemas/mixins/__init__.pyi +0 -0
- amsdal/schemas/mixins/check_dependencies_mixin.py +115 -0
- amsdal/schemas/mixins/check_dependencies_mixin.pyi +42 -0
- amsdal/schemas/mixins/verify_schemas_mixin.py +96 -0
- amsdal/schemas/mixins/verify_schemas_mixin.pyi +33 -0
- amsdal/schemas/repository.py +84 -0
- amsdal/schemas/repository.pyi +22 -0
- amsdal/schemas/utils.py +16 -0
- amsdal/schemas/utils.pyi +10 -0
- amsdal/services/__init__.cpython-312-darwin.so +0 -0
- amsdal/services/transaction_execution.cpython-312-darwin.so +0 -0
- amsdal/utils/rollback/__init__.py +99 -54
- amsdal/utils/tests/helpers.py +46 -37
- {amsdal-0.3.6.dist-info → amsdal-0.4.0.dist-info}/METADATA +8 -8
- {amsdal-0.3.6.dist-info → amsdal-0.4.0.dist-info}/RECORD +148 -140
- amsdal/contrib/auth/models/login_session/hooks/pre_init.py +0 -68
- amsdal/contrib/auth/models/login_session/model.json +0 -23
- amsdal/contrib/auth/models/login_session/modifiers/display_name.py +0 -11
- amsdal/contrib/auth/models/permission/fixtures/basic_permissions.json +0 -62
- amsdal/contrib/auth/models/permission/model.json +0 -18
- amsdal/contrib/auth/models/permission/modifiers/display_name.py +0 -11
- amsdal/contrib/auth/models/user/hooks/post_init.py +0 -76
- amsdal/contrib/auth/models/user/hooks/pre_create.py +0 -8
- amsdal/contrib/auth/models/user/model.json +0 -25
- amsdal/contrib/auth/models/user/modifiers/display_name.py +0 -19
- amsdal/contrib/frontend_configs/models/frontend_activator_config/model.json +0 -11
- amsdal/contrib/frontend_configs/models/frontend_config_async_validator/model.json +0 -11
- amsdal/contrib/frontend_configs/models/frontend_config_group_validator/model.json +0 -52
- amsdal/contrib/frontend_configs/models/frontend_config_option/model.json +0 -15
- amsdal/contrib/frontend_configs/models/frontend_config_skip_none_base/model.json +0 -6
- amsdal/contrib/frontend_configs/models/frontend_config_skip_none_base/properties/model_dump.py +0 -13
- amsdal/contrib/frontend_configs/models/frontend_config_slider_option/model.json +0 -19
- amsdal/contrib/frontend_configs/models/frontend_config_text_mask/model.json +0 -26
- amsdal/contrib/frontend_configs/models/frontend_config_validator/model.json +0 -41
- amsdal/contrib/frontend_configs/models/frontend_control_config/model.json +0 -250
- amsdal/contrib/frontend_configs/models/frontend_model_config/fixtures/permissions.json +0 -24
- amsdal/contrib/frontend_configs/models/frontend_model_config/model.json +0 -17
- amsdal/contrib/frontend_configs/models/frontent_config_control_action/model.json +0 -54
- amsdal/contrib/frontend_configs/models/frontent_config_control_action/properties/action_validate.py +0 -33
- amsdal/migration/__init__.cpython-312-darwin.so +0 -0
- amsdal/migration/base_migration_schemas.cpython-312-darwin.so +0 -0
- amsdal/migration/base_migration_schemas.pyi +0 -119
- amsdal/migration/data_classes.cpython-312-darwin.so +0 -0
- amsdal/migration/data_classes.pyi +0 -165
- amsdal/migration/executors/__init__.cpython-312-darwin.so +0 -0
- amsdal/migration/executors/base.cpython-312-darwin.so +0 -0
- amsdal/migration/executors/base.pyi +0 -117
- amsdal/migration/executors/default_executor.cpython-312-darwin.so +0 -0
- amsdal/migration/executors/default_executor.pyi +0 -184
- amsdal/migration/executors/state_executor.cpython-312-darwin.so +0 -0
- amsdal/migration/executors/state_executor.pyi +0 -151
- amsdal/migration/file_migration_executor.cpython-312-darwin.so +0 -0
- amsdal/migration/file_migration_executor.pyi +0 -122
- amsdal/migration/file_migration_generator.cpython-312-darwin.so +0 -0
- amsdal/migration/file_migration_generator.pyi +0 -229
- amsdal/migration/file_migration_store.cpython-312-darwin.so +0 -0
- amsdal/migration/file_migration_store.pyi +0 -114
- amsdal/migration/file_migration_writer.cpython-312-darwin.so +0 -0
- amsdal/migration/file_migration_writer.pyi +0 -73
- amsdal/migration/migrations.cpython-312-darwin.so +0 -0
- amsdal/migration/migrations.pyi +0 -166
- amsdal/migration/migrations_loader.cpython-312-darwin.so +0 -0
- amsdal/migration/migrations_loader.pyi +0 -32
- amsdal/migration/schemas_loaders.cpython-312-darwin.so +0 -0
- amsdal/migration/schemas_loaders.pyi +0 -37
- amsdal/migration/templates/data_migration.tmpl +0 -18
- amsdal/migration/templates/dict_validator.tmpl +0 -4
- amsdal/migration/templates/migration.tmpl +0 -6
- amsdal/migration/templates/model_class.tmpl +0 -8
- amsdal/migration/templates/model_class_layout.tmpl +0 -24
- amsdal/migration/templates/options_validator.tmpl +0 -4
- amsdal/migration/utils.cpython-312-darwin.so +0 -0
- amsdal/migration/utils.pyi +0 -58
- amsdal/mixins/build_mixin.cpython-312-darwin.so +0 -0
- amsdal/mixins/build_mixin.pyi +0 -78
- /amsdal/{migration/__init__.pyi → contrib/auth/models/__init__.py} +0 -0
- /amsdal/{migration/executors → contrib/auth/models}/__init__.pyi +0 -0
- {amsdal-0.3.6.dist-info → amsdal-0.4.0.dist-info}/LICENSE.txt +0 -0
- {amsdal-0.3.6.dist-info → amsdal-0.4.0.dist-info}/WHEEL +0 -0
- {amsdal-0.3.6.dist-info → amsdal-0.4.0.dist-info}/licenses/LICENSE.txt +0 -0
- {amsdal-0.3.6.dist-info → amsdal-0.4.0.dist-info}/top_level.txt +0 -0
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
from typing import Any
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
def post_init(self, *, is_new_object: bool, kwargs: dict[str, Any]) -> None: # type: ignore[no-untyped-def]
|
|
5
|
-
"""
|
|
6
|
-
Post-initializes a user object by validating email and password, and hashing the password.
|
|
7
|
-
|
|
8
|
-
This method checks if the email and password are provided and valid. If the object is new,
|
|
9
|
-
it hashes the password and sets the object ID to the lowercased email.
|
|
10
|
-
|
|
11
|
-
Args:
|
|
12
|
-
is_new_object (bool): Indicates if the object is new.
|
|
13
|
-
kwargs (dict[str, Any]): The keyword arguments containing user details.
|
|
14
|
-
|
|
15
|
-
Raises:
|
|
16
|
-
UserCreationError: If the email or password is invalid.
|
|
17
|
-
"""
|
|
18
|
-
import bcrypt
|
|
19
|
-
|
|
20
|
-
from amsdal.contrib.auth.errors import UserCreationError
|
|
21
|
-
|
|
22
|
-
email = kwargs.get('email', None)
|
|
23
|
-
password = kwargs.get('password', None)
|
|
24
|
-
|
|
25
|
-
if email is None or email == '':
|
|
26
|
-
msg = "Email can't be empty"
|
|
27
|
-
raise UserCreationError(msg)
|
|
28
|
-
|
|
29
|
-
if password is None or password == '':
|
|
30
|
-
msg = "Password can't be empty"
|
|
31
|
-
raise UserCreationError(msg)
|
|
32
|
-
|
|
33
|
-
kwargs['email'] = email.lower()
|
|
34
|
-
|
|
35
|
-
if is_new_object and '_metadata' not in kwargs:
|
|
36
|
-
hashed_password = bcrypt.hashpw(password.encode('utf-8'), bcrypt.gensalt())
|
|
37
|
-
self.password = hashed_password
|
|
38
|
-
self._object_id = email.lower()
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
def pre_update(self) -> None: # type: ignore[no-untyped-def]
|
|
42
|
-
import bcrypt
|
|
43
|
-
|
|
44
|
-
original_object = self.refetch_from_db()
|
|
45
|
-
|
|
46
|
-
password = self.password
|
|
47
|
-
|
|
48
|
-
if original_object.password and password is not None:
|
|
49
|
-
if isinstance(password, str):
|
|
50
|
-
password = password.encode('utf-8')
|
|
51
|
-
|
|
52
|
-
try:
|
|
53
|
-
if not bcrypt.checkpw(password, original_object.password):
|
|
54
|
-
self.password = password
|
|
55
|
-
except ValueError:
|
|
56
|
-
hashed_password = bcrypt.hashpw(password, bcrypt.gensalt())
|
|
57
|
-
self.password = hashed_password
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
async def apre_update(self) -> None: # type: ignore[no-untyped-def]
|
|
61
|
-
import bcrypt
|
|
62
|
-
|
|
63
|
-
original_object = await self.arefetch_from_db()
|
|
64
|
-
|
|
65
|
-
password = self.password
|
|
66
|
-
|
|
67
|
-
if original_object.password and password is not None:
|
|
68
|
-
if isinstance(password, str):
|
|
69
|
-
password = password.encode('utf-8')
|
|
70
|
-
|
|
71
|
-
try:
|
|
72
|
-
if not bcrypt.checkpw(password, original_object.password):
|
|
73
|
-
self.password = password
|
|
74
|
-
except ValueError:
|
|
75
|
-
hashed_password = bcrypt.hashpw(password, bcrypt.gensalt())
|
|
76
|
-
self.password = hashed_password
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "User",
|
|
3
|
-
"type": "object",
|
|
4
|
-
"properties": {
|
|
5
|
-
"email": {
|
|
6
|
-
"title": "Email",
|
|
7
|
-
"type": "string"
|
|
8
|
-
},
|
|
9
|
-
"password": {
|
|
10
|
-
"title": "Password (hash)",
|
|
11
|
-
"type": "binary"
|
|
12
|
-
},
|
|
13
|
-
"permissions": {
|
|
14
|
-
"title": "Permissions",
|
|
15
|
-
"type": "array",
|
|
16
|
-
"items": {
|
|
17
|
-
"type": "Permission"
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
},
|
|
21
|
-
"required": [
|
|
22
|
-
"email",
|
|
23
|
-
"password"
|
|
24
|
-
]
|
|
25
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
@property # type: ignore[misc]
|
|
2
|
-
def display_name(self) -> str: # type: ignore[no-untyped-def]
|
|
3
|
-
"""
|
|
4
|
-
Returns the display name of the user.
|
|
5
|
-
|
|
6
|
-
This method returns the email of the user as their display name.
|
|
7
|
-
|
|
8
|
-
Returns:
|
|
9
|
-
str: The email of the user.
|
|
10
|
-
"""
|
|
11
|
-
return self.email
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
def __str__(self) -> str: # type: ignore[no-untyped-def] # noqa: N807
|
|
15
|
-
return f'User(email={self.email})'
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
def __repr__(self) -> str: # type: ignore[no-untyped-def] # noqa: N807
|
|
19
|
-
return str(self)
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendConfigGroupValidator",
|
|
3
|
-
"type": "FrontendConfigSkipNoneBase",
|
|
4
|
-
"properties": {
|
|
5
|
-
"mainControl": {
|
|
6
|
-
"title": "Main Control",
|
|
7
|
-
"type": "string"
|
|
8
|
-
},
|
|
9
|
-
"dependentControls": {
|
|
10
|
-
"title": "Dependent Controls",
|
|
11
|
-
"type": "array",
|
|
12
|
-
"items": {
|
|
13
|
-
"type": "string"
|
|
14
|
-
}
|
|
15
|
-
},
|
|
16
|
-
"condition": {
|
|
17
|
-
"title": "Condition",
|
|
18
|
-
"type": "string",
|
|
19
|
-
"options": [
|
|
20
|
-
{
|
|
21
|
-
"key": "Less Than",
|
|
22
|
-
"value": "lt"
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
"key": "Less Than or Equal",
|
|
26
|
-
"value": "lte"
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
"key": "Greater Than",
|
|
30
|
-
"value": "gt"
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
"key": "Greater Than or Equal",
|
|
34
|
-
"value": "gte"
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
"key": "Equal",
|
|
38
|
-
"value": "eq"
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
"key": "Not Equal",
|
|
42
|
-
"value": "neq"
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
"key": "Exist",
|
|
46
|
-
"value": "exist"
|
|
47
|
-
}
|
|
48
|
-
]
|
|
49
|
-
}
|
|
50
|
-
},
|
|
51
|
-
"meta_class": "TypeMeta"
|
|
52
|
-
}
|
amsdal/contrib/frontend_configs/models/frontend_config_skip_none_base/properties/model_dump.py
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
from typing import Any
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
def model_dump(self, **kwargs: Any) -> dict[str, Any]: # type: ignore[no-untyped-def] # noqa: ARG001
|
|
5
|
-
kwargs['exclude_none'] = True
|
|
6
|
-
|
|
7
|
-
return super().model_dump(**kwargs) # type: ignore[misc]
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
def model_dump_json(self, **kwargs: Any) -> str: # type: ignore[no-untyped-def] # noqa: ARG001
|
|
11
|
-
kwargs['exclude_none'] = True
|
|
12
|
-
|
|
13
|
-
return super().model_dump_json(**kwargs) # type: ignore[misc]
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendConfigSliderOption",
|
|
3
|
-
"type": "FrontendConfigSkipNoneBase",
|
|
4
|
-
"properties": {
|
|
5
|
-
"min": {
|
|
6
|
-
"title": "Minimum",
|
|
7
|
-
"type": "number"
|
|
8
|
-
},
|
|
9
|
-
"max": {
|
|
10
|
-
"title": "Maximum",
|
|
11
|
-
"type": "number"
|
|
12
|
-
},
|
|
13
|
-
"range": {
|
|
14
|
-
"title": "Range",
|
|
15
|
-
"type": "boolean"
|
|
16
|
-
}
|
|
17
|
-
},
|
|
18
|
-
"meta_class": "TypeMeta"
|
|
19
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendConfigTextMask",
|
|
3
|
-
"type": "FrontendConfigSkipNoneBase",
|
|
4
|
-
"properties": {
|
|
5
|
-
"mask_string": {
|
|
6
|
-
"title": "Mask String",
|
|
7
|
-
"type": "string"
|
|
8
|
-
},
|
|
9
|
-
"prefix": {
|
|
10
|
-
"title": "Prefix",
|
|
11
|
-
"type": "string"
|
|
12
|
-
},
|
|
13
|
-
"suffix": {
|
|
14
|
-
"title": "Suffix",
|
|
15
|
-
"type": "string"
|
|
16
|
-
},
|
|
17
|
-
"thousands_separator": {
|
|
18
|
-
"title": "Thousands Separator",
|
|
19
|
-
"type": "string"
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
"required": [
|
|
23
|
-
"mask_string"
|
|
24
|
-
],
|
|
25
|
-
"meta_class": "TypeMeta"
|
|
26
|
-
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendConfigValidator",
|
|
3
|
-
"type": "FrontendConfigGroupValidator",
|
|
4
|
-
"properties": {
|
|
5
|
-
"function": {
|
|
6
|
-
"title": "Function",
|
|
7
|
-
"type": "string",
|
|
8
|
-
"options": [
|
|
9
|
-
{
|
|
10
|
-
"key": "Minimum",
|
|
11
|
-
"value": "min"
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
"key": "Maximum",
|
|
15
|
-
"value": "max"
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
"key": "Minimum Length",
|
|
19
|
-
"value": "minLength"
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
"key": "Maximum Length",
|
|
23
|
-
"value": "maxLength"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"key": "Required",
|
|
27
|
-
"value": "required"
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
"key": "Pattern",
|
|
31
|
-
"value": "pattern"
|
|
32
|
-
}
|
|
33
|
-
]
|
|
34
|
-
},
|
|
35
|
-
"value": {
|
|
36
|
-
"title": "Value",
|
|
37
|
-
"type": "string"
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
"meta_class": "TypeMeta"
|
|
41
|
-
}
|
|
@@ -1,250 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendControlConfig",
|
|
3
|
-
"type": "FrontendConfigSkipNoneBase",
|
|
4
|
-
"properties": {
|
|
5
|
-
"type": {
|
|
6
|
-
"title": "Type",
|
|
7
|
-
"type": "string",
|
|
8
|
-
"options": [
|
|
9
|
-
{
|
|
10
|
-
"key": "Infoscreen",
|
|
11
|
-
"value": "infoscreen"
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
"key": "Info Group",
|
|
15
|
-
"value": "info-group"
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
"key": "Text",
|
|
19
|
-
"value": "text"
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
"key": "Number",
|
|
23
|
-
"value": "number"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"key": "Select",
|
|
27
|
-
"value": "select"
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
"key": "Object Group",
|
|
31
|
-
"value": "object_group"
|
|
32
|
-
},
|
|
33
|
-
{
|
|
34
|
-
"key": "Group",
|
|
35
|
-
"value": "group"
|
|
36
|
-
},
|
|
37
|
-
{
|
|
38
|
-
"key": "Group Toggle",
|
|
39
|
-
"value": "group_toggle"
|
|
40
|
-
},
|
|
41
|
-
{
|
|
42
|
-
"key": "Group Switch",
|
|
43
|
-
"value": "group_switch"
|
|
44
|
-
},
|
|
45
|
-
{
|
|
46
|
-
"key": "Password",
|
|
47
|
-
"value": "password"
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
"key": "Email",
|
|
51
|
-
"value": "email"
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
"key": "Phone",
|
|
55
|
-
"value": "phone"
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
"key": "textarea",
|
|
59
|
-
"value": "textarea"
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
"key": "Multiselect",
|
|
63
|
-
"value": "multiselect"
|
|
64
|
-
},
|
|
65
|
-
{
|
|
66
|
-
"key": "number_initial",
|
|
67
|
-
"value": "number_initial"
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
"key": "number_plus",
|
|
71
|
-
"value": "number_plus"
|
|
72
|
-
},
|
|
73
|
-
{
|
|
74
|
-
"key": "number_minus",
|
|
75
|
-
"value": "number_minus"
|
|
76
|
-
},
|
|
77
|
-
{
|
|
78
|
-
"key": "number_equals",
|
|
79
|
-
"value": "number_equals"
|
|
80
|
-
},
|
|
81
|
-
{
|
|
82
|
-
"key": "toggle",
|
|
83
|
-
"value": "toggle"
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
"key": "radio",
|
|
87
|
-
"value": "radio"
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
"key": "checkbox",
|
|
91
|
-
"value": "checkbox"
|
|
92
|
-
},
|
|
93
|
-
{
|
|
94
|
-
"key": "number-slider",
|
|
95
|
-
"value": "number-slider"
|
|
96
|
-
},
|
|
97
|
-
{
|
|
98
|
-
"key": "number-operations",
|
|
99
|
-
"value": "number-operations"
|
|
100
|
-
},
|
|
101
|
-
{
|
|
102
|
-
"key": "date",
|
|
103
|
-
"value": "date"
|
|
104
|
-
},
|
|
105
|
-
{
|
|
106
|
-
"key": "dateTriplet",
|
|
107
|
-
"value": "dateTriplet"
|
|
108
|
-
},
|
|
109
|
-
{
|
|
110
|
-
"key": "array",
|
|
111
|
-
"value": "array"
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
"key": "object",
|
|
115
|
-
"value": "object"
|
|
116
|
-
},
|
|
117
|
-
{
|
|
118
|
-
"key": "file",
|
|
119
|
-
"value": "file"
|
|
120
|
-
},
|
|
121
|
-
{
|
|
122
|
-
"key": "dropzone",
|
|
123
|
-
"value": "dropzone"
|
|
124
|
-
},
|
|
125
|
-
{
|
|
126
|
-
"key": "object_latest",
|
|
127
|
-
"value": "object_latest"
|
|
128
|
-
},
|
|
129
|
-
{
|
|
130
|
-
"key": "Dictionary",
|
|
131
|
-
"value": "dict"
|
|
132
|
-
},
|
|
133
|
-
{
|
|
134
|
-
"key": "Time",
|
|
135
|
-
"value": "time"
|
|
136
|
-
},
|
|
137
|
-
{
|
|
138
|
-
"key": "Datetime",
|
|
139
|
-
"value": "datetime"
|
|
140
|
-
},
|
|
141
|
-
{
|
|
142
|
-
"key": "Bytes",
|
|
143
|
-
"value": "Bytes"
|
|
144
|
-
}
|
|
145
|
-
]
|
|
146
|
-
},
|
|
147
|
-
"name": {
|
|
148
|
-
"title": "Name",
|
|
149
|
-
"type": "string"
|
|
150
|
-
},
|
|
151
|
-
"label": {
|
|
152
|
-
"title": "Label",
|
|
153
|
-
"type": "string"
|
|
154
|
-
},
|
|
155
|
-
"required": {
|
|
156
|
-
"title": "Required",
|
|
157
|
-
"type": "boolean"
|
|
158
|
-
},
|
|
159
|
-
"hideLabel": {
|
|
160
|
-
"title": "Hide Label",
|
|
161
|
-
"type": "boolean"
|
|
162
|
-
},
|
|
163
|
-
"actions": {
|
|
164
|
-
"title": "Actions",
|
|
165
|
-
"type": "array",
|
|
166
|
-
"items": {
|
|
167
|
-
"type": "FrontendConfigControlAction"
|
|
168
|
-
}
|
|
169
|
-
},
|
|
170
|
-
"validators": {
|
|
171
|
-
"title": "Validators",
|
|
172
|
-
"type": "array",
|
|
173
|
-
"items": {
|
|
174
|
-
"type": "FrontendConfigValidator"
|
|
175
|
-
}
|
|
176
|
-
},
|
|
177
|
-
"asyncValidators": {
|
|
178
|
-
"title": "Async Validators",
|
|
179
|
-
"type": "array",
|
|
180
|
-
"items": {
|
|
181
|
-
"type": "FrontendConfigAsyncValidator"
|
|
182
|
-
}
|
|
183
|
-
},
|
|
184
|
-
"activators": {
|
|
185
|
-
"title": "Activators",
|
|
186
|
-
"type": "array",
|
|
187
|
-
"items": {
|
|
188
|
-
"type": "FrontendActivatorConfig"
|
|
189
|
-
}
|
|
190
|
-
},
|
|
191
|
-
"additionalText": {
|
|
192
|
-
"title": "Additional Text",
|
|
193
|
-
"type": "string"
|
|
194
|
-
},
|
|
195
|
-
"value": {
|
|
196
|
-
"title": "Value",
|
|
197
|
-
"type": "anything"
|
|
198
|
-
},
|
|
199
|
-
"placeholder": {
|
|
200
|
-
"title": "Placeholder",
|
|
201
|
-
"type": "string"
|
|
202
|
-
},
|
|
203
|
-
"options": {
|
|
204
|
-
"title": "Options",
|
|
205
|
-
"type": "array",
|
|
206
|
-
"items": {
|
|
207
|
-
"type": "FrontendConfigOption"
|
|
208
|
-
}
|
|
209
|
-
},
|
|
210
|
-
"mask": {
|
|
211
|
-
"title": "Mask",
|
|
212
|
-
"type": "FrontendConfigTextMask"
|
|
213
|
-
},
|
|
214
|
-
"controls": {
|
|
215
|
-
"title": "Controls",
|
|
216
|
-
"type": "array",
|
|
217
|
-
"items": {
|
|
218
|
-
"type": "FrontendControlConfig"
|
|
219
|
-
}
|
|
220
|
-
},
|
|
221
|
-
"showSearch": {
|
|
222
|
-
"title": "Show Search",
|
|
223
|
-
"type": "boolean"
|
|
224
|
-
},
|
|
225
|
-
"sliderOptions": {
|
|
226
|
-
"title": "Slider Option",
|
|
227
|
-
"type": "FrontendConfigSliderOption"
|
|
228
|
-
},
|
|
229
|
-
"customLabel": {
|
|
230
|
-
"title": "Custom Label",
|
|
231
|
-
"type": "array",
|
|
232
|
-
"items": {
|
|
233
|
-
"type": "string"
|
|
234
|
-
}
|
|
235
|
-
},
|
|
236
|
-
"control": {
|
|
237
|
-
"title": "Control",
|
|
238
|
-
"type": "FrontendControlConfig"
|
|
239
|
-
},
|
|
240
|
-
"entityType": {
|
|
241
|
-
"title": "Entity Type",
|
|
242
|
-
"type": "string"
|
|
243
|
-
}
|
|
244
|
-
},
|
|
245
|
-
"required": [
|
|
246
|
-
"type",
|
|
247
|
-
"name"
|
|
248
|
-
],
|
|
249
|
-
"meta_class": "TypeMeta"
|
|
250
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"Permission": [
|
|
3
|
-
{
|
|
4
|
-
"external_id": "frontend_model_config_read",
|
|
5
|
-
"model": "FrontendModelConfig",
|
|
6
|
-
"action": "read"
|
|
7
|
-
},
|
|
8
|
-
{
|
|
9
|
-
"external_id": "frontend_model_config_update",
|
|
10
|
-
"model": "FrontendModelConfig",
|
|
11
|
-
"action": "update"
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
"external_id": "frontend_model_config_delete",
|
|
15
|
-
"model": "FrontendModelConfig",
|
|
16
|
-
"action": "delete"
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
"external_id": "frontend_model_config_create",
|
|
20
|
-
"model": "FrontendModelConfig",
|
|
21
|
-
"action": "create"
|
|
22
|
-
}
|
|
23
|
-
]
|
|
24
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendModelConfig",
|
|
3
|
-
"type": "object",
|
|
4
|
-
"properties": {
|
|
5
|
-
"class_name": {
|
|
6
|
-
"title": "Class Name",
|
|
7
|
-
"type": "string"
|
|
8
|
-
},
|
|
9
|
-
"control": {
|
|
10
|
-
"title": "Control",
|
|
11
|
-
"type": "FrontendControlConfig"
|
|
12
|
-
}
|
|
13
|
-
},
|
|
14
|
-
"required": [
|
|
15
|
-
"class_name"
|
|
16
|
-
]
|
|
17
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"title": "FrontendConfigControlAction",
|
|
3
|
-
"type": "FrontendConfigSkipNoneBase",
|
|
4
|
-
"properties": {
|
|
5
|
-
"action": {
|
|
6
|
-
"title": "Action",
|
|
7
|
-
"type": "string"
|
|
8
|
-
},
|
|
9
|
-
"text": {
|
|
10
|
-
"title": "Text",
|
|
11
|
-
"type": "string"
|
|
12
|
-
},
|
|
13
|
-
"type": {
|
|
14
|
-
"title": "Type",
|
|
15
|
-
"type": "string",
|
|
16
|
-
"options": [
|
|
17
|
-
{
|
|
18
|
-
"key": "Arrow Next",
|
|
19
|
-
"value": "arrow-next"
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
"key": "Arrow Prev",
|
|
23
|
-
"value": "arrow-prev"
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"key": "Action Button",
|
|
27
|
-
"value": "action-button"
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
"key": "Text Next",
|
|
31
|
-
"value": "text-next"
|
|
32
|
-
},
|
|
33
|
-
{
|
|
34
|
-
"key": "Text Prev",
|
|
35
|
-
"value": "text-prev"
|
|
36
|
-
}
|
|
37
|
-
]
|
|
38
|
-
},
|
|
39
|
-
"dataLayerEvent": {
|
|
40
|
-
"title": "Data Layer Event",
|
|
41
|
-
"type": "string"
|
|
42
|
-
},
|
|
43
|
-
"activator": {
|
|
44
|
-
"title": "Activator",
|
|
45
|
-
"type": "string"
|
|
46
|
-
},
|
|
47
|
-
"icon": {
|
|
48
|
-
"title": "Icon",
|
|
49
|
-
"type": "string"
|
|
50
|
-
}
|
|
51
|
-
},
|
|
52
|
-
"required": ["action", "text", "type"],
|
|
53
|
-
"meta_class": "TypeMeta"
|
|
54
|
-
}
|