<div id="schedule_calendar">
  <div  class="navigation_content">
    <div><%= theme_image_tag "schedule/home_sche.gif", :class => "my_navigation_content_title" %></div>
    <% display_open_colse_box(:id => "my_navigation_schedule_calendar") do %>
      <table class="content_box_bg" style="width:100%;">
        <tr>
          <td style="text-align: left;">
            <%=h display_calender_month(:format => :year_month) %>
          </td>
          <td style="text-align: right;">
            <%= calendar_move_remote(:update => "schedule_calendar",
                                     :partial => "part/navigations/schedule_calendar_navigation",
                                     :url => {:action => :show_calendar, :user_id => @schedule_user.id} ) %>
          </td>
        </tr>
      </table>
      <div style="background-color:#FFFFFF;">
        <%=
           mars_calendar(:year => @calendar_year, :month => @calendar_month) do |cur|
             if @schedules_date.detect{|d| d.to_date == cur} || @friends_for_schedule.detect{|f| f.birthday?(cur) }
               cell_text = ""
               cell_text << link_to(cur.mday, show_list_schedules_path(:user_id => @schedule_user.id, :date => cur))
               [cell_text, nil]
             else
               [nil, nil]
             end
           end
           %>
      </div>
      <div class="all_link">
        <% if @schedule_user.same_user?(current_user) %>
          [ <%= link_to "天気予報", current_user.now_prefecture.yahoo_weather_url %> ]
          [ <%= link_to("新規予定", new_schedule_path(:user_id => current_user.id, :date => Date.today)) %> ]
        <% end %>
        [ <%= link_to("カレンダー", show_calendar_schedules_path(:user_id => @schedule_user.id)) %> ]
      </div>
    <% end %>
  </div>
  <div align="right">
    <div style="margin-bottom: 5px; cursor: pointer;">
      <%= display_open_colse_box_button("my_navigation_schedule_calendar") %>
    </div>
  </div>
</div>
