mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2026-02-15 11:36:23 +01:00
[ADD] Locale mapping for DataTables and Moment.JS
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
{% extends "allianceauth/base-bs5.html" %}
|
||||
|
||||
{% load aa_i18n %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block page_title %}
|
||||
@@ -82,6 +83,8 @@
|
||||
{% include "bundles/chart-js.html" %}
|
||||
{% include "bundles/moment-js.html" with locale=True %}
|
||||
|
||||
{% get_datatables_language_static LANGUAGE_CODE as DT_LANG_PATH %}
|
||||
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
const MUMBLESTATS_DATETIME_FORMAT = 'YYYY-MM-DD, HH:mm';
|
||||
@@ -89,6 +92,7 @@
|
||||
'use strict';
|
||||
|
||||
$("#table-mumble-connection-history").DataTable({
|
||||
language: {url: '{{ DT_LANG_PATH }}'},
|
||||
ajax: {
|
||||
url: '{% url "mumble:connection_history_data" %}',
|
||||
dataSrc: 'connection_history_data',
|
||||
@@ -132,6 +136,7 @@
|
||||
});
|
||||
|
||||
$("#table-mumble-connection-stats").DataTable({
|
||||
language: {url: '{{ DT_LANG_PATH }}'},
|
||||
ajax: {
|
||||
url: '{% url "mumble:release_counts_data" %}',
|
||||
dataSrc: 'release_counts_data',
|
||||
|
||||
Reference in New Issue
Block a user