Реализован интерфейс согласий
This commit is contained in:
@@ -476,12 +476,22 @@ async def app_config(request: Request, response: Response, settings: SnapshotDep
|
||||
},
|
||||
"operator": {"call_phone": values["operator.call.phone"]},
|
||||
"consents": {
|
||||
name: {
|
||||
"required": settings.boolean(f"consent.{name}.required"),
|
||||
"document_url": values.get(f"consent.{name}.document_url"),
|
||||
"version": values[f"consent.{name}.version"],
|
||||
}
|
||||
for name in ("personal_data", "user_agreement", "marketing")
|
||||
"personal_data": {
|
||||
"required": settings.boolean("consent.personal_data.required"),
|
||||
"document_url": values.get("consent.personal_data.document_url"),
|
||||
"privacy_policy_document_url": values.get(
|
||||
"consent.privacy_policy.document_url"
|
||||
),
|
||||
"version": values["consent.personal_data.version"],
|
||||
},
|
||||
**{
|
||||
name: {
|
||||
"required": settings.boolean(f"consent.{name}.required"),
|
||||
"document_url": values.get(f"consent.{name}.document_url"),
|
||||
"version": values[f"consent.{name}.version"],
|
||||
}
|
||||
for name in ("user_agreement", "marketing")
|
||||
},
|
||||
},
|
||||
"attachments": {
|
||||
"allowed_extensions": settings.strings("chat.attachments.allowed_extensions"),
|
||||
|
||||
@@ -69,10 +69,12 @@ REQUIRED_SETTINGS = {
|
||||
"consent.personal_data.required",
|
||||
"consent.personal_data.document_url",
|
||||
"consent.personal_data.version",
|
||||
"consent.privacy_policy.document_url",
|
||||
"consent.user_agreement.required",
|
||||
"consent.user_agreement.document_url",
|
||||
"consent.user_agreement.version",
|
||||
"consent.marketing.required",
|
||||
"consent.marketing.document_url",
|
||||
"consent.marketing.version",
|
||||
"chat.attachments.allowed_extensions",
|
||||
"chat.attachments.allowed_mime_types",
|
||||
|
||||
Reference in New Issue
Block a user