Map: Use standard Leaflet green/red pin icons for GPX route start/end markers in map_iframe_single.html
This commit is contained in:
@@ -263,7 +263,15 @@ def delete_post(post_id):
|
||||
|
||||
current_app.logger.info(f'Found post to delete: ID={post.id}, Title="{title}"')
|
||||
|
||||
|
||||
try:
|
||||
# Delete associated map route if exists
|
||||
from app.models import MapRoute
|
||||
map_route = MapRoute.query.filter_by(post_id=post.id).first()
|
||||
if map_route:
|
||||
db.session.delete(map_route)
|
||||
current_app.logger.info(f'Deleted MapRoute for post {post.id}')
|
||||
|
||||
# Delete associated files and records
|
||||
db.session.delete(post)
|
||||
db.session.commit()
|
||||
|
||||
Reference in New Issue
Block a user