# Author renyupeng # coding=utf-8 # @Time : 2021/11/24 1:37 下午 # @Site : # @File : SchedulerList.py # @Software: PyCharm # @contact: renyupeng@c-top.com.cn # @Tel 1501435553 class SchedulerList: def __init__(self): self.Scheduler_List = {"bytedance_ad_report_daily_dw": "bytedance_ad", "bytedance_advertiser_report_daily_dw": "bytedance_account", "bytedance_creative_report_daily_dw": "bytedance_creative", "bytedance_material_image_report_daily_dw": "bytedance_image", "bytedance_material_video_report_daily_dw": "bytedance_video", "bytedance_campaign_report_daily_dw":"bytedance_campaign", "kuaishou_account_report_daily_dw": "account", "kuaishou_campaign_report_daily_dw": "campaign", "kuaishou_material_video_report_daily_dw": "videos", "kuaishou_unit_report_daily_dw": "unit"} self.Live_Scheduler_List = { "kuaishou_live_account_report_daily_dw": "ruixuan", "kuaishou_live_campaign_report_daily_dw": "ruixuan", "kuaishou_live_unit_report_daily_dw": "ruixuan"} @classmethod def SchedulerList(cls, table): try: return SchedulerList().Scheduler_List[table] except KeyError: return None @classmethod def LiveSchedulerList(cls, table): try: return SchedulerList().Live_Scheduler_List[table] except KeyError: return None