From 0c8dc6f77b1b53934d51161e6f9c66f9790660e0 Mon Sep 17 00:00:00 2001 From: SDE Date: Mon, 7 Aug 2023 23:50:43 +0300 Subject: [PATCH 1/3] 0.1.43 not parse airports wo city --- ReferenceDataApp/funcs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ReferenceDataApp/funcs.py b/ReferenceDataApp/funcs.py index 49e8c0e..7ec7679 100644 --- a/ReferenceDataApp/funcs.py +++ b/ReferenceDataApp/funcs.py @@ -58,7 +58,7 @@ def create_airports_by_airportsList(airportsList, city=None): kwargs.update({'iata_code': airport_Dict['iata']}) airport = Airport.objects.get(**kwargs) except Airport.DoesNotExist: - print(f'{airport_Dict["int_name"]} не найден в БД > добавляем') + print(f' - - {airport_Dict["int_name"]} не найден в БД > добавляем') except Exception as e: print(f'error = {str(e)}') @@ -184,7 +184,7 @@ def parse_data(): try: city = City.objects.get(**kwargs) except City.DoesNotExist: - print(f'{city_Dict["name:en"]} не найдена в БД > добавляем') + print(f' - {city_Dict["name:en"]} не найдена в БД > добавляем') except Exception as e: print(f'error = {str(e)}') From 9b7b7d52a41637c815a90d9da17a35f4d401444c Mon Sep 17 00:00:00 2001 From: SDE Date: Tue, 8 Aug 2023 00:18:08 +0300 Subject: [PATCH 2/3] 0.1.44 fix profile admin --- AuthApp/admin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AuthApp/admin.py b/AuthApp/admin.py index 7589aae..f83ba94 100644 --- a/AuthApp/admin.py +++ b/AuthApp/admin.py @@ -125,7 +125,7 @@ class Admin_UserProfile(Admin_BaseIconModel): ('1С', { 'classes': ['wide'], 'fields': ( - ('id_1s', 'name',), + ('name',), ) }), ) From 6d121c8879b18c26dc7a4b02781115f10c6af84c Mon Sep 17 00:00:00 2001 From: SDE Date: Tue, 8 Aug 2023 00:23:04 +0300 Subject: [PATCH 3/3] 0.1.45 fix get city when parse --- ReferenceDataApp/funcs.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ReferenceDataApp/funcs.py b/ReferenceDataApp/funcs.py index 7ec7679..120ba73 100644 --- a/ReferenceDataApp/funcs.py +++ b/ReferenceDataApp/funcs.py @@ -181,6 +181,9 @@ def parse_data(): if city_Dict['name:ru']: kwargs.update({'name_ru': city_Dict['name:ru']}) + if country: + kwargs.update({'country': country}) + try: city = City.objects.get(**kwargs) except City.DoesNotExist: