Sha256: 1ba0d9c94ebab8c77899a413686a00e2fce8d99d3f4fc1b9727b49bc40438317

Contents?: true

Size: 1.55 KB

Versions: 4

Compression:

Stored size: 1.55 KB

Contents

<%= "<div id=\"#{opts[:div_id]}\">".html_safe if opts[:div_id] %>

<%= if session[:edit_mode] > 1 
  dc_link_for_create(controller: 'cmsedit', table: 'dc_forum', title: 'dc_forum.add_new_forum' )
    end %>

<div class="forum-topics">
  <div class="forum-title">
    <h3><%= t 'dc_forum.forums_list' %></h3>
  </div>
  
  <% for forum in forums %>
    <div class="topic-<%= cycle("odd", "even") %>">
      <%= if session[:edit_mode] > 1 then
          dc_link_for_edit(controller: 'cmsedit', table: 'dc_forum', id: forum._id, title: 'dc_forum.edit_forum' ); end %>
      <div class="name">  
        <%= link_to(forum.name,{ path: params[:path], forum: forum.id} ) %>
      </div>

      <div class='description'>
        <%= forum.description %><br>
        <b><%= t('dc_forum.topics') %>:</b>
         <%= forum.topics %> &nbsp;|&nbsp;
         
<% zadnja_sprememba = DcForumTopic.where(dc_forum_id: forum.id).order_by(updated_at: -1).first; if zadnja_sprememba %>
         <b><%= t('dc_forum.last_change') %>:</b>
         <%= dc_pretty_date(zadnja_sprememba.updated_at) %> &nbsp;|&nbsp; 
         <%= link_to(zadnja_sprememba.subject, { path: params[:path], forum: forum.id, topic: zadnja_sprememba._id } ) %>
<% end %>         
         
<% if false %>
         <b><%= t('dc_forum.replies') %>:</b>
         <%= forum.replies %> &nbsp;|&nbsp; 

         <b><%= t('dc_forum.last') %>:</b>
         <%= forum.updated_by_name %>
         <%= dc_pretty_date(forum.updated_at) %>
<% end %>      
      </div>
    </div>
  <% end %>
</div>

<%= "</div>".html_safe if opts[:div_id] %>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
drg_blog_news_forum-0.6.5 app/views/dc_forum/_forums.html.erb
drg_blog_news_forum-0.6.4 app/views/dc_forum/_forums.html.erb
drg_blog_news_forum-0.6.3 app/views/dc_forum/_forums.html.erb
drg_blog_news_forum-0.6.1 app/views/dc_forum/_forums.html.erb