Date group updated..

This commit is contained in:
Cüneyt Şentürk 2021-02-23 22:28:18 +03:00
parent 9065ee764f
commit 683745e851
7 changed files with 8 additions and 5 deletions

View File

@ -87,6 +87,7 @@ export default {
created() {
if (this.locale !== 'en') {
const lang = require(`flatpickr/dist/l10n/${this.locale}.js`).default[this.locale];
this.config.locale = lang;
}
},

View File

@ -40,6 +40,7 @@
@elseif ($type == 'dateGroup')
{{ Form::$type($field['name'], $field['title'], $field['icon'], array_merge([
'data-field' => 'settings',
'show-date-format' => company_date_format(),
],
$field['attributes']),
isset($report->settings->{$field['name']}) ? $report->settings->{$field['name']}: null

View File

@ -10,7 +10,7 @@
<base-alert type="warning" v-if="typeof form.response !== 'undefined' && form.response.error" v-html="form.response.message"></base-alert>
<div class="row">
{{ Form::dateGroup('paid_at', trans('general.date'), 'calendar', ['id' => 'paid_at', 'required' => 'required', 'date-format' => 'Y-m-d', 'autocomplete' => 'off'], Date::now()->toDateString()) }}
{{ Form::dateGroup('paid_at', trans('general.date'), 'calendar', ['id' => 'paid_at', 'required' => 'required', 'show-date-format' => company_date_format(), 'date-format' => 'Y-m-d', 'autocomplete' => 'off'], Date::now()->toDateString()) }}
{{ Form::moneyGroup('amount', trans('general.amount'), 'money-bill-alt', ['required' => 'required', 'autofocus' => 'autofocus', 'currency' => $currency, 'dynamic-currency' => 'currency'], $document->grand_total) }}

View File

@ -40,7 +40,7 @@
maxDate: {{ $attributes['max-date'] }}
@endif
}"
locale="{{ language()->getShortCode() }}"
@if (!empty($attributes['v-model']))

View File

@ -43,7 +43,7 @@
maxDate: {{ $attributes['max-date'] }}
@endif
}"
locale="{{ language()->getShortCode() }}"
@if (!empty($attributes['v-model']))

View File

@ -11,7 +11,8 @@
{{ Form::$type($field['name'], $field['title']) }}
@elseif ($type == 'dateGroup')
{{ Form::$type($field['name'], $field['title'], $field['icon'], array_merge([
'model' => 'form.settings'.'.'.$field['name']
'model' => 'form.settings'.'.'.$field['name'],
'show-date-format' => company_date_format(),
],
$field['attributes'])
) }}

View File

@ -34,7 +34,7 @@
@elseif ($type == 'fileGroup')
{{ Form::$type($field['name'], trans($field['title']), $field['attributes']) }}
@elseif ($type == 'dateGroup')
{{ Form::$type($field['name'], trans($field['title']), $field['icon'], array_merge(['id' => $field['name'], 'date-format' => 'Y-m-d', 'autocomplete' => 'off'], $field['attributes']), Date::parse($setting[$field['name']] ?? now())->toDateString()) }}
{{ Form::$type($field['name'], trans($field['title']), $field['icon'], array_merge(['id' => $field['name'], 'date-format' => 'Y-m-d', 'show-date-format' => company_date_format(), 'autocomplete' => 'off'], $field['attributes']), Date::parse($setting[$field['name']] ?? now())->toDateString()) }}
@elseif ($type == 'accountSelectGroup')
{{ Form::selectGroup($field['name'], trans_choice('general.accounts', 1), 'university', $accounts, setting($module->getAlias() . '.' . $field['name']), $field['attributes']) }}
@elseif ($type == 'categorySelectGroup')