Skip to content

Commit

Permalink
Fix review editing
Browse files Browse the repository at this point in the history
  • Loading branch information
guerler committed Dec 6, 2017
1 parent 9fc4817 commit 662e01a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
Expand Up @@ -274,6 +274,7 @@ def edit_review(self, trans, **kwd):
saved_component_names = []
for component_name in components_dict.keys():
flushed = False
private = None
# Retrieve the review information from the form.
# The star rating form field is a radio button list, so it will not be received if it was not clicked in the form.
# Due to this behavior, default the value to 0.
Expand Down
7 changes: 4 additions & 3 deletions templates/webapps/tool_shed/common/common.mako
@@ -1,10 +1,11 @@
<%def name="render_checkbox(checkbox)">
<%def name="render_checkbox(checkbox, disabled=False, refresh_on_change=False)">
<% from galaxy.web.form_builder import CheckboxField %>
<input type="checkbox" id="${checkbox.name}" name="${checkbox.name}" value="true" ${"checked" if CheckboxField.is_checked(checkbox.value) else ""} >
<input type="checkbox" id="${checkbox.name}" name="${checkbox.name}" value="true" refresh_on_change=${refresh_on_change} ${"checked" if CheckboxField.is_checked(checkbox.value) else ""} ${"disabled" if disabled else ""}
>
</%def>
<%def name="render_select(select)">
<select name="${select.name}" refresh_on_change="true">
<select name="${select.name}">
%for o in select.options:
<option value="${o[1]}">${o[0]}</option>
%endfor
Expand Down
Expand Up @@ -73,7 +73,7 @@ ${render_tool_shed_repository_actions( repository=repository, changeset_revision
<tr>
<td>
<label>Private:</label>
${private_check_box.get_html( disabled=True )}
${render_checkbox(private_check_box, disabled=True)}
<div class="toolParamHelp" style="clear: both;">
A private review can be accessed only by the owner of the repository and authorized repository reviewers.
</div>
Expand Down

0 comments on commit 662e01a

Please sign in to comment.