From 52a4127913126be41e835b64de74d8b684d616dc Mon Sep 17 00:00:00 2001
From: Fredrik Jonsson <frjo@xdeb.org>
Date: Thu, 28 May 2020 09:25:54 +0200
Subject: [PATCH] Followup changes after crating new draft workflow state.

---
 hypha/apply/funds/views.py  | 2 +-
 hypha/apply/review/views.py | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/hypha/apply/funds/views.py b/hypha/apply/funds/views.py
index a4d03f77d..5fb60dbe0 100644
--- a/hypha/apply/funds/views.py
+++ b/hypha/apply/funds/views.py
@@ -137,7 +137,7 @@ class UpdateReviewersMixin:
             action = None
             if submission.status == INITIAL_STATE:
                 # Automatically transition the application to "Internal review".
-                action = submission.workflow.stepped_phases[1][0].name
+                action = submission.workflow.stepped_phases[2][0].name
             elif submission.status == 'proposal_discussion':
                 # Automatically transition the proposal to "Internal review".
                 action = 'proposal_internal_review'
diff --git a/hypha/apply/review/views.py b/hypha/apply/review/views.py
index d4ed8a4db..06526cf68 100644
--- a/hypha/apply/review/views.py
+++ b/hypha/apply/review/views.py
@@ -187,13 +187,13 @@ def review_workflow_actions(request, submission):
     action = None
     if submission.status == INITIAL_STATE:
         # Automatically transition the application to "Internal review".
-        action = submission_stepped_phases[1][0].name
+        action = submission_stepped_phases[2][0].name
     elif submission.status == 'proposal_discussion':
         # Automatically transition the proposal to "Internal review".
         action = 'proposal_internal_review'
-    elif submission.status == submission_stepped_phases[1][0].name and submission.reviews.count() > 1:
+    elif submission.status == submission_stepped_phases[2][0].name and submission.reviews.count() > 1:
         # Automatically transition the application to "Ready for discussion".
-        action = submission_stepped_phases[2][0].name
+        action = submission_stepped_phases[3][0].name
     elif submission.status == 'ext_external_review' and submission.reviews.by_reviewers().count() > 1:
         # Automatically transition the application to "Ready for discussion".
         action = 'ext_post_external_review_discussion'
-- 
GitLab