Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync with DCC/Development #549

Merged
merged 5 commits into from
Jul 31, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/controllers/plans_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def template_options(org_id, funder_id)
# If no templates were available use the generic templates
if @templates.empty?
@msg = _("Using the generic Data Management Plan")
@templates << Template.find_by(is_default: true)
@templates << Template.where(is_default: true, published: true).first
end

@templates = @templates.sort{|x,y| x.title <=> y.title } if @templates.count > 1
Expand Down
25 changes: 11 additions & 14 deletions app/views/guidance_groups/admin_edit.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -33,20 +33,17 @@
</div>
</td>
</tr>
<!-- if guidance group published then display check_box -->
<% if @guidance_group.published == true then %>
<tr>
<td class="first"><%= _('Published') %></td>
<td>
<div class="div_left_icon_g">
<%= f.check_box :published %>
</div>
<div class="div_right_icon_g">
<!--%= link_to( image_tag('help_button.png'), '#', :class => 'guidance_group_subset_popover', :rel => "popover", 'data-html' => "true", 'data-content' => _('If the guidance is only meant for a subset of users e.g. those in a specific college or institute, check this box. Users will be able to select to display this subset guidance when answering questions in the 'create plan' wizard.'))%-->
</div>
</td>
</tr>
<% end %>
<tr>
<td class="first"><%= _('Published') %></td>
<td>
<div class="div_left_icon_g">
<%= f.check_box :published %>
</div>
<div class="div_right_icon_g">
<!--%= link_to( image_tag('help_button.png'), '#', :class => 'guidance_group_subset_popover', :rel => "popover", 'data-html' => "true", 'data-content' => _('If the guidance is only meant for a subset of users e.g. those in a specific college or institute, check this box. Users will be able to select to display this subset guidance when answering questions in the 'create plan' wizard.'))%-->
</div>
</td>
</tr>

<tr>
<td class="first"><%= _('Optional subset') %></td>
Expand Down