feat: cal_mpointstat增加cal_exp_duration_hour 的前置处理
This commit is contained in:
parent
2e67f7c468
commit
972b460a9f
|
@ -23,7 +23,7 @@ from apps.third.king.k import kingClient
|
|||
from apps.third.king.king_api import kapis
|
||||
from apps.enm.services import insert_mplogx_from_king_rest_chunk, MpointCache
|
||||
from django.utils.timezone import localtime
|
||||
from apps.wpm.tasks import get_total_hour_now
|
||||
from apps.wpm.tasks import get_total_hour_now, cal_exp_duration_hour
|
||||
|
||||
myLogger = logging.getLogger("log")
|
||||
|
||||
|
@ -222,7 +222,8 @@ def cal_mpointstats(is_now=1, year=None, month=None, day=None, hour=None):
|
|||
cal_mpointstat_hour(item.id, year, month, day, hour)
|
||||
|
||||
# 先调整一下班时间,以防计算错误
|
||||
get_total_hour_now()
|
||||
get_total_hour_now() # 先处理total_hour_now
|
||||
cal_exp_duration_hour() # 再处理shut_hour
|
||||
|
||||
# 开始计算enstat
|
||||
mgroups = Mgroup.objects.filter(need_enm=True).order_by("sort")
|
||||
|
|
Loading…
Reference in New Issue