From 122f0b9cba837c5d979102a9105007c1dc81234f Mon Sep 17 00:00:00 2001 From: snipe Date: Thu, 25 Aug 2016 18:35:28 -0700 Subject: [PATCH] Custom fields form in asset edit view --- .../views/models/custom_fields_form.blade.php | 35 ++++++++++++++----- 1 file changed, 27 insertions(+), 8 deletions(-) diff --git a/resources/views/models/custom_fields_form.blade.php b/resources/views/models/custom_fields_form.blade.php index 8097e2c900..220aab8aa7 100644 --- a/resources/views/models/custom_fields_form.blade.php +++ b/resources/views/models/custom_fields_form.blade.php @@ -1,13 +1,32 @@ @if($model->fieldset) @foreach($model->fieldset->fields AS $field) -
- -
- +
+ +
+ + @if ($field->element!='text') + + @if ($field->element=='listbox') + {{ Form::select($field->db_column_name(), $field->formatFieldValuesAsArray(), Input::old($field->db_column_name(), $asset->{$field->db_column_name()}), ['class'=>'format select2 form-control']) }} + @elseif ($field->element=='checkbox') + + @foreach ($field->formatFieldValuesAsArray() as $key => $value) + +
+ +
+ @endforeach + + @endif + + + @else + + + @endif + first($field->db_column_name()); if ($errormessage) {