baseline
[omp.pkp.sfu.ca.git] / templates / designer / completed.tpl
blobda06fddfad259e331f6857725718a4703aef11a7
1 {**
2  * completed.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  * Show layout editor's submission archive.
8  *
9  * $Id: completed.tpl,v 1.5 2009/07/30 23:16:14 tylerl Exp $
10  *}
11 {if !$dateFrom}
12 {assign var="dateFrom" value="--"}
13 {/if}
15 {if !$dateTo}
16 {assign var="dateTo" value="--"}
17 {/if}
19 <form method="post" name="submit" action="{url op="submissions" path=$pageToDisplay}">
20         <select name="searchField" size="1" class="selectMenu">
21                 {html_options_translate options=$fieldOptions selected=$searchField}
22         </select>
23         <select name="searchMatch" size="1" class="selectMenu">
24                 <option value="contains"{if $searchMatch == 'contains'} selected="selected"{/if}>{translate key="form.contains"}</option>
25                 <option value="is"{if $searchMatch == 'is'} selected="selected"{/if}>{translate key="form.is"}</option>
26                 <option value="startsWith"{if $searchMatch == 'startsWith'} selected="selected"{/if}>{translate key="form.startsWith"}</option>
27         </select>
28         <input type="text" size="15" name="search" class="textField" value="{$search|escape}" />
29         <br/>
30         <select name="dateSearchField" size="1" class="selectMenu">
31                 {html_options_translate options=$dateFieldOptions selected=$dateSearchField}
32         </select>
33         {translate key="common.between"}
34         {html_select_date prefix="dateFrom" time=$dateFrom all_extra="class=\"selectMenu\"" year_empty="" month_empty="" day_empty="" start_year="-5" end_year="+1"}
35         {translate key="common.and"}
36         {html_select_date prefix="dateTo" time=$dateTo all_extra="class=\"selectMenu\"" year_empty="" month_empty="" day_empty="" start_year="-5" end_year="+1"}
37         <input type="hidden" name="dateToHour" value="23" />
38         <input type="hidden" name="dateToMinute" value="59" />
39         <input type="hidden" name="dateToSecond" value="59" />
40         <br/>
41         <input type="submit" value="{translate key="common.search"}" class="button" />
42 </form>
43 &nbsp;
45 <div id="submissions">
46 <table width="100%" class="listing">
47         <tr><td colspan="7" class="headseparator">&nbsp;</td></tr>
48         <tr class="heading" valign="bottom">
49                 <td width="5%">{translate key="common.id"}</td>
50                 <td width="5%"><span class="disabled">MM-DD</span><br />{translate key="common.assign"}</td>
51                 <td width="5%">{translate key="submissions.arrangement"}</td>
52                 <td width="25%">{translate key="monograph.authors"}</td>
53                 <td width="30%">{translate key="monograph.title"}</td>
54                 <td width="5%">{translate key="submission.complete"}</td>
55                 <td width="25%" align="right">{translate key="common.status"}</td>
56         </tr>
57         <tr><td colspan="7" class="headseparator">&nbsp;</td></tr>
58 {iterate from=submissions item=submission}
59         {assign var="monographId" value=$submission->getMonographId()}
60         {assign var="layoutAssignment" value=$submission->getLayoutAssignment()}
62         <tr valign="top">
63                 <td>{$monographId|escape}</td>
64                 <td>{$layoutAssignment->getDateNotified()|date_format:$dateFormatTrunc}</td>
65                 <td>{$submission->getArrangementAbbrev()|escape}</td>
66                 <td>{$submission->getAuthorString(true)|truncate:40:"..."|escape}</td>
67                 <td><a href="{url op="submission" path=$monographId}" class="action">{$submission->getLocalizedTitle()|strip_unsafe_html|truncate:60:"..."}</a></td>
68                 <td>{$layoutAssignment->getDateCompleted()|date_format:$dateFormatTrunc}</td>
69                 <td align="right">
70                         {assign var="status" value=$submission->getStatus()}
71                         {if $status == STATUS_ARCHIVED}
72                                 {translate key="submissions.archived"}
73                         {elseif $status == STATUS_QUEUED}
74                                 {translate key="submissions.queued"}
75                         {elseif $status == STATUS_PUBLISHED}
76                                 ##ID##          
77                         {elseif $status == STATUS_DECLINED}
78                                 {translate key="submissions.declined"}                                                          
79                         {/if}
80                 </td>
81         </tr>
82         <tr>
83                 <td colspan="7" class="{if $submissions->eof()}end{/if}separator">&nbsp;</td>
84         </tr>
85 {/iterate}
86 {if $submissions->wasEmpty()}
87         <tr>
88                 <td colspan="7" class="nodata">{translate key="submissions.noSubmissions"}</td>
89         </tr>
90         <tr>
91                 <td colspan="7" class="endseparator">&nbsp;</td>
92         </tr>
93 {else}
94         <tr>
95                 <td colspan="4" align="left">{page_info iterator=$submissions}</td>
96                 <td colspan="3" align="right">{page_links anchor="submissions" name="submissions" iterator=$submissions searchField=$searchField searchMatch=$searchMatch search=$search dateFromDay=$dateFromDay dateFromYear=$dateFromYear dateFromMonth=$dateFromMonth dateToDay=$dateToDay dateToYear=$dateToYear dateToMonth=$dateToMonth}</td>
97         </tr>
98 {/if}
99 </table>
100 </div>