diff options
author | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2012-12-17 12:01:45 +0100 |
---|---|---|
committer | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2012-12-17 12:01:45 +0100 |
commit | b80bd744ad873f6fc43018bc4bfb90677de167bd (patch) | |
tree | 072c4b0e33d442528555b82c415f5e7a1712b2b0 /app/views/hunt_groups/_index_core.html.haml | |
parent | 3e706c2025ecc5523e81ad649639ef2ff75e7bac (diff) |
Start of GS5.
Diffstat (limited to 'app/views/hunt_groups/_index_core.html.haml')
-rw-r--r-- | app/views/hunt_groups/_index_core.html.haml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/app/views/hunt_groups/_index_core.html.haml b/app/views/hunt_groups/_index_core.html.haml new file mode 100644 index 0000000..3000e97 --- /dev/null +++ b/app/views/hunt_groups/_index_core.html.haml @@ -0,0 +1,34 @@ +- show_seconds = hunt_groups.map{|x| ! x.seconds_between_jumps.nil? }.include?(true) + +%table + %tr + %th= t('hunt_groups.index.name') + %th= t('hunt_groups.index.strategy') + - if show_seconds + %th= t('hunt_groups.index.seconds_between_jumps') + %th= t('hunt_groups.index.phone_numbers') + %th= t('hunt_groups.index.hunt_group_members') + + - reset_cycle + - for hunt_group in hunt_groups + %tr{:class => cycle('odd', 'even')} + %td= hunt_group.name + %td= t("hunt_groups.strategies.#{hunt_group.strategy}") + - if show_seconds + %td= hunt_group.seconds_between_jumps + %td + - if hunt_group.phone_numbers.count > 0 + =render 'phone_numbers/listing', :phone_numbers => hunt_group.phone_numbers + %br + = render :partial => 'shared/create_link', :locals => {:parent => hunt_group, :child_class => PhoneNumber, :short_link => true} + + %td + - if hunt_group.hunt_group_members.count > 3 + = link_to hunt_group.hunt_group_members.count, hunt_group_hunt_group_members_path(hunt_group) + %br + - elsif hunt_group.hunt_group_members.count > 0 + =render 'hunt_group_members/listing', :hunt_group_members => hunt_group.hunt_group_members + %br + = render :partial => 'shared/create_link', :locals => {:parent => hunt_group, :child_class => HuntGroupMember, :short_link => true} + + =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:parent => hunt_group.tenant, :child => hunt_group}
\ No newline at end of file |