From 721800bf2ed0ef6f6d7b5bad75a66f3a4a7674a0 Mon Sep 17 00:00:00 2001 From: Todd Dembrey <todd.dembrey@torchbox.com> Date: Thu, 16 Aug 2018 09:43:38 +0100 Subject: [PATCH] Enable staff to edit the application when not locked --- .../funds/templates/funds/applicationsubmission_form.html | 6 ------ opentech/apply/funds/workflow.py | 7 +++++++ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/opentech/apply/funds/templates/funds/applicationsubmission_form.html b/opentech/apply/funds/templates/funds/applicationsubmission_form.html index 8cfff8a97..bd994fa91 100644 --- a/opentech/apply/funds/templates/funds/applicationsubmission_form.html +++ b/opentech/apply/funds/templates/funds/applicationsubmission_form.html @@ -39,12 +39,6 @@ {% endfor %} </form> </div> - - <aside class="sidebar"> - {% block determination %} - {% include 'determinations/includes/determination_block.html' with submission=object %} - {% endblock %} - </aside> </div> {% endblock %} diff --git a/opentech/apply/funds/workflow.py b/opentech/apply/funds/workflow.py index 59291fdd1..6eebaa692 100644 --- a/opentech/apply/funds/workflow.py +++ b/opentech/apply/funds/workflow.py @@ -117,6 +117,9 @@ class DefaultPermissions(BasePermissions): def can_staff_review(self, user: 'User') -> bool: return True + def can_staff_edit(self, user: 'User') -> bool: + return True + class ReviewerReviewPermissions(DefaultPermissions): def can_reviewer_review(self, user: 'User') -> bool: @@ -127,6 +130,10 @@ class CanEditPermissions(DefaultPermissions): def can_applicant_edit(self, user: 'User') -> bool: return True + def can_staff_edit(self, user: 'User') -> bool: + # Prevent staff editing whilst with the user for edits + return False + Request = Stage('Request', False) -- GitLab