<% # encoding: utf-8 %>

<table>
	<caption> <%= t("module_name.personal_lab") %> </caption>
	<tbody>
		<% if !@lab.year.blank? %>
		<tr><th><%= t("personal_lab.year")%></th><td><%= @lab.year %></td></tr>
		<% end %>

		<% if !@lab.language.blank? %>
		<tr><th><%= t("personal_lab.language")%></th><td><%= @lab.language %></td></tr>
		<% end %>

		<% if !@lab.lab_title.blank? %>
		<tr><th><%= t("personal_lab.lab_title")%></th><td><%= @lab.lab_title %></td></tr>
		<% end %>

		<% if !@lab.location.blank? %>
		<tr><th><%= t("personal_lab.location")%></th><td><%= @lab.location %></td></tr>
		<% end %>

		<% if !@lab.participating_professor.blank? %>
		<tr><th><%= t("personal_lab.participating_professor")%></th><td><%= @lab.participating_professor %></td></tr>
		<% end %>

		<% if !@lab.participating_student.blank? %>
		<tr><th><%= t("personal_lab.participating_student")%></th><td><%= @lab.participating_student %></td></tr>
		<% end %>

		<% if !@lab.extension_no.blank? %>
		<tr><th><%= t("personal_lab.extension_no")%></th><td><%= @lab.extension_no %></td></tr>
		<% end %>

		<% if !@lab.research_direction.blank? %>
		<tr><th><%= t("personal_lab.research_direction")%></th><td><%= @lab.research_direction %></td></tr>
		<% end %>

		<% if !@lab.facility.blank? %>
		<tr><th><%= t("personal_lab.facility")%></th><td><%= @lab.facility %></td></tr>
		<% end %>

		<% if !@lab.language.blank? %>
		<tr><th><%= t("personal_lab.url")%></th><td><%= link_to t(:url), @lab.url, {:target => '_blank', :title => @lab.url} if !@lab.url.blank? %></td></tr>
		<% end %>

		<tr><th><%= t("personal_lab.authors")%></th><td><%= User.from_id(@lab.create_user_id).name rescue '' %></td></tr>

		<% if @lab.lab_files.size > 0 %>
		<tr><th><%= t("personal_lab.file")%></th>
		<td>
			<div>				
				<div class="showFile">
					<i class="icons-paperclip"></i>
					<% @lab.lab_files.each do | lfile | %>
					<%= link_to lfile.title, lfile.file.url, {:target => '_blank', :title => lfile.title} if lfile.file.file %>
					<% end %>
				</div>
			</div>
		</td>
		</tr>
		<% end %>
	</tbody>
</table>
