1
0
forked from erp-dev/erp

feat: message-api for mission via wecomm agent

This commit is contained in:
2026-05-14 09:30:38 +08:00
parent 9359013b4c
commit f409f2e6ee
38 changed files with 2085 additions and 49 deletions

View File

@@ -84,6 +84,12 @@ TENCENTCLOUD_TIIA_QPS = env.int('TENCENTCLOUD_TIIA_QPS', default=10) # Tencent
# 使用https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=xxxx
WECOM_WEBHOOK_BASE_URL = 'https://qyapi.weixin.qq.com/cgi-bin/webhook/send'
WECOM_WEBHOOK_KEY = env('WECOM_WEBHOOK_KEY', default='')
MESSAGE_API_AUTHORIZATION = env('MESSAGE_API_AUTHORIZATION', default='hophopkk')
MESSAGE_API_BASE_URL = env('MESSAGE_API_BASE_URL', default='https://www.ruicaiyinhua.online')
MESSAGE_API_DEFAULT_NEWS_IMAGE_URL = env(
'MESSAGE_API_DEFAULT_NEWS_IMAGE_URL',
default='https://via.placeholder.com/640x360.png?text=No+Image',
)
SPEAK_ENDPOINT = env('SPEAK_ENDPOINT', default='http://8.148.215.233:9004/speak')
PRINTING_ORDER_CREATED_SPEECH_ENABLED = False
AGENT_ACCESS_KEY = env('AGENT_ACCESS_KEY', default='')

43
flower/settings_test.py Normal file
View File

@@ -0,0 +1,43 @@
from .settings import *
DATABASES = {
"default": {
"ENGINE": "django.db.backends.sqlite3",
"NAME": ":memory:",
}
}
CACHES = {
"default": {
"BACKEND": "django.core.cache.backends.locmem.LocMemCache",
"LOCATION": "notifier-tests",
}
}
STORAGES = {
"default": {
"BACKEND": "django.core.files.storage.FileSystemStorage",
},
"staticfiles": {
"BACKEND": "django.contrib.staticfiles.storage.StaticFilesStorage",
},
}
DEFAULT_FILE_STORAGE = "django.core.files.storage.FileSystemStorage"
STATICFILES_STORAGE = "django.contrib.staticfiles.storage.StaticFilesStorage"
PASSWORD_HASHERS = [
"django.contrib.auth.hashers.MD5PasswordHasher",
]
class DisableMigrations(dict):
def __contains__(self, item):
return True
def __getitem__(self, item):
return None
MIGRATION_MODULES = DisableMigrations()