5 * Copyright 1999-2001 (c) VA Linux Systems
6 * Copyright (C) 2011 Alain Peyrat - Alcatel-Lucent
7 * Copyright 2012-2014, Franck Villaume - TrivialDev
8 * Copyright 2012, Thorsten “mirabilos” Glaser <t.glaser@tarent.de>
9 * http://fusionforge.org/
11 * This file is part of FusionForge. FusionForge is free software;
12 * you can redistribute it and/or modify it under the terms of the
13 * GNU General Public License as published by the Free Software
14 * Foundation; either version 2 of the Licence, or (at your option)
17 * FusionForge is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License along
23 * with FusionForge; if not, write to the Free Software Foundation, Inc.,
24 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
35 html_use_coolfieldset();
36 $ath->header(array ('title'=> $ah->getStringID().' '. $ah->getSummary(), 'atid'=>$ath->getID()));
41 <script type="text/javascript">//<![CDATA[
42 jQuery(document).ready(function() {
43 jQuery("#tabber").tabs();
47 <h1>[#<?php echo $ah->getID(); ?>] <?php echo $ah->getSummary(); ?></h1>
49 <form id="trackermodlimitedform" action="<?php echo getStringFromServer('PHP_SELF'); ?>?group_id=<?php echo $group_id; ?>&atid=<?php echo $ath->getID(); ?>" enctype="multipart/form-data" method="post">
50 <input type="hidden" name="form_key" value="<?php echo form_generate_key(); ?>" />
51 <input type="hidden" name="func" value="postmod" />
52 <input type="hidden" name="MAX_FILE_SIZE" value="10000000" />
53 <input type="hidden" name="artifact_id" value="<?php echo $ah->getID(); ?>" />
57 if (session_loggedin()) {
61 if ($ah->isMonitoring()) {
64 $text=_('Stop Monitoring');
71 <a id="tracker-monitor" href="index.php?group_id='.$group_id.'&artifact_id='.$ah->getID().'&atid='.$ath->getID().'&func=monitor" title="'.util_html_secure(html_get_tooltip_description('monitor')).'"><strong>'.
72 html_image('ic/'.$img.'','20','20').' '.$text.'</strong></a>';
76 $votes = $ah->getVotes();
77 echo '<span id="tracker-votes" title="'.html_get_tooltip_description('votes').'" >'.html_e('strong', array(), _('Votes') . _(': ')).sprintf('%1$d/%2$d (%3$d%%)', $votes[0], $votes[1], $votes[2]).'</span>';
78 if ($ath->canVote()) {
80 $key = 'pointer_down';
81 $txt = _('Retract Vote');
84 $txt = _('Cast Vote');
86 echo '<a id="tracker-vote" alt="'.$txt.'" title="'.html_get_tooltip_description('vote').'" href="'.getselfhref(array('func' => $key)) . '">' .
87 html_image('ic/' . $key . '.png', '16', '16', array('border' => '0')) . '</a>';
92 if ($group->usesPM()) {
94 <a href="'.getStringFromServer('PHP_SELF').'?func=taskmgr&group_id='.$group_id.'&atid='.$atid.'&aid='.$aid.'">'.
95 html_image('ic/taskman20w.png','20','20').'<strong>'._('Build Task Relation').'</strong></a>';
100 <input type="submit" name="submit" value="<?php echo _('Save Changes') ?>" />
108 <td><strong><?php echo _('Submitted by')._(':'); ?></strong><br />
110 echo $ah->getSubmittedRealName();
111 if($ah->getSubmittedBy() != 100) {
112 $submittedUnixName = $ah->getSubmittedUnixName();
113 $submittedBy = $ah->getSubmittedBy();
115 (<tt><?php echo util_make_link_u ($submittedUnixName,$submittedBy,$submittedUnixName); ?></tt>)
118 <td><strong><?php echo _('Date Submitted')._(':'); ?></strong><br />
120 echo date(_('Y-m-d H:i'), $ah->getOpenDate() );
122 $close_date = $ah->getCloseDate();
123 if ($ah->getStatusID()==2 && $close_date > 1) {
124 echo '<br /><strong>'._('Date Closed')._(':').'</strong><br />'
125 .date(_('Y-m-d H:i'), $close_date);
132 $ath->renderExtraFields($ah->getExtraFieldData(),true,'none',false,'Any',array(),false,'UPDATE');
136 <td><strong><?php echo _('Assigned to')._(':'); ?></strong><br />
137 <span id="tracker-assigned_to" title="<?php echo html_get_tooltip_description('assigned_to') ?>">
138 <?php echo $ah->getAssignedRealName(); ?> (<?php echo $ah->getAssignedUnixName(); ?>)
141 <strong><?php echo _('Priority')._(':'); ?></strong><br />
142 <span id="tracker-priority" title="<?php echo html_get_tooltip_description('priority') ?>">
143 <?php echo $ah->getPriority(); ?>
147 <?php if (!$ath->usesCustomStatuses()) { ?>
150 <strong><?php echo _('State')._(':'); ?></strong><br />
151 <span id="tracker-status_id" title="<?php echo util_html_secure(html_get_tooltip_description('status_id')) ?>">
152 <?php echo $ath->statusBox ('status_id', $ah->getStatusID() ); ?>
160 $ath->renderRelatedTasks($group, $ah);
163 <td colspan="2"><strong><?php echo _('Summary')._(':'); ?><?php echo utils_requiredField(); ?></strong><br />
164 <span id="tracker-summary" title="<?php echo html_get_tooltip_description('summary') ?>">
165 <?php echo $ah->getSummary(); ?>
171 <?php $ah->showDetails(); ?>
176 $count=db_numrows($ah->getMessages());
177 $nb = $count? ' ('.$count.')' : '';
178 $pm = new PluginManager();
179 $pluginsListeners = $pm->GetHookListeners('artifact_extra_detail');
180 $pluginfound = false;
181 foreach ($pluginsListeners as $pluginsListener) {
182 if ($ath->Group->usesPlugin($pluginsListener)) {
189 <li><a href="#tabber-comments"><?php echo _('Comments'); ?></a></li>
190 <li><a href="#tabber-attachments"><?php echo _('Attachments'); ?></a></li>
191 <?php if ($pluginfound) { ?>
192 <li><a href="#tabber-commits"><?php echo _('Commits'); ?></a></li>
194 <li><a href="#tabber-changes"><?php echo _('Changes'); ?></a></li>
196 <div id="tabber-comments" class="tabbertab" title="<?php echo _('Comments').$nb; ?>">
199 <br /><strong><?php echo _('Add A Comment') ?>: <?php echo notepad_button('document.forms.trackermodlimitedform.details') ?></strong><br />
200 <textarea id="tracker-comment" name="details" rows="7" cols="60" title="<?php echo util_html_secure(html_get_tooltip_description('comment')) ?>"></textarea>
202 <h2><?php echo _('Comments')._(': ');
211 $file_list = $ah->getFiles();
212 $count=count($file_list);
213 $nb = $count? ' ('.$count.')' : '';
215 <div id="tabber-attachments" class="tabbertab" title="<?php echo _('Attachments').$nb; ?>">
216 <h2><?php echo _('Existing Files')._(':'); ?></h2>
219 <?php echo _('Attach Files')._(':'); ?> <?php echo('('._('max upload size: '.human_readable_bytes(util_get_maxuploadfilesize())).')') ?><br />
220 <input type="file" name="input_file0" size="30" /><br />
221 <input type="file" name="input_file1" size="30" /><br />
222 <input type="file" name="input_file2" size="30" /><br />
223 <input type="file" name="input_file3" size="30" /><br />
224 <input type="file" name="input_file4" size="30" />
226 <h2><?php echo _('Attached Files')._(':'); ?></h2>
229 // print a list of files attached to this Artifact
231 $ath->renderFiles($group_id, $ah);
236 <?php if ($pluginfound) { ?>
237 <div id="tabber-commits" class="tabbertab" title="<?php echo _('Commits'); ?>">
239 <tr><td colspan="2"><!-- dummy in case the hook is empty --></td></tr>
241 $hookParams['artifact_id'] = $aid;
242 $hookParams['group_id'] = $group_id;
243 plugin_hook("artifact_extra_detail",$hookParams);
248 <div id="tabber-changes" class="tabbertab" title="<?php echo _('Changes'); ?>">
249 <h2><?php echo _('Changes') ?></h2>
250 <?php $ah->showHistory(); ?>
252 <?php $ah->showRelations(); ?>
261 // c-file-style: "bsd"