mirror of
https://github.com/OpenBankProject/API-Manager.git
synced 2026-02-06 14:26:53 +00:00
changes in API_Explorer_Host name
This commit is contained in:
parent
df2efe52f6
commit
d0f71cb399
@ -39,8 +39,8 @@ class ApiCollectionListView(IndexView, LoginRequiredMixin, FormView ):
|
|||||||
api_collections_for_user = api.get(api_collections_for_user_url_path)
|
api_collections_for_user = api.get(api_collections_for_user_url_path)
|
||||||
if 'api_collections' in api_collections_for_user:
|
if 'api_collections' in api_collections_for_user:
|
||||||
apicollections_list.extend(api_collections_for_user['api_collections'])
|
apicollections_list.extend(api_collections_for_user['api_collections'])
|
||||||
for api_collection_id_with_locale in apicollections_list:
|
for ac in apicollections_list:
|
||||||
api_collection_id_with_locale["collection_on_api_explorer_url"] = f"{settings.API_EXPLORER}/?api-collection-id={api_collection_id_with_locale['api_collection_id']}"
|
ac["collection_on_api_explorer_url"] = f"{settings.API_EXPLORER_HOST}/?api-collection-id={ac['api_collection_id']}"
|
||||||
except APIError as err:
|
except APIError as err:
|
||||||
messages.error(self.request, err)
|
messages.error(self.request, err)
|
||||||
return []
|
return []
|
||||||
|
|||||||
@ -32,8 +32,8 @@ class IndexView(LoginRequiredMixin, FormView):
|
|||||||
error_once_only(self.request, response['message'])
|
error_once_only(self.request, response['message'])
|
||||||
else:
|
else:
|
||||||
api_collections=response['api_collections']
|
api_collections=response['api_collections']
|
||||||
for api_collection_id_with_locale in api_collections:
|
for ac in api_collections:
|
||||||
api_collection_id_with_locale["collection_on_api_explorer_url"] = f"{settings.API_EXPLORER}/?api-collection-id={api_collection_id_with_locale['api_collection_id']}"
|
ac["collection_on_api_explorer_url"] = f"{settings.API_EXPLORER_HOST}/?api-collection-id={ac['api_collection_id']}"
|
||||||
except APIError as err:
|
except APIError as err:
|
||||||
messages.error(self.request, err)
|
messages.error(self.request, err)
|
||||||
except Exception as err:
|
except Exception as err:
|
||||||
|
|||||||
@ -253,7 +253,7 @@ API_MANAGER_DATE_FORMAT= '%Y-%m-%d'
|
|||||||
|
|
||||||
|
|
||||||
API_HOST = 'http://127.0.0.1:8080'
|
API_HOST = 'http://127.0.0.1:8080'
|
||||||
API_EXPLORER = 'http://127.0.0.1:8082'
|
API_EXPLORER_HOST = 'http://127.0.0.1:8082'
|
||||||
# Only override this if you have a separate portal instance
|
# Only override this if you have a separate portal instance
|
||||||
API_PORTAL = API_HOST
|
API_PORTAL = API_HOST
|
||||||
API_BASE_PATH = '/obp/v'
|
API_BASE_PATH = '/obp/v'
|
||||||
|
|||||||
@ -37,8 +37,8 @@ class IndexView(LoginRequiredMixin, FormView):
|
|||||||
else:
|
else:
|
||||||
dynamic_endpoints=response['dynamic_endpoints']
|
dynamic_endpoints=response['dynamic_endpoints']
|
||||||
#Accessing API-Explorer URL, parameters API-Collection Id and selected Language eg. locale=en_GB (for English)
|
#Accessing API-Explorer URL, parameters API-Collection Id and selected Language eg. locale=en_GB (for English)
|
||||||
for locale in dynamic_endpoints:
|
for ac in dynamic_endpoints:
|
||||||
locale["dynamicendpoint_on_api_explorer_url"] = f"{settings.API_EXPLORER}/?api-dynamic_endpoint-id={locale['dynamic_endpoint_id']}"
|
ac["dynamicendpoint_on_api_explorer_url"] = f"{settings.API_EXPLORER_HOST}/?api-dynamic_endpoint-id={ac['dynamic_endpoint_id']}"
|
||||||
except APIError as err:
|
except APIError as err:
|
||||||
messages.error(self.request, err)
|
messages.error(self.request, err)
|
||||||
except Exception as err:
|
except Exception as err:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user