Added a workaround for the not working customRangeLabel option of the daterangepicker component (fixes #2353)

This commit is contained in:
Bernd Bestel 2023-10-04 16:46:24 +02:00
parent 69db4b558b
commit c9215a9a4e
No known key found for this signature in database
GPG Key ID: 71BD34C0D4891300

View File

@ -116,7 +116,6 @@ $("#daterange-filter").daterangepicker({
},
"applyLabel": __t("Apply"),
"cancelLabel": __t("Cancel"),
"customRangeLabel": __t("Custom range"),
"ranges": ranges
}, function(start, end, label)
{
@ -124,6 +123,7 @@ $("#daterange-filter").daterangepicker({
UpdateUriParam("end_date", end.format("YYYY-MM-DD"))
window.location.reload();
});
$('[data-range-key="Custom Range"]').text(__t("Custom range")); // customRangeLabel option doesn't work, however
$("#daterange-filter").on("cancel.daterangepicker", function(ev, picker)
{