2012-01-28 16:47:55 +02:00
|
|
|
%h3
|
|
|
|
Projects
|
|
|
|
%small= "( #{current_user.projects.count} )"
|
2012-02-28 22:59:36 +02:00
|
|
|
- if current_user.can_create_project?
|
|
|
|
%span.right
|
|
|
|
= link_to new_project_path, :class => "btn small" do
|
|
|
|
New Project
|
2012-01-28 00:51:02 +02:00
|
|
|
%hr
|
|
|
|
- unless @projects.empty?
|
2012-02-12 23:52:27 +02:00
|
|
|
%div.content_list= render "tile"
|
2011-10-28 14:41:39 +03:00
|
|
|
|
2012-01-28 00:51:02 +02:00
|
|
|
-# If projects requris paging
|
|
|
|
-# We add ajax loader & init script
|
|
|
|
- if @projects.count == @limit
|
|
|
|
.loading{ :style => "display:none;"}
|
|
|
|
%center= image_tag "ajax-loader.gif"
|
2011-12-20 08:29:14 +02:00
|
|
|
|
2012-01-28 00:51:02 +02:00
|
|
|
:javascript
|
|
|
|
$(function(){
|
2012-02-12 23:52:27 +02:00
|
|
|
Pager.init(#{@limit});
|
2012-01-28 00:51:02 +02:00
|
|
|
});
|
|
|
|
- else
|
|
|
|
%h2 Nothing here
|