app/views/my/dashboard.html.haml
.app.view-dashboard
= render "application/header"
.app-body
.app-body-title
.ui-body-title
.ui-body-title-label
%h1.title-xl
%i.icon-home
= _("My archive")
.ui-body-title-actions
%a.button{:"data-create-set" => true}
%i.icon-plus
= _("Create set")
%a.primary-button{:href => import_path}
%i.icon-upload.bright
= _("Import media")
.app-body-ui-container
.bordered.ui-container.midtone.table.rounded-right.rounded-bottom
= render "application/sidebar/my_archive"
.app-body-content.table-cell.table-substance.ui-container.context-fix
- unless @latest_user_resources.blank?
= render :partial => "media_resources/wrapper",
:locals => {:media_resources => @latest_user_resources,
:title => _("Content I am responsible for"),
:link => my_media_resources_path(:sort => :updated_at),
:with_actions => true,
:id => "latest_user_resources_block"}
%hr.separator
- unless @latest_user_imports.blank?
= render :partial => "media_resources/wrapper",
:locals => {:media_resources => @latest_user_imports,
:title => _("My latest imports"),
:link => my_latest_imports_path,
:item_layout => "miniature",
:with_actions => true,
:id => "latest_user_imports_block" }
%hr.separator
- unless @user_favorite_resources.blank?
= render :partial => "media_resources/wrapper",
:locals => {:media_resources => @user_favorite_resources,
:title => _("My favorites"),
:link => my_favorites_path(:sort => :updated_at),
:with_actions => true,
:id => "user_favorite_resources_block" }
%hr.separator
- unless @user_keywords.blank?
= render :partial => "keywords/wrapper",
:locals => {:keywords => @user_keywords,
:title => _("My keywords"),
:link => my_keywords_path,
:id => "user_keywords_block" }
%hr.separator
- unless @user_entrusted_resources.blank?
= render :partial => "media_resources/wrapper",
:locals => {:media_resources => @user_entrusted_resources,
:title => _("Content entrusted to me"),
:link => my_entrusted_media_resources_path(:sort => :updated_at),
:item_layout => "miniature",
:with_actions => true,
:id => "user_entrusted_resources_block" }
%hr.separator
- unless @user_groups.blank?
= render :partial => "groups/wrapper",
:locals => {:groups => @user_groups,
:title => _("My workgroups"),
:link => my_groups_path,
:id => "my_groups_block"}
%hr.separator
- if @user_groups.blank? and @user_entrusted_resources.blank? and @user_keywords.blank? and @user_favorite_resources.blank? and @latest_user_imports.blank? and @latest_user_resources.blank? #TODO: and @user_contexts.blank?
.row.mts
.pvh.mth.mbl
.title-l.by-center
= _("Welcome")
.title-s.by-center
= _("Share your media, archive your works, explore content, develop knowledge.")
.mtm
%a.button{:href => explore_path}
%i.icon-eye
= _("Explore content")
%a.primary-button{:href => import_path}
%i.icon-upload.bright
= _("Import media")
%hr.separator
- unless @user_contexts_count.zero?
= render :partial => "contexts/wrapper",
:locals => {:contexts => @user_contexts.first(3),
:title => _("Vokabulare"),
:link => my_contexts_path,
:id => "my_contexts_block"}
.app-footer-push
= render :partial => "application/footer"