Skip to content

Commit

Permalink
Grey out URL field in annotate & report to avoid non-existent URLs be…
Browse files Browse the repository at this point in the history
…ing processed
  • Loading branch information
gossminn committed Feb 27, 2025
1 parent b538af7 commit ec8d8dc
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions app/templates/base/_formhelpers.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
{% endmacro %}


{% macro render_field(field) %}
{% macro render_field(field, disabled=False) %}
<div class="form-group">
{{ field.label }}
{{ field(class_="form-control input-s", size=32) }}
{{ field(class_="form-control input-s", disabled=disabled, size=32) }}
</div>
<dd>{% if field.errors %}
<ul class=errors>
Expand Down
2 changes: 1 addition & 1 deletion app/templates/orchard/annotate.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<br>
<form method="POST" action="/orchard/annotate" enctype="multipart/form-data">
{{ form.hidden_tag() }}
<p>{{ render_field(form.url) }}</p>
<p>{{ render_field(form.url, disabled=True) }}</p>
<p>{{ render_field(form.note) }}</p>
<div class="form-check">
{{ form.accept_tos(class_="form-check-input") }}
Expand Down
2 changes: 1 addition & 1 deletion app/templates/orchard/report.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<br><br>
<form method="POST" action="/orchard/report" enctype="multipart/form-data">
{{ form.hidden_tag() }}
<p>{{ render_field(form.url) }}</p>
<p>{{ render_field(form.url, disabled=True) }}</p>
<p>{{ render_field(form.report) }}</p>
<div class="form-check">
{{ form.accept_tos(class_="form-check-input") }}
Expand Down

0 comments on commit ec8d8dc

Please sign in to comment.