James Cole
2024-10-18 07:35:19 +02:00
parent 02233fd7a4
commit 7f3e3fc3bf
2 changed files with 2 additions and 3 deletions

View File

@@ -107,7 +107,6 @@ class JavascriptController extends Controller
$lang = $pref->data; $lang = $pref->data;
$dateRange = $this->getDateRangeConfig(); $dateRange = $this->getDateRangeConfig();
$uid = substr(hash('sha256', sprintf('%s-%s-%s', (string)config('app.key'), auth()->user()->id, auth()->user()->email)), 0, 12); $uid = substr(hash('sha256', sprintf('%s-%s-%s', (string)config('app.key'), auth()->user()->id, auth()->user()->email)), 0, 12);
$data = [ $data = [
'currencyCode' => $currency->code, 'currencyCode' => $currency->code,
'currencySymbol' => $currency->symbol, 'currencySymbol' => $currency->symbol,

View File

@@ -1,12 +1,12 @@
// date ranges // date ranges
var ranges = {}; var ranges = {};
{% for title, range in dateRangeConfig.ranges %} {% for title, range in dateRangeConfig.ranges %}
ranges["{{ title }}"] = [moment("{{ range[0].format('Y-m-d') }}"), moment("{{ range[1].format('Y-m-d') }}")]; ranges["{{ title|escape('js') }}"] = [moment("{{ range[0].format('Y-m-d') }}"), moment("{{ range[1].format('Y-m-d') }}")];
{% endfor %} {% endfor %}
// date range meta configuration // date range meta configuration
var dateRangeMeta = { var dateRangeMeta = {
title: "{{ dateRangeTitle }}", title: "{{ dateRangeTitle|escape('js') }}",
url: "{{ route('daterange') }}", url: "{{ route('daterange') }}",
labels: { labels: {
apply: "{{ 'apply'|_ }}", apply: "{{ 'apply'|_ }}",