04/08 Recalculation of overnight from 12 PM - 3 AM

This commit is contained in:
2026-04-08 17:39:17 -04:00
parent 6e1c9bbc7d
commit 8ad5c4b047
5 changed files with 38 additions and 46 deletions
+2 -6
View File
@@ -200,6 +200,7 @@ def qr_statistics():
today_date=datetime.now().strftime('%Y-%m-%d'))
except Exception as e:
db.session.rollback()
# Log the error using the correct method
logger_handler.log_database_error('statistics_page_error', e)
flash('Error loading statistics. Please try again.', 'error')
@@ -293,13 +294,8 @@ def export_statistics():
return response
except Exception as e:
db.session.rollback()
logger_handler.log_database_error('statistics_export_error', e)
return jsonify({'error': 'Export failed'}), 500
except Exception as e:
# Log the error
logger_handler.log_database_error('statistics_page_error', e)
flash('Error loading statistics. Please try again.', 'error')
return redirect(url_for('dashboard.dashboard'))
# EMPLOYEE MANAGEMENT ROUTES