<%= t(:Services) %>

<%= search_form_for(@search, url: schedules_service_path) do |f| %>
<%= f.label :citizen_name, t(:Citizen)+": " %>
<%= f.text_field :citizen_name_cont, :class => "search-field"%>
<%= f.label :citizen_cpf, t(:cpf)+": " %>
<%= f.text_field :citizen_cpf_eq, :class => "cpf", :type => "tel"%>
<%= f.label :limite_inicio, "A partir de: " %>
<% if @limite_inicio %> <%= f.text_field :limite_inicio, { :value => @limite_inicio.strftime("%d/%m/%Y"), :class => "date agendamentos_atend_calendario", :readonly => "true" } %> <% end %>
<%= f.label :limite_fim, "Até: " %>
<% if @limite_fim %> <%= f.text_field :limite_fim, { :value => @limite_fim.strftime("%d/%m/%Y"), :class => "date agendamentos_atend_calendario", :readonly => "true" } %> <% end %>
<%= f.label :service_place_city_hall_id, t(:city_hall) %>
<% if @currentProfessionalServicePlace.role == "adm_c3sl" %> <%= f.collection_select :service_place_city_hall_id_eq, CityHall.active.order(:name), :id, :name, { :include_blank => "Todos", selected: 0 }, { :class => "search-field" } %> <% else %> <%= f.collection_select :service_place_city_hall_id_eq, CityHall.where(id: @currentCityHall.id), :id, :name, { disabled: true }, { :class => "search-field" } %> <% end %>
<%= f.label :shift_professional_performer_id, t(:Professional)+": " %>
<%= f.collection_select :shift_professional_performer_id_eq, [], :id, :name, {:include_blank => "Todos"}, {:class => "search-field"} %>
<%= f.label :service_place_id_eq, t(:service_place) %>
<%= f.collection_select :service_place_id_eq, [], :id, :name,{ :include_blank => "Todos" }, { :class => "search-field" } %>
<%= f.label :escala_tipo_atendimento_id, t(:service_type)+": " %>
<%= f.collection_select :shift_service_type_id_eq, [], :id, :description, {:include_blank => "Todos"}, {:class => "search-field"} %>
<%= f.label :situation_id, t(:Situation)+": " %>
<%= f.collection_select :situation_id_eq, @situations, :id, :description, {:include_blank => "Todos"}, {:class => "search-field"} %>
<%= f.button t(:Search), :class => " waves-effect btn" %> <%= f.button t(:Report), :class => " waves-effect btn", :name => "relatorio_atendimentos" %> <%= button_tag t(:clear_fields), :id => "reset_btn", :class => "waves-effect btn-flat", :type => "button" %>
<% end %>
<%= render "tabela_schedules_service" %>