获取三方token bug

This commit is contained in:
曹前明 2022-10-04 20:47:38 +08:00
parent 9c4388da78
commit 7aa6f5ccea
2 changed files with 4 additions and 2 deletions

View File

@ -1,11 +1,11 @@
from apps.system.models import Dept
from django.conf import settings
from apps.third.tapis import dhapis
from apps.third.dahua import dhClient
def sync_dahua_dept(dept: Dept):
# 同步大华部门信息
from apps.third.clients import dhClient
third_info = dept.third_info
if settings.DAHUA_ENABLED and not third_info.get('dh_id', False):
# 如果dh_id 不存在

View File

@ -5,7 +5,9 @@ from apps.utils.tasks import CustomTask
from apps.third.models import Tlog
from celery import shared_task
from django.utils import timezone
from apps.third.clients import xxClient, dhClient, spClient
from apps.third.dahua import dhClient
from apps.third.xunxi import xxClient
from apps.third.speaker import spClient
@shared_task(base=CustomTask)