diff --git a/.DS_Store b/.DS_Store index 952c9f83..64e88bb6 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/osinaweb/.DS_Store b/osinaweb/.DS_Store index 58387e56..8b9af095 100644 Binary files a/osinaweb/.DS_Store and b/osinaweb/.DS_Store differ diff --git a/osinaweb/db.sqlite3 b/osinaweb/db.sqlite3 index f41da46d..dcc9f2de 100644 Binary files a/osinaweb/db.sqlite3 and b/osinaweb/db.sqlite3 differ diff --git a/osinaweb/osinacore/.DS_Store b/osinaweb/osinacore/.DS_Store index bf21a061..fec57147 100644 Binary files a/osinaweb/osinacore/.DS_Store and b/osinaweb/osinacore/.DS_Store differ diff --git a/osinaweb/osinacore/__pycache__/urls.cpython-310.pyc b/osinaweb/osinacore/__pycache__/urls.cpython-310.pyc index 7fed1287..34705951 100644 Binary files a/osinaweb/osinacore/__pycache__/urls.cpython-310.pyc and b/osinaweb/osinacore/__pycache__/urls.cpython-310.pyc differ diff --git a/osinaweb/osinacore/__pycache__/views.cpython-310.pyc b/osinaweb/osinacore/__pycache__/views.cpython-310.pyc index a55176bb..7bc0d61b 100644 Binary files a/osinaweb/osinacore/__pycache__/views.cpython-310.pyc and b/osinaweb/osinacore/__pycache__/views.cpython-310.pyc differ diff --git a/osinaweb/osinacore/add/__pycache__/urls.cpython-310.pyc b/osinaweb/osinacore/add/__pycache__/urls.cpython-310.pyc index b54f5f17..fedff0fe 100644 Binary files a/osinaweb/osinacore/add/__pycache__/urls.cpython-310.pyc and b/osinaweb/osinacore/add/__pycache__/urls.cpython-310.pyc differ diff --git a/osinaweb/osinacore/add/__pycache__/views.cpython-310.pyc b/osinaweb/osinacore/add/__pycache__/views.cpython-310.pyc index 8fd7241d..2bb551e8 100644 Binary files a/osinaweb/osinacore/add/__pycache__/views.cpython-310.pyc and b/osinaweb/osinacore/add/__pycache__/views.cpython-310.pyc differ diff --git a/osinaweb/osinacore/add/urls.py b/osinaweb/osinacore/add/urls.py index fa822197..59b7659c 100644 --- a/osinaweb/osinacore/add/urls.py +++ b/osinaweb/osinacore/add/urls.py @@ -11,6 +11,7 @@ urlpatterns = [ path('businessmodal/', views.add_business_modal, name='addbusinessmodal'), path('staff/', views.add_staff, name='adduser'), path('project/', views.add_project, name='addproject'), + path('userstory//', views.add_user_story_modal, name='adduserstorymodal'), path('projectnote//', views.add_project_note_modal, name='addprojectnotemodal'), path('file/', views.add_file_modal, name='addfilemodal'), path('credential/', views.add_credential_modal, name='addcredentialmodal'), diff --git a/osinaweb/osinacore/add/views.py b/osinaweb/osinacore/add/views.py index 8cb9a252..755a2909 100644 --- a/osinaweb/osinacore/add/views.py +++ b/osinaweb/osinacore/add/views.py @@ -279,6 +279,31 @@ def add_project(request): return render(request, 'add_templates/add-project.html', context) +def add_user_story_modal(request, project_id): + project = get_object_or_404(Project, project_id=project_id) + if request.method == 'POST': + content = request.POST.get('content') + + story = ProjectRequirement( + content = content, + project = project, + added_by = request.user, + ) + story.save() + # Reload the parent page using JavaScript + response = HttpResponse('') + return response + + + context = { + + 'project' : project, + + } + + return render(request, 'add_templates/add-userstory-modal.html', context) + + def add_project_note_modal(request, project_id): diff --git a/osinaweb/osinacore/templates/.DS_Store b/osinaweb/osinacore/templates/.DS_Store index 9cd29b59..29ace2ca 100644 Binary files a/osinaweb/osinacore/templates/.DS_Store and b/osinaweb/osinacore/templates/.DS_Store differ diff --git a/osinaweb/osinacore/templates/add_templates/add-userstory-modal.html b/osinaweb/osinacore/templates/add_templates/add-userstory-modal.html index e0616879..a18ac2ae 100644 --- a/osinaweb/osinacore/templates/add_templates/add-userstory-modal.html +++ b/osinaweb/osinacore/templates/add_templates/add-userstory-modal.html @@ -13,7 +13,7 @@ -
+ {% csrf_token %}

Add User Story

diff --git a/osinaweb/osinacore/templates/details_pages/project-details.html b/osinaweb/osinacore/templates/details_pages/project-details.html index f410ff49..0e3d053c 100644 --- a/osinaweb/osinacore/templates/details_pages/project-details.html +++ b/osinaweb/osinacore/templates/details_pages/project-details.html @@ -274,7 +274,7 @@ diff --git a/osinaweb/osinacore/templates/popup_modals/.DS_Store b/osinaweb/osinacore/templates/popup_modals/.DS_Store index 4a373ee2..fa066f82 100644 Binary files a/osinaweb/osinacore/templates/popup_modals/.DS_Store and b/osinaweb/osinacore/templates/popup_modals/.DS_Store differ diff --git a/osinaweb/osinacore/templates/popup_modals/add-project-note-modal.html b/osinaweb/osinacore/templates/popup_modals/add-project-note-modal.html deleted file mode 100644 index bd95f5c6..00000000 --- a/osinaweb/osinacore/templates/popup_modals/add-project-note-modal.html +++ /dev/null @@ -1,116 +0,0 @@ -{% load static %} - - - - - - - - Osina - - - - - - - - - {% csrf_token %} -

Add Note

- -
- - - -
- -
-
- -
- -
- -
- -
- -
- -
- -
- -
- -
- -
- -
-
- -
- -
- - - -
- -
-
- - - \ No newline at end of file diff --git a/osinaweb/osinacore/templates/popup_modals/add-userstory-modal.html b/osinaweb/osinacore/templates/popup_modals/add-userstory-modal.html deleted file mode 100644 index e0616879..00000000 --- a/osinaweb/osinacore/templates/popup_modals/add-userstory-modal.html +++ /dev/null @@ -1,32 +0,0 @@ -{% load static %} - - - - - - - Osina - - - - - - - -
- {% csrf_token %} -

Add User Story

- -
- -
- -
- -
-
- - \ No newline at end of file diff --git a/osinaweb/osinacore/templates/popup_modals/addcredentials-modal.html b/osinaweb/osinacore/templates/popup_modals/addcredentials-modal.html deleted file mode 100644 index 0f4bff0f..00000000 --- a/osinaweb/osinacore/templates/popup_modals/addcredentials-modal.html +++ /dev/null @@ -1,39 +0,0 @@ -{% load static %} - - - - - - - - Osina - - - - - - - -
-

Add Credential

- -
- -
- -
- -
- -
- -
- -
- -
-
- - - \ No newline at end of file diff --git a/osinaweb/osinacore/templates/popup_modals/addfile-modal.html b/osinaweb/osinacore/templates/popup_modals/addfile-modal.html deleted file mode 100644 index ff6dd06a..00000000 --- a/osinaweb/osinacore/templates/popup_modals/addfile-modal.html +++ /dev/null @@ -1,86 +0,0 @@ -{% load static %} - - - - - - - - Osina - - - - - - - -
-

Add File

- -
-
- -
- - - -
-
- - Upload - Document(s) - -
-
- -
- -
-
-
- - - - - - - - - \ No newline at end of file diff --git a/osinaweb/osinacore/templates/popup_modals/addtag-modal.html b/osinaweb/osinacore/templates/popup_modals/addtag-modal.html deleted file mode 100644 index 87ba5017..00000000 --- a/osinaweb/osinacore/templates/popup_modals/addtag-modal.html +++ /dev/null @@ -1,32 +0,0 @@ -{% load static %} - - - - - - - Osina - - - - - - - -
- {% csrf_token %} -

Add Tag

- -
- -
- -
- -
-
- - \ No newline at end of file diff --git a/osinaweb/osinacore/templates/popup_modals/addtime-modal.html b/osinaweb/osinacore/templates/popup_modals/addtime-modal.html deleted file mode 100644 index 1e2375de..00000000 --- a/osinaweb/osinacore/templates/popup_modals/addtime-modal.html +++ /dev/null @@ -1,33 +0,0 @@ -{% load static %} - - - - - - - Osina - - - - - - - -
-

Add Timeline

- -
- - - -
- -

Value in minutes

- -
- -
-
- - \ No newline at end of file diff --git a/osinaweb/osinacore/urls.py b/osinaweb/osinacore/urls.py index c31367fb..03055550 100644 --- a/osinaweb/osinacore/urls.py +++ b/osinaweb/osinacore/urls.py @@ -61,7 +61,6 @@ urlpatterns = [ #Modals urls - path('add-user-story//', views.add_user_story_modal, name='adduserstory'), path('update-status//', views.update_status_modal, name='updatestatus'), path('show-points//', views.show_points_modal, name='showpoints'), path('timeline/', views.timeline_modal, name='timeline'), diff --git a/osinaweb/osinacore/views.py b/osinaweb/osinacore/views.py index 08b5b4e4..b7b2bbb8 100644 --- a/osinaweb/osinacore/views.py +++ b/osinaweb/osinacore/views.py @@ -403,32 +403,6 @@ def add_business_modal(request, *args, **kwargs): -def add_user_story_modal(request, project_id): - project = get_object_or_404(Project, project_id=project_id) - if request.method == 'POST': - content = request.POST.get('content') - - story = ProjectRequirement( - content = content, - project = project, - added_by = request.user, - ) - story.save() - # Reload the parent page using JavaScript - response = HttpResponse('') - return response - - - context = { - - 'project' : project, - - } - - return render(request, 'popup_modals/add-userstory-modal.html', context) - - - def status_mobile_modal (request, *args, **kwargs):