baseline
[omp.pkp.sfu.ca.git] / templates / submission / metadata / metadata.tpl
blob6f78186a6af93e02b6d51bfa5ee55c9af452d5b1
1 {**
2  * metadata.tpl
3  *
4  * Copyright (c) 2003-2008 John Willinsky
5  * Distributed under the GNU GPL v2. For full terms see the file docs/COPYING.
6  *
7  * Subtemplate defining the submission metadata table.
8  *
9  * $Id: metadata.tpl,v 1.6 2009/09/10 00:40:18 mcrider Exp $
10  *}
12 {literal}
13 <script type="text/javascript">
14 <!--
15 function show(id) {
16         var info = document.getElementById(id);
17         if(info.style.display=='block') info.style.display='none';
18         else info.style.display='block';
20 //-->
21 </script>
22 {/literal}
24 <div id="metadata">
25 <h3>{translate key="submission.metadata"}</h3>
27 <p><a href="{url op="viewMetadata" path=$submission->getMonographId()}" class="action">{translate key="submission.editMetadata"}</a></p>
29 {if $submission->getWorkType() != WORK_TYPE_EDITED_VOLUME}
30         <h4>{translate key="monograph.authors"}</h4>
31 {/if}
33 {assign var="authorIndex" value=0} 
34 {assign var="firstAuthor" value=false}
36 {foreach name=authors from=$submission->getAuthors() item=author}
38         {if $submission->getWorkType() == WORK_TYPE_EDITED_VOLUME}
39                 {if $authorIndex == 0 && $author->getContributionType() == CONTRIBUTION_TYPE_VOLUME_EDITOR}
40                         <h4>{translate key="inserts.contributors.volumeEditors"}</h4>
41                 {/if}
42                 {if $firstAuthor == false && $author->getContributionType() != CONTRIBUTION_TYPE_VOLUME_EDITOR}
43                         <h4>{translate key="monograph.authors"}</h4>
44                         {assign var="firstAuthor" value=true}
45                 {/if}
46         {/if}
48         <div class="{if $authorIndex % 2}oddSideIndicator{else}evenSideIndicator{/if}">
49                 {assign var=emailString value="`$author->getFullName()` <`$author->getEmail()`>"}
50                 {url|assign:"url" page="user" op="email" redirectUrl=$currentUrl to=$emailString|to_array subject=$submission->getLocalizedTitle()|strip_tags monographId=$submission->getMonographId()}
51                 &nbsp;<a href="javascript:show('authors-{$author->getId()|escape}-display')">{$author->getFullname()}</a>&nbsp;{icon name="mail" url=$url}
52                 {if $author->getPrimaryContact()}<br />&nbsp;{translate key="author.submit.selectPrincipalContact"}{/if}
53         <br />
54         </div>
55         <div id="authors-{$author->getId()|escape}-display" class="{if $authorIndex % 2}oddSideIndicator{else}evenSideIndicator{/if}" style="display:none">
56                 <table class="data">
57                 {if $author->getUrl()}
58                 <tr valign="top">
59                         <td class="label">{translate key="user.url"}</td>
60                         <td class="value"><a href="{$author->getUrl()|escape:"quotes"}">{$author->getUrl()|escape}</a></td>
61                 </tr>
62                 {/if}
63                 <tr valign="top">
64                         <td class="label">{translate key="user.affiliation"}</td>
65                         <td class="value">{$author->getAffiliation()|escape|nl2br|default:"&mdash;"}</td>
66                 </tr>
67                 <tr valign="top">
68                         <td class="label">{translate key="common.country"}</td>
69                         <td class="value">{$author->getCountryLocalized()|escape|default:"&mdash;"}</td>
70                 </tr>
71                 <tr valign="top">
72                         <td class="label">{translate key="user.biography"}</td>
73                         <td class="value">{$author->getAuthorBiography()|strip_unsafe_html|nl2br|default:"&mdash;"}</td>
74                 </tr>
75                 {if !$smarty.foreach.authors.last}
76                 <tr>
77                         <td colspan="2" class="separator">&nbsp;</td>
78                 </tr>
79                 {/if}
80                 </table>
81         </div>
82         <br />
83         {assign var="authorIndex" value=$authorIndex+1}
84 {/foreach}
86 <h4>{translate key="submission.titleAndAbstract"}</h4>
88 <table width="100%" class="data">
89         <tr valign="top">
90                 <td width="20%" class="label">{translate key="monograph.title"}</td>
91                 <td width="80%" class="value">{$submission->getLocalizedTitle()|strip_unsafe_html|default:"&mdash;"}</td>
92         </tr>
94         <tr>
95                 <td colspan="2" class="separator">&nbsp;</td>
96         </tr>
97         <tr valign="top">
98                 <td class="label">{translate key="monograph.abstract"}</td>
99                 <td class="value">{$submission->getLocalizedAbstract()|strip_unsafe_html|nl2br|default:"&mdash;"}</td>
100         </tr>
101 </table>
103 <h4>{translate key="submission.supportingAgencies"}</h4>
104         
105 <table width="100%" class="data">
106         <tr valign="top">
107                 <td width="20%" class="label">{translate key="author.submit.agencies"}</td>
108                 <td width="80%" class="value">{$submission->getLocalizedSponsor()|escape|default:"&mdash;"}</td>
109         </tr>
110 </table>
111 </div>