Skip to content

Commit

Permalink
Merge pull request #84 from davewalker5/scientific-name-in-selector
Browse files Browse the repository at this point in the history
Show scientific name in species drop-down list
  • Loading branch information
davewalker5 authored Oct 29, 2024
2 parents 92a6bd9 + 105cc6b commit 2dfd6f4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
FROM python:3.10-slim-bullseye AS runtime

COPY naturerecorderpy-1.7.0.0 /opt/naturerecorderpy
COPY naturerecorderpy-1.8.0.0 /opt/naturerecorderpy

WORKDIR /opt/naturerecorderpy

RUN apt-get update -y
RUN pip install -r requirements.txt
RUN pip install nature_recorder-1.7.0-py3-none-any.whl
RUN pip install nature_recorder-1.8.0-py3-none-any.whl

ENV NATURE_RECORDER_DATA_FOLDER=/var/opt/naturerecorderpy
ENV NATURE_RECORDER_DB=/var/opt/naturerecorderpy/naturerecorder.db
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def find_package_files(directory, remove_root):

setuptools.setup(
name="nature_recorder",
version="1.7.0",
version="1.8.0",
description="Wildlife sightings database",
packages=setuptools.find_packages("src"),
include_package_data=True,
Expand Down
6 changes: 5 additions & 1 deletion src/naturerec_web/sightings/templates/sightings/species.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@
<option value="">Please select ...</option>
{% for value in species %}
<option value="{{ value.id }}" {% if value.id == species_id %}selected{% endif %}>
{{ value.name }}
{% if value.scientific_name != None %}
{{ value.name }} ( {{value.scientific_name }} )
{% else %}
{{ value.name }}
{% endif %}
</option>
{% endfor %}
</select>

0 comments on commit 2dfd6f4

Please sign in to comment.