<%# render :partial => 'organizations/item', :locals => {:organization => @organization} %>

<h1><%= @organization.name %></h1>
<p>
  <b>URL:</b>
  <%= source_url_link @organization %>
</p>

<% unless @organization.topics.blank? -%>
<p>
  <b>Topics:</b>
  <%= render :partial => 'shared/topics', :locals => {:topics => @organization.topics} %>
</p>
<% end %>

<p>
   <b>Events:</b>
   <%= render :partial => 'events/list', :locals => { :events =>  @organization.events } %>
</p>

<% content_for :sidebar do %>
  <div class='box'>
    <ul>
    	<li><%= link_to 'Edit this organization', edit_organization_url %> 
    	<li><%= link_to 'Import events from an existing source', new_organization_source_path(@organization) %>
    </ul>
  </div>
<%# link_to 'Destroy', @organization, :confirm => 'Are you sure?', :method => :delete %>
<% end %>
<%# render :partial => 'organizations/item', :locals => {:organization => @organization} %>

<h1><%= @organization.name %></h1>
<p>
  <b>URL:</b>
  <%= source_url_link @organization %>
</p>

<% unless @organization.topics.blank? -%>
<p>
  <b>Topics:</b>
  <%= render :partial => 'shared/topics', :locals => {:topics => @organization.topics} %>
</p>
<% end %>

<p>
   <b>Events:</b>
   <%= render :partial => 'events/list', :locals => { :events =>  @organization.events } %>
</p>

<% content_for :sidebar do %>
  <div class='box'>
    <ul>
    	<li><%= link_to 'Edit this organization', edit_organization_url %> 
    	<li><%= link_to 'Import events from an existing source', new_organization_source_path(@organization) %>
      <li><%= link_to 'Add an event', '/events/new?event[organization_id]=' + @organization.id.to_s %>
      <%# XXX TODO - last line is a hack.  Should use something like new_event_url after updating routes.rb,
                     or figure out how to set params to pass org id. %>
    </ul>
  </div>
<%# link_to 'Destroy', @organization, :confirm => 'Are you sure?', :method => :delete %>
<% end %>
Add link to add-event page from Org show page.
Add link to add-event page from Org show page.

 [Fixes #23663807]
