mirror of
https://github.com/snipe/snipe-it.git
synced 2025-01-13 06:47:46 -08:00
More style polishing on custom fields in bulk edit
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
2695576968
commit
7042260871
|
@ -37,21 +37,20 @@
|
||||||
@elseif ($field->element=='checkbox')
|
@elseif ($field->element=='checkbox')
|
||||||
<!-- Checkboxes -->
|
<!-- Checkboxes -->
|
||||||
@foreach ($field->formatFieldValuesAsArray() as $key => $value)
|
@foreach ($field->formatFieldValuesAsArray() as $key => $value)
|
||||||
<div>
|
<label class="form-control">
|
||||||
<label>
|
<input type="checkbox" value="{{ $value }}" name="{{ $field->db_column_name() }}[]" {{ isset($item) ? (in_array($value, array_map('trim', explode(',', $item->{$field->db_column_name()}))) ? ' checked="checked"' : '') : (Request::old($field->db_column_name()) != '' ? ' checked="checked"' : (in_array($key, array_map('trim', explode(',', $field->defaultValue($model->id)))) ? ' checked="checked"' : '')) }}>
|
||||||
<input type="checkbox" value="{{ $value }}" name="{{ $field->db_column_name() }}[]" class="minimal" {{ isset($item) ? (in_array($value, array_map('trim', explode(',', $item->{$field->db_column_name()}))) ? ' checked="checked"' : '') : (Request::old($field->db_column_name()) != '' ? ' checked="checked"' : (in_array($key, array_map('trim', explode(',', $field->defaultValue($model->id)))) ? ' checked="checked"' : '')) }}>
|
|
||||||
{{ $value }}
|
{{ $value }}
|
||||||
</label>
|
</label>
|
||||||
</div>
|
|
||||||
@endforeach
|
@endforeach
|
||||||
@elseif ($field->element=='radio')
|
@elseif ($field->element=='radio')
|
||||||
@foreach ($field->formatFieldValuesAsArray() as $value)
|
@foreach ($field->formatFieldValuesAsArray() as $value)
|
||||||
<div>
|
|
||||||
<label>
|
<label class="form-control">
|
||||||
<input type="radio" value="{{ $value }}" name="{{ $field->db_column_name() }}" class="minimal" {{ isset($item) ? ($item->{$field->db_column_name()} == $value ? ' checked="checked"' : '') : (Request::old($field->db_column_name()) != '' ? ' checked="checked"' : (in_array($value, explode(', ', $field->defaultValue($model->id))) ? ' checked="checked"' : '')) }}>
|
<input type="radio" value="{{ $value }}" name="{{ $field->db_column_name() }}" {{ isset($item) ? ($item->{$field->db_column_name()} == $value ? ' checked="checked"' : '') : (Request::old($field->db_column_name()) != '' ? ' checked="checked"' : (in_array($value, explode(', ', $field->defaultValue($model->id))) ? ' checked="checked"' : '')) }}>
|
||||||
{{ $value }}
|
{{ $value }}
|
||||||
</label>
|
</label>
|
||||||
</div>
|
|
||||||
@endforeach
|
@endforeach
|
||||||
|
|
||||||
@endif
|
@endif
|
||||||
|
|
Loading…
Reference in a new issue