If a category has items in it, disable changing the category type (#2288)

This commit is contained in:
Daniel Meltzer 2016-07-20 22:27:33 -04:00 committed by snipe
parent 68b0bbbec9
commit ba6f26cef9

View file

@ -55,7 +55,7 @@
<i class='fa fa-asterisk'></i>
</div>
<div class="col-md-7">
{{ Form::select('category_type', $category_types , Input::old('category_type', $category->category_type), array('class'=>'select2', 'style'=>'min-width:350px')) }}
{{ Form::select('category_type', $category_types , Input::old('category_type', $category->category_type), array('class'=>'select2', 'style'=>'min-width:350px', $category->itemCount() > 0 ? 'disabled' : '')) }}
{!! $errors->first('category_type', '<span class="alert-msg"><i class="fa fa-times"></i> :message</span>') !!}
</div>
</div>