2010-05-02 23:33:17 +00:00
|
|
|
%ul
|
2010-05-26 00:41:10 +00:00
|
|
|
= admin_submenu_item 'pages', admin_pages_url do
|
|
|
|
.header
|
|
|
|
%p= link_to t('admin.pages.index.new'), new_admin_page_url
|
|
|
|
.inner
|
|
|
|
%h2= t('admin.pages.index.lastest_items')
|
|
|
|
%ul
|
|
|
|
- current_site.pages.latest_updated.each do |page|
|
|
|
|
%li
|
|
|
|
= link_to truncate(page.title, :length => 40), edit_admin_page_url(page)
|
|
|
|
%span= time_ago_in_words(page.updated_at)
|
2010-05-24 00:18:23 +00:00
|
|
|
|
|
|
|
- current_site.content_types.each do |content_type|
|
|
|
|
- item_on = (content_type.slug == @content_type.slug) rescue nil
|
2010-05-26 00:41:10 +00:00
|
|
|
= admin_submenu_item content_type.name, admin_contents_url(content_type.slug), :i18n => false, :css => (item_on ? 'on' : '') do
|
|
|
|
.header
|
|
|
|
%p= link_to t('admin.contents.index.new'), new_admin_content_url(content_type.slug)
|
|
|
|
.inner
|
|
|
|
%h2= t('admin.contents.index.lastest_items')
|
|
|
|
%ul
|
|
|
|
- content_type.contents.latest_updated.each do |content|
|
|
|
|
%li
|
|
|
|
= link_to truncate(content.send(content_type.highlighted_field_name), :length => 40), edit_admin_content_path(content_type.slug, content)
|
|
|
|
%span= time_ago_in_words(content.updated_at)
|
|
|
|
|
2010-05-24 00:18:23 +00:00
|
|
|
.action
|
|
|
|
= link_to content_tag(:span, t('admin.content_types.index.new')), new_admin_content_type_url
|