Fixed method search_global_company_profiles_id
This commit is contained in:
@@ -73,6 +73,7 @@ class FocusCompliance(Request):
|
|||||||
:return: Список идентификаторов профилей
|
:return: Список идентификаторов профилей
|
||||||
:rtype: list
|
:rtype: list
|
||||||
"""
|
"""
|
||||||
|
try:
|
||||||
response = self.get(f'{self._focus_base_url}/companies/profiles/search', query=self.inn)
|
response = self.get(f'{self._focus_base_url}/companies/profiles/search', query=self.inn)
|
||||||
profiles = response['legalEntityProfiles']
|
profiles = response['legalEntityProfiles']
|
||||||
|
|
||||||
@@ -82,6 +83,8 @@ class FocusCompliance(Request):
|
|||||||
return [profile['id'] for profile in profiles]
|
return [profile['id'] for profile in profiles]
|
||||||
else:
|
else:
|
||||||
return [profiles[0]['id']]
|
return [profiles[0]['id']]
|
||||||
|
except KeyError:
|
||||||
|
return None
|
||||||
|
|
||||||
def legal_entity_profile_report(self, profile_id_list: list, path: str = None) -> dict:
|
def legal_entity_profile_report(self, profile_id_list: list, path: str = None) -> dict:
|
||||||
"""Получение печатного отчета по профилю ЮЛ
|
"""Получение печатного отчета по профилю ЮЛ
|
||||||
|
|||||||
2
setup.py
2
setup.py
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="kontur_focus",
|
name="kontur_focus",
|
||||||
version="0.2.4",
|
version="0.2.5",
|
||||||
author="Ilya Sapunov",
|
author="Ilya Sapunov",
|
||||||
author_email="sapunov@selectel.ru",
|
author_email="sapunov@selectel.ru",
|
||||||
description="Библиотека-обертка для взаимодействия с REST API Контур.Фокус и Фокус.Комплаенс",
|
description="Библиотека-обертка для взаимодействия с REST API Контур.Фокус и Фокус.Комплаенс",
|
||||||
|
|||||||
Reference in New Issue
Block a user