akaunting/resources/views/partials/form/text_editor_group.blade.php

47 lines
1.7 KiB
PHP
Raw Normal View History

2019-11-22 15:16:57 +03:00
@stack($name . '_input_start')
2020-02-01 13:32:43 +03:00
<div
class="form-group {{ $col }}{{ isset($attributes['required']) ? ' required' : '' }}{{ isset($attributes['readonly']) ? ' readonly' : '' }}{{ isset($attributes['disabled']) ? ' disabled' : '' }}"
2021-03-25 23:34:16 +03:00
:class="[{'has-error': {{ isset($attributes['v-error']) ? $attributes['v-error'] : 'form.errors.get("' . $name . '")' }} }]"
@if (isset($attributes['show']))
v-if="{{ $attributes['show'] }}"
@endif
>
@if (!empty($text))
{!! Form::label($name, $text, ['class' => 'form-control-label'])!!}
@endif
2019-11-22 15:16:57 +03:00
<akaunting-html-editor
2020-02-14 14:56:58 +03:00
name="{{ $name }}"
2020-01-20 18:16:56 +03:00
@if (!empty($value))
:value="`{{ $value }}`"
2020-07-28 17:37:35 +03:00
@else
:value="''"
2020-02-01 13:32:43 +03:00
@endif
2020-01-20 18:16:56 +03:00
2020-02-01 13:32:43 +03:00
@if (!empty($attributes['v-model']))
@input="{{ $attributes['v-model'] . ' = $event' }}"
@elseif (!empty($attributes['data-field']))
@input="{{ 'form.' . $attributes['data-field'] . '.' . $name . ' = $event' }}"
@else
@input="form.{{ $name }} = $event"
@endif
@if (isset($attributes['disabled']))
2020-03-19 22:39:52 +03:00
:disabled="{{ $attributes['disabled'] }}"
@endif
2021-04-07 17:53:54 +03:00
@if (isset($attributes['readonly']))
:readonly="{{ $attributes['readonly'] }}"
@endif
></akaunting-html-editor>
2019-11-22 15:16:57 +03:00
2020-02-01 13:32:43 +03:00
<div class="invalid-feedback d-block"
v-if="{{ isset($attributes['v-error']) ? $attributes['v-error'] : 'form.errors.has("' . $name . '")' }}"
v-html="{{ isset($attributes['v-error-message']) ? $attributes['v-error-message'] : 'form.errors.get("' . $name . '")' }}">
</div>
2019-11-22 15:16:57 +03:00
</div>
@stack($name . '_input_end')