]>
src.bluestatic.org Git - bugdar.git/blob - index.php
2 /*=====================================================================*\
3 || ################################################################### ||
4 || # BugStrike [#]version[#]
5 || # --------------------------------------------------------------- # ||
6 || # Copyright ©2002-[#]year[#] by Iris Studios, Inc. All Rights Reserved. # ||
7 || # This file may not be reproduced in any way without permission. # ||
8 || # --------------------------------------------------------------- # ||
9 || # User License Agreement at http://www.iris-studios.com/license/ # ||
10 || ################################################################### ||
11 \*=====================================================================*/
13 $fetchtemplates = array(
18 define('SVN', '$Id$');
20 $focus['index
'] = 'focus
';
22 require_once('./global.php
');
24 if (!can_perform('canviewbugs
'))
26 $message->error_permission();
29 // ###################################################################
31 // #*# pagination needs to be done here
33 $bugs_fetch = $db->query("
34 SELECT bug.*, user1.displayname AS firstreport, user2.displayname AS lastpost, user3.displayname AS hiddenlastpost
35 FROM " . TABLE_PREFIX . "bug AS bug
36 LEFT JOIN user AS user1
37 ON (bug.userid = user1.userid)
38 LEFT JOIN user AS user2
39 ON (bug.lastpostby = user2.userid)
40 LEFT JOIN user AS user3
41 ON (bug.hiddenlastpostby = user3.userid)" . ((!can_perform('canviewhidden
')) ? "
42 WHERE !hidden" : "") . "
43 ORDER BY bug." . ((can_perform('canviewhidden
')) ? "lastposttime" : "hiddenlastposttime") . " DESC"
46 while ($bug = $db->fetch_array($bugs_fetch))
48 $bug['bgcolour
'] = $bugsys->datastore['status
']["$bug[status]"]['color
'];
49 $bug['product
'] = $bugsys->datastore['product
']["$bug[productid]"]['title
'];
50 $bug['version
'] = $bugsys->datastore['version
']["$bug[versionid]"]['version
'];
51 $bug['status
'] = $bugsys->datastore['status
']["$bug[status]"]['status
'];
52 $bug['resolution
'] = $bugsys->datastore['resolution
']["$bug[resolution]"]['resolution
'];
54 $bug['hiddendisplay
'] = ((!can_perform('canviewhidden
') AND $bug['hiddenlastposttime
']) ? true : false);
56 $bug['lastposttime
'] = (($bug['hiddendisplay
']) ? $bug['hiddenlastposttime
'] : $bug['lastposttime
']);
57 $bug['lastpost
'] = (($bug['hiddendisplay
']) ? $bug['hiddenlastpost
'] : $bug['lastpost
']);
59 $bug['lastpostinfo
'] = $datef->format($bugsys->options['dateformat
'], $bug['lastposttime
']) . ' by
' . $bug['lastpost
'];
61 eval('$bugs .= "' . $template->fetch('trackerhome_bits') . '";');
64 $db->free_result($bugs_fetch);
66 $show['newreport
'] = ((can_perform('cansubmitbugs
')) ? true : false);
68 eval('$template->flush("' . $template->fetch('TRACKERHOME') . '");');
70 /*=====================================================================*\
71 || ###################################################################
74 || ###################################################################
75 \*=====================================================================*/