<%
  if @member

    @projects = Project.where(is_hidden: false, :create_user_id => @member.id).desc(:period_start_date)

    @project_intro = !PersonalProjectIntro.where(:user_id => @member.id).blank? ? PersonalProjectIntro.where(:user_id => @member.id).first : PersonalProjectIntro.new
%>

  <% if @project_intro.brief_intro and !@project_intro.blank? %> 

    <div class="info">
        <%= @project_intro.text.html_safe rescue '' %>
      </div>

  <% end %> 

  <% if ( !@project_intro.blank? and @project_intro.complete_list ) or @project_intro.blank? %> 

    <% if !@projects.blank? %> 

      <table class="table">
        <thead>
          <tr>
      			<th class="grid3"><%= t('personal_project.period') %></th>
      			<th class="grid9"><%= t('personal_project.project_title') %></th>
      		</tr>
        </thead>
        <tbody>
      		
      	<% @projects.each do |project| %>	
      			
          <tr>
      			<td><%= project.period_start_date.strftime("%Y.%m") %> ~ <%= project.period_end_date.strftime("%Y.%m") %></td>
      			<td>
      			<%= link_to project.project_title, panel_personal_project_front_end_project_path(project) %>
      			</td>
      		</tr>		
      		
      	<% end %>	

        </tbody>
      </table>

    <% end %> 

  <% end %> 

<% end %> 