@if($attribute->exists)
{!! Form::model($attribute, ['method' => 'PATCH','url' => ['attributes', $attribute->id]]) !!}
@else
{!! Form::open(array('route' => 'attribute.store','files' => true)) !!}
@endif
@if(!empty($attribute['id']))
{!! Form::hidden('id', $attribute['id'],array('class'=>'form-control', 'placeholder'=>'', )) !!}
@endif
{!! Form::hidden('attrSetId', $setid) !!}
{!! Form::text('defaultValue', old('defaultValue', $attribute['defaultValue']),array('class'=>'form-control')) !!}
{!! Form::checkbox('required', $attribute['required'], $attribute['required'],array('class' => 'minimal')) !!}
@if(!empty($attribute['id']))
{{$attribute['type']}}
{!! Form::hidden('name', $attribute['type']) !!}
@else
{!! Form::select('type', $attributeType, $attribute['type'],array('class'=>'form-control', 'required' => 'required')) !!}
@endif
{!! Form::close() !!}