From 4e67f8769a3a3199bfb5b363fe9baa231c329a2b Mon Sep 17 00:00:00 2001 From: Stefan Wintermeyer Date: Sun, 20 Jan 2013 20:57:35 +0100 Subject: Refactoring --- app/views/gateways/_index_core.html.haml | 34 +++++++++++++++++--------------- 1 file changed, 18 insertions(+), 16 deletions(-) (limited to 'app/views/gateways/_index_core.html.haml') diff --git a/app/views/gateways/_index_core.html.haml b/app/views/gateways/_index_core.html.haml index 21414c3..dd2d1f5 100644 --- a/app/views/gateways/_index_core.html.haml +++ b/app/views/gateways/_index_core.html.haml @@ -1,17 +1,19 @@ -%table - %tr - %th= t('gateways.index.name') - %th= t('gateways.index.technology') - %th= t('gateways.index.inbound') - %th= t('gateways.index.outbound') - %th= t('gateways.index.description') +- cache(['gateways_table', gateways.count, gateways.first, gateways.last]) do + %table + %tr + %th= t('gateways.index.name') + %th= t('gateways.index.technology') + %th= t('gateways.index.inbound') + %th= t('gateways.index.outbound') + %th= t('gateways.index.description') - - reset_cycle - - for gateway in gateways - %tr{:class => cycle('odd', 'even')} - %td= gateway.name - %td= gateway.technology - %td= gateway.inbound - %td= gateway.outbound - %td= gateway.description - =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:child => gateway} \ No newline at end of file + - reset_cycle + - for gateway in gateways + %tr{:class => cycle('odd', 'even')} + - cache(['gateway_single_table_row_within_tr', gateway, gateways.count]) do + %td= gateway.name + %td= gateway.technology + %td= gateway.inbound + %td= gateway.outbound + %td= gateway.description + =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:child => gateway} \ No newline at end of file -- cgit v1.2.3