anchor.diff:      $('select#building_id').find('option').removeClass('hide');
       $('select#building_id').find('option').not('option[data-wing="' + selected + '"]').addClass('hide');
     });
  -
  -
  -
   </script>
  
positive.code:   <% end %>
  
  <script>
    var active;
    var bool;
  
    $("input:radio").on('click', function() {
      $(".show_room").empty();
      active = $(this).attr("value");
      if (active == "ativa")
        bool = true;
      else
        bool = false;
  
      if (bool) {
        <% @rooms.each do |room| %>
          if (<%= room.active %>) {
            $(".show_room").append(
  
negative.code: 
    <p>
      <b>Funcionamento:&nbsp;</b>
      <%= label_tag(:id_all , "Todas") %>
      <%= radio_button_tag(:room_status_filter, "all", true, :id => "id_all") %>
      <%= label_tag(:id_active, "Ativa") %>
      <%= radio_button_tag(:room_status_filter, "active", false, :id => "id_active") %>
      <%= label_tag(:id_anactive, "Inativa") %>
      <%= radio_button_tag(:room_status_filter, "inactive", false, :id => "id_anactive") %>
    </p>
  
    <% if @rooms.count == 0 %>
  