Changed default image so static/icons can be cleared without issue

This commit is contained in:
2025-04-21 13:55:53 +02:00
parent 26f9f20b53
commit 52025a55c2
4 changed files with 11 additions and 7 deletions

View File

@@ -5,7 +5,7 @@ from flask_login import LoginManager # type: ignore
import os
# App Config
app = Flask(__name__)
app = Flask(__name__, instance_relative_config=True)
app.config["SQLALCHEMY_DATABASE_URI"] = "sqlite:///services.sqlite"
app.config["SQLALCHEMY_TRACK_MODIFICATIONS"] = False # Wat is dit?
app.config["SECRET_KEY"] = "bvjchsygvduycgsyugc" # Andere secret key

View File

@@ -10,20 +10,23 @@
<div class="col" onclick="location.href='{{service.url}}';" style="cursor: pointer;">
{{service["name"]}}
</div>
<div class="col-sm-3 dots dropdown">
<button class="btn btn-light py-0" type="button" id="threeDotDropdown" data-bs-toggle="dropdown" aria-expanded="false">
<button class="btn btn-light py-0" type="button" id="threeDotDropdown" data-bs-toggle="dropdown"
aria-expanded="false">
&#x22EE;
</button>
<ul class="dropdown-menu" aria-labelledby="threeDotDropdown">
<li>
<a class="dropdown-item" href="{{ url_for('dash.edit_service', service_id=service.id) }}">Edit</a>
<a class="dropdown-item"
href="{{ url_for('dash.edit_service', service_id=service.id) }}">Edit</a>
</li>
<li>
<hr class="dropdown-divider">
</li>
<li>
<form action="{{ url_for('dash.delete_service', service_id=service.id) }}" method="POST" style="display:inline;">
<form action="{{ url_for('dash.delete_service', service_id=service.id) }}" method="POST"
style="display:inline;">
<button style="color: red;" type="submit" class="dropdown-item">Delete</button>
</form>
</li>
@@ -32,7 +35,8 @@
</div>
<div class="row">
<div class="col-sm-9" onclick="location.href='{{service.url}}';" style="cursor: pointer;">
<img class="fit-picture" src="{{ url_for('static', filename='icons/'+service['icon'])}}">
<img class="fit-picture" src="{{ url_for('static', filename='icons/'+service['icon'])}}"
onerror="this.onerror=null; this.src='{{url_for('static', filename='google.png')}}';">
</div>
</div>
<div class="row">
@@ -43,4 +47,4 @@
</div>
{% endfor %}
</div>
{%endblock%}
{%endblock%}

View File

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB