diff --git a/loko/home/migrations/0009_alter_homewidget_widget_code.py b/loko/home/migrations/0009_alter_homewidget_widget_code.py new file mode 100644 index 0000000..f2d7948 --- /dev/null +++ b/loko/home/migrations/0009_alter_homewidget_widget_code.py @@ -0,0 +1,18 @@ +# Generated by Django 6.0.7 on 2026-09-21 14:38 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('home', '0008_create_controller_shortcuts_widget'), + ] + + operations = [ + migrations.AlterField( + model_name='homewidget', + name='widget_code', + field=models.CharField(choices=[('territory_kpis', 'Métriques du patrimoine'), ('recent_activity', "Radar d'activité"), ('intervention_stats', 'Statistiques interventions'), ('contracts_summary', 'Résumé contrats'), ('map_today', 'Carte du jour'), ('operator_shortcuts', 'Raccourcis opérateur'), ('assets_links', 'Liens assets'), ('stock_summary', 'Résumé stock'), ('observer_shortcuts', 'Raccourcis observateur'), ('incident_counter', 'Compteur incidents à traiter'), ('intervention_to_verify', 'Compteur interventions à vérifier'), ('intervention_to_plan', 'Compteur interventions à planifier'), ('intervention_to_approve', 'Compteur interventions à approuver'), ('intervention_checked_to_approve', 'Compteur interventions vérifiées à approuver'), ('intervention_finished', 'Compteur interventions terminées'), ('intervention_on_pause', 'Compteur interventions en pause'), ('external_interventions', 'Interventions externes'), ('stock_actions', 'Actions stock'), ('exceptional_transport', 'Transport exceptionnel'), ('controller_shortcuts', 'Raccourcis contrôleur')], max_length=50, unique=True, verbose_name='Code du widget'), + ), + ] diff --git a/loko/home/static/home/home_index.js b/loko/home/static/home/home_index.js index 9bfc4f9..6c6db09 100644 --- a/loko/home/static/home/home_index.js +++ b/loko/home/static/home/home_index.js @@ -350,9 +350,9 @@ if (mapContainer && typeof maplibregl !== 'undefined') { } else { renderLegend(); } + } catch (e) { + console.error("Could not load activity geojson:", e); } - } catch (e) { - console.error("Could not load activity geojson:", e); } }); diff --git a/loko/home/templates/home/home_index.html b/loko/home/templates/home/home_index.html index 33968aa..8de7f91 100644 --- a/loko/home/templates/home/home_index.html +++ b/loko/home/templates/home/home_index.html @@ -186,5 +186,5 @@ - + {% endblock script %}