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

39 lines
2.0 KiB
PHP
Raw Normal View History

2019-11-16 10:21:14 +03:00
@stack($name . '_input_start')
<akaunting-select
class="{{ $col }} {{ isset($attributes['required']) ? 'required' : '' }}"
:form-classes="[{'has-error': {{ isset($attributes['v-error']) ? $attributes['v-error'] : 'form.errors.get("' . $name . '")' }} }]"
2019-11-16 10:21:14 +03:00
:title="'{{ $text }}'"
:placeholder="'{{ trans('general.form.select.field', ['field' => $text]) }}'"
:name="'{{ $name }}'"
:options="{{ json_encode($values) }}"
:value="'{{ old($name, $selected) }}'"
:icon="'{{ $icon }}'"
2020-01-03 14:04:00 +03:00
:add-new="{{ json_encode([
'status' => true,
'text' => trans('general.form.add_new', ['field' => $text]),
'path' => isset($attributes['path']) ? $attributes['path']: false,
'type' => isset($attributes['type']) ? $attributes['type'] : 'modal',
'field' => isset($attributes['field']) ? $attributes['field'] : 'name',
'buttons' => [
'cancel' => [
'text' => trans('general.cancel'),
'icon' => 'fas fa-times',
'class' => 'btn-outline-secondary'
],
'confirm' => [
'text' => trans('general.save'),
'icon' => 'fas fa-save',
'class' => 'btn-success'
]
]
2020-01-03 14:04:00 +03:00
])}}"
2020-01-19 01:34:27 +03:00
@interface="{{ !empty($attributes['v-model']) ? $attributes['v-model'] . ' = $event' : (!empty($attributes['data-field']) ? 'form.' . $attributes['data-field'] . '.' . $name . ' = $event' : 'form.' . $name . ' = $event') }}"
2019-11-16 10:21:14 +03:00
@if (!empty($attributes['change']))
@change="{{ $attributes['change'] }}($event)"
@endif
:form-error="{{ isset($attributes['v-error-message']) ? $attributes['v-error-message'] : 'form.errors.get("' . $name . '")' }}"
:no-data-text="'{{ trans('general.no_data') }}'"
:no-matching-data-text="'{{ trans('general.no_matching_data') }}'"
2019-11-16 10:21:14 +03:00
></akaunting-select>
@stack($name . '_input_end')