티스토리 뷰

MBIParam

Test_UpdateData()

 

 

class cMBI01:
    MBIParam= {
        'CategoryLevel': 3, # -1 or 3
        'StartCategory': None, # None or "교육 서비스업"
        'CollectionCategory': "제조업", # None or "제조업"
        'TargetCategory': None, # None or "특수목적용 기계 제조업"
        'CompanyTypes': ["외감"], # "유가증권", "코스닥", "코넥스", "등록법인", "외감", "일반법인", "개인사업자"
        'DataTable_SMInfo': "MBIData_SMInfo01",
        'DataTable_DART': "MBIData_DART01",
        'IsAnotherProcess': False
    }

    def __init__(self):
        self.MBIServer = cMBIServerAccess()
        self.BTime = cBTime()

    @classmethod
    def CheckStartCategory(cls, categoryName):
        startCategory = cls.MBIParam.get('StartCategory')
        if startCategory:
            if startCategory == categoryName: return "StartCategory"
            else: return "NOT"
        else: return None

    @classmethod
    def CheckCollectionCategory(cls, categoryName):
        collectionCategory = cls.MBIParam.get('CollectionCategory')
        if collectionCategory:
            if collectionCategory == categoryName: return "CollectionCategory"
            else: return "NOT"
        return None

    @classmethod
    def CheckTargetCategory(cls, categoryName):
        targetCategory = cls.MBIParam.get('TargetCategory')
        if targetCategory:
            if targetCategory == categoryName: return "TargetCategory"
            else: return "NOT"
        else: return None

          
    def Test_UpdateData(self):
        isAnotherProcessor = True
        dartManager = cDARTManager(isAnotherProcessor)
        sminfoManager = cSMInfoManager()
        targetLevel = MBIParam.get("CategoryLevel")
        if not targetLevel: targetLevel = 3
        #dartManager.CollectCategoryData_DART02()
        #sminfoManager.CollectCompanyList_SMInfo()
#        dartManager.CollectCategoryData_DART02(targetLevel)
#        dartManager.ArrangeCategoryList_DART()
#        sminfoManager.ArrangeCategoryList_SMInfo()
        dartManager.CollectCompanyData_DART()
        sminfoMagager.CollectCompanyData()
반응형