amsdal_crm 0.1.5__py3-none-any.whl → 0.1.7__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.
- amsdal_crm/__about__.py +1 -1
- amsdal_crm/errors.py +1 -1
- amsdal_crm/lifecycle/consumer.py +8 -1
- amsdal_crm/migrations/0000_initial.py +0 -1
- amsdal_crm/models/stage.py +0 -4
- amsdal_crm/services/custom_field_service.py +2 -2
- {amsdal_crm-0.1.5.dist-info → amsdal_crm-0.1.7.dist-info}/METADATA +1 -1
- {amsdal_crm-0.1.5.dist-info → amsdal_crm-0.1.7.dist-info}/RECORD +9 -9
- {amsdal_crm-0.1.5.dist-info → amsdal_crm-0.1.7.dist-info}/WHEEL +0 -0
amsdal_crm/__about__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = '0.1.
|
|
1
|
+
__version__ = '0.1.7'
|
amsdal_crm/errors.py
CHANGED
amsdal_crm/lifecycle/consumer.py
CHANGED
|
@@ -126,7 +126,7 @@ def _add_custom_fields_to_control(control: dict[str, Any], custom_field_controls
|
|
|
126
126
|
)
|
|
127
127
|
|
|
128
128
|
|
|
129
|
-
def
|
|
129
|
+
def _get_values_from_response(response: dict[str, Any] | list[dict[str, Any]]) -> dict[str, Any]:
|
|
130
130
|
"""
|
|
131
131
|
Extracts values from a response dictionary or list of dictionaries.
|
|
132
132
|
|
|
@@ -150,6 +150,13 @@ def get_values_from_response(response: dict[str, Any] | list[dict[str, Any]]) ->
|
|
|
150
150
|
return response['rows'][0]
|
|
151
151
|
|
|
152
152
|
|
|
153
|
+
def get_values_from_response(response: dict[str, Any] | list[dict[str, Any]]) -> dict[str, Any]:
|
|
154
|
+
_values = _get_values_from_response(response)
|
|
155
|
+
if 'custom_fields' in _values:
|
|
156
|
+
return _values['custom_fields']
|
|
157
|
+
return {}
|
|
158
|
+
|
|
159
|
+
|
|
153
160
|
class CustomAttributesFrontendConfigConsumer(LifecycleConsumer):
|
|
154
161
|
"""Consumer that propagates custom attributes into frontend config.
|
|
155
162
|
|
|
@@ -430,7 +430,6 @@ class Migration(migrations.Migration):
|
|
|
430
430
|
"db_fields": {"pipeline": ["pipeline_partition_key"]},
|
|
431
431
|
"primary_key": ["partition_key"],
|
|
432
432
|
"indexed": [["order"]],
|
|
433
|
-
"unique": [["pipeline", "name"]],
|
|
434
433
|
"foreign_keys": {"pipeline": [{"pipeline_partition_key": "string"}, "Pipeline", ["partition_key"]]},
|
|
435
434
|
},
|
|
436
435
|
"description": "Pipeline stage model.\n\nRepresents a stage within a sales pipeline with win probability\nand closed status indicators.",
|
amsdal_crm/models/stage.py
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
from typing import ClassVar
|
|
4
4
|
|
|
5
|
-
from amsdal_models.classes.data_models.constraints import UniqueConstraint
|
|
6
5
|
from amsdal_models.classes.data_models.indexes import IndexInfo
|
|
7
6
|
from amsdal_models.classes.model import Model
|
|
8
7
|
from amsdal_utils.models.enums import ModuleType
|
|
@@ -20,9 +19,6 @@ class Stage(Model):
|
|
|
20
19
|
model_config: ClassVar[ConfigDict] = ConfigDict(arbitrary_types_allowed=True)
|
|
21
20
|
|
|
22
21
|
__module_type__: ClassVar[ModuleType] = ModuleType.CONTRIB
|
|
23
|
-
__constraints__: ClassVar[list[UniqueConstraint]] = [
|
|
24
|
-
UniqueConstraint(name='unq_stage_pipeline_name', fields=['pipeline', 'name'])
|
|
25
|
-
]
|
|
26
22
|
__indexes__: ClassVar[list[IndexInfo]] = [
|
|
27
23
|
IndexInfo(name='idx_stage_order', field='order'),
|
|
28
24
|
]
|
|
@@ -126,10 +126,10 @@ class CustomFieldService:
|
|
|
126
126
|
|
|
127
127
|
elif definition.field_type == 'date':
|
|
128
128
|
if isinstance(value, datetime):
|
|
129
|
-
return value
|
|
129
|
+
return value.isoformat()
|
|
130
130
|
# Try parsing ISO format
|
|
131
131
|
try:
|
|
132
|
-
return datetime.fromisoformat(value)
|
|
132
|
+
return datetime.fromisoformat(value).isoformat()
|
|
133
133
|
except (ValueError, AttributeError) as exc:
|
|
134
134
|
msg = f'Invalid date for field {definition.field_name}: {value}'
|
|
135
135
|
raise CustomFieldValidationError(msg) from exc
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
amsdal_crm/Third-Party Materials - AMSDAL Dependencies - License Notices.md,sha256=ML7PqsHrTMNNZn8E_rA-LzDCAafMSxMcrmSg8YOi-wo,113896
|
|
2
|
-
amsdal_crm/__about__.py,sha256=
|
|
2
|
+
amsdal_crm/__about__.py,sha256=mFY0GwwuN-a3M8w93_mskS6GZIvv9SNdjLfJaWNsm-I,22
|
|
3
3
|
amsdal_crm/__init__.py,sha256=b4wxJYesA5Ctk1IrAvlw64i_0EU3SiK1Tw6sUYakd18,303
|
|
4
4
|
amsdal_crm/app.py,sha256=JLvueh_2KURQLDWMQlq4Z6gAFsqBDTRf6pK095ehp14,1373
|
|
5
5
|
amsdal_crm/constants.py,sha256=5Ga7q9zEKcQZnAoKv_SE_7w8WxvhPFkM9gY9NruOEaA,347
|
|
6
|
-
amsdal_crm/errors.py,sha256=
|
|
6
|
+
amsdal_crm/errors.py,sha256=vLANHcfz5YHO1O_gb4LaCK3KrQI2yi_BJjKg-7HdF68,515
|
|
7
7
|
amsdal_crm/settings.py,sha256=YbwDeiKaahqipGoBGkMRzYKGk8flt7IrkmMTLDyC9OQ,751
|
|
8
8
|
amsdal_crm/fixtures/__init__.py,sha256=1tDNXZhcbZBd4tX3lTKKlom1NUg1TX2aa2IbymWO9f0,20
|
|
9
9
|
amsdal_crm/fixtures/permissions.py,sha256=cYA-gWkKQdoN79GymQVHtT0GyFXMzaskwp13Ietp9wE,1107
|
|
10
10
|
amsdal_crm/fixtures/pipelines.py,sha256=ZCLmgrA700Sl7Oy7l4IQ8FbIbC1378OkcJTrZe5701o,2064
|
|
11
11
|
amsdal_crm/lifecycle/__init__.py,sha256=B8nw19lEIr7U15Lnu6jh7yzZwF9LWWh4-p3X63sAicQ,31
|
|
12
|
-
amsdal_crm/lifecycle/consumer.py,sha256=
|
|
13
|
-
amsdal_crm/migrations/0000_initial.py,sha256=
|
|
12
|
+
amsdal_crm/lifecycle/consumer.py,sha256=NhfFsbQeQUfCb9Mz-YBRZjKHL-annAqHt6Gc9b-I9_g,8824
|
|
13
|
+
amsdal_crm/migrations/0000_initial.py,sha256=OKa-QrcE6DIzrHCRvYvmJDXGve83fVl9wOxqENnIbaE,57030
|
|
14
14
|
amsdal_crm/models/__init__.py,sha256=DSuGeLKPNL_EUGohWtrH6Eof6Nk--dHyZpfqbGWmYIY,1350
|
|
15
15
|
amsdal_crm/models/account.py,sha256=prb8Tl0nYyObTeql1fLX1cVRszauzPRSN7xv-H26hRg,4918
|
|
16
16
|
amsdal_crm/models/activity.py,sha256=UtO1--oSPfrQCfQwWfIlEkjdXuaRG9znesPrGe1JqGM,4775
|
|
@@ -19,14 +19,14 @@ amsdal_crm/models/contact.py,sha256=xOTl8zUIEm2_Tk-CQxGAjzR_iuLA7Q_aKmJZAMXZ1F0,
|
|
|
19
19
|
amsdal_crm/models/custom_field_definition.py,sha256=Z0k_QR6rZ1hWkg4Wn-w8Rn9GSIgpOg_moUYRsmRPZQI,1666
|
|
20
20
|
amsdal_crm/models/deal.py,sha256=kEmS_nkicWKhZO1PbeAJLYbAffdo6LU8Nm5xDQDOwkA,6448
|
|
21
21
|
amsdal_crm/models/pipeline.py,sha256=DXJh5MbCCRctEHhDfxef5RxFWSKN0D4v6UK75q5ssL8,925
|
|
22
|
-
amsdal_crm/models/stage.py,sha256=
|
|
22
|
+
amsdal_crm/models/stage.py,sha256=zNL8UkbfGPi77mXTHjsD0k_MpyFHcwL4dsquBLAHIjE,1383
|
|
23
23
|
amsdal_crm/models/workflow_rule.py,sha256=cnIEaX-hWcRYvN5gR4uPt7Cirr8sPPdJibZapD8VRpY,1547
|
|
24
24
|
amsdal_crm/services/__init__.py,sha256=ngHA-MUPrsHvga8vFP61b8v7rrAWl-h1VZTjhlJCXkI,465
|
|
25
25
|
amsdal_crm/services/activity_service.py,sha256=3iuEmaSicwm81rouLPum5VaWW0bAMnNWNPRCHkNhewU,1873
|
|
26
|
-
amsdal_crm/services/custom_field_service.py,sha256=
|
|
26
|
+
amsdal_crm/services/custom_field_service.py,sha256=r2dr2gijTbi9r56XV64bSArx0jTGwcjTlIdxzWb0ZCM,5170
|
|
27
27
|
amsdal_crm/services/deal_service.py,sha256=ZF7cAc6r10xgXZ8D8Oy3hnE-6GgAXq8fuG_Y4QerRGw,4839
|
|
28
28
|
amsdal_crm/services/email_service.py,sha256=kung83otZAzm5MjezbWFP_Bp9CJ2NXLlDdjMX9MvNIc,3788
|
|
29
29
|
amsdal_crm/services/workflow_service.py,sha256=oKOFJrwnMZxAiHuScs63tZxL801z-6ryrUuPMC7OXlE,7036
|
|
30
|
-
amsdal_crm-0.1.
|
|
31
|
-
amsdal_crm-0.1.
|
|
32
|
-
amsdal_crm-0.1.
|
|
30
|
+
amsdal_crm-0.1.7.dist-info/METADATA,sha256=GHVRRe9IbO83dHzlaxVnLFj6RiD9V3b9N7sVU3JX6AY,1596
|
|
31
|
+
amsdal_crm-0.1.7.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
32
|
+
amsdal_crm-0.1.7.dist-info/RECORD,,
|
|
File without changes
|