-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Inlining review and fact check activity fields
www.agileplannerapp.com/boards/173808/cards/5629 ... with edition form. these were left out earlier, causing review activities to not save edition changes. part of a larger change: #251
- Loading branch information
Vinay Patel
committed
Sep 10, 2014
1 parent
34556c2
commit 7649d01
Showing
11 changed files
with
34 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
<div class="alert alert-info"> | ||
<p>Request this edition to be amended further.</p> | ||
<%= render 'shared/request_amendments' %> | ||
<%= render 'shared/request_amendments', locals: { render_activity_forms: render_activity_forms } %> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,19 @@ | ||
<% # edition transitions are done using fields inlined in the edition form. | ||
# we need to render activity forms to allow edition transitions on views | ||
# where activity fields are not inlined with edition form. | ||
render_activity_forms = false unless defined?(:render_activity_forms) %> | ||
|
||
<% if @resource.in_review? %> | ||
<%= render '/shared/review' %> | ||
<%= render '/shared/review', render_activity_forms: render_activity_forms %> | ||
<% elsif @resource.fact_check? %> | ||
<%= render '/shared/fact_check' %> | ||
<%= render '/shared/fact_check', render_activity_forms: render_activity_forms %> | ||
<% elsif @resource.fact_check_received? %> | ||
<%= render '/shared/fact_check_received' %> | ||
<%= render '/shared/fact_check_received', render_activity_forms: render_activity_forms %> | ||
<% elsif @resource.fact_check_skipped? %> | ||
<div class="alert alert-info"> | ||
<p>Fact check was skipped for this edition.</p> | ||
</div> | ||
<%= render '/shared/ready' %> | ||
<%= render '/shared/ready', render_activity_forms: render_activity_forms %> | ||
<% elsif @resource.ready? %> | ||
<%= render '/shared/ready' %> | ||
<%= render '/shared/ready', render_activity_forms: render_activity_forms %> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,6 @@ | ||
<% render_activity_forms = false unless defined?(:render_activity_forms) %> | ||
|
||
<%= build_review_button(@resource, "request_amendments", "Needs more work").html_safe %> | ||
<%= edition_activities_forms(@resource, request_amendments: "Request amendments") %> | ||
<% if render_activity_forms %> | ||
<%= edition_activities_forms(@resource, request_amendments: "Request amendments") %> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters