{!! Form::open(['url' => action([\App\Http\Controllers\ContactController::class, 'updateAllSelected']), 'method' => 'post']) !!}

@lang('contact.add_contact')

{!! Form::select('contact_ids[]', $contact_ids ?? [], array_keys($contact_ids ?? []), ['class' => 'form-control select2', 'id' => 'contact_ids', 'multiple', 'style' => 'width: 100%;']); !!}
{!! Form::label('selected_all', __('lang.selected_all') . ':') !!}
{!! Form::label('location_id', __('lang.location') . ':') !!}
{!! Form::select('location_id', getLocations(), '', ['class' => 'form-control']); !!}
{!! Form::label('customer_group_id', __('lang.customer_group') . ':') !!}
{!! Form::select('customer_group_id', $customer_groups, '', ['class' => 'form-control']); !!}
{!! Form::label('tags', __('lang.tags') ) !!}
{!! Form::select('tags[]', $tags ?? [], null , ['class' => 'form-control select2', 'id' => 'user_id', 'multiple', 'style' => 'width: 100%;']); !!}
{!! Form::label('pay_term_number', __('contact.pay_term') . ':') !!} @show_tooltip(__('tooltip.pay_term'))
{!! Form::number('pay_term_number', null, ['class' => 'form-control width-40 pull-left', 'placeholder' => __('contact.pay_term')]); !!} {!! Form::select('pay_term_type', ['months' => __('lang_v1.months'), 'days' => __('lang_v1.days')], '', ['class' => 'form-control width-60 pull-left','placeholder' => __('messages.please_select')]); !!}
{!! Form::label('allocate_sales_person', __('lang.allocate_sales_person') . ':' ) !!}
{!! Form::select('allocate_sales_person[]', $users ?? [], null , ['class' => 'form-control select2 allocate_sales_person', 'id' => 'allocate_sales_person', 'multiple' => 'multiple', 'style' => 'width: 100%;']); !!}
{!! Form::label('assigned_to_users', __('lang.sales_person') . ':' ) !!}
{!! Form::select('assigned_to_users[]', ['' => __('lang.selected')] + getSalesPersons()->toArray() ?? [], null , ['class' => 'form-control select2', 'id' => 'assigned_to_users', 'style' => 'width: 100%;']); !!}
{!! Form::label('state_id', __('business.state') . ':' ) !!}
{!! Form::select('state_id', statesDefault()??[], null , ['class' => 'form-control select2', 'id' => 'modal_state_id', 'placeholder' => __('lang.selected'), 'style' => 'width: 100%;']); !!}
{!! Form::label('city_id', __('business.city') . ':' ) !!}
{!! Form::select('city_id', [], null , ['class' => 'form-control select2', 'id' => 'modal_city_id', 'placeholder' => __('lang.selected'), 'style' => 'width: 100%;']); !!}
{{--
{!! Form::label('city', __('business.city') . ':') !!}
{!! Form::text('city', null, ['class' => 'form-control', 'placeholder' => __('business.city')]); !!}
{!! Form::label('state', __('business.state') . ':') !!}
{!! Form::text('state', null, ['class' => 'form-control', 'placeholder' => __('business.state')]); !!}
--}}
{!! Form::close() !!}