(20250123) Made a common API to disable all integrations.
This commit is contained in:
@@ -119,9 +119,11 @@ from abc import ABC, abstractmethod
|
||||
|
||||
class MailController(CoreMessageController, ABC):
|
||||
|
||||
# ┏┓┓ ┓┏ • ┓ ┓
|
||||
# ┃ ┃┏┓┏┏ ┃┃┏┓┏┓┓┏┓┣┓┃┏┓┏
|
||||
# ┗┛┗┗┻┛┛ ┗┛┗┻┛ ┗┗┻┗┛┗┗ ┛
|
||||
# ┏┓┓ ┓┏
|
||||
# ┃ ┃┏┓┏┏ ┃┃┏┓┏┓┏
|
||||
# ┗┛┗┗┻┛┛ ┗┛┗┻┛ ┛
|
||||
|
||||
SERVICE_TYPE = "email"
|
||||
|
||||
# For AI Magic through LLMs:
|
||||
RECEIVED_MAIL_SUMMARIZATION_PROMPT_TEMPLATE = [
|
||||
@@ -189,7 +191,7 @@ class MailController(CoreMessageController, ABC):
|
||||
# Prepare the combined base filter:
|
||||
sms_filter = {}
|
||||
for k, v in (base_filter or {}).items(): sms_filter[k] = v
|
||||
sms_filter["serviceType"] = "email"
|
||||
sms_filter["serviceType"] = self.SERVICE_TYPE
|
||||
|
||||
# Invoke the parents' constructor:
|
||||
CoreMessageController.__init__(
|
||||
@@ -203,6 +205,9 @@ class MailController(CoreMessageController, ABC):
|
||||
debug_only_errors = debug_only_errors
|
||||
)
|
||||
|
||||
# Init a variable in a parent:
|
||||
self._service_type = self.SERVICE_TYPE
|
||||
|
||||
# ┓┏ ┓
|
||||
# ┣┫┏┓┃┏┓┏┓┏┓┏
|
||||
# ┛┗┗ ┗┣┛┗ ┛ ┛
|
||||
|
||||
Reference in New Issue
Block a user