mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
Added if/else for custom fields model partial
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
1b9d046f5f
commit
2434c82a75
|
@ -1,10 +1,18 @@
|
||||||
@if (($model) && ($model->fieldset))
|
@if (($model) && ($model->fieldset))
|
||||||
@foreach($model->fieldset->fields AS $field)
|
@foreach($model->fieldset->fields AS $field)
|
||||||
|
@if (
|
||||||
|
((!isset($show_display_checkin_fields))
|
||||||
|
|| (($field->display_checkin == '1')
|
||||||
|
&& ($show_display_checkin_fields =='true'))) &&
|
||||||
|
((!isset($show_display_checkout_fields))
|
||||||
|
|| (($field->display_checkout == '1')
|
||||||
|
&& ($show_display_checkout_fields =='true')))
|
||||||
|
)
|
||||||
|
|
||||||
<div class="form-group{{ $errors->has($field->db_column_name()) ? ' has-error' : '' }}">
|
<div class="form-group{{ $errors->has($field->db_column_name()) ? ' has-error' : '' }}">
|
||||||
<label for="{{ $field->db_column_name() }}" class="col-md-3 control-label">{{ $field->name }} </label>
|
<label for="{{ $field->db_column_name() }}" class="col-md-3 control-label">{{ $field->name }} </label>
|
||||||
<div class="col-md-7 col-sm-12">
|
<div class="col-md-7 col-sm-12">
|
||||||
|
|
||||||
|
|
||||||
@if ($field->element!='text')
|
@if ($field->element!='text')
|
||||||
|
|
||||||
@if ($field->element=='listbox')
|
@if ($field->element=='listbox')
|
||||||
|
@ -83,6 +91,7 @@
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@endif
|
||||||
@endforeach
|
@endforeach
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue