Changeset 1571

Show
Ignore:
Timestamp:
05/05/08 16:42:14 (1 week ago)
Author:
mbriggs
Message:

Add minimize functionality to processes in clients show view

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • hive/trunk/data_webapp/app/helpers/clients_helper.rb

    r1501 r1571  
    6060  end 
    6161 
     62  def minimize_cell(id) 
     63    out = %{<td class="minimize">} 
     64    out += %{<INPUT type='button' value='-' onclick='if(this.value=="-"){Effect.SlideUp("#{id}",{duration:0});this.value="+";}else{Effect.SlideDown("#{id}",{duration:0});this.value="-";}'>} 
     65    out += %{</td>} 
     66  end 
     67 
     68  def details_title_row_plus(title,id) 
     69    outty = %{<tr class="dataTitle">} 
     70    outty += title_cell(title) 
     71    if not id.nil? 
     72      outty += minimize_cell(id) 
     73    end 
     74    outty += %{</tr>} 
     75  end 
     76     
    6277  def details_title_row(title) 
    6378    outty = %{<tr class="dataTitle">} 
  • hive/trunk/data_webapp/app/views/clients/show.html.erb

    r1501 r1571  
    2525        <tbody> 
    2626          <%#= details("Processes",p) %> 
    27           <%= details_title_row("Process: " + p.name) %> 
     27          <%= details_title_row_plus("Process: " + p.name[/[^\/\\]*$/],"proc"+p.id.to_s) %> 
     28          <%= '<tr><td colspan="3"><table id="proc' + p.id.to_s + '" width="100%">'%> 
    2829          <tr><td align="center"> 
    2930            <%= view_details_link('OsProcess',p.id) %> 
     
    5152          </div></td></tr> 
    5253<% end %> 
     54        </table></td></tr> 
    5355        </tbody> 
    5456      </table> 
    5557  <% end %> 
    5658<% else %> 
     59        </table></td></tr> 
    5760        </tbody> 
    5861      </table> 
  • hive/trunk/data_webapp/public/stylesheets/scaffold.css

    r1501 r1571  
    5555  text-align: center; 
    5656  white-space: nowrap; 
     57} 
     58 
     59td.minimize { 
     60  width: 12px; 
     61  max-width: 12px; 
    5762} 
    5863