Tasks admin tags - WIP


This is a WIP PR to allow code review in parallel

Refactored code to avoid extra code in _grouped_index.html.haml including test to verify
Added main logic and bootstrap style (based on checkboxes) to allow merging and deleting tags if user is admin
Removed unused flags resources
Added some styles to allow showing debug information in screen while running in dev environment

Still Pending:
Control params for new action "reorganize" in tags_controller 
Adding control to avoid merges without new names.
Adding warning popup before merging or deletion
Adding Tests
He probado esto y ahora funciona bien, sin necesidad de eval, gracias

BlackBerry de movistar, allí donde estés está tu oficin@

-----Original Message-----
From: Saverio Trioni <notifications@github.com>
Date: Wed, 24 Dec 2014 09:23:11 
To: coopdevs/timeoverflow<timeoverflow@noreply.github.com>
Reply-To: coopdevs/timeoverflow <reply@reply.github.com>
Cc: Daniel Macho<danielmacho72@gmail.com>
Subject: Re: [timeoverflow] Tasks admin tags - WIP (#113)

> +                  :new_name,
> +                  :delete_button,
> +                  :merge_button,
> +                  tags: [])
> +  end
> +
> +  def alpha_tags_from_post_type(post_type)
> +    case post_type
> +    when "offer" then Offer
> +    when "inquiry" then Inquiry
> +    when "all" then Post
> +    end.active_alpha_tags(current_organization)
> +  end
> +
> +  def selected_tags(params)
> +    st = []

Esto significa simplemente que el value que estás poniendo al checkbox (en cuanto input de un formulario) está mal. Si el value es simplemente tu string, entonces se recogerá bien. Has probado a usar
```
= check_box_tag "tags[]", tag
```
en lugar de
```
= check_box_tag "tags[]", value: tag
```
Mira aquí: http://apidock.com/rails/ActionView/Helpers/FormTagHelper/check_box_tag

---
Reply to this email directly or view it on GitHub:
https://github.com/coopdevs/timeoverflow/pull/113/files#r22260523