Skip to content
This repository has been archived by the owner on Feb 22, 2020. It is now read-only.

Commit

Permalink
Merged branch issue77 into master
Browse files Browse the repository at this point in the history
  • Loading branch information
rahit committed Aug 27, 2017
2 parents b482514 + 18b3b28 commit 7a0cc19
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
2 changes: 2 additions & 0 deletions interface/backend/api/urls.py
Expand Up @@ -9,6 +9,7 @@
CandidateViewSet,
NoduleViewSet,
ImageSeriesViewSet,
ImageSrcApiView
)

router = routers.DefaultRouter()
Expand All @@ -19,5 +20,6 @@

urlpatterns = [
url(r'^', include(router.urls)),
url(r'^image_src/$', ImageSrcApiView.as_view()),
url(r'^api-auth/', include('rest_framework.urls', namespace='rest_framework'))
]
12 changes: 12 additions & 0 deletions interface/backend/api/views.py
Expand Up @@ -6,6 +6,7 @@
Candidate,
Nodule,
)
from rest_framework.views import APIView
from backend.images.models import ImageSeries


Expand All @@ -27,3 +28,14 @@ class NoduleViewSet(viewsets.ModelViewSet):
class ImageSeriesViewSet(viewsets.ModelViewSet):
queryset = ImageSeries.objects.all()
serializer_class = serializers.ImageSeriesSerializer


class ImageSrcApiView(APIView):
"""
View list of images from dataset directory
"""
def get(self, request):
"""
Return a list of files and folders in dataset
"""
pass
2 changes: 1 addition & 1 deletion interface/frontend/index.html
Expand Up @@ -104,7 +104,7 @@ <h3 class="card-title">{{ selected.patient_id }}</h3>
methods: {
fetchData: function () {
var vm = this;
this.$http.get('/api/images/').then(
this.$http.get('/api/image_src/').then(
function (response) {
this.availableSeries = response.body;
}, function () {
Expand Down

0 comments on commit 7a0cc19

Please sign in to comment.