Skip to content

Commit

Permalink
Add donate link to footer (#1127)
Browse files Browse the repository at this point in the history
## Fixes issue
#215

## Description of Changes
Added a `Donate` link to the footer so that it is available on all pages
throughout the application instead of just the home page. I also updated
the casing of `Download department data` so that it matches the rest of
the casing on the footer.

## Screenshots (if appropriate)
Before:
<img width="1470" alt="Screenshot 2024-10-03 at 4 25 31 PM"
src="https://github.com/user-attachments/assets/62f9b72c-f72d-437b-86ce-60a350f16101">

After:
<img width="1470" alt="Screenshot 2024-10-03 at 4 26 08 PM"
src="https://github.com/user-attachments/assets/92ffee96-1594-4adc-97be-d965ee87c3d0">

## Tests and Linting
- [x] This branch is up-to-date with the `develop` branch.
- [x] `pytest` passes on my local development environment.
- [x] `pre-commit` passes on my local development environment.
  • Loading branch information
michplunkett authored Oct 4, 2024
1 parent 710019e commit 059c565
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
4 changes: 3 additions & 1 deletion OpenOversight/app/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,9 @@ <h5>OpenOversight</h5>
<br>
<a href="https://lucyparsonslabs.com/" target="_blank">Lucy Parsons Labs</a>
<br>
<a href="{{ url_for("main.all_data") }}" target="_blank">Download department data</a>
<a href="https://lucyparsonslabs.com/donate" target="_blank">Donate</a>
<br>
<a href="{{ url_for("main.all_data") }}" target="_blank">Download Department Data</a>
</p>
</div>
<div class="col-sm-4">
Expand Down
6 changes: 6 additions & 0 deletions OpenOversight/tests/routes/test_other.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ def test_routes_ok(route, client, mockdata):
rv = client.get(route)
assert rv.status_code == HTTPStatus.OK

# Assert donate link is in all base pages
assert (
'<a href="https://lucyparsonslabs.com/donate" target="_blank">Donate</a>'
in rv.data.decode()
)


def test_user_can_access_profile(client, session):
with current_app.test_request_context():
Expand Down

0 comments on commit 059c565

Please sign in to comment.