83 lines
2.5 KiB
PHP
Raw Normal View History

2019-11-16 10:21:14 +03:00
@stack($name . '_input_start')
2022-06-01 10:15:55 +03:00
<akaunting-money
@if (! empty($attributes['v-error']))
:form-classes="[{'has-error': {{ $attributes['v-error'] }} }]"
@else
:form-classes="[{'has-error': form.errors.has('{{ $name }}') }]"
@endif
2022-06-01 10:15:55 +03:00
col="{{ $formGroupClass }}"
@if (! empty($attributes['money-class']))
2020-12-29 21:55:21 +03:00
money-class="{{ $attributes['money-class'] }}"
@endif
2022-06-01 10:15:55 +03:00
@if ($required)
:required="{{ ($required) ? 'true' : 'false' }}"
@endif
2022-06-01 10:15:55 +03:00
@if ($readonly)
:readonly="{{ $readonly }}"
@endif
2022-06-01 10:15:55 +03:00
@if ($disabled)
:disabled="{{ $disabled }}"
@endif
2019-11-16 10:21:14 +03:00
2022-06-01 10:15:55 +03:00
@if (isset($attributes['v-show']))
v-if="{{ $attributes['v-show'] }}"
@endif
@if (isset($attributes['masked']))
:masked="{{ ($attributes['masked']) ? 'true' : 'false' }}"
@endif
2020-02-14 14:56:58 +03:00
name="{{ $name }}"
2022-06-01 10:15:55 +03:00
title="{{ $label }}"
:group_class="'{{ $formGroupClass }}'"
@if (! empty($icon))
2020-02-14 14:56:58 +03:00
icon="{{ $icon }}"
2022-06-01 10:15:55 +03:00
@endif
:currency="{{ json_encode($attributes['currency']) }}"
:value="{{ $value }}"
2019-11-16 10:21:14 +03:00
2022-06-01 10:15:55 +03:00
@if (! empty($attributes['dynamic-currency']))
:dynamic-currency="{{ $attributes['dynamic-currency'] }}"
@else
:dynamic-currency="currency"
@endif
2022-06-01 10:15:55 +03:00
@if (! empty($attributes['v-model']))
v-model="{{ $attributes['v-model'] }}"
@endif
2022-06-01 10:15:55 +03:00
@if (! empty($attributes['change']))
@change="{{ $attributes['change'] }}($event)"
@endif
2022-06-01 10:15:55 +03:00
@if (! empty($attributes['input']))
@input="{{ $attributes['input'] }}"
@endif
2022-06-01 10:15:55 +03:00
@if (! empty($attributes['v-model']))
2020-06-05 16:14:00 +03:00
@interface="form.errors.clear('{{ $attributes['v-model'] }}'); {{ $attributes['v-model'] . ' = $event' }}"
@elseif (!empty($attributes['data-field']))
@interface="form.errors.clear('{{ 'form.' . $attributes['data-field'] . '.' . $name }}'); {{ 'form.' . $attributes['data-field'] . '.' . $name . ' = $event' }}"
@else
2020-06-05 16:14:00 +03:00
@interface="form.errors.clear('{{ $name }}'); form.{{ $name }} = $event"
@endif
@if (isset($attributes['v-error-message']))
2022-06-01 10:15:55 +03:00
:error="{{ $attributes['v-error-message'] }}"
@else
2022-06-01 10:15:55 +03:00
:error="form.errors.get('{{ $name }}')"
@endif
2020-12-24 01:28:38 +03:00
@if (isset($attributes['row-input']))
:row-input="{{ $attributes['row-input'] }}"
@endif
></akaunting-money>
2019-11-16 10:21:14 +03:00
@stack($name . '_input_end')