- include_javascript 'admin/reader' - include_stylesheet 'admin/reader_group' - body_classes << "reversed" - render_region :header do |header| - header.title do %h1 = t('reader_extension.group').titlecase + ":" = @group.name - render_region :main do |main| - main.messages do #group_messages.box .actions = link_to image('plus') + ' ' + t("reader_extension.create_new_message"), new_admin_group_message_url(@group), :class => 'action create' %h3 =t('reader_extension.admin_messages').titlecase - ['group_welcome', 'group_invitation'].each do |func| - message = Message.functional(func, @group) %p.ruled %label = t("message_functions.#{func}") - if message %strong = link_to message.subject, admin_message_url(message) - else = link_to image('plus') + ' ' + t("reader_extension.create_#{func}"), new_admin_group_message_url(@group, :function => func), :class => 'action create' %h4 =t('reader_extension.other_messages').titlecase - @group.messages.ordinary.each do |message| %p.ruled = link_to message.subject, admin_message_url(message) %span.sent - if message.sent_at = t('reader_extension.last_sent') = l(message.sent_at, :format => :short) - main.pages do #group_pages.box %h3 =t('reader_extension.private_pages').titlecase %ul - page = Page.respond_to?(:homepage) ? Page.homepage : Page.find_by_parent_id(nil) %li{:id => "page_holder_#{page.id}"} = render :partial => 'admin/permissions/page', :object => page - main.members do #group_people.box .actions = link_to image('plus') + ' ' + t('reader_extension.add_members'), new_admin_group_group_invitation_url(@group), :class => 'action' %h3 =t('reader_extension.group_members').titlecase - readers = Reader.find(:all) - total = readers.count - column_length = (readers.count-1) / 2 - columns = [readers[0..column_length], readers[column_length+1..readers.count]] - columns.each do |column| %ul.column - column.each do |reader| %li{:id => "reader_holder_#{reader.id}"} = render :partial => 'admin/memberships/reader', :object => reader - render_region :footer do |footer| - footer.notes do #footnotes %p = t('reader_extension.private_page_explanation') - footer.javascript do :javascript var h1 = $('group_pages').getHeight(); var h2 = $('group_people').getHeight(); var h = (h1 > h2) ? h1 : h2 $('group_people').setStyle({'height': h + 'px'}); $('group_pages').setStyle({'height': h + 'px'});