<% #
 # This file is part of the Anotatornia suite.
 # 
 # Copyright © 2007, 2008, 2009, 2010 by Instytut Podstaw Informatyki
 # Polskiej Akademii Nauk (IPI PAN; Institute of Computer Science, Polish
 # Academy of Sciences; cf. www.ipipan.waw.pl).  All rights reserved.
 # 
 # This file may be distributed and/or modified under the terms of the
 # GNU General Public License version 3 as published by the Free Software
 # Foundation and appearing in the file COPYING included in the packaging
 # of this file.  (See http://www.gnu.org/licenses/translations.html for
 # unofficial translations.)
 # 
 # A commercial license is available from IPI PAN (contact
 # Michal.Ciesiolka.waw.pl or ipi.waw.pl for more
 # information).  Licensees holding a valid commercial license from IPI
 # PAN may use this file in accordance with that license.
 # 
 # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING
 # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 # PURPOSE.
%>

<% log_time "oglądactwo 1" -%>

<div id="main">
  <div id="flash_notice">
  <%= render :partial => '/layouts/notice' -%>
  </div>
  <%= render :partial => '/layouts/powitalny' -%>
  <p>

<% if Rola.wszewid?(session[:rola_id]) -%>
Rozbieżności występują w&nbsp;<%= @ile_rozbieznych %>
       akapicie/tach. <br/>
Do osądzenia dojrzało/y <%= @ile_podsadnych %>.
</p>

<% if @ile_podsadnych_total != 0 -%>

<h1>Przejdź do </h1>
<%= render :partial => 'ogladactwo_goto' -%>


<h1>Akapity podsądne</h1>

<%= render :partial => 'ogladactwo_lista_akapitow', :object =>
[@akapity_podsadne, if Rola.audytor?(session[:rola_id]) : "Doradzaj"
else "Rozsądzaj" end] -%>

<% end #of #{if są rozbieżne}.
-%>

<% log_time "oglądactwo po podsądnych przed skoment. (27)" -%>

<div id="akapity_skomentowane">
  <%= render :partial => 'akapity_skomentowane' -%>
</div>

<% log_time "oglądactwo 32" -%>

<div id="prosby_anotatorek">
  <%= render :partial => 'prosby_anotatorek' -%>
</div>

<div id="wsze_transze_BW">
<%= render :partial => 'wsze_transze_BW' 
       -%>
</div>

<div id="wsze_transze_otwarte">
<%= render :partial => 'wsze_transze_otwarte' 
       -%>
</div>


<% else # of #{if wszewid }.
-%>
 
<h1>Akapity zweryfikowane</h1>

<%    qtra = 100 
   (Akapit.min_id/qtra).upto( Akapit.max_id/qtra + 1)  do |id|
      limits = [id*qtra+1, (id+1)*qtra]
  quasi_transza = Akapit.quasi_transza( limits )
      if quasi_transza.size > 0 -%>
<div id="quasi_transza_<%= limits.join("-") %>">
<%= render :partial => 'quasi_transza', :object => [quasi_transza,  limits.join("-")] -%>
</div>
 <% end # of #{quasi_transza.size},
 end # of #{min_id.upto( max_id )}.
-%>

<% end # of #{if wszewid?}.
-%>


</div>


<% log_time "oglądactwo 65" -%>
<%
### Local Variables: 
### mode: mmm
### End:
-%>
