From 4627a5e5ee6c2cec30a9b3eb742cef0d9346983e Mon Sep 17 00:00:00 2001 From: SteffRhes Date: Tue, 28 Nov 2023 17:32:43 +0100 Subject: [PATCH] bug fix on entity creation Was due to missing url routing because apis/urls.py hadn't contained the same data as apis-core/apis/urls.py had. Namely generic URI routing to + /entity/. --- apis/settings/base.py | 3 ++- apis/urls.py | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/apis/settings/base.py b/apis/settings/base.py index 6ae3796..803805f 100644 --- a/apis/settings/base.py +++ b/apis/settings/base.py @@ -133,7 +133,8 @@ {"NAME": "django.contrib.auth.password_validation.NumericPasswordValidator"}, ] -APIS_BASE_URI = "https://sola.acdh-dev.oeaw.ac.at/apis/api/entity/" +APIS_BASE_URI = "https://sola.acdh-dev.oeaw.ac.at/" + APIS_MIN_CHAR = 3 diff --git a/apis/urls.py b/apis/urls.py index 3e2abc3..b1fe33e 100644 --- a/apis/urls.py +++ b/apis/urls.py @@ -2,13 +2,16 @@ from django.contrib import admin from django.conf import settings from rest_framework import routers +from django.urls import path +from apis_core.apis_entities.api_views import GetEntityGeneric urlpatterns = [ - url(r'^apis/', include('apis_core.urls', namespace="apis")), + url(r'^apis/', include('apis_core.urls', namespace="apis")), url(r'^bibsonomy/', include('apis_bibsonomy.urls', namespace="bibsonomy")), url(r'^api-auth/', include('rest_framework.urls', namespace='rest_framework')), url(r'^bibsonomy/', include('apis_bibsonomy.urls', namespace="bibsonomy")), + path(r"entity//", GetEntityGeneric.as_view(), name="GetEntityGenericRoot"), url(r'^admin/', admin.site.urls), url(r'^', include('webpage.urls', namespace='webpage')), ]