Skip to content

Commit

Permalink
Merge pull request #464 from Xpirix/form_resubmission
Browse files Browse the repository at this point in the history
Feedback resubmission fix
  • Loading branch information
Xpirix authored Nov 21, 2024
2 parents ea5dd31 + 4955a95 commit 10598b8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions dockerize/docker/REQUIREMENTS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,3 +62,4 @@ uwsgi~=2.0
freezegun~=1.4

sentry-sdk~=2.2
setuptools~=74.1
4 changes: 2 additions & 2 deletions qgis-app/plugins/tests/test_plugin_version_feedback.py
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ def test_post_create_single_task_feedback(self):
"feedback": "single line feedback"
}
)
self.assertEqual(response.status_code, 200)
self.assertEqual(response.status_code, 302)
feedbacks = PluginVersionFeedback.objects.filter(
version=self.version_2).all()
self.assertEqual(len(feedbacks), 1)
Expand All @@ -345,7 +345,7 @@ def test_post_create_multiple_task_feedback(self):
"feedback": "- [ ] task one\n - [ ] task two"
}
)
self.assertEqual(response.status_code, 200)
self.assertEqual(response.status_code, 302)
feedbacks = PluginVersionFeedback.objects.filter(
version=self.version_2).all()
self.assertEqual(len(feedbacks), 2)
Expand Down
4 changes: 4 additions & 0 deletions qgis-app/plugins/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -1434,6 +1434,10 @@ def version_feedback(request, package_name, version):
task=task
)
version_feedback_notify(version, request.user)
return HttpResponseRedirect(
reverse('version_feedback',
args=[package_name, version.version])
)
form = VersionFeedbackForm()
feedbacks = PluginVersionFeedback.objects.filter(version=version)
return render(
Expand Down

0 comments on commit 10598b8

Please sign in to comment.