You can subscribe to this list here.
| 2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(34) |
Aug
(215) |
Sep
(180) |
Oct
(135) |
Nov
(105) |
Dec
(81) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2002 |
Jan
(76) |
Feb
(22) |
Mar
(154) |
Apr
(149) |
May
(128) |
Jun
(94) |
Jul
(14) |
Aug
(24) |
Sep
(77) |
Oct
(52) |
Nov
(22) |
Dec
(6) |
| 2003 |
Jan
(4) |
Feb
(10) |
Mar
(6) |
Apr
(29) |
May
(10) |
Jun
(37) |
Jul
(39) |
Aug
(13) |
Sep
(23) |
Oct
(3) |
Nov
(7) |
Dec
(2) |
| 2004 |
Jan
|
Feb
(10) |
Mar
(4) |
Apr
|
May
(35) |
Jun
(4) |
Jul
(17) |
Aug
(6) |
Sep
(14) |
Oct
(18) |
Nov
(2) |
Dec
(14) |
| 2005 |
Jan
(9) |
Feb
(30) |
Mar
(6) |
Apr
|
May
(38) |
Jun
(23) |
Jul
(21) |
Aug
(76) |
Sep
(50) |
Oct
(51) |
Nov
(13) |
Dec
|
|
From: Jirka P. <fi...@us...> - 2002-06-17 13:48:22
|
Update of /cvsroot/phpbt/phpbt/templates/default
In directory usw-pr-cvs1:/tmp/cvs-serv29019/phpbt/templates/default
Modified Files:
bugform.html
Log Message:
Localized a bit and added some fields (with code cleanup). Needed somebody to redesign the HTML form in bugform.html. I've only inserted some fields and didn't care much about visual design Let me know.
Index: bugform.html
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/bugform.html,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- bugform.html 18 May 2002 03:00:50 -0000 1.5
+++ bugform.html 17 Jun 2002 13:48:19 -0000 1.6
@@ -1,83 +1,59 @@
<form action="bug.php" method="post">
-<input type="hidden" name="bugid" value="0">
-<input type="hidden" name="project" value="{$project}">
-<input type="hidden" name="op" value="do">
-<table border="0">
- {if $error}
- <tr>
- <td colspan="2" class="error">{$error}</td>
- </tr>
- {/if}
- <tr>
- <td align="right" valign="top">Project:</td>
- <td>{$projectname|stripslashes}</td>
- </tr>
- <tr>
- <td align="right" valign="top">Version:</td>
- <td>
- <select name="version">
- {build_select box=version selected=$version project=$project}
- </select>
- </td>
- </tr>
-
- <tr>
- <td align="right" valign="top">Summary:</td>
- <td><input type="text" size="50" maxlength="100" name="title" value="{$title|stripslashes|htmlentities}"></td>
- </tr>
- <tr>
- <td align="right" valign="top">Description:</td>
- <td><textarea name="description" cols="50" rows="8" wrap=virtual>{$description|stripslashes|htmlentities}</textarea></td>
- </tr>
- <tr>
- <td align="right" valign="top">URL:</td>
- <td><input type="text" size="30" maxlength="255" name="url" value="{$url}"></td>
- </tr>
-
- <tr>
- <td align="right" valign="top">Severity:</td>
- <td>
- <select name="severity">
- {build_select box=severity selected=$severity}
- </select>
- </td>
- </tr>
-
- <tr>
- <td align="right" valign="top">Priority:</td>
- <td>
- <select name="priority">
- {build_select box=priority selected=$priority}
- </select>
- </td>
- </tr>
-
- <tr>
- <td align="right" valign="top">Component:</td>
- <td>
- <select name="component">
- {build_select box=component selected=$component project=$project}
- </select>
- </td>
- </tr>
-
- <tr>
- <td align="right" valign="top">OS:</td>
- <td>
- <select name="os">
- {build_select box=os selected=$os}
- </select>
- </td>
- </tr>
- <tr>
- <td align="right" valign="top">
- Add another:
- </td>
- <td valign="top">
- <input type="checkbox" name="another" value="1">
- </td>
+ <input type="hidden" name="bugid" value="0">
+ <input type="hidden" name="project" value="{$project}">
+ <input type="hidden" name="op" value="do">
+ <table border="0">
+{if $error}
+ <tr>
+ <td colspan="2" class="error">{$error}</td>
+ </tr>
+{/if}
+ <tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Project}:</td>
+ <td>{$projectname|stripslashes|htmlspecialchars}</td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Version}:</td>
+ <td><select name="version">{build_select box=version selected=$version project=$project}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Summary}:</td>
+ <td><input type="text" size="50" maxlength="100" name="title"
+ value="{$title|stripslashes|htmlentities}"></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Description}:</td>
+ <td><textarea name="description" cols="50" rows="8"
+ wrap=virtual>{$description|stripslashes|htmlentities}</textarea></td>
+ </tr><tr>
+ <td align="right" valign="top">URL:</td>
+ <td><input type="text" size="30" maxlength="255" name="url" value="{$url}"></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Severity}:</td>
+ <td><select name="severity">{build_select box=severity selected=$severity}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Priority}:</td>
+ <td><select name="priority">{build_select box=priority selected=$priority}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Component}:</td>
+ <td><select name="component">{build_select box=component selected=$component project=$project}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Database}:</td>
+ <td><select name="database">{build_select box=database selected=$database}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.Site}:</td>
+ <td><select name="site">{build_select box=site selected=$site}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.OS}:</td>
+ <td><select name="os">{build_select box=os selected=$os}
+ </select></td>
+ </tr><tr>
+ <td align="right" valign="top">{$STRING.BUGFORM.AddAnother}:</td>
+ <td valign="top"><input type="checkbox" name="another" value="1"></td>
</tr>
-
-</table>
-<input type="submit" name="submit" value="Submit">
+ </table>
+ <input type="submit" name="submit" value="Submit">
</form>
|
|
From: Benjamin C. <bc...@us...> - 2002-06-17 13:09:05
|
Update of /cvsroot/phpbt/phpbt/languages In directory usw-pr-cvs1:/tmp/cvs-serv12675/languages Modified Files: en.php Log Message: Cleanup Index: en.php =================================================================== RCS file: /cvsroot/phpbt/phpbt/languages/en.php,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- en.php 17 Jun 2002 12:49:11 -0000 1.23 +++ en.php 17 Jun 2002 13:09:00 -0000 1.24 @@ -91,20 +91,20 @@ 'sitelist' => 'Site list', 'sites' => 'Sites', 'QUERY' => array( - 'opt_All' => 'All', - 'Project' => 'Project', - 'Version' => 'Version', - 'Component' => 'Component', - 'Status' => 'Status', - 'Resolution' => 'Resolution', - 'OpSys' => 'OpSys', - 'Priority' => 'Priority', - 'Severity' => 'Severity', - 'Database' => 'Database', - 'ReportedOnSite' => 'Reported on Site', - 'Summary' => 'Summary', - 'DescriptionEntry' => 'A description entry', - 'SortBy' => 'Sort By', + 'opt_All' => 'All', + 'Project' => 'Project', + 'Version' => 'Version', + 'Component' => 'Component', + 'Status' => 'Status', + 'Resolution' => 'Resolution', + 'OpSys' => 'OpSys', + 'Priority' => 'Priority', + 'Severity' => 'Severity', + 'Database' => 'Database', + 'ReportedOnSite' => 'Reported on Site', + 'Summary' => 'Summary', + 'DescriptionEntry' => 'A description entry', + 'SortBy' => 'Sort By', 'SortBy_BugNumber' => 'Bug Number', 'SortBy_Severity' => 'Severity', 'SortBy_Reporter' => 'Reporter', @@ -112,33 +112,33 @@ 'SortBy_Status' => 'Status', 'SortAsc' => 'Ascending', 'SortDesc' => 'Descending', - 'SaveThisQueryAs' => 'Save this query as', - 'ResetBackToDefaultQuery' => 'Reset back to default query', - 'SubmitQuery' => 'Submit query', - 'SavedQueries' => 'Saved Queries', - 'GoToThe' => 'Go to the', - 'AdvancedQueryPage' => 'advanced query page', - 'SimpleQueryPage' => 'simple query page', - 'SureDeleteSavedQuery' => 'Are you sure to delete this saved query?', - 'MatchingAs' => 'matching as', + 'SaveThisQueryAs' => 'Save this query as', + 'ResetBackToDefaultQuery' => 'Reset back to default query', + 'SubmitQuery' => 'Submit query', + 'SavedQueries' => 'Saved Queries', + 'GoToThe' => 'Go to the', + 'AdvancedQueryPage' => 'advanced query page', + 'SimpleQueryPage' => 'simple query page', + 'SureDeleteSavedQuery' => 'Are you sure you want to delete this saved query?', + 'MatchingAs' => 'matching as', 'MatchingAs_Regexp' => 'regexp', 'MatchingAs_NotRegexp' => 'not regexp', 'MatchingAs_Substring' => 'substring', 'MatchingAs_Exact' => 'exact', - 'eMail_Reporter' => 'Reporter', - 'eMail_AssignedTo' => 'Assigned To' + 'eMail_Reporter' => 'Reporter', + 'eMail_AssignedTo' => 'Assigned To' ), - 'WRAP' => array( - 'FindBug' => 'Find Bug', - 'Home' => 'Home', - 'AddNewBug' => 'Add a new Bug', - 'QueryBugs' => 'Query Bugs', - 'ViewReports' => 'View Reports', - 'Documentation' => 'Read Documentation', - 'AdminTools' => 'Admin Tools', - 'CreateNewAccount' => 'Create a new Account' - ) - ); + 'WRAP' => array( + 'FindBug' => 'Find Bug', + 'Home' => 'Home', + 'AddNewBug' => 'Add a new Bug', + 'QueryBugs' => 'Query Bugs', + 'ViewReports' => 'View Reports', + 'Documentation' => 'Read Documentation', + 'AdminTools' => 'Admin Tools', + 'CreateNewAccount' => 'Create a new Account' + ) +); // Page titles $TITLE = array( @@ -190,5 +190,6 @@ 'database' => 'Databases', 'site' => 'Sites', 'documentation' => 'Read documentation' - ); +); + ?> |
|
From: Benjamin C. <bc...@us...> - 2002-06-17 12:49:18
|
Update of /cvsroot/phpbt/phpbt/languages
In directory usw-pr-cvs1:/tmp/cvs-serv7334/languages
Modified Files:
en.php
Log Message:
Removed trailing space
Index: en.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/languages/en.php,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- en.php 17 Jun 2002 09:21:52 -0000 1.22
+++ en.php 17 Jun 2002 12:49:11 -0000 1.23
@@ -192,4 +192,3 @@
'documentation' => 'Read documentation'
);
?>
-
|
|
From: Benjamin C. <bc...@us...> - 2002-06-17 12:34:02
|
Update of /cvsroot/phpbt/phpbt
In directory usw-pr-cvs1:/tmp/cvs-serv3205
Modified Files:
query.php
Log Message:
Fixes bug #561074 - Opera submits the incorrect value on the query page for the components and versions
Index: query.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/query.php,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -r1.81 -r1.82
--- query.php 14 Jun 2002 15:26:05 -0000 1.81
+++ query.php 17 Jun 2002 12:33:59 -0000 1.82
@@ -129,8 +129,8 @@
// Project/Version/Component
if (!empty($projects)) {
$proj[] = "b.project_id = $projects";
- if (!empty($versions)) $proj[] = "b.version_id = $versions";
- if (!empty($components)) $proj[] = "b.component_id = $components";
+ if (!empty($versions) and $versions != 'All') $proj[] = "b.version_id = $versions";
+ if (!empty($components) and $components != 'All') $proj[] = "b.component_id = $components";
$query[] = '('.delimit_list(' and ',$proj).')';
} elseif (!$perm->have_perm('Admin')) { // Filter results from hidden projects
$query[] = "b.project_id not in ($restricted_projects)";
|
|
From: Jirka P. <fi...@us...> - 2002-06-17 09:21:57
|
Update of /cvsroot/phpbt/phpbt/templates/default
In directory usw-pr-cvs1:/tmp/cvs-serv14929/phpbt/templates/default
Modified Files:
queryform-simple.html queryform.html wrap-popup.html wrap.html
Log Message:
Switch to associative arrays for templates and some code cleanup.
Q: Is anyone testing files from CVS, except me and Ben? Please, let me know ...
Index: queryform-simple.html
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/queryform-simple.html,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- queryform-simple.html 13 Jun 2002 14:26:37 -0000 1.8
+++ queryform-simple.html 17 Jun 2002 09:21:52 -0000 1.9
@@ -28,55 +28,55 @@
<form method="get" action="query.php" name="query">
<table>
<tr valign="baseline">
- <td valign="top"><b>{$STRING._Project}:</b></td>
+ <td valign="top"><b>{$STRING.QUERY.Project}:</b></td>
<td valign="top">
<select name="projects" onChange="updateMenus(this.form)">
- <option value=''>{$STRING._opt_All}</option>
+ <option value=''>{$STRING.QUERY.opt_All}</option>
{build_select box=project}
</select>
</td>
</tr>
<tr valign="baseline">
- <td valign="top"><b>{$STRING._Version}:</b></td>
+ <td valign="top"><b>{$STRING.QUERY.Version}:</b></td>
<td valign="top">
- <select name="versions"><option value=''>{$STRING._opt_All}</option></select>
+ <select name="versions"><option value=''>{$STRING.QUERY.opt_All}</option></select>
</td>
</tr>
<tr valign="baseline">
- <td valign="top"><b>{$STRING._Component}:</b></td>
+ <td valign="top"><b>{$STRING.QUERY.Component}:</b></td>
<td valign="top">
- <select name="components"><option value=''>{$STRING._opt_All}</option></select>
+ <select name="components"><option value=''>{$STRING.QUERY.opt_All}</option></select>
</td>
</tr>
<tr valign="baseline">
- <td valign="top"><b>{$STRING._Status}:</b></td>
+ <td valign="top"><b>{$STRING.QUERY.Status}:</b></td>
<td valign="top">
<select name="status[]" multiple size="7">{build_select box=status}</select>
</td>
</tr>
<tr valign="baseline">
- <td valign="top"><b>{$STRING._SortBy}:</b></td>
+ <td valign="top"><b>{$STRING.QUERY.SortBy}:</b></td>
<td valign="top">
<select name="order">
<option value="bug_id">
- {$STRING._SortBy_BugNumber}
+ {$STRING.QUERY.SortBy_BugNumber}
</option>
<option selected value="severity.sort_order">
- {$STRING._SortBy_Severity}
+ {$STRING.QUERY.SortBy_Severity}
</option>
<option value="reporter">
- {$STRING._SortBy_Reporter}
+ {$STRING.QUERY.SortBy_Reporter}
</option>
<option value="status.sort_order">
- {$STRING._SortBy_Status}
+ {$STRING.QUERY.SortBy_Status}
</option>
<option value="priority">
- {$STRING._SortBy_Priority}
+ {$STRING.QUERY.SortBy_Priority}
</option>
</select>
<select name="sort">
- <option selected value="asc">{$STRING._SortAsc}</option>
- <option value="desc">{$STRING._SortDesc}</option>
+ <option selected value="asc">{$STRING.QUERY.SortAsc}</option>
+ <option value="desc">{$STRING.QUERY.SortDesc}</option>
</select>
</td>
</tr>
@@ -84,20 +84,20 @@
<br>
<br>
{if $smarty.session.uid}
- {$STRING._SaveThisQueryAs}: <input maxlength="40" type="text" name="savedqueryname">
+ {$STRING.QUERY.SaveThisQueryAs}: <input maxlength="40" type="text" name="savedqueryname">
<br><br>
{/if}
<input type="hidden" name="op" value="doquery">
- <input type="reset" value="{$STRING._ResetBackToDefaultQuery}">
- <input type="submit" value="{$STRING._SubmitQuery}">
+ <input type="reset" value="{$STRING.QUERY.ResetBackToDefaultQuery}">
+ <input type="submit" value="{$STRING.QUERY.SubmitQuery}">
{if count($queries)}
<br><br>
- <b>{$STRING._SavedQueries}</b>
+ <b>{$STRING.QUERY.SavedQueries}</b>
<br>
{section name=query loop=$queries}
- <a href="{$smarty.server.PHP_SELF}?{$queries[query].saved_query_string}">{$queries[query].saved_query_name}</a> (<a href="{$smarty.server.PHP_SELF}?op=delquery&queryid={$queries[query].saved_query_id}&form=simple" onClick="return confirm('{$STRING._SureDeleteSavedQuery}');">{$STRING.delete}</a>)<br>
+ <a href="{$smarty.server.PHP_SELF}?{$queries[query].saved_query_string}">{$queries[query].saved_query_name}</a> (<a href="{$smarty.server.PHP_SELF}?op=delquery&queryid={$queries[query].saved_query_id}&form=simple" onClick="return confirm('{$STRING.QUERY.SureDeleteSavedQuery}');">{$STRING.delete}</a>)<br>
{/section}
{/if}
</form>
<br>
- {$STRING._1GoToThe} <a href="{$smarty.server.PHP_SELF}?op=query&form=advanced">{$STRING._1AdvancedQueryPage}</a>
+ {$STRING.QUERY.GoToThe} <a href="{$smarty.server.PHP_SELF}?op=query&form=advanced">{$STRING.QUERY.AdvancedQueryPage}</a>
Index: queryform.html
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/queryform.html,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- queryform.html 13 Jun 2002 14:26:39 -0000 1.16
+++ queryform.html 17 Jun 2002 09:21:53 -0000 1.17
@@ -28,13 +28,13 @@
<form method="get" action="query.php" name="query">
<table>
<tr>
- <th align="left">{$STRING._Status}:</th>
- <th align="left">{$STRING._Resolution}:</th>
- <th align="left">{$STRING._OpSys}:</th>
- <th align="left">{$STRING._Priority}:</th>
- <th align="left">{$STRING._Severity}:</th>
- <th align="left">{$STRING._Database}:</th>
- <th align="left">{$STRING._ReportedOnSite}:</th>
+ <th align="left">{$STRING.QUERY.Status}:</th>
+ <th align="left">{$STRING.QUERY.Resolution}:</th>
+ <th align="left">{$STRING.QUERY.OpSys}:</th>
+ <th align="left">{$STRING.QUERY.Priority}:</th>
+ <th align="left">{$STRING.QUERY.Severity}:</th>
+ <th align="left">{$STRING.QUERY.Database}:</th>
+ <th align="left">{$STRING.QUERY.ReportedOnSite}:</th>
</tr><tr>
<td align="left" valign="top"><select name="status[]"
multiple size="7">{build_select box=status}</select></td>
@@ -64,19 +64,19 @@
<option value="email">Email</option>
<option value="login">Login</option>
</select>: <input name="email1"
- size="30" value=""> {$STRING._MatchingAs}
+ size="30" value=""> {$STRING.QUERY.MatchingAs}
<select name="emailtype1">
- <option value="rlike">{$STRING._MatchingAs_Regexp}</option>
- <option value="not rlike">{$STRING._MatchingAs_NotRegexp}</option>
- <option selected value="like">{$STRING._MatchingAs_Substring}</option>
- <option value="=">{$STRING._MatchingAs_Exact}</option>
+ <option value="rlike">{$STRING.QUERY.MatchingAs_Regexp}</option>
+ <option value="not rlike">{$STRING.QUERY.MatchingAs_NotRegexp}</option>
+ <option selected value="like">{$STRING.QUERY.MatchingAs_Substring}</option>
+ <option value="=">{$STRING.QUERY.MatchingAs_Exact}</option>
</select></td>
<td><input type="checkbox"
name="emailfield1[]" value="owner"
- checked>{$STRING._eMail_AssignedTo}</td>
+ checked>{$STRING.QUERY.eMail_AssignedTo}</td>
</tr><tr>
<td><input type="checkbox" name="emailfield1[]"
- value="reporter">{$STRING._eMail_Reporter}</td>
+ value="reporter">{$STRING.QUERY.eMail_Reporter}</td>
</tr>
</table></td>
</tr>
@@ -85,72 +85,72 @@
</table>
<table border="0">
<tr>
- <td align="right">{$STRING._Summary}:</td>
+ <td align="right">{$STRING.QUERY.Summary}:</td>
<td><input name="title" size="30" value=""></td>
<td><select name="title_type">
- <option value="like" selected>{$STRING._MatchingAs_Substring}</option>
- <option value="rlike">{$STRING._MatchingAs_Regexp}</option>
- <option value="not rlike">{$STRING._MatchingAs_NotRegexp}</option>
+ <option value="like" selected>{$STRING.QUERY.MatchingAs_Substring}</option>
+ <option value="rlike">{$STRING.QUERY.MatchingAs_Regexp}</option>
+ <option value="not rlike">{$STRING.QUERY.MatchingAs_NotRegexp}</option>
</select></td>
</tr><tr>
- <td align="right">{$STRING._DescriptionEntry}:</td>
+ <td align="right">{$STRING.QUERY.DescriptionEntry}:</td>
<td><input name="description" size="30" value=""></td>
<td><select name="description_type">
- <option value="like" selected>{$STRING._MatchingAs_Substring}</option>
- <option value="rlike">{$STRING._MatchingAs_Regexp}</option>
- <option value="not rlike">{$STRING._MatchingAs_NotRegexp}</option>
+ <option value="like" selected>{$STRING.QUERY.MatchingAs_Substring}</option>
+ <option value="rlike">{$STRING.QUERY.MatchingAs_Regexp}</option>
+ <option value="not rlike">{$STRING.QUERY.MatchingAs_NotRegexp}</option>
</select></td>
</tr><tr>
<td align="right">URL:</td>
<td><input name="url" size="30" value=""></td>
<td><select name="url_type">
- <option value="like" selected>{$STRING._MatchingAs_Substring}</option>
- <option value="rlike">{$STRING._MatchingAs_Regexp}</option>
- <option value="not rlike">{$STRING._MatchingAs_NotRegexp}</option>
+ <option value="like" selected>{$STRING.QUERY.MatchingAs_Substring}</option>
+ <option value="rlike">{$STRING.QUERY.MatchingAs_Regexp}</option>
+ <option value="not rlike">{$STRING.QUERY.MatchingAs_NotRegexp}</option>
</select></td>
</tr>
</table>
<hr align="left" width="100%">
<table>
<tr>
- <td><b>{$STRING._Project}:</b></td>
+ <td><b>{$STRING.QUERY.Project}:</b></td>
<td><select name="projects" onChange="updateMenus(this.form)">
- <option value=''>{$STRING._opt_All}</option>{build_select box=project}</select></td>
+ <option value=''>{$STRING.QUERY.opt_All}</option>{build_select box=project}</select></td>
</tr><tr>
- <td><b>{$STRING._Version}:</b></td>
- <td><select name="versions"><option value=''>{$STRING._opt_All}</option></select></td>
+ <td><b>{$STRING.QUERY.Version}:</b></td>
+ <td><select name="versions"><option value=''>{$STRING.QUERY.opt_All}</option></select></td>
</tr><tr>
- <td><b>{$STRING._Component}:</b></td>
- <td><select name="components"><option value=''>{$STRING._opt_All}</option></select></td>
+ <td><b>{$STRING.QUERY.Component}:</b></td>
+ <td><select name="components"><option value=''>{$STRING.QUERY.opt_All}</option></select></td>
</tr>
</table>
<hr align="left" width="100%">
<input type="hidden" name="op" value="doquery">
- <b>{$STRING._SortBy}:</b>
+ <b>{$STRING.QUERY.SortBy}:</b>
<select name="order">
- <option value="bug_id">{$STRING._SortBy_BugNumber}</option>
- <option selected value="severity.sort_order">{$STRING._SortBy_Severity}</option>
- <option value="reporter.login">{$STRING._SortBy_Reporter}</option>
- <option value="status.sort_order">{$STRING._SortBy_Status}</option>
- <option value="priority">{$STRING._SortBy_Priority}</option>
+ <option value="bug_id">{$STRING.QUERY.SortBy_BugNumber}</option>
+ <option selected value="severity.sort_order">{$STRING.QUERY.SortBy_Severity}</option>
+ <option value="reporter.login">{$STRING.QUERY.SortBy_Reporter}</option>
+ <option value="status.sort_order">{$STRING.QUERY.SortBy_Status}</option>
+ <option value="priority">{$STRING.QUERY.SortBy_Priority}</option>
</select>
<select name="sort">
- <option selected value="asc">{$STRING._SortAsc}</option>
- <option value="desc">{$STRING._SortDesc}</option>
+ <option selected value="asc">{$STRING.QUERY.SortAsc}</option>
+ <option value="desc">{$STRING.QUERY.SortDesc}</option>
</select>
</nobr>
<br><br>
{if $smarty.session.uid}
- {$STRING._SaveThisQueryAs}: <input maxlength="40" type="text" name="savedqueryname">
+ {$STRING.QUERY.SaveThisQueryAs}: <input maxlength="40" type="text" name="savedqueryname">
<br><br>
{/if}
- <input type="reset" value="{$STRING._ResetBackToDefaultQuery}">
- <input type="submit" value="{$STRING._SubmitQuery}">
+ <input type="reset" value="{$STRING.QUERY.ResetBackToDefaultQuery}">
+ <input type="submit" value="{$STRING.QUERY.SubmitQuery}">
{if count($queries)}
- <br><br><b>{$STRING._SavedQueries}</b><br>
+ <br><br><b>{$STRING.QUERY.SavedQueries}</b><br>
{section name=query loop=$queries}
<a href="{$smarty.server.PHP_SELF}?{$queries[query].saved_query_string}">{$queries[query].saved_query_name}</a> (<a href="{$smarty.server.PHP_SELF}?op=delquery&queryid={$queries[query].saved_query_id}&form=advanced" onClick="return confirm('Are you sure you want to delete this saved query?');">Delete</a>)<br>
{/section}
{/if}
</form>
-<br>{$STRING._1GoToThe} <a href="{$smarty.server.PHP_SELF}?op=query">{$STRING._1SimpleQueryPage}</a>
+<br>{$STRING.QUERY.GoToThe} <a href="{$smarty.server.PHP_SELF}?op=query">{$STRING.QUERY.SimpleQueryPage}</a>
Index: wrap-popup.html
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/wrap-popup.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- wrap-popup.html 18 May 2002 03:01:22 -0000 1.1
+++ wrap-popup.html 17 Jun 2002 09:21:53 -0000 1.2
@@ -1,18 +1,15 @@
<html>
<head>
- <META HTTP-EQUIV="Expires" CONTENT="-1">
- <title>phpBugTracker - {$page_title}</title>
- <link rel="StyleSheet" href="styles/{$STYLE}.css" type="text/css">
- <META http-equiv="Content-Type" content="text/html; charset={$STRING.lang_charset}">
+ <META HTTP-EQUIV="Expires" CONTENT="-1">
+ <title>phpBugTracker - {$page_title}</title>
+ <link rel="StyleSheet" href="styles/{$STYLE}.css" type="text/css">
+ <META http-equiv="Content-Type" content="text/html; charset={$STRING.lang_charset}">
</head>
<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0">
- <table width="100%" cellspacing="0" cellpadding="0">
- <tr>
- <td class="maincontent">
- {include file=$content_template}
- </td>
- </tr>
- </table>
+ <table width="100%" cellspacing="0" cellpadding="0">
+ <tr>
+ <td class="maincontent">{include file=$content_template}</td>
+ </tr>
+ </table>
</body>
</html>
-<head><meta HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE"></head>
Index: wrap.html
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/wrap.html,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- wrap.html 18 May 2002 03:01:22 -0000 1.18
+++ wrap.html 17 Jun 2002 09:21:53 -0000 1.19
@@ -1,91 +1,78 @@
<html>
<head>
- <META HTTP-EQUIV="Expires" CONTENT="-1">
- <title>phpBugTracker - {$page_title}</title>
- <link rel="StyleSheet" href="styles/{$STYLE}.css" type="text/css">
- <META http-equiv="Content-Type" content="text/html; charset={$STRING.lang_charset}">
+ <META HTTP-EQUIV="Expires" CONTENT="-1">
+ <title>phpBugTracker - {$page_title}</title>
+ <link rel="StyleSheet" href="styles/{$STYLE}.css" type="text/css">
+ <META http-equiv="Content-Type" content="text/html; charset={$STRING.lang_charset}">
</head>
<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0">
- <table width="100%" cellspacing="0" cellpadding="0" height="100%">
- <tr>
- <td width="150" height="30" class="nav">
- phpBugTracker
- </td>
- <td height="30" class="nav" align="right">
- <form action="bug.php">
- <input type="hidden" name="op" value="show">
- Find bug <input type="text" name="bugid" size="4" class="navinput">
-
- </form>
- </td>
- </tr>
- <tr>
- <td width="150" class="sidenav">
- <!-- Nav Links -->
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='index.php'">
- <a href="index.php" class="sidenavlink">Home</a>
- </div>
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='bug.php?op=add'">
- <a href="bug.php?op=add" class="sidenavlink">Add a New Bug</a>
- </div>
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='query.php?op=query'">
- <a href="query.php?op=query" class="sidenavlink">Query Bugs</a>
- </div>
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='report.php'">
- <a href="report.php" class="sidenavlink">View Reports</a>
- </div>
- {if not NEW_ACCOUNTS_DISABLED and not $smarty.session.uid}
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='newaccount.php'">
- <a href="newaccount.php" class="sidenavlink">Create a new account</a>
- </div>
- {/if}
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='docs/html/userguide.html'">
- <a href="docs/html/userguide.html" class="sidenavlink">Read Documentation</a>
- </div>
- {if isset($perm) and $perm->have_perm('Administrator')}
- <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='admin/project.php'">
- <a href="admin/project.php" class="sidenavlink">Admin Tools</a>
- </div>
- {/if}
- </td>
- <td class="maincontent">
- {include file=$content_template}
- </td>
- </tr>
- <tr>
- <td width="150" height="30" class="sidenav">
-  
- </td>
- <td height="30" class="bottomnav">
- <form method="post" action="{$smarty.server.REQUEST_URI}">
-
- {if not $smarty.session.uid}
- {if EMAIL_IS_LOGIN}
- {assign var="loginlabel" value="Email"}
- {else}
- {assign var="loginlabel" value="Login"}
- {/if}
- {$loginerror}
- {$loginlabel}: <input type="text" name="username" class="bottomnavinput" value="{$smarty.cookies.phpbt_user}">
- Password: <input type="password" name="password" class="bottomnavinput">
- <input type="hidden" name="dologin" value="1">
- <input type="submit" value="Login" class="bottomnavinput">
- <input type="submit" name="sendpass" value="Email Password" class="bottomnavinput" title="Forgot your password? Have it sent to you">
- {if RECALL_LOGIN}
- <input type="checkbox" name="savecookie" value="1" {if !empty($smarty.cookies.phpbt_user)}checked{/if} class="bottomnavinput" title="Remember {$loginlabel} for next time"> Remember me
- {/if}
- {else}
- [ Bugs assigned to me: <a href="query.php?op=mybugs&assignedto=1&open=1" title="Open">{$owner_open}</a> / <a href="query.php?op=mybugs&assignedto=1&open=0" title="Closed">{$owner_closed}</a>
- | Bugs reported by me: <a href="query.php?op=mybugs&reportedby=1&open=1" title="Open">{$reporter_open}</a> / <a href="query.php?op=mybugs&reportedby=1&open=0" title="Closed">{$reporter_closed}</a>
- | <a href="user.php">Personal Page</a>
- | <a href="logout.php">Logout {$smarty.session.uname}</a>
- ]
- {/if}
-
- </form>
- </td>
- </tr>
- </table>
+ <table width="100%" cellspacing="0" cellpadding="0" height="100%">
+ <tr>
+ <td width="150" height="30" class="nav"> phpBugTracker</td>
+ <td height="30" class="nav" align="right"><form action="bug.php">
+ <input type="hidden" name="op" value="show">
+ {$STRING.WRAP.FindBug} <input type="text" name="bugid" size="4" class="navinput">
+
+ </form></td>
+ </tr><tr>
+ <td width="150" class="sidenav">
+ <!-- Nav Links -->
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='index.php'">
+ <a href="index.php" class="sidenavlink">{$STRING.WRAP.Home}</a>
+ </div>
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='bug.php?op=add'">
+ <a href="bug.php?op=add" class="sidenavlink">{$STRING.WRAP.AddNewBug}</a>
+ </div>
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='query.php?op=query'">
+ <a href="query.php?op=query" class="sidenavlink">{$STRING.WRAP.QueryBugs}</a>
+ </div>
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='report.php'">
+ <a href="report.php" class="sidenavlink">{$STRING.WRAP.ViewReports}</a>
+ </div>
+{if not NEW_ACCOUNTS_DISABLED and not $smarty.session.uid}
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='newaccount.php'">
+ <a href="newaccount.php" class="sidenavlink">{$STRING.WRAP.CreateNewAccount}</a>
+ </div>
+{/if}
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='docs/html/userguide.html'">
+ <a href="docs/html/userguide.html" class="sidenavlink">{$STRING.WRAP.Documentation}</a>
+ </div>
+{if isset($perm) and $perm->have_perm('Administrator')}
+ <div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='admin/project.php'">
+ <a href="admin/project.php" class="sidenavlink">{$STRING.WRAP.AdminTools}</a>
+ </div>
+{/if}
+ </td><td class="maincontent">{include file=$content_template}</td>
+ </tr><tr>
+ <td width="150" height="30" class="sidenav"> </td>
+ <td height="30" class="bottomnav">
+ <form method="post" action="{$smarty.server.REQUEST_URI}">
+
+{if not $smarty.session.uid}
+ {if EMAIL_IS_LOGIN}
+ {assign var="loginlabel" value="Email"}
+ {else}
+ {assign var="loginlabel" value="Login"}
+ {/if}
+ {$loginerror}
+ {$loginlabel}: <input type="text" name="username" class="bottomnavinput" value="{$smarty.cookies.phpbt_user}">
+ Password: <input type="password" name="password" class="bottomnavinput">
+ <input type="hidden" name="dologin" value="1">
+ <input type="submit" value="Login" class="bottomnavinput">
+ <input type="submit" name="sendpass" value="Email Password" class="bottomnavinput" title="Forgot your password? Have it sent to you">
+ {if RECALL_LOGIN}
+ <input type="checkbox" name="savecookie" value="1" {if !empty($smarty.cookies.phpbt_user)}checked{/if} class="bottomnavinput" title="Remember {$loginlabel} for next time"> Remember me
+ {/if}
+{else}
+ [ Bugs assigned to me: <a href="query.php?op=mybugs&assignedto=1&open=1" title="Open">{$owner_open}</a> / <a href="query.php?op=mybugs&assignedto=1&open=0" title="Closed">{$owner_closed}</a>
+ | Bugs reported by me: <a href="query.php?op=mybugs&reportedby=1&open=1" title="Open">{$reporter_open}</a> / <a href="query.php?op=mybugs&reportedby=1&open=0" title="Closed">{$reporter_closed}</a>
+ | <a href="user.php">Personal Page</a>
+ | <a href="logout.php">Logout {$smarty.session.uname}</a> ]
+{/if}
+
+ </form>
+ </td>
+ </tr>
+ </table>
</body>
</html>
-<head><meta HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE"></head>
|
|
From: Jirka P. <fi...@us...> - 2002-06-17 09:21:56
|
Update of /cvsroot/phpbt/phpbt/languages
In directory usw-pr-cvs1:/tmp/cvs-serv14929/phpbt/languages
Modified Files:
cz.php cz_iso-8859-2.php en.php
Log Message:
Switch to associative arrays for templates and some code cleanup.
Q: Is anyone testing files from CVS, except me and Ben? Please, let me know ...
Index: cz.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/languages/cz.php,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- cz.php 13 Jun 2002 14:26:36 -0000 1.12
+++ cz.php 17 Jun 2002 09:21:52 -0000 1.13
@@ -90,42 +90,54 @@
'addnewsite' => 'Pøidat nové prostøedí',
'sitelist' => 'Seznam prostøedí',
'sites' => 'Prostøedí',
- '_opt_All' => 'Ve',
- '_Project' => 'Projekt',
- '_Version' => 'Verze',
- '_Component' => 'Komponenta',
- '_Status' => 'Status',
- '_Resolution' => 'Rozhodnutí',
- '_OpSys' => 'Operaèní systém',
- '_Priority' => 'Priorita',
- '_Severity' => 'Dùleitost',
- '_Database' => 'Databáze',
- '_ReportedOnSite' => 'Prostøedí výskytu',
- '_Summary' => 'Shrnutí',
- '_DescriptionEntry' => 'Poloka popisu',
- '_SortBy' => 'Tøídit podle',
- '_SortBy_BugNumber' => 'Èísla BUGu',
- '_SortBy_Severity' => 'Dùleitosti',
- '_SortBy_Reporter' => 'Reportéra',
- '_SortBy_Priority' => 'Priority',
- '_SortBy_Status' => 'Statutu',
- '_SortAsc' => 'Vzestupnì',
- '_SortDesc' => 'Sestupnì',
- '_SaveThisQueryAs' => 'Uloit tento dotaz jako',
- '_ResetBackToDefaultQuery' => 'Zpìt k pùvodnímu dotazu',
- '_SubmitQuery' => 'Odeslat dotaz',
- '_SavedQueries' => 'Uloené dotazy',
- '_1GoToThe' => 'Pøejít na',
- '_1AdvancedQueryPage' => 'stránku pokroèilého vyhledávání',
- '_1SimpleQueryPage' => 'stránku jednoduchého vyhledávání',
- '_SureDeleteSavedQuery' => 'Jste si jisti, e chcete odstranit tento uloený dotaz?',
- '_MatchingAs' => 'odpovídá (vyhledat jako)',
- '_MatchingAs_Regexp' => 'regulárním výrazem',
- '_MatchingAs_NotRegexp' => 'není regulárním výrazem',
- '_MatchingAs_Substring' => 'podøetìzec',
- '_MatchingAs_Exact' => 'pøesnì',
- '_eMail_Reporter' => 'reportér',
- '_eMail_AssignedTo' => 'pøiøazeno',
+ 'QUERY' => array(
+ 'opt_All' => 'Ve',
+ 'Project' => 'Projekt',
+ 'Version' => 'Verze',
+ 'Component' => 'Komponenta',
+ 'Status' => 'Status',
+ 'Resolution' => 'Rozhodnutí',
+ 'OpSys' => 'Operaèní systém',
+ 'Priority' => 'Priorita',
+ 'Severity' => 'Dùleitost',
+ 'Database' => 'Databáze',
+ 'ReportedOnSite' => 'Prostøedí výskytu',
+ 'Summary' => 'Shrnutí',
+ 'DescriptionEntry' => 'Poloka popisu',
+ 'SortBy' => 'Tøídit podle',
+ 'SortBy_BugNumber' => 'Èísla BUGu',
+ 'SortBy_Severity' => 'Dùleitosti',
+ 'SortBy_Reporter' => 'Reportéra',
+ 'SortBy_Priority' => 'Priority',
+ 'SortBy_Status' => 'Statutu',
+ 'SortAsc' => 'Vzestupnì',
+ 'SortDesc' => 'Sestupnì',
+ 'SaveThisQueryAs' => 'Uloit tento dotaz jako',
+ 'ResetBackToDefaultQuery' => 'Zpìt k pùvodnímu dotazu',
+ 'SubmitQuery' => 'Odeslat dotaz',
+ 'SavedQueries' => 'Uloené dotazy',
+ 'GoToThe' => 'Pøejít na',
+ 'AdvancedQueryPage' => 'stránku pokroèilého vyhledávání',
+ 'SimpleQueryPage' => 'stránku jednoduchého vyhledávání',
+ 'SureDeleteSavedQuery' => 'Jste si jisti, e chcete odstranit tento uloený dotaz?',
+ 'MatchingAs' => 'odpovídá (vyhledat jako)',
+ 'MatchingAs_Regexp' => 'regulárním výrazem',
+ 'MatchingAs_NotRegexp' => 'není regulárním výrazem',
+ 'MatchingAs_Substring' => 'podøetìzec',
+ 'MatchingAs_Exact' => 'pøesnì',
+ 'eMail_Reporter' => 'reportér',
+ 'eMail_AssignedTo' => 'pøiøazeno'
+ ),
+ 'WRAP' => array(
+ 'FindBug' => 'Hledat BUG',
+ 'Home' => 'Domù',
+ 'AddNewBug' => 'Pøidat nový BUG',
+ 'QueryBugs' => 'Prohledávání',
+ 'ViewReports' => 'Hláení/Reporty',
+ 'Documentation' => 'Dokumentace',
+ 'AdminTools' => 'Administraèní nástroje',
+ 'CreateNewAccount' => 'Vytvoøit nový úèet'
+ )
);
// Page titles
@@ -176,8 +188,7 @@
'adddatabase' => 'Pøidat databázi',
'editdatabase' => 'Upravit databázi',
'database' => 'Databáze',
- 'site' => 'Prostøedí',
- 'documentation' => 'Dokumentace'
+ 'site' => 'Prostøedí'
);
?>
Index: cz_iso-8859-2.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/languages/cz_iso-8859-2.php,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- cz_iso-8859-2.php 13 Jun 2002 14:26:37 -0000 1.9
+++ cz_iso-8859-2.php 17 Jun 2002 09:21:52 -0000 1.10
@@ -90,42 +90,54 @@
'addnewsite' => 'Pøidat nové prostøedí',
'sitelist' => 'Seznam prostøedí',
'sites' => 'Prostøedí',
- '_opt_All' => 'V¹e',
- '_Project' => 'Projekt',
- '_Version' => 'Verze',
- '_Component' => 'Komponenta',
- '_Status' => 'Status',
- '_Resolution' => 'Rozhodnutí',
- '_OpSys' => 'Operaèní systém',
- '_Priority' => 'Priorita',
- '_Severity' => 'Dùle¾itost',
- '_Database' => 'Databáze',
- '_ReportedOnSite' => 'Prostøedí výskytu',
- '_Summary' => 'Shrnutí',
- '_DescriptionEntry' => 'Polo¾ka popisu',
- '_SortBy' => 'Tøídit podle',
- '_SortBy_BugNumber' => 'Èísla BUGu',
- '_SortBy_Severity' => 'Dùle¾itosti',
- '_SortBy_Reporter' => 'Reportéra',
- '_SortBy_Status' => 'Statutu',
- '_SortBy_Priority' => 'Priority',
- '_SortAsc' => 'Vzestupnì',
- '_SortDesc' => 'Sestupnì',
- '_SaveThisQueryAs' => 'Ulo¾t tento dotaz jako',
- '_ResetBackToDefaultQuery' => 'Zpìt k pùvodnímu dotazu',
- '_SubmitQuery' => 'Odeslat dotaz',
- '_SavedQueries' => 'Ulo¾ené dotazy',
- '_1GoToThe' => 'Pøejít na',
- '_1AdvancedQueryPage' => 'stránku pokroèilého vyhledávání',
- '_1SimpleQueryPage' => 'stránku jednoduchého vyhledávání',
- '_SureDeleteSavedQuery' => 'Jste si jisti, ¾e chcete smazat tento ulo¾ený dotaz?',
- '_MatchingAs' => 'odpovídá (vyhledat jako)',
- '_MatchingAs_Regexp' => 'regulárním výrazem',
- '_MatchingAs_NotRegexp' => 'není regulárním výrazem',
- '_MatchingAs_Substring' => 'podøetìzec',
- '_MatchingAs_Exact' => 'pøesnì',
- '_eMail_Reporter' => 'reportér',
- '_eMail_AssignedTo' => 'pøiøazeno'
+ 'QUERY' => array(
+ 'opt_All' => 'V¹e',
+ 'Project' => 'Projekt',
+ 'Version' => 'Verze',
+ 'Component' => 'Komponenta',
+ 'Status' => 'Status',
+ 'Resolution' => 'Rozhodnutí',
+ 'OpSys' => 'Operaèní systém',
+ 'Priority' => 'Priorita',
+ 'Severity' => 'Dùle¾itost',
+ 'Database' => 'Databáze',
+ 'ReportedOnSite' => 'Prostøedí výskytu',
+ 'Summary' => 'Shrnutí',
+ 'DescriptionEntry' => 'Polo¾ka popisu',
+ 'SortBy' => 'Tøídit podle',
+ 'SortBy_BugNumber' => 'Èísla BUGu',
+ 'SortBy_Severity' => 'Dùle¾itosti',
+ 'SortBy_Reporter' => 'Reportéra',
+ 'SortBy_Priority' => 'Priority',
+ 'SortBy_Status' => 'Statutu',
+ 'SortAsc' => 'Vzestupnì',
+ 'SortDesc' => 'Sestupnì',
+ 'SaveThisQueryAs' => 'Ulo¾it tento dotaz jako',
+ 'ResetBackToDefaultQuery' => 'Zpìt k pùvodnímu dotazu',
+ 'SubmitQuery' => 'Odeslat dotaz',
+ 'SavedQueries' => 'Ulo¾ené dotazy',
+ 'GoToThe' => 'Pøejít na',
+ 'AdvancedQueryPage' => 'stránku pokroèilého vyhledávání',
+ 'SimpleQueryPage' => 'stránku jednoduchého vyhledávání',
+ 'SureDeleteSavedQuery' => 'Jste si jisti, ¾e chcete odstranit tento ulo¾ený dotaz?',
+ 'MatchingAs' => 'odpovídá (vyhledat jako)',
+ 'MatchingAs_Regexp' => 'regulárním výrazem',
+ 'MatchingAs_NotRegexp' => 'není regulárním výrazem',
+ 'MatchingAs_Substring' => 'podøetìzec',
+ 'MatchingAs_Exact' => 'pøesnì',
+ 'eMail_Reporter' => 'reportér',
+ 'eMail_AssignedTo' => 'pøiøazeno'
+ ),
+ 'WRAP' => array(
+ 'FindBug' => 'Hledat BUG',
+ 'Home' => 'Domù',
+ 'AddNewBug' => 'Pøidat nový BUG',
+ 'QueryBugs' => 'Prohledávání',
+ 'ViewReports' => 'Hlá¹ení/Reporty',
+ 'Documentation' => 'Dokumentace',
+ 'AdminTools' => 'Administraèní nástroje',
+ 'CreateNewAccount' => 'Vytvoøit nový úèet'
+ )
);
// Page titles
@@ -176,7 +188,7 @@
'adddatabase' => 'Pøidat databázi',
'editdatabase' => 'Upravit databázi',
'database' => 'Databáze',
- 'documentation' => 'Dokumentace',
'site' => 'Prostøedí'
);
?>
+
Index: en.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/languages/en.php,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- en.php 13 Jun 2002 14:26:37 -0000 1.21
+++ en.php 17 Jun 2002 09:21:52 -0000 1.22
@@ -90,42 +90,54 @@
'addnewsite' => 'Add new Site',
'sitelist' => 'Site list',
'sites' => 'Sites',
- '_opt_All' => 'All',
- '_Project' => 'Project',
- '_Version' => 'Version',
- '_Component' => 'Component',
- '_Status' => 'Status',
- '_Resolution' => 'Resolution',
- '_OpSys' => 'OpSys',
- '_Priority' => 'Priority',
- '_Severity' => 'Severity',
- '_Database' => 'Database',
- '_ReportedOnSite' => 'Reported on Site',
- '_Summary' => 'Summary',
- '_DescriptionEntry' => 'A description entry',
- '_SortBy' => 'Sort By',
- '_SortBy_BugNumber' => 'Bug Number',
- '_SortBy_Severity' => 'Severity',
- '_SortBy_Reporter' => 'Reporter',
- '_SortBy_Priority' => 'Priority',
- '_SortBy_Status' => 'Status',
- '_SortAsc' => 'Ascending',
- '_SortDesc' => 'Descending',
- '_SaveThisQueryAs' => 'Save this query as',
- '_ResetBackToDefaultQuery' => 'Reset back to default query',
- '_SubmitQuery' => 'Submit query',
- '_SavedQueries' => 'Saved Queries',
- '_1GoToThe' => 'Go to the',
- '_1AdvancedQueryPage' => 'advanced query page',
- '_1SimpleQueryPage' => 'simple query page',
- '_SureDeleteSavedQuery' => 'Are you sure to delete this saved query?',
- '_MatchingAs' => 'matching as',
- '_MatchingAs_Regexp' => 'regexp',
- '_MatchingAs_NotRegexp' => 'not regexp',
- '_MatchingAs_Substring' => 'substring',
- '_MatchingAs_Exact' => 'exact',
- '_eMail_Reporter' => 'Reporter',
- '_eMail_AssignedTo' => 'Assigned To'
+ 'QUERY' => array(
+ 'opt_All' => 'All',
+ 'Project' => 'Project',
+ 'Version' => 'Version',
+ 'Component' => 'Component',
+ 'Status' => 'Status',
+ 'Resolution' => 'Resolution',
+ 'OpSys' => 'OpSys',
+ 'Priority' => 'Priority',
+ 'Severity' => 'Severity',
+ 'Database' => 'Database',
+ 'ReportedOnSite' => 'Reported on Site',
+ 'Summary' => 'Summary',
+ 'DescriptionEntry' => 'A description entry',
+ 'SortBy' => 'Sort By',
+ 'SortBy_BugNumber' => 'Bug Number',
+ 'SortBy_Severity' => 'Severity',
+ 'SortBy_Reporter' => 'Reporter',
+ 'SortBy_Priority' => 'Priority',
+ 'SortBy_Status' => 'Status',
+ 'SortAsc' => 'Ascending',
+ 'SortDesc' => 'Descending',
+ 'SaveThisQueryAs' => 'Save this query as',
+ 'ResetBackToDefaultQuery' => 'Reset back to default query',
+ 'SubmitQuery' => 'Submit query',
+ 'SavedQueries' => 'Saved Queries',
+ 'GoToThe' => 'Go to the',
+ 'AdvancedQueryPage' => 'advanced query page',
+ 'SimpleQueryPage' => 'simple query page',
+ 'SureDeleteSavedQuery' => 'Are you sure to delete this saved query?',
+ 'MatchingAs' => 'matching as',
+ 'MatchingAs_Regexp' => 'regexp',
+ 'MatchingAs_NotRegexp' => 'not regexp',
+ 'MatchingAs_Substring' => 'substring',
+ 'MatchingAs_Exact' => 'exact',
+ 'eMail_Reporter' => 'Reporter',
+ 'eMail_AssignedTo' => 'Assigned To'
+ ),
+ 'WRAP' => array(
+ 'FindBug' => 'Find Bug',
+ 'Home' => 'Home',
+ 'AddNewBug' => 'Add a new Bug',
+ 'QueryBugs' => 'Query Bugs',
+ 'ViewReports' => 'View Reports',
+ 'Documentation' => 'Read Documentation',
+ 'AdminTools' => 'Admin Tools',
+ 'CreateNewAccount' => 'Create a new Account'
+ )
);
// Page titles
@@ -180,3 +192,4 @@
'documentation' => 'Read documentation'
);
?>
+
|
|
From: Jirka P. <fi...@us...> - 2002-06-17 09:21:56
|
Update of /cvsroot/phpbt/phpbt/templates/default/admin
In directory usw-pr-cvs1:/tmp/cvs-serv14929/phpbt/templates/default/admin
Modified Files:
wrap.html
Log Message:
Switch to associative arrays for templates and some code cleanup.
Q: Is anyone testing files from CVS, except me and Ben? Please, let me know ...
Index: wrap.html
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/wrap.html,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- wrap.html 13 Jun 2002 14:26:40 -0000 1.14
+++ wrap.html 17 Jun 2002 09:21:53 -0000 1.15
@@ -53,7 +53,7 @@
<a href="site.php" class="sidenavlink">{$TITLE.site}</a>
</div>
<div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='../docs/html/userguide.html'">
- <a href="../docs/html/userguide.html" class="sidenavlink">{$TITLE.documentation}</a>
+ <a href="../docs/html/userguide.html" class="sidenavlink">{$STRING.WRAP.Documentation}</a>
</div>
<div class="navbox" onMouseOver="this.className='navboxselected'" onMouseOut="this.className='navbox'" onClick="document.location.href='../index.php'">
<a href="../index.php" class="sidenavlink">{$TITLE.usertools}</a>
|
|
From: Jirka P. <fi...@us...> - 2002-06-14 15:30:49
|
Update of /cvsroot/phpbt/phpbt/schemas In directory usw-pr-cvs1:/tmp/cvs-serv29455/phpbt/schemas Modified Files: mysql.in oci8.in pgsql.in Log Message: Fixed short 'changed field' and char -> varchar. Index: mysql.in =================================================================== RCS file: /cvsroot/phpbt/phpbt/schemas/mysql.in,v retrieving revision 1.30 retrieving revision 1.31 diff -u -r1.30 -r1.31 --- mysql.in 13 Jun 2002 11:29:39 -0000 1.30 +++ mysql.in 14 Jun 2002 15:30:45 -0000 1.31 @@ -103,9 +103,9 @@ CREATE TABLE TBL_BUG_HISTORY ( bug_id int(10) unsigned NOT NULL default '0', - changed_field char(20) NOT NULL default '', - old_value char(255) NOT NULL default '', - new_value char(255) NOT NULL default '', + changed_field varchar(30) NOT NULL default '', + old_value varchar(255) NOT NULL default '', + new_value varchar(255) NOT NULL default '', created_by int(10) unsigned NOT NULL default '0', created_date bigint(20) unsigned NOT NULL default '0' ) TYPE=MyISAM; Index: oci8.in =================================================================== RCS file: /cvsroot/phpbt/phpbt/schemas/oci8.in,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- oci8.in 13 Jun 2002 11:29:39 -0000 1.14 +++ oci8.in 14 Jun 2002 15:30:45 -0000 1.15 @@ -104,7 +104,7 @@ CREATE TABLE TBL_BUG_HISTORY ( bug_id number(10) default '0' NOT NULL, - changed_field varchar2(20) default '' NOT NULL, + changed_field varchar2(30) default '' NOT NULL, old_value varchar2(255) default '' NOT NULL, new_value varchar2(255) default '' NOT NULL, created_by number(10) default '0' NOT NULL, Index: pgsql.in =================================================================== RCS file: /cvsroot/phpbt/phpbt/schemas/pgsql.in,v retrieving revision 1.31 retrieving revision 1.32 diff -u -r1.31 -r1.32 --- pgsql.in 13 Jun 2002 11:29:39 -0000 1.31 +++ pgsql.in 14 Jun 2002 15:30:45 -0000 1.32 @@ -105,7 +105,7 @@ CREATE TABLE TBL_BUG_HISTORY ( bug_id INT4 NOT NULL DEFAULT '0', - changed_field varchar(20) NOT NULL DEFAULT '', + changed_field varchar(30) NOT NULL DEFAULT '', old_value varchar(255) NOT NULL DEFAULT '', new_value varchar(255) NOT NULL DEFAULT '', created_by INT4 NOT NULL DEFAULT '0', |
|
From: Jirka P. <fi...@us...> - 2002-06-14 15:26:09
|
Update of /cvsroot/phpbt/phpbt
In directory usw-pr-cvs1:/tmp/cvs-serv27194/phpbt
Modified Files:
bug.php query.php
Log Message:
Some fixes and adding of 'closed' and 'to be closed' 'in version'. Someone is wanted to review bugemail.txt and change the second mail template.
Index: bug.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/bug.php,v
retrieving revision 1.109
retrieving revision 1.110
diff -u -r1.109 -r1.110
--- bug.php 13 Jun 2002 16:03:29 -0000 1.109
+++ bug.php 14 Jun 2002 15:26:05 -0000 1.110
@@ -159,16 +159,69 @@
);
foreach($cfgDatabase as $field => $table) {
- $oldvalue = $db->getOne("select ${field}_name from $table".
- " where ${field}_id = {$buginfo[$field.'_id']}");
+ switch ($field) {
+ case 'database':
+ if ($buginfo[$field.'_id']) {
+ $db_oldvalue = $db->getRow('select '.$field.'_name, '.$field.'_version from '.$table.
+ ' where '.$field.'_id = '.$buginfo[$field.'_id']);
+ $oldvalue = $db_oldvalue[$field.'_name'].' '.$db_oldvalue[$field.'_version'];
+ } else {
+ $oldvalue = 'None';
+ }
+
+ if (!empty($cf[$field.'_id'])) {
+ $db_newvalue = $db->getRow('select '.$field.'_name, '.$field.'_version from '.$table.
+ ' where '.$field.'_id = '.$cf[$field.'_id']);
+ $newvalue = $db_newvalue[$field.'_name'].' '.$db_newvalue[$field.'_version'];
+ } else {
+ $newvalue = 'None';
+ }
+ break;
+ default:
+ $oldvalue = $db->getOne("select ${field}_name from $table".
+ " where ${field}_id = {$buginfo[$field.'_id']}");
+ if (!empty($cf[$field.'_id'])) {
+ $newvalue = $db->getOne("select ${field}_name from $table".
+ " where ${field}_id = {$cf[$field.'_id']}");
+ }
+ break;
+ }
+ if (!empty($cf[$field.'_id'])) {
+ $db->query('insert into '.TBL_BUG_HISTORY.
+ ' (bug_id, changed_field, old_value, new_value, created_by, created_date)'.
+ " values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
+ $db->quote(stripslashes($oldvalue)),
+ $db->quote(stripslashes($newvalue)), $u, $now)).")");
+ $t->assign(array(
+ $field.'_id' => stripslashes($newvalue),
+ $field.'_id_stat' => '!'
+ ));
+ } else {
+ $t->assign(array(
+ $field.'_id' => stripslashes($oldvalue),
+ $field.'_id_stat' => ' '
+ ));
+ }
+ }
+
+ // Handle versions other than version
+ $versions = array ('to_be_closed_in_version' => 'to be closed in version',
+ 'closed_in_version' => 'closed in version');
+
+ foreach($versions as $field => $field_name) {
+ if ($buginfo[$field.'_id']) {
+ $oldvalue = $db->getOne('select version_name from '.$cfgDatabase['version'].
+ ' where version_id = '.$buginfo[$field.'_id']);
+ }
+
if (!empty($cf[$field.'_id'])) {
- $newvalue = $db->getOne("select ${field}_name from $table".
- " where ${field}_id = {$cf[$field.'_id']}");
+ $newvalue = $db->getOne('select version_name from '.$cfgDatabase['version'].
+ ' where version_id = '.$cf[$field.'_id']);
$db->query('insert into '.TBL_BUG_HISTORY.
' (bug_id, changed_field, old_value, new_value, created_by, created_date)'.
- " values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
- $db->quote(stripslashes($oldvalue)),
- $db->quote(stripslashes($newvalue)), $u, $now)).")");
+ " values (". join(', ', array($buginfo['bug_id'], $db->quote($field_name),
+ $db->quote(stripslashes($oldvalue)),
+ $db->quote(stripslashes($newvalue)), $u, $now)).")");
$t->assign(array(
$field.'_id' => stripslashes($newvalue),
$field.'_id_stat' => '!'
@@ -181,7 +234,7 @@
}
}
- // Reporter never changes;
+ // Reporter never changes
$reporter = $db->getOne('select email from '.TBL_AUTH_USER.
" u, ".TBL_USER_PREF." p where u.user_id = {$buginfo['created_by']} ".
"and u.user_id = p.user_id and email_notices = 1");
Index: query.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/query.php,v
retrieving revision 1.80
retrieving revision 1.81
diff -u -r1.80 -r1.81
--- query.php 13 Jun 2002 15:07:10 -0000 1.80
+++ query.php 14 Jun 2002 15:26:05 -0000 1.81
@@ -90,7 +90,8 @@
if (!empty($severity) and $severity[0]) {
$flags[] = 'b.severity_id in ('.delimit_list(',',$severity).')';
}
- if (!empty($database) and $database[0]) {
+ if (!empty($database) and isset($database[0])) {
+ // $database[0] can be 0, which stands for no database reported
$flags[] = 'b.database_id in ('.delimit_list(',',$database).')';
}
if (!empty($site) and $site[0]) {
|
|
From: Jirka P. <fi...@us...> - 2002-06-14 15:26:09
|
Update of /cvsroot/phpbt/phpbt/templates/default
In directory usw-pr-cvs1:/tmp/cvs-serv27194/phpbt/templates/default
Modified Files:
bugemail.txt
Log Message:
Some fixes and adding of 'closed' and 'to be closed' 'in version'. Someone is wanted to review bugemail.txt and change the second mail template.
Index: bugemail.txt
===================================================================
RCS file: /cvsroot/phpbt/phpbt/templates/default/bugemail.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- bugemail.txt 6 Apr 2002 23:47:59 -0000 1.4
+++ bugemail.txt 14 Jun 2002 15:26:06 -0000 1.5
@@ -10,11 +10,15 @@
{$url_stat} URL: {$url}
{$project_id_stat} Product: {$project_id}
{$version_id_stat} Version: {$version_id}
+{$to_be_closed_in_version_id_stat} To be Closed in Version: {$to_be_closed_in_version_id}
+{$closed_in_version_id_stat} Closed in Version: {$closed_in_version_id}
{$component_id_stat} Component: {$component_id}
+{$site_id_stat} Site(s): {$site_id}
{$status_id_stat} Status: {$status_id}
{$resolution_id_stat} Resolution: {$resolution_id}
{$severity_id_stat} Severity: {$severity_id}
{$os_id_stat} OS/Version: {$os_id}
+{$database_id_stat} Database: {$database_id}
{$priority_stat} Priority: {$priority}
{$assignedto_stat} Assigned To: {$assignedto}
============================================================================
|
|
From: Jirka P. <fi...@us...> - 2002-06-14 13:42:42
|
> Yup, it is good to get this out of the way before 1.0. :) Some editors > have a nice 'entab' feature which will smartly replace leading spaces > with tabs to clean up the indentation. I don't know one off-hand for > linux, though, otherwise I would have already gone through the files and > changed them. > > So, just to be clear.... > leading spaces =3D=3D bad > leading tabs =3D=3D good Unfortunately, it's not only in replacing spaces with tabs, it have to be d= one by a thinking one (a human if possible) not the machine only, because s= imply replacing spaces with tabs will produce worse looking code than it lo= okedd before. We both are strictly using tabs. Others can do so. And we both can start wi= th smoothly replacing. But there is no goal to do it now, OK? Let's say we = will clean it up before 1.0. |
|
From: Ben C. <php...@be...> - 2002-06-14 13:13:10
|
I love it when other people clean up after me. :) On Fri, Jun 14, 2002 at 12:59:40PM -0000, Jirka Pech wrote: > > One reason to have it changeable by the user is because sometimes the > > closed version changes after it has been set! :) A bug may get reopened > > and then have to be reclosed, potentially on a different version of a > > product. > > Yes, I understand. But know this e-mail from CVS is obsoleted, because I've changed it bugdisplay.html for closed_in_version and so ... you know, it's not buggy now. > |
|
From: Ben C. <php...@be...> - 2002-06-14 13:12:48
|
Ok, sounds good. Then we'll just switch these over as we get around to it. On Fri, Jun 14, 2002 at 01:05:13PM -0000, Jirka Pech wrote: > > Well, I know script language="..." is supported in all browsers. Is > > script type="..." widely supported? > > Yes, it is. I'm using it for a very long time (say from HTML4.0 was proposed by W3C as a standart) and I've never heard it's not supported. > But we can leave 'language' where it is (because it is supported same as 'type', but only isn't a standart) and when I will (or you or somebody else will) change some script where it is used, I will (or you or somebody can) then replace it with type, OK? > I think it's not necessary to replace it all now. > > > On Thu, Jun 13, 2002 at 02:23:43AM -0700, Jirka Pech wrote: > >> Update of /cvsroot/phpbt/phpbt/templates/default > >> In directory usw-pr-cvs1:/tmp/cvs-serv12398/phpbt/templates/default > >> > >> Modified Files: > >> queryform-simple.html queryform.html > >> Log Message: > >> Added some JavaScript (BTW: there is no 'language' attribute in standart, but 'type' only), some localization. > > P.S.: There is a bug 561074, which is Opera related. I haven't Opera installed, so it's for you or somebody else. > |
|
From: Ben C. <php...@be...> - 2002-06-14 13:11:29
|
Yup, it is good to get this out of the way before 1.0. :) Some editors have a nice 'entab' feature which will smartly replace leading spaces with tabs to clean up the indentation. I don't know one off-hand for linux, though, otherwise I would have already gone through the files and changed them. So, just to be clear.... leading spaces == bad leading tabs == good :) BTW, Jirka, I moved the localization thread to the localization list and subscribed you to it. Let me know if you don't see my response to your message about the underscores and long $STRING array. On Fri, Jun 14, 2002 at 12:56:11PM -0000, Jirka Pech wrote: > > Please remember that we are using tabs for indenting rather than spaces. > > It's hard to track changes when half the file changes only because > > spaces are replacing tabs. > > I've replaced spaces with tabs, because I thought that it's code we like, not tabs with spaces, because you told me before that we don't like spaces. I undertand that many lines changed, but it's good to be done before 1.0. So I started with it and I'm changing every function, I'm doing changes into, in the same way. Replacing spaces with tabs. OK? > > _______________________________________________________________ > > Don't miss the 2002 Sprint PCS Application Developer's Conference > August 25-28 in Las Vegas - http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink > > _______________________________________________ > phpbt-dev mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/phpbt-dev |
|
From: Jirka P. <fi...@us...> - 2002-06-14 13:05:19
|
> Well, I know script language=3D"..." is supported in all browsers. Is > script type=3D"..." widely supported? Yes, it is. I'm using it for a very long time (say from HTML4.0 was propo= sed by W3C as a standart) and I've never heard it's not supported. But we can leave 'language' where it is (because it is supported same as = 'type', but only isn't a standart) and when I will (or you or somebody else= will) change some script where it is used, I will (or you or somebody can)= then replace it with type, OK? I think it's not necessary to replace it all now. > On Thu, Jun 13, 2002 at 02:23:43AM -0700, Jirka Pech wrote: >> Update of /cvsroot/phpbt/phpbt/templates/default >> In directory usw-pr-cvs1:/tmp/cvs-serv12398/phpbt/templates/default >> >> Modified Files: >> =09queryform-simple.html queryform.html >> Log Message: >> Added some JavaScript (BTW: there is no 'language' attribute in standart= , but 'type' only), some localization. P.S.: There is a bug 561074, which is Opera related. I haven't Opera instal= led, so it's for you or somebody else. |
|
From: Jirka P. <fi...@us...> - 2002-06-14 12:59:46
|
> One reason to have it changeable by the user is because sometimes the > closed version changes after it has been set! :) A bug may get reopened > and then have to be reclosed, potentially on a different version of a > product. Yes, I understand. But know this e-mail from CVS is obsoleted, because I've= changed it bugdisplay.html for closed_in_version and so ... you know, it's= not buggy now. |
|
From: Jirka P. <fi...@us...> - 2002-06-14 12:56:17
|
> Please remember that we are using tabs for indenting rather than spaces. > It's hard to track changes when half the file changes only because > spaces are replacing tabs. I've replaced spaces with tabs, because I thought that it's code we like, n= ot tabs with spaces, because you told me before that we don't like spaces. = I undertand that many lines changed, but it's good to be done before 1.0. S= o I started with it and I'm changing every function, I'm doing changes into= , in the same way. Replacing spaces with tabs. OK? |
|
From: Ben C. <php...@be...> - 2002-06-14 12:43:51
|
Well, I know script language="..." is supported in all browsers. Is
script type="..." widely supported?
On Thu, Jun 13, 2002 at 02:23:43AM -0700, Jirka Pech wrote:
> Update of /cvsroot/phpbt/phpbt/templates/default
> In directory usw-pr-cvs1:/tmp/cvs-serv12398/phpbt/templates/default
>
> Modified Files:
> queryform-simple.html queryform.html
> Log Message:
> Added some JavaScript (BTW: there is no 'language' attribute in standart, but 'type' only), some localization.
>
>
> Index: queryform-simple.html
> ===================================================================
> RCS file: /cvsroot/phpbt/phpbt/templates/default/queryform-simple.html,v
> retrieving revision 1.6
> retrieving revision 1.7
> diff -u -r1.6 -r1.7
> --- queryform-simple.html 8 Jun 2002 20:28:52 -0000 1.6
> +++ queryform-simple.html 13 Jun 2002 09:23:40 -0000 1.7
> @@ -1,9 +1,11 @@
> -<script language="JavaScript">
> +<script type="text/JavaScript">
> <!--
> versions = new Array();
> components = new Array();
> +closedversions = new Array();
> versions['All'] = new Array(new Array('','All'));
> components['All'] = new Array(new Array('','All'));
> +closedversions['All'] = new Array(new Array('','All'));
> {project_js}
>
> {literal}
> @@ -25,56 +27,56 @@
> </script>
> <form method="get" action="query.php" name="query">
> <table>
|
|
From: Ben C. <php...@be...> - 2002-06-14 12:42:40
|
One reason to have it changeable by the user is because sometimes the closed version changes after it has been set! :) A bug may get reopened and then have to be reclosed, potentially on a different version of a product. On Wed, Jun 12, 2002 at 01:01:25PM -0000, Jirka Pech wrote: > > Update of /cvsroot/phpbt/phpbt/templates/default > > In directory usw-pr-cvs1:/tmp/cvs-serv8094/templates/default > > > > Modified Files: > > bugdisplay.html > > Log Message: > > Updated for closed_version and to_be_closed_version. May be a little buggy -- needs testing > > > > Mhmm ... there may be something wrong. I've tested it (from scratch) and everything goes OK, except Closed in Version, which doesn't change. Maybe there is other script, which have to be changed. I can't remember exactly what I've changed when I was adding to be closed in version and database tracking. > > I thought "Closed in Version" will be added automatically, when closing a bug. It's good to have it changeable by hand, but not necessary. What do you think about it? > > BTW: Design is good. > > _______________________________________________________________ > > Sponsored by: > ThinkGeek at http://www.ThinkGeek.com/ > _______________________________________________ > phpbt-dev mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/phpbt-dev |
|
From: Ben C. <php...@be...> - 2002-06-14 12:36:16
|
Please remember that we are using tabs for indenting rather than spaces.
It's hard to track changes when half the file changes only because
spaces are replacing tabs.
On Thu, Jun 13, 2002 at 09:03:32AM -0700, Jirka Pech wrote:
> Update of /cvsroot/phpbt/phpbt
> In directory usw-pr-cvs1:/tmp/cvs-serv16459/phpbt
>
> Modified Files:
> bug.php
> Log Message:
> Did some dirty work on code cleanup. Next change have to be changed fields notify for (to_be_)closed_in_version_id, database_id and then site_id when modified bugdisplay template and bug.php again.
> Going home for today.
>
>
> Index: bug.php
> ===================================================================
> RCS file: /cvsroot/phpbt/phpbt/bug.php,v
> retrieving revision 1.108
> retrieving revision 1.109
> diff -u -r1.108 -r1.109
> --- bug.php 13 Jun 2002 15:20:21 -0000 1.108
> +++ bug.php 13 Jun 2002 16:03:29 -0000 1.109
> @@ -119,271 +119,281 @@
> ///
> /// Send the email about changes to the bug and log the changes in the DB
> function do_changedfields($userid, &$buginfo, $cf = array(), $comments = '') {
> - global $db, $t, $u, $select, $now, $STRING, $QUERY;
> + global $db, $t, $u, $select, $now, $STRING, $QUERY;
>
> - // It's a new bug if the changedfields array is empty and there are no comments
> - $newbug = (!count($cf) and !$comments);
> + // It's a new bug if the changedfields array is empty and there are no comments
> + $newbug = (!count($cf) and !$comments);
>
> - $template = $newbug ? 'bugemail-newbug.txt' : 'bugemail.txt';
> - foreach(array('title','url') as $field) {
> - if (isset($cf[$field])) {
> - $db->query('insert into '.TBL_BUG_HISTORY
> - .' (bug_id, changed_field, old_value, new_value, created_by, created_date)'
> - ." values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
> - $db->quote(stripslashes($buginfo[$field])),
> - $db->quote(stripslashes($cf[$field])), $u, $now)).")");
> - $t->assign(array(
> - $field => stripslashes($cf[$field]),
> - $field.'_stat' => '!'
> - ));
> - } else {
> - $t->assign(array(
> - $field => stripslashes($buginfo[$field]),
> - $field.'_stat' => ' '
> - ));
> - }
> - }
> -
> - // create array with tablenames for following loop
> - $cfgDatabase = array(
> - 'project' => TBL_PROJECT,
> - 'component' => TBL_COMPONENT,
> - 'status' => TBL_STATUS,
> - 'resolution' => TBL_RESOLUTION,
> - 'database' => TBL_DATABASE,
> - 'severity' => TBL_SEVERITY,
> - 'os' => TBL_OS,
> - 'version' => TBL_VERSION
> - );
> -
> - foreach($cfgDatabase as $field => $table) {
> - $oldvalue = $db->getOne("select ${field}_name from $table"
> - ." where ${field}_id = {$buginfo[$field.'_id']}");
> - if (!empty($cf[$field.'_id'])) {
> - $newvalue = $db->getOne("select ${field}_name from $table"
> - ." where ${field}_id = {$cf[$field.'_id']}");
> - $db->query('insert into '.TBL_BUG_HISTORY
> - .' (bug_id, changed_field, old_value, new_value, created_by, created_date)'
> - ." values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
> - $db->quote(stripslashes($oldvalue)),
> - $db->quote(stripslashes($newvalue)), $u, $now)).")");
> - $t->assign(array(
> - $field.'_id' => stripslashes($newvalue),
> - $field.'_id_stat' => '!'
> - ));
> - } else {
> - $t->assign(array(
> - $field.'_id' => stripslashes($oldvalue),
> - $field.'_id_stat' => ' '
> - ));
> - }
> - }
> -
> - // Reporter never changes;
> - $reporter = $db->getOne('select email from '.TBL_AUTH_USER
> - ." u, ".TBL_USER_PREF." p where u.user_id = {$buginfo['created_by']} ".
> - "and u.user_id = p.user_id and email_notices = 1");
> - $reporterstat = ' ';
> - $assignedto = $db->getOne('select email from '.TBL_AUTH_USER." u, ".
> - TBL_USER_PREF.' p where u.user_id = '
> - .(!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to']).
> - " and u.user_id = p.user_id and email_notices = 1");
> - $assignedtostat = !empty($cf['assigned_to']) ? '!' : ' ';
> -
> - // If there are new comments grab the comments immediately before the latest
> - if ($comments or $newbug) {
> - $rs = $db->limitQuery('select u.login, c.comment_text, c.created_date'
> - .' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER.' u'
> - ." where bug_id = {$buginfo['bug_id']} and c.created_by = u.user_id"
> - .' order by created_date desc', 0, 2);
> - $rs->fetchInto($row);
> - $t->assign(array(
> - 'newpostedby' => $row['login'],
> - 'newpostedon' => date(TIME_FORMAT, $row['created_date']).' on '.
> - date(DATE_FORMAT, $row['created_date']),
> - 'newcomments' => textwrap('+ '.format_comments($row['comment_text']),72,"\n+ ")
> - ));
> - // If this comment is the first additional comment after the creation of the
> - // bug then we need to grab the bug's description as the previous comment
> - if ($rs->numRows() < 2) {
> - list($by, $on, $comments) = $db->getRow('select u.login, b.created_date, b.description'
> - .' from '.TBL_BUG.' b, '.TBL_AUTH_USER.' u'
> - ." where b.created_by = u.user_id and bug_id = {$buginfo['bug_id']}",
> - null, DB_FETCHMODE_ORDERED);
> - $t->assign(array(
> - 'oldpostedby' => $by,
> - 'oldpostedon' => date(TIME_FORMAT,$on).' on '.date(DATE_FORMAT,$on),
> - 'oldcomments' => textwrap(format_comments($comments),72)
> - ));
> + $template = $newbug ? 'bugemail-newbug.txt' : 'bugemail.txt';
> + foreach(array('title','url') as $field) {
> + if (isset($cf[$field])) {
> + $db->query('insert into '.TBL_BUG_HISTORY.
> + ' (bug_id, changed_field, old_value, new_value, created_by, created_date)'.
> + " values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
> + $db->quote(stripslashes($buginfo[$field])),
> + $db->quote(stripslashes($cf[$field])), $u, $now)).")");
> + $t->assign(array(
> + $field => stripslashes($cf[$field]),
> + $field.'_stat' => '!'
> + ));
> + } else {
> + $t->assign(array(
> + $field => stripslashes($buginfo[$field]),
> + $field.'_stat' => ' '
> + ));
> + }
> + }
> +
> + // create array with tablenames for following loop
> + $cfgDatabase = array(
> + 'project' => TBL_PROJECT,
> + 'component' => TBL_COMPONENT,
> + 'status' => TBL_STATUS,
> + 'resolution' => TBL_RESOLUTION,
> + 'database' => TBL_DATABASE,
> + 'severity' => TBL_SEVERITY,
> + 'os' => TBL_OS,
> + 'version' => TBL_VERSION,
> + 'database' => TBL_DATABASE,
> + 'site' => TBL_SITE
> + );
> +
> + foreach($cfgDatabase as $field => $table) {
> + $oldvalue = $db->getOne("select ${field}_name from $table".
> + " where ${field}_id = {$buginfo[$field.'_id']}");
> + if (!empty($cf[$field.'_id'])) {
> + $newvalue = $db->getOne("select ${field}_name from $table".
> + " where ${field}_id = {$cf[$field.'_id']}");
> + $db->query('insert into '.TBL_BUG_HISTORY.
> + ' (bug_id, changed_field, old_value, new_value, created_by, created_date)'.
> + " values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
> + $db->quote(stripslashes($oldvalue)),
> + $db->quote(stripslashes($newvalue)), $u, $now)).")");
> + $t->assign(array(
> + $field.'_id' => stripslashes($newvalue),
> + $field.'_id_stat' => '!'
> + ));
> + } else {
> + $t->assign(array(
> + $field.'_id' => stripslashes($oldvalue),
> + $field.'_id_stat' => ' '
> + ));
> + }
> + }
> +
> + // Reporter never changes;
> + $reporter = $db->getOne('select email from '.TBL_AUTH_USER.
> + " u, ".TBL_USER_PREF." p where u.user_id = {$buginfo['created_by']} ".
> + "and u.user_id = p.user_id and email_notices = 1");
> + $reporterstat = ' ';
> + $assignedto = $db->getOne('select email from '.TBL_AUTH_USER." u, ".
> + TBL_USER_PREF.' p where u.user_id = '.
> + (!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to']).
> + " and u.user_id = p.user_id and email_notices = 1");
> + $assignedtostat = !empty($cf['assigned_to']) ? '!' : ' ';
> +
> + // If there are new comments grab the comments immediately before the latest
> + if ($comments or $newbug) {
> + $rs = $db->limitQuery('select u.login, c.comment_text, c.created_date'.
> + ' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER.' u'.
> + " where bug_id = {$buginfo['bug_id']} and c.created_by = u.user_id".
> + ' order by created_date desc', 0, 2);
> + $rs->fetchInto($row);
> + $t->assign(array(
> + 'newpostedby' => $row['login'],
> + 'newpostedon' => date(TIME_FORMAT, $row['created_date']).' on '.
> + date(DATE_FORMAT, $row['created_date']),
> + 'newcomments' => textwrap('+ '.format_comments($row['comment_text']),72,"\n+ ")
> + ));
> +
> + // If this comment is the first additional comment after the creation of the
> + // bug then we need to grab the bug's description as the previous comment
> + if ($rs->numRows() < 2) {
> + list($by, $on, $comments) = $db->getRow('select u.login, b.created_date, b.description'.
> + ' from '.TBL_BUG.' b, '.TBL_AUTH_USER.' u'.
> + " where b.created_by = u.user_id and bug_id = {$buginfo['bug_id']}",
> + null, DB_FETCHMODE_ORDERED);
> + $t->assign(array(
> + 'oldpostedby' => $by,
> + 'oldpostedon' => date(TIME_FORMAT,$on).' on '.date(DATE_FORMAT,$on),
> + 'oldcomments' => textwrap(format_comments($comments),72)
> + ));
> + } else {
> + $rs->fetchInto($row);
> + $t->assign(array(
> + 'oldpostedby' => $row['login'],
> + 'oldpostedon' => date(TIME_FORMAT,$row['created_date']).' on '.
> + date(DATE_FORMAT,$row['created_date']),
> + 'oldcomments' => textwrap(format_comments($row['comment_text']),72)
> + ));
> + }
> + $t->assign('showcomments', true);
> } else {
> - $rs->fetchInto($row);
> - $t->assign(array(
> - 'oldpostedby' => $row['login'],
> - 'oldpostedon' => date(TIME_FORMAT,$row['created_date']).' on '.
> - date(DATE_FORMAT,$row['created_date']),
> - 'oldcomments' => textwrap(format_comments($row['comment_text']),72)
> - ));
> - }
> - $t->assign('showcomments', true);
> - } else {
> - $t->assign('showcomments', false);
> - }
> -
> - $maillist = array();
> - // Don't email the person who just made the changes (later, make this
> - // behavior toggable by the user)
> - if ($userid != $buginfo['created_by'] and !empty($reporter))
> - $maillist[] = $reporter;
> - if ($userid != (!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to'])
> - and !empty($assignedto))
> - $maillist[] = $assignedto;
> -
> - // Collect the CCs
> - if ($ccs = $db->getCol(sprintf($QUERY['bug-cc-list'], $buginfo['bug_id']))) {
> - $maillist = array_merge($maillist, $ccs);
> - }
> -
> - // Later add a watcher (such as QA person) check here
> - if (count($maillist)) {
> - if ($toemail = delimit_list(', ',$maillist)) {
> - $t->assign(array(
> - 'bugid' => $buginfo['bug_id'],
> - 'bugurl' => INSTALL_URL."/bug.php?op=show&bugid={$buginfo['bug_id']}",
> - 'priority' => $select['priority'][(!empty($cf['priority']) ? $cf['priority'] : $buginfo['priority'])],
> - 'priority_stat' => !empty($cf['priority']) ? '!' : ' ',
> - 'reporter' => $reporter,
> - 'reporter_stat' => $reporterstat,
> - 'assignedto' => $assignedto,
> - 'assignedto_stat' => $assignedtostat
> - ));
> -
> - qp_mail($toemail,"[Bug {$buginfo['bug_id']}] ".($newbug ? 'New' : 'Changed').' - '.
> - stripslashes((!empty($cf['title']) ? $cf['title'] : $buginfo['title'])),
> - $t->fetch($template),
> - sprintf("From: %s\nReply-To: %s\nErrors-To: %s", ADMIN_EMAIL, ADMIN_EMAIL, ADMIN_EMAIL));
> + $t->assign('showcomments', false);
> + }
> +
> + $maillist = array();
> +
> + // Don't email the person who just made the changes (later, make this
> + // behavior toggable by the user)
> + if ($userid != $buginfo['created_by'] and !empty($reporter)) {
> + $maillist[] = $reporter;
> + }
> + if ($userid != (!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to'])
> + and !empty($assignedto)) {
> + $maillist[] = $assignedto;
> + }
> +
> + // Collect the CCs
> + if ($ccs = $db->getCol(sprintf($QUERY['bug-cc-list'], $buginfo['bug_id']))) {
> + $maillist = array_merge($maillist, $ccs);
> + }
> +
> + // Later add a watcher (such as QA person) check here
> + if (count($maillist)) {
> + if ($toemail = delimit_list(', ',$maillist)) {
> + $t->assign(array(
> + 'bugid' => $buginfo['bug_id'],
> + 'bugurl' => INSTALL_URL."/bug.php?op=show&bugid={$buginfo['bug_id']}",
> + 'priority' => $select['priority'][(!empty($cf['priority']) ? $cf['priority'] : $buginfo['priority'])],
> + 'priority_stat' => !empty($cf['priority']) ? '!' : ' ',
> + 'reporter' => $reporter,
> + 'reporter_stat' => $reporterstat,
> + 'assignedto' => $assignedto,
> + 'assignedto_stat' => $assignedtostat
> + ));
> +
> + qp_mail($toemail,"[Bug {$buginfo['bug_id']}] ".($newbug ? 'New' : 'Changed').' - '.
> + stripslashes((!empty($cf['title']) ? $cf['title'] : $buginfo['title'])),
> + $t->fetch($template),
> + sprintf("From: %s\nReply-To: %s\nErrors-To: %s", ADMIN_EMAIL, ADMIN_EMAIL, ADMIN_EMAIL));
> + }
> }
> - }
> }
>
> function update_bug($bugid = 0) {
> - global $db, $t, $u, $STRING, $perm, $now, $_pv;
> + global $db, $t, $u, $STRING, $perm, $now, $_pv;
>
> - // Pull bug from database to determine changed fields and for user validation
> - $buginfo = $db->getRow("select * from ".TBL_BUG." where bug_id = $bugid");
> - $changedfields = array();
> -
> - if (isset($_pv)) {
> - foreach ($_pv as $k => $v) {
> - $$k = $v;
> - if ($k == 'url') {
> -
> - if (($v == 'http://') || ($v == 'https://')) {
> - $v = '';
> - } elseif (($v) && (strtolower(substr($v,0,7)) != 'http://') && (strtolower(substr($v,0,8)) != 'https://') && (strtolower(substr($v,0,6)) != 'ftp://')) {
> - $v = 'http://'.$v;
> - }
> - $url = $v;
> - }
> -
> - if (isset($buginfo[$k]) && stripslashes($buginfo[$k]) != stripslashes($v)) {
> - $changedfields[$k] = $v;
> - }
> - }
> - }
> -
> - // Should we allow changes to be made to this bug by this user?
> - if (STRICT_UPDATING and !($u == $buginfo['assigned_to'] or
> - $u == $buginfo['created_by'] or $perm->have_perm('Manager'))) {
> - show_bug($bugid,array('status' => $STRING['bugbadperm']));
> - return;
> - }
> -
> - // Check for more than one person modifying the bug at the same time
> - if ($last_modified_date != $buginfo['last_modified_date']) {
> - show_bug($bugid, array('status' => $STRING['datecollision']));
> - return;
> - }
> -
> - // Add CC if specified
> - if ($add_cc) {
> - if (!$cc_uid = $db->getOne("select user_id from ".TBL_AUTH_USER.
> - " where login = '$add_cc'")) {
> - show_bug($bugid,array('status' => $STRING['nouser']));
> - return;
> - }
> - $cc_already = $db->getOne('select user_id from '.TBL_BUG_CC.
> - " where bug_id = $bugid and user_id = $cc_uid");
> - if (!$cc_already && $cc_uid != $buginfo['created_by']) {
> - $db->query("insert into ".TBL_BUG_CC." (bug_id, user_id, created_by,
> - created_date) values ($bugid, $cc_uid, $u, $now)");
> - }
> - }
> -
> - // Remove CCs if requested
> - if (isset($remove_cc) and $remove_cc[0]) {
> - $db->query('delete from '.TBL_BUG_CC." where bug_id = $bugid
> - and user_id in (".delimit_list(',', $remove_cc).')');
> - }
> -
> - // Add dependency if requested
> - if (!empty($add_dependency)) {
> - $add_dependency = preg_replace('/\D/', '', $add_dependency);
> - // Validate the bug number
> - if (!is_numeric($add_dependency)) {
> - show_bug($bugid, array('add_dep' => $STRING['nobug']));
> - return;
> - }
> - if (!$db->getOne('select count(*) from '.TBL_BUG." where bug_id = $add_dependency")) {
> - show_bug($bugid, array('add_dep' => $STRING['nobug']));
> - return;
> + // Pull bug from database to determine changed fields and for user validation
> + $buginfo = $db->getRow("select * from ".TBL_BUG." where bug_id = $bugid");
> + $changedfields = array();
> +
> + if (isset($_pv)) {
> + foreach ($_pv as $k => $v) {
> + $$k = $v;
> + if ($k == 'url') {
> + if (($v == 'http://') || ($v == 'https://')) {
> + $v = '';
> + } elseif (($v) && (strtolower(substr($v,0,7)) != 'http://') && (strtolower(substr($v,0,8)) != 'https://') && (strtolower(substr($v,0,6)) != 'ftp://')) {
> + $v = 'http://'.$v;
> }
> -
> - // Check if the dependency has already been added
> - if ($db->getOne('select count(*) from '.TBL_BUG_DEPENDENCY.
> - " where bug_id = $bugid and depends_on = $add_dependency")) {
> - show_bug($bugid, array('add_dep' => $STRING['dupe_dependency']));
> - return;
> - }
> -
> - // Add it
> - $db->query("insert into ".TBL_BUG_DEPENDENCY.
> - " (bug_id, depends_on) values($bugid, $add_dependency)");
> + $url = $v;
> + }
> +
> + if (isset($buginfo[$k]) && stripslashes($buginfo[$k]) != stripslashes($v)) {
> + $changedfields[$k] = $v;
> + }
> + }
> + }
> +
> + // Should we allow changes to be made to this bug by this user?
> + if (STRICT_UPDATING and !($u == $buginfo['assigned_to'] or
> + $u == $buginfo['created_by'] or $perm->have_perm('Manager'))) {
> + show_bug($bugid,array('status' => $STRING['bugbadperm']));
> + return;
> + }
> +
> + // Check for more than one person modifying the bug at the same time
> + if ($last_modified_date != $buginfo['last_modified_date']) {
> + show_bug($bugid, array('status' => $STRING['datecollision']));
> + return;
> + }
> +
> + // Add CC if specified
> + if ($add_cc) {
> + if (!$cc_uid = $db->getOne("select user_id from ".TBL_AUTH_USER.
> + " where login = '$add_cc'")) {
> + show_bug($bugid,array('status' => $STRING['nouser']));
> + return;
> }
> + $cc_already = $db->getOne('select user_id from '.TBL_BUG_CC.
> + " where bug_id = $bugid and user_id = $cc_uid");
> + if (!$cc_already && $cc_uid != $buginfo['created_by']) {
> + $db->query("insert into ".TBL_BUG_CC." (bug_id, user_id, created_by,
> + created_date) values ($bugid, $cc_uid, $u, $now)");
> + }
> + }
> +
> + // Remove CCs if requested
> + if (isset($remove_cc) and $remove_cc[0]) {
> + $db->query('delete from '.TBL_BUG_CC." where bug_id = $bugid and user_id in (".
> + delimit_list(',', $remove_cc).')');
> + }
>
> - // Remove dependency if requested
> - if (!empty($del_dependency)) {
> - $del_dependency = preg_replace('/\D/', '', $del_dependency);
> - if (is_numeric($del_dependency)) {
> - $db->query("delete from ".TBL_BUG_DEPENDENCY.
> - " where bug_id = $bugid and depends_on = $del_dependency");
> - }
> + // Add dependency if requested
> + if (!empty($add_dependency)) {
> + $add_dependency = preg_replace('/\D/', '', $add_dependency);
> +
> + // Validate the bug number
> + if (!is_numeric($add_dependency)) {
> + show_bug($bugid, array('add_dep' => $STRING['nobug']));
> + return;
> + }
> + if (!$db->getOne('select count(*) from '.TBL_BUG." where bug_id = $add_dependency")) {
> + show_bug($bugid, array('add_dep' => $STRING['nobug']));
> + return;
> }
> -
> - if ($comments) {
> - //$comments = strip_tags($comments); -- Uncomment this if you want no <> content in the comments
> - $db->query("insert into ".TBL_COMMENT." (comment_id, bug_id, comment_text, created_by, created_date)"
> - ." values (".$db->nextId(TBL_COMMENT).", $bugid, ".
> - $db->quote(stripslashes($comments)).", $u, $now)");
> - }
> -
> - // Allow for removing of some items from the bug page
> - $priority = $priority ? $priority : 0;
> - $os_id = $os_id ? $os_id : 0;
> - $severity_id = $severity_id ? $severity_id : 0;
> +
> + // Check if the dependency has already been added
> + if ($db->getOne('select count(*) from '.TBL_BUG_DEPENDENCY.
> + " where bug_id = $bugid and depends_on = $add_dependency")) {
> + show_bug($bugid, array('add_dep' => $STRING['dupe_dependency']));
> + return;
> + }
> +
> + // Add it
> + $db->query("insert into ".TBL_BUG_DEPENDENCY.
> + " (bug_id, depends_on) values($bugid, $add_dependency)");
> + }
>
> - $db->query("update ".TBL_BUG." set title = ".$db->quote(stripslashes($title)).
> - ', url = '.$db->quote(stripslashes($url)).", severity_id = $severity_id, ".
> - "priority = $priority, status_id = $status_id, ".
> - "database_id = $database_id, to_be_closed_in_version_id = $to_be_closed_in_version_id, ".
> - "resolution_id = $resolution_id, assigned_to = $assigned_to, ".
> - "project_id = $project_id, version_id = $version_id, ".
> - "component_id = $component_id, os_id = $os_id, last_modified_by = $u, ".
> - "last_modified_date = $now where bug_id = $bugid");
> -
> - if (count($changedfields) or !empty($comments)) {
> - do_changedfields($u, $buginfo, $changedfields, $comments);
> - }
> - header("Location: bug.php?op=show&bugid=$bugid&pos=$pos");
> + // Remove dependency if requested
> + if (!empty($del_dependency)) {
> + $del_dependency = preg_replace('/\D/', '', $del_dependency);
> + if (is_numeric($del_dependency)) {
> + $db->query("delete from ".TBL_BUG_DEPENDENCY.
> + " where bug_id = $bugid and depends_on = $del_dependency");
> + }
> + }
> +
> + if ($comments) {
> + // $comments = strip_tags($comments); -- Uncomment this if you want no <> content in the comments
> + $db->query("insert into ".TBL_COMMENT." (comment_id, bug_id, comment_text, created_by, created_date)".
> + " values (".$db->nextId(TBL_COMMENT).", $bugid, ".
> + $db->quote(stripslashes($comments)).", $u, $now)");
> + }
> +
> + // Allow for removing of some items from the bug page
> + $priority = $priority ? $priority : 0;
> + $os_id = $os_id ? $os_id : 0;
> + $severity_id = $severity_id ? $severity_id : 0;
> +
> + $db->query("update ".TBL_BUG." set title = ".$db->quote(stripslashes($title)).
> + ', url = '.$db->quote(stripslashes($url)).", severity_id = $severity_id, ".
> + "priority = $priority, status_id = $status_id, ".
> + "database_id = $database_id, to_be_closed_in_version_id = $to_be_closed_in_version_id, ".
> + 'closed_in_version_id = '.$closed_in_version_id.', '.
> + // 'site_id ='.$site_id.', '.
> + // -- uncomment this when bugdisplay template ready
> + "resolution_id = $resolution_id, assigned_to = $assigned_to, ".
> + "project_id = $project_id, version_id = $version_id, ".
> + "component_id = $component_id, os_id = $os_id, last_modified_by = $u, ".
> + "last_modified_date = $now where bug_id = $bugid");
> +
> + if (count($changedfields) or !empty($comments)) {
> + do_changedfields($u, $buginfo, $changedfields, $comments);
> + }
> +
> + header("Location: bug.php?op=show&bugid=$bugid&pos=$pos");
> }
>
> function do_form($bugid = 0) {
>
>
> _______________________________________________________________
>
> Don't miss the 2002 Sprint PCS Application Developer's Conference
> August 25-28 in Las Vegas - http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink
>
> _______________________________________________
> phpbt-dev mailing list
> php...@li...
> https://lists.sourceforge.net/lists/listinfo/phpbt-dev
|
|
From: Jirka P. <fi...@us...> - 2002-06-14 07:52:28
|
> We have we started using underscores to prefix variable names? I did it only in indexes (keys) of STRING array. There were 2 reasons for= doing it. First reason was that I was adding many strings to en.php and I = want it to be better trackable in future, because some of them are in fact = doubling existing indexes (keys) in English, but for example in Czech they = differ. The second was that almost all of them are connected to queryform templat= es only. I wanted to prefix them with e.g. 'queryform_', but I wasn't decid= ed for sure. Maybe you (talking native English) are not able to see it, but this is ve= ry helpful for us (translating to another languages), when deciding on the = figure of the flexible word (English words are not flexible, but Czech word= s are) we will use. If this is not a big problem, I want to prefix indexes in STRING and TITL= E with underscores and some kind of shortened name of the template, when I = will add strings to en.php in the future and I think, if everybody will do = it the same way, it will help the translators. What do you think, is it a problem or not? If it is a problem, I will of = course rename that indexes (keys) in language files and in templates and wi= ll forget it. Please, tell me. Another thing I thought about yesterday is the number of indexes in STRIN= G array. It's growing and it may grow about ten or more times. I don't actu= ally know exactly if it will have some performance impact, what do you thin= k about it? Please post this also to 'localization list' and subscribe me there if yo= u want to start a dialogue about it. Have a nice day! Jirka Pech [We have two days parliament elections in our country today and tomorrow, s= o I may fall offline until monday.] |
|
From: Ben C. <php...@be...> - 2002-06-14 04:06:17
|
We have we started using underscores to prefix variable names?
On Thu, Jun 13, 2002 at 02:23:43AM -0700, Jirka Pech wrote:
> Update of /cvsroot/phpbt/phpbt/templates/default
> In directory usw-pr-cvs1:/tmp/cvs-serv12398/phpbt/templates/default
>
> Modified Files:
> queryform-simple.html queryform.html
> Log Message:
> Added some JavaScript (BTW: there is no 'language' attribute in standart, but 'type' only), some localization.
>
>
> Index: queryform-simple.html
> ===================================================================
> RCS file: /cvsroot/phpbt/phpbt/templates/default/queryform-simple.html,v
> retrieving revision 1.6
> retrieving revision 1.7
> diff -u -r1.6 -r1.7
> --- queryform-simple.html 8 Jun 2002 20:28:52 -0000 1.6
> +++ queryform-simple.html 13 Jun 2002 09:23:40 -0000 1.7
> @@ -1,9 +1,11 @@
> -<script language="JavaScript">
> +<script type="text/JavaScript">
> <!--
> versions = new Array();
> components = new Array();
> +closedversions = new Array();
> versions['All'] = new Array(new Array('','All'));
> components['All'] = new Array(new Array('','All'));
> +closedversions['All'] = new Array(new Array('','All'));
> {project_js}
>
> {literal}
> @@ -25,56 +27,56 @@
> </script>
> <form method="get" action="query.php" name="query">
> <table>
> - <tr>
> - <td valign="top"><b>Project:</b></td>
> + <tr valign="baseline">
> + <td valign="top"><b>{$TITLE._Project}:</b></td>
> <td valign="top">
> <select name="projects" onChange="updateMenus(this.form)">
> - <option value=''>All</option>
> + <option value=''>{$TITLE._opt_All}</option>
> {build_select box=project}
> </select>
> </td>
> </tr>
> - <tr>
> - <td valign="top"><b>Version:</b></td>
> + <tr valign="baseline">
> + <td valign="top"><b>{$TITLE._Version}:</b></td>
> <td valign="top">
> - <select name="versions"><option value=''>All</option></select>
> + <select name="versions"><option value=''>{$TITLE._opt_All}</option></select>
> </td>
> </tr>
> - <tr>
> - <td valign="top"><b>Component:</b></td>
> + <tr valign="baseline">
> + <td valign="top"><b>{$TITLE._Component}:</b></td>
> <td valign="top">
> - <select name="components"><option value=''>All</option></select>
> + <select name="components"><option value=''>{$TITLE._opt_All}</option></select>
> </td>
> </tr>
> - <tr>
> - <td valign="top"><b>Status:</b></td>
> + <tr valign="baseline">
> + <td valign="top"><b>{$TITLE._Status}:</b></td>
> <td valign="top">
> <select name="status[]" multiple size="7">{build_select box=status}</select>
> </td>
> </tr>
> - <tr>
> - <td valign="top"><b>Sort By:</b></td>
> + <tr valign="baseline">
> + <td valign="top"><b>{$TITLE._SortBy}:</b></td>
> <td valign="top">
> <select name="order">
> <option value="bug_id">
> - Bug Number
> + {$TITLE._SortBy_BugNumber}
> </option>
> <option selected value="severity.sort_order">
> - Severity
> + {$TITLE._SortBy_Severity}
> </option>
> <option value="reporter">
> - Reporter
> + {$TITLE._SortBy_Reporter}
> </option>
> <option value="status.sort_order">
> - Status
> + {$TITLE._SortBy_Status}
> </option>
> <option value="priority">
> - Priority
> + {$TITLE._SortBy_Priority}
> </option>
> </select>
> <select name="sort">
> - <option selected value="asc">Ascending</option>
> - <option value="desc">Descending</option>
> + <option selected value="asc">{$TITLE._SortAsc}</option>
> + <option value="desc">{$TITLE._SortDesc}</option>
> </select>
> </td>
> </tr>
> @@ -82,20 +84,20 @@
> <br>
> <br>
> {if $smarty.session.uid}
> - Save this query as: <input maxlength="40" type="text" name="savedqueryname">
> + {$TITLE._SaveThisQueryAs}: <input maxlength="40" type="text" name="savedqueryname">
> <br><br>
> {/if}
> <input type="hidden" name="op" value="doquery">
> - <input type="reset" value="Reset back to the default query">
> - <input type="submit" value="Submit query">
> + <input type="reset" value="{$TITLE._ResetBackToDefaultQuery}">
> + <input type="submit" value="{$TITLE._SubmitQuery}">
> {if count($queries)}
> <br><br>
> - <b>Saved Queries</b>
> + <b>{$TITLE._SavedQueries}</b>
> <br>
> {section name=query loop=$queries}
> - <a href="{$smarty.server.PHP_SELF}?{$queries[query].saved_query_string}">{$queries[query].saved_query_name}</a> (<a href="{$smarty.server.PHP_SELF}?op=delquery&queryid={$queries[query].saved_query_id}&form=simple" onClick="return confirm('Are you sure you want to delete this saved query?');">Delete</a>)<br>
> + <a href="{$smarty.server.PHP_SELF}?{$queries[query].saved_query_string}">{$queries[query].saved_query_name}</a> (<a href="{$smarty.server.PHP_SELF}?op=delquery&queryid={$queries[query].saved_query_id}&form=simple" onClick="return confirm('{$TITLE._SureDeleteSavedQuery}');">{$STRING.delete}</a>)<br>
> {/section}
> {/if}
> </form>
> <br>
> - Go to the <a href="{$smarty.server.PHP_SELF}?op=query&form=advanced">advanced query page</a>
> + {$TITLE._1GoToThe} <a href="{$smarty.server.PHP_SELF}?op=query&form=advanced">{$TITLE._1AdvancedQueryPage}</a>
>
> Index: queryform.html
> ===================================================================
> RCS file: /cvsroot/phpbt/phpbt/templates/default/queryform.html,v
> retrieving revision 1.14
> retrieving revision 1.15
> diff -u -r1.14 -r1.15
> --- queryform.html 12 Jun 2002 13:50:49 -0000 1.14
> +++ queryform.html 13 Jun 2002 09:23:40 -0000 1.15
> @@ -1,8 +1,10 @@
> -<script language="JavaScript">
> +<script type="text/JavaScript">
> <!--
> versions = new Array();
> +closedversions = new Array();
> components = new Array();
> versions['All'] = new Array(new Array('','All'));
> +closedversions['All'] = new Array(new Array('','All'));
> components['All'] = new Array(new Array('','All'));
> {project_js}
>
> @@ -26,7 +28,7 @@
> <form method="get" action="query.php" name="query">
> <table>
> <tr>
> - <th align="left">Status:</th>
> + <th align="left">{$TITLE._Status}:</th>
> <th align="left">Resolution:</th>
> <th align="left">OpSys:</th>
> <th align="left">Priority:</th>
> @@ -166,63 +168,63 @@
> <hr align="left" width="100%">
> <table>
> <tr>
> - <td><b>Project:</b></td>
> + <td><b>{$TITLE._Project}:</b></td>
> <td>
> <select name="projects" onChange="updateMenus(this.form)">
> - <option value=''>All</option>
> + <option value=''>{$TITLE._opt_All}</option>
> {build_select box=project}
> </select>
> </td>
> </tr>
> <tr>
> - <td><b>Version:</b></td>
> + <td><b>{$TITLE._Version}:</b></td>
> <td>
> - <select name="versions"><option value=''>All</option></select>
> + <select name="versions"><option value=''>{$TITLE._opt_All}</option></select>
> </td>
> </tr>
> <tr>
> - <td><b>Component:</b></td>
> + <td><b>{$TITLE._Component}:</b></td>
> <td>
> - <select name="components"><option value=''>All</option></select>
> + <select name="components"><option value=''>{$TITLE._opt_All}</option></select>
> </td>
> </tr>
> </table>
> <hr align="left" width="100%">
> <input type="hidden" name="op" value="doquery">
> - <nobr><b>Sort By:</b>
> + <nobr><b>{$TITLE._SortBy}:</b>
> <select name="order">
> <option value="bug_id">
> - Bug Number
> + {$TITLE._SortBy_BugNumber}
> </option>
> <option selected value="severity.sort_order">
> - Severity
> + {$TITLE._SortBy_Severity}
> </option>
> <option value="reporter.login">
> - Reporter
> + {$TITLE._SortBy_Reporter}
> </option>
> <option value="status.sort_order">
> - Status
> + {$TITLE._SortBy_Status}
> </option>
> <option value="priority">
> - Priority
> + {$TITLE._SortBy_Priority}
> </option>
> </select>
> <select name="sort">
> - <option selected value="asc">Ascending</option>
> - <option value="desc">Descending</option>
> + <option selected value="asc">{$TITLE._SortAsc}</option>
> + <option value="desc">{$TITLE._SortDesc}</option>
> </select>
> </nobr>
> <br>
> <br>
> {if $smarty.session.uid}
> - Save this query as: <input maxlength="40" type="text" name="savedqueryname">
> + {$TITLE._SaveThisQueryAs}: <input maxlength="40" type="text" name="savedqueryname">
> <br><br>
> {/if}
> - <input type="reset" value="Reset back to the default query">
> - <input type="submit" value="Submit query">
> + <input type="reset" value="{$TITLE._ResetBackToDefaultQuery}">
> + <input type="submit" value="{$TITLE._SubmitQuery}">
> {if count($queries)}
> <br><br>
> - <b>Saved Queries</b>
> + <b>{$TITLE._SavedQueries}</b>
> <br>
> {section name=query loop=$queries}
> <a href="{$smarty.server.PHP_SELF}?{$queries[query].saved_query_string}">{$queries[query].saved_query_name}</a> (<a href="{$smarty.server.PHP_SELF}?op=delquery&queryid={$queries[query].saved_query_id}&form=advanced" onClick="return confirm('Are you sure you want to delete this saved query?');">Delete</a>)<br>
> @@ -230,5 +232,5 @@
> {/if}
> </form>
> <br>
> - Go to the <a href="{$smarty.server.PHP_SELF}?op=query">simple query page</a>
> + {$TITLE._1GoToThe} <a href="{$smarty.server.PHP_SELF}?op=query">simple query page</a>
>
>
>
> _______________________________________________________________
>
> Don't miss the 2002 Sprint PCS Application Developer's Conference
> August 25-28 in Las Vegas - http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink
>
> _______________________________________________
> phpbt-dev mailing list
> php...@li...
> https://lists.sourceforge.net/lists/listinfo/phpbt-dev
|
|
From: Jirka P. <fi...@us...> - 2002-06-13 16:03:36
|
Update of /cvsroot/phpbt/phpbt
In directory usw-pr-cvs1:/tmp/cvs-serv16459/phpbt
Modified Files:
bug.php
Log Message:
Did some dirty work on code cleanup. Next change have to be changed fields notify for (to_be_)closed_in_version_id, database_id and then site_id when modified bugdisplay template and bug.php again.
Going home for today.
Index: bug.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/bug.php,v
retrieving revision 1.108
retrieving revision 1.109
diff -u -r1.108 -r1.109
--- bug.php 13 Jun 2002 15:20:21 -0000 1.108
+++ bug.php 13 Jun 2002 16:03:29 -0000 1.109
@@ -119,271 +119,281 @@
///
/// Send the email about changes to the bug and log the changes in the DB
function do_changedfields($userid, &$buginfo, $cf = array(), $comments = '') {
- global $db, $t, $u, $select, $now, $STRING, $QUERY;
+ global $db, $t, $u, $select, $now, $STRING, $QUERY;
- // It's a new bug if the changedfields array is empty and there are no comments
- $newbug = (!count($cf) and !$comments);
+ // It's a new bug if the changedfields array is empty and there are no comments
+ $newbug = (!count($cf) and !$comments);
- $template = $newbug ? 'bugemail-newbug.txt' : 'bugemail.txt';
- foreach(array('title','url') as $field) {
- if (isset($cf[$field])) {
- $db->query('insert into '.TBL_BUG_HISTORY
- .' (bug_id, changed_field, old_value, new_value, created_by, created_date)'
- ." values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
- $db->quote(stripslashes($buginfo[$field])),
- $db->quote(stripslashes($cf[$field])), $u, $now)).")");
- $t->assign(array(
- $field => stripslashes($cf[$field]),
- $field.'_stat' => '!'
- ));
- } else {
- $t->assign(array(
- $field => stripslashes($buginfo[$field]),
- $field.'_stat' => ' '
- ));
- }
- }
-
- // create array with tablenames for following loop
- $cfgDatabase = array(
- 'project' => TBL_PROJECT,
- 'component' => TBL_COMPONENT,
- 'status' => TBL_STATUS,
- 'resolution' => TBL_RESOLUTION,
- 'database' => TBL_DATABASE,
- 'severity' => TBL_SEVERITY,
- 'os' => TBL_OS,
- 'version' => TBL_VERSION
- );
-
- foreach($cfgDatabase as $field => $table) {
- $oldvalue = $db->getOne("select ${field}_name from $table"
- ." where ${field}_id = {$buginfo[$field.'_id']}");
- if (!empty($cf[$field.'_id'])) {
- $newvalue = $db->getOne("select ${field}_name from $table"
- ." where ${field}_id = {$cf[$field.'_id']}");
- $db->query('insert into '.TBL_BUG_HISTORY
- .' (bug_id, changed_field, old_value, new_value, created_by, created_date)'
- ." values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
- $db->quote(stripslashes($oldvalue)),
- $db->quote(stripslashes($newvalue)), $u, $now)).")");
- $t->assign(array(
- $field.'_id' => stripslashes($newvalue),
- $field.'_id_stat' => '!'
- ));
- } else {
- $t->assign(array(
- $field.'_id' => stripslashes($oldvalue),
- $field.'_id_stat' => ' '
- ));
- }
- }
-
- // Reporter never changes;
- $reporter = $db->getOne('select email from '.TBL_AUTH_USER
- ." u, ".TBL_USER_PREF." p where u.user_id = {$buginfo['created_by']} ".
- "and u.user_id = p.user_id and email_notices = 1");
- $reporterstat = ' ';
- $assignedto = $db->getOne('select email from '.TBL_AUTH_USER." u, ".
- TBL_USER_PREF.' p where u.user_id = '
- .(!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to']).
- " and u.user_id = p.user_id and email_notices = 1");
- $assignedtostat = !empty($cf['assigned_to']) ? '!' : ' ';
-
- // If there are new comments grab the comments immediately before the latest
- if ($comments or $newbug) {
- $rs = $db->limitQuery('select u.login, c.comment_text, c.created_date'
- .' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER.' u'
- ." where bug_id = {$buginfo['bug_id']} and c.created_by = u.user_id"
- .' order by created_date desc', 0, 2);
- $rs->fetchInto($row);
- $t->assign(array(
- 'newpostedby' => $row['login'],
- 'newpostedon' => date(TIME_FORMAT, $row['created_date']).' on '.
- date(DATE_FORMAT, $row['created_date']),
- 'newcomments' => textwrap('+ '.format_comments($row['comment_text']),72,"\n+ ")
- ));
- // If this comment is the first additional comment after the creation of the
- // bug then we need to grab the bug's description as the previous comment
- if ($rs->numRows() < 2) {
- list($by, $on, $comments) = $db->getRow('select u.login, b.created_date, b.description'
- .' from '.TBL_BUG.' b, '.TBL_AUTH_USER.' u'
- ." where b.created_by = u.user_id and bug_id = {$buginfo['bug_id']}",
- null, DB_FETCHMODE_ORDERED);
- $t->assign(array(
- 'oldpostedby' => $by,
- 'oldpostedon' => date(TIME_FORMAT,$on).' on '.date(DATE_FORMAT,$on),
- 'oldcomments' => textwrap(format_comments($comments),72)
- ));
+ $template = $newbug ? 'bugemail-newbug.txt' : 'bugemail.txt';
+ foreach(array('title','url') as $field) {
+ if (isset($cf[$field])) {
+ $db->query('insert into '.TBL_BUG_HISTORY.
+ ' (bug_id, changed_field, old_value, new_value, created_by, created_date)'.
+ " values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
+ $db->quote(stripslashes($buginfo[$field])),
+ $db->quote(stripslashes($cf[$field])), $u, $now)).")");
+ $t->assign(array(
+ $field => stripslashes($cf[$field]),
+ $field.'_stat' => '!'
+ ));
+ } else {
+ $t->assign(array(
+ $field => stripslashes($buginfo[$field]),
+ $field.'_stat' => ' '
+ ));
+ }
+ }
+
+ // create array with tablenames for following loop
+ $cfgDatabase = array(
+ 'project' => TBL_PROJECT,
+ 'component' => TBL_COMPONENT,
+ 'status' => TBL_STATUS,
+ 'resolution' => TBL_RESOLUTION,
+ 'database' => TBL_DATABASE,
+ 'severity' => TBL_SEVERITY,
+ 'os' => TBL_OS,
+ 'version' => TBL_VERSION,
+ 'database' => TBL_DATABASE,
+ 'site' => TBL_SITE
+ );
+
+ foreach($cfgDatabase as $field => $table) {
+ $oldvalue = $db->getOne("select ${field}_name from $table".
+ " where ${field}_id = {$buginfo[$field.'_id']}");
+ if (!empty($cf[$field.'_id'])) {
+ $newvalue = $db->getOne("select ${field}_name from $table".
+ " where ${field}_id = {$cf[$field.'_id']}");
+ $db->query('insert into '.TBL_BUG_HISTORY.
+ ' (bug_id, changed_field, old_value, new_value, created_by, created_date)'.
+ " values (". join(', ', array($buginfo['bug_id'], $db->quote($field),
+ $db->quote(stripslashes($oldvalue)),
+ $db->quote(stripslashes($newvalue)), $u, $now)).")");
+ $t->assign(array(
+ $field.'_id' => stripslashes($newvalue),
+ $field.'_id_stat' => '!'
+ ));
+ } else {
+ $t->assign(array(
+ $field.'_id' => stripslashes($oldvalue),
+ $field.'_id_stat' => ' '
+ ));
+ }
+ }
+
+ // Reporter never changes;
+ $reporter = $db->getOne('select email from '.TBL_AUTH_USER.
+ " u, ".TBL_USER_PREF." p where u.user_id = {$buginfo['created_by']} ".
+ "and u.user_id = p.user_id and email_notices = 1");
+ $reporterstat = ' ';
+ $assignedto = $db->getOne('select email from '.TBL_AUTH_USER." u, ".
+ TBL_USER_PREF.' p where u.user_id = '.
+ (!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to']).
+ " and u.user_id = p.user_id and email_notices = 1");
+ $assignedtostat = !empty($cf['assigned_to']) ? '!' : ' ';
+
+ // If there are new comments grab the comments immediately before the latest
+ if ($comments or $newbug) {
+ $rs = $db->limitQuery('select u.login, c.comment_text, c.created_date'.
+ ' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER.' u'.
+ " where bug_id = {$buginfo['bug_id']} and c.created_by = u.user_id".
+ ' order by created_date desc', 0, 2);
+ $rs->fetchInto($row);
+ $t->assign(array(
+ 'newpostedby' => $row['login'],
+ 'newpostedon' => date(TIME_FORMAT, $row['created_date']).' on '.
+ date(DATE_FORMAT, $row['created_date']),
+ 'newcomments' => textwrap('+ '.format_comments($row['comment_text']),72,"\n+ ")
+ ));
+
+ // If this comment is the first additional comment after the creation of the
+ // bug then we need to grab the bug's description as the previous comment
+ if ($rs->numRows() < 2) {
+ list($by, $on, $comments) = $db->getRow('select u.login, b.created_date, b.description'.
+ ' from '.TBL_BUG.' b, '.TBL_AUTH_USER.' u'.
+ " where b.created_by = u.user_id and bug_id = {$buginfo['bug_id']}",
+ null, DB_FETCHMODE_ORDERED);
+ $t->assign(array(
+ 'oldpostedby' => $by,
+ 'oldpostedon' => date(TIME_FORMAT,$on).' on '.date(DATE_FORMAT,$on),
+ 'oldcomments' => textwrap(format_comments($comments),72)
+ ));
+ } else {
+ $rs->fetchInto($row);
+ $t->assign(array(
+ 'oldpostedby' => $row['login'],
+ 'oldpostedon' => date(TIME_FORMAT,$row['created_date']).' on '.
+ date(DATE_FORMAT,$row['created_date']),
+ 'oldcomments' => textwrap(format_comments($row['comment_text']),72)
+ ));
+ }
+ $t->assign('showcomments', true);
} else {
- $rs->fetchInto($row);
- $t->assign(array(
- 'oldpostedby' => $row['login'],
- 'oldpostedon' => date(TIME_FORMAT,$row['created_date']).' on '.
- date(DATE_FORMAT,$row['created_date']),
- 'oldcomments' => textwrap(format_comments($row['comment_text']),72)
- ));
- }
- $t->assign('showcomments', true);
- } else {
- $t->assign('showcomments', false);
- }
-
- $maillist = array();
- // Don't email the person who just made the changes (later, make this
- // behavior toggable by the user)
- if ($userid != $buginfo['created_by'] and !empty($reporter))
- $maillist[] = $reporter;
- if ($userid != (!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to'])
- and !empty($assignedto))
- $maillist[] = $assignedto;
-
- // Collect the CCs
- if ($ccs = $db->getCol(sprintf($QUERY['bug-cc-list'], $buginfo['bug_id']))) {
- $maillist = array_merge($maillist, $ccs);
- }
-
- // Later add a watcher (such as QA person) check here
- if (count($maillist)) {
- if ($toemail = delimit_list(', ',$maillist)) {
- $t->assign(array(
- 'bugid' => $buginfo['bug_id'],
- 'bugurl' => INSTALL_URL."/bug.php?op=show&bugid={$buginfo['bug_id']}",
- 'priority' => $select['priority'][(!empty($cf['priority']) ? $cf['priority'] : $buginfo['priority'])],
- 'priority_stat' => !empty($cf['priority']) ? '!' : ' ',
- 'reporter' => $reporter,
- 'reporter_stat' => $reporterstat,
- 'assignedto' => $assignedto,
- 'assignedto_stat' => $assignedtostat
- ));
-
- qp_mail($toemail,"[Bug {$buginfo['bug_id']}] ".($newbug ? 'New' : 'Changed').' - '.
- stripslashes((!empty($cf['title']) ? $cf['title'] : $buginfo['title'])),
- $t->fetch($template),
- sprintf("From: %s\nReply-To: %s\nErrors-To: %s", ADMIN_EMAIL, ADMIN_EMAIL, ADMIN_EMAIL));
+ $t->assign('showcomments', false);
+ }
+
+ $maillist = array();
+
+ // Don't email the person who just made the changes (later, make this
+ // behavior toggable by the user)
+ if ($userid != $buginfo['created_by'] and !empty($reporter)) {
+ $maillist[] = $reporter;
+ }
+ if ($userid != (!empty($cf['assigned_to']) ? $cf['assigned_to'] : $buginfo['assigned_to'])
+ and !empty($assignedto)) {
+ $maillist[] = $assignedto;
+ }
+
+ // Collect the CCs
+ if ($ccs = $db->getCol(sprintf($QUERY['bug-cc-list'], $buginfo['bug_id']))) {
+ $maillist = array_merge($maillist, $ccs);
+ }
+
+ // Later add a watcher (such as QA person) check here
+ if (count($maillist)) {
+ if ($toemail = delimit_list(', ',$maillist)) {
+ $t->assign(array(
+ 'bugid' => $buginfo['bug_id'],
+ 'bugurl' => INSTALL_URL."/bug.php?op=show&bugid={$buginfo['bug_id']}",
+ 'priority' => $select['priority'][(!empty($cf['priority']) ? $cf['priority'] : $buginfo['priority'])],
+ 'priority_stat' => !empty($cf['priority']) ? '!' : ' ',
+ 'reporter' => $reporter,
+ 'reporter_stat' => $reporterstat,
+ 'assignedto' => $assignedto,
+ 'assignedto_stat' => $assignedtostat
+ ));
+
+ qp_mail($toemail,"[Bug {$buginfo['bug_id']}] ".($newbug ? 'New' : 'Changed').' - '.
+ stripslashes((!empty($cf['title']) ? $cf['title'] : $buginfo['title'])),
+ $t->fetch($template),
+ sprintf("From: %s\nReply-To: %s\nErrors-To: %s", ADMIN_EMAIL, ADMIN_EMAIL, ADMIN_EMAIL));
+ }
}
- }
}
function update_bug($bugid = 0) {
- global $db, $t, $u, $STRING, $perm, $now, $_pv;
+ global $db, $t, $u, $STRING, $perm, $now, $_pv;
- // Pull bug from database to determine changed fields and for user validation
- $buginfo = $db->getRow("select * from ".TBL_BUG." where bug_id = $bugid");
- $changedfields = array();
-
- if (isset($_pv)) {
- foreach ($_pv as $k => $v) {
- $$k = $v;
- if ($k == 'url') {
-
- if (($v == 'http://') || ($v == 'https://')) {
- $v = '';
- } elseif (($v) && (strtolower(substr($v,0,7)) != 'http://') && (strtolower(substr($v,0,8)) != 'https://') && (strtolower(substr($v,0,6)) != 'ftp://')) {
- $v = 'http://'.$v;
- }
- $url = $v;
- }
-
- if (isset($buginfo[$k]) && stripslashes($buginfo[$k]) != stripslashes($v)) {
- $changedfields[$k] = $v;
- }
- }
- }
-
- // Should we allow changes to be made to this bug by this user?
- if (STRICT_UPDATING and !($u == $buginfo['assigned_to'] or
- $u == $buginfo['created_by'] or $perm->have_perm('Manager'))) {
- show_bug($bugid,array('status' => $STRING['bugbadperm']));
- return;
- }
-
- // Check for more than one person modifying the bug at the same time
- if ($last_modified_date != $buginfo['last_modified_date']) {
- show_bug($bugid, array('status' => $STRING['datecollision']));
- return;
- }
-
- // Add CC if specified
- if ($add_cc) {
- if (!$cc_uid = $db->getOne("select user_id from ".TBL_AUTH_USER.
- " where login = '$add_cc'")) {
- show_bug($bugid,array('status' => $STRING['nouser']));
- return;
- }
- $cc_already = $db->getOne('select user_id from '.TBL_BUG_CC.
- " where bug_id = $bugid and user_id = $cc_uid");
- if (!$cc_already && $cc_uid != $buginfo['created_by']) {
- $db->query("insert into ".TBL_BUG_CC." (bug_id, user_id, created_by,
- created_date) values ($bugid, $cc_uid, $u, $now)");
- }
- }
-
- // Remove CCs if requested
- if (isset($remove_cc) and $remove_cc[0]) {
- $db->query('delete from '.TBL_BUG_CC." where bug_id = $bugid
- and user_id in (".delimit_list(',', $remove_cc).')');
- }
-
- // Add dependency if requested
- if (!empty($add_dependency)) {
- $add_dependency = preg_replace('/\D/', '', $add_dependency);
- // Validate the bug number
- if (!is_numeric($add_dependency)) {
- show_bug($bugid, array('add_dep' => $STRING['nobug']));
- return;
- }
- if (!$db->getOne('select count(*) from '.TBL_BUG." where bug_id = $add_dependency")) {
- show_bug($bugid, array('add_dep' => $STRING['nobug']));
- return;
+ // Pull bug from database to determine changed fields and for user validation
+ $buginfo = $db->getRow("select * from ".TBL_BUG." where bug_id = $bugid");
+ $changedfields = array();
+
+ if (isset($_pv)) {
+ foreach ($_pv as $k => $v) {
+ $$k = $v;
+ if ($k == 'url') {
+ if (($v == 'http://') || ($v == 'https://')) {
+ $v = '';
+ } elseif (($v) && (strtolower(substr($v,0,7)) != 'http://') && (strtolower(substr($v,0,8)) != 'https://') && (strtolower(substr($v,0,6)) != 'ftp://')) {
+ $v = 'http://'.$v;
}
-
- // Check if the dependency has already been added
- if ($db->getOne('select count(*) from '.TBL_BUG_DEPENDENCY.
- " where bug_id = $bugid and depends_on = $add_dependency")) {
- show_bug($bugid, array('add_dep' => $STRING['dupe_dependency']));
- return;
- }
-
- // Add it
- $db->query("insert into ".TBL_BUG_DEPENDENCY.
- " (bug_id, depends_on) values($bugid, $add_dependency)");
+ $url = $v;
+ }
+
+ if (isset($buginfo[$k]) && stripslashes($buginfo[$k]) != stripslashes($v)) {
+ $changedfields[$k] = $v;
+ }
+ }
+ }
+
+ // Should we allow changes to be made to this bug by this user?
+ if (STRICT_UPDATING and !($u == $buginfo['assigned_to'] or
+ $u == $buginfo['created_by'] or $perm->have_perm('Manager'))) {
+ show_bug($bugid,array('status' => $STRING['bugbadperm']));
+ return;
+ }
+
+ // Check for more than one person modifying the bug at the same time
+ if ($last_modified_date != $buginfo['last_modified_date']) {
+ show_bug($bugid, array('status' => $STRING['datecollision']));
+ return;
+ }
+
+ // Add CC if specified
+ if ($add_cc) {
+ if (!$cc_uid = $db->getOne("select user_id from ".TBL_AUTH_USER.
+ " where login = '$add_cc'")) {
+ show_bug($bugid,array('status' => $STRING['nouser']));
+ return;
}
+ $cc_already = $db->getOne('select user_id from '.TBL_BUG_CC.
+ " where bug_id = $bugid and user_id = $cc_uid");
+ if (!$cc_already && $cc_uid != $buginfo['created_by']) {
+ $db->query("insert into ".TBL_BUG_CC." (bug_id, user_id, created_by,
+ created_date) values ($bugid, $cc_uid, $u, $now)");
+ }
+ }
+
+ // Remove CCs if requested
+ if (isset($remove_cc) and $remove_cc[0]) {
+ $db->query('delete from '.TBL_BUG_CC." where bug_id = $bugid and user_id in (".
+ delimit_list(',', $remove_cc).')');
+ }
- // Remove dependency if requested
- if (!empty($del_dependency)) {
- $del_dependency = preg_replace('/\D/', '', $del_dependency);
- if (is_numeric($del_dependency)) {
- $db->query("delete from ".TBL_BUG_DEPENDENCY.
- " where bug_id = $bugid and depends_on = $del_dependency");
- }
+ // Add dependency if requested
+ if (!empty($add_dependency)) {
+ $add_dependency = preg_replace('/\D/', '', $add_dependency);
+
+ // Validate the bug number
+ if (!is_numeric($add_dependency)) {
+ show_bug($bugid, array('add_dep' => $STRING['nobug']));
+ return;
+ }
+ if (!$db->getOne('select count(*) from '.TBL_BUG." where bug_id = $add_dependency")) {
+ show_bug($bugid, array('add_dep' => $STRING['nobug']));
+ return;
}
-
- if ($comments) {
- //$comments = strip_tags($comments); -- Uncomment this if you want no <> content in the comments
- $db->query("insert into ".TBL_COMMENT." (comment_id, bug_id, comment_text, created_by, created_date)"
- ." values (".$db->nextId(TBL_COMMENT).", $bugid, ".
- $db->quote(stripslashes($comments)).", $u, $now)");
- }
-
- // Allow for removing of some items from the bug page
- $priority = $priority ? $priority : 0;
- $os_id = $os_id ? $os_id : 0;
- $severity_id = $severity_id ? $severity_id : 0;
+
+ // Check if the dependency has already been added
+ if ($db->getOne('select count(*) from '.TBL_BUG_DEPENDENCY.
+ " where bug_id = $bugid and depends_on = $add_dependency")) {
+ show_bug($bugid, array('add_dep' => $STRING['dupe_dependency']));
+ return;
+ }
+
+ // Add it
+ $db->query("insert into ".TBL_BUG_DEPENDENCY.
+ " (bug_id, depends_on) values($bugid, $add_dependency)");
+ }
- $db->query("update ".TBL_BUG." set title = ".$db->quote(stripslashes($title)).
- ', url = '.$db->quote(stripslashes($url)).", severity_id = $severity_id, ".
- "priority = $priority, status_id = $status_id, ".
- "database_id = $database_id, to_be_closed_in_version_id = $to_be_closed_in_version_id, ".
- "resolution_id = $resolution_id, assigned_to = $assigned_to, ".
- "project_id = $project_id, version_id = $version_id, ".
- "component_id = $component_id, os_id = $os_id, last_modified_by = $u, ".
- "last_modified_date = $now where bug_id = $bugid");
-
- if (count($changedfields) or !empty($comments)) {
- do_changedfields($u, $buginfo, $changedfields, $comments);
- }
- header("Location: bug.php?op=show&bugid=$bugid&pos=$pos");
+ // Remove dependency if requested
+ if (!empty($del_dependency)) {
+ $del_dependency = preg_replace('/\D/', '', $del_dependency);
+ if (is_numeric($del_dependency)) {
+ $db->query("delete from ".TBL_BUG_DEPENDENCY.
+ " where bug_id = $bugid and depends_on = $del_dependency");
+ }
+ }
+
+ if ($comments) {
+ // $comments = strip_tags($comments); -- Uncomment this if you want no <> content in the comments
+ $db->query("insert into ".TBL_COMMENT." (comment_id, bug_id, comment_text, created_by, created_date)".
+ " values (".$db->nextId(TBL_COMMENT).", $bugid, ".
+ $db->quote(stripslashes($comments)).", $u, $now)");
+ }
+
+ // Allow for removing of some items from the bug page
+ $priority = $priority ? $priority : 0;
+ $os_id = $os_id ? $os_id : 0;
+ $severity_id = $severity_id ? $severity_id : 0;
+
+ $db->query("update ".TBL_BUG." set title = ".$db->quote(stripslashes($title)).
+ ', url = '.$db->quote(stripslashes($url)).", severity_id = $severity_id, ".
+ "priority = $priority, status_id = $status_id, ".
+ "database_id = $database_id, to_be_closed_in_version_id = $to_be_closed_in_version_id, ".
+ 'closed_in_version_id = '.$closed_in_version_id.', '.
+ // 'site_id ='.$site_id.', '.
+ // -- uncomment this when bugdisplay template ready
+ "resolution_id = $resolution_id, assigned_to = $assigned_to, ".
+ "project_id = $project_id, version_id = $version_id, ".
+ "component_id = $component_id, os_id = $os_id, last_modified_by = $u, ".
+ "last_modified_date = $now where bug_id = $bugid");
+
+ if (count($changedfields) or !empty($comments)) {
+ do_changedfields($u, $buginfo, $changedfields, $comments);
+ }
+
+ header("Location: bug.php?op=show&bugid=$bugid&pos=$pos");
}
function do_form($bugid = 0) {
|
|
From: Jirka P. <fi...@us...> - 2002-06-13 15:20:24
|
Update of /cvsroot/phpbt/phpbt
In directory usw-pr-cvs1:/tmp/cvs-serv27840/phpbt
Modified Files:
bug.php
Log Message:
Update for function show_bug. Not tested.
Index: bug.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/bug.php,v
retrieving revision 1.107
retrieving revision 1.108
diff -u -r1.107 -r1.108
--- bug.php 21 May 2002 13:37:00 -0000 1.107
+++ bug.php 13 Jun 2002 15:20:21 -0000 1.108
@@ -476,29 +476,29 @@
}
function show_bug_printable($bugid) {
- global $db, $me, $t, $select, $TITLE, $QUERY, $restricted_projects;
+ global $db, $me, $t, $select, $TITLE, $QUERY, $restricted_projects;
- if (!is_numeric($bugid) or
- !$row = $db->getRow(sprintf($QUERY['bug-printable'], $bugid,
- $restricted_projects))) {
+ if (!is_numeric($bugid) or
+ !$row = $db->getRow(sprintf($QUERY['bug-printable'], $bugid,
+ $restricted_projects))) {
show_text($STRING['bugbadnum'],true);
exit;
- }
+ }
- $t->assign($row);
- $t->assign(array(
- 'bug_dependencies' => delimit_list(', ', $db->getCol('select '.
- db_concat("'<a href=\"$me?op=show&bugid='", 'depends_on', '\'">#\'',
- 'depends_on', '\'</a>\'').' from '.TBL_BUG_DEPENDENCY.
- " where bug_id = $bugid"))
+ $t->assign($row);
+ $t->assign(array(
+ 'bug_dependencies' => delimit_list(', ', $db->getCol('select '.
+ db_concat("'<a href=\"$me?op=show&bugid='", 'depends_on', '\'">#\'',
+ 'depends_on', '\'</a>\'').' from '.TBL_BUG_DEPENDENCY.
+ " where bug_id = $bugid"))
));
- // Show the comments
- $t->assign('comments', $db->getAll('select comment_text, c.created_date, login'
- .' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER
- ." where bug_id = $bugid and c.created_by = user_id order by c.created_date"));
-
- $t->wrap('bugdisplay-printable.html', 'viewbug');
+ // Show the comments
+ $t->assign('comments', $db->getAll('select comment_text, c.created_date, login'.
+ ' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER.
+ " where bug_id = $bugid and c.created_by = user_id order by c.created_date"
+ ));
+ $t->wrap('bugdisplay-printable.html', 'viewbug');
}
///
@@ -547,49 +547,49 @@
}
function show_bug($bugid = 0, $error = array()) {
- global $db, $me, $t, $STRING, $TITLE, $u, $_gv, $QUERY, $restricted_projects;
+ global $db, $me, $t, $STRING, $TITLE, $u, $_gv, $QUERY, $restricted_projects;
- if (!ereg('^[0-9]+$',$bugid) or
- !$row = $db->getRow(sprintf($QUERY['bug-show-bug'], $bugid,
- $restricted_projects))) {
- show_text($STRING['bugbadnum'],true);
- return;
- }
-
- prev_next_links($bugid, isset($_gv['pos']) ? $_gv['pos'] : 0);
- $t->assign($row);
- $t->assign(array(
- 'error' => $error,
- 'already_voted' => $db->getOne("select count(*) from ".TBL_BUG_VOTE.
- " where bug_id = $bugid and user_id = $u"),
- 'num_votes' => $db->getOne("select count(*) from ".TBL_BUG_VOTE.
- " where bug_id = $bugid"),
- 'bug_dependencies' => delimit_list(', ', $db->getCol('select '.
- db_concat("'<a href=\"$me?op=show&bugid='", 'depends_on', '\'">#\'',
- 'depends_on', '\'</a>\'').' from '.TBL_BUG_DEPENDENCY.
- " where bug_id = $bugid")),
- ));
-
- // Show the attachments
- $attachments = array();
- $rs = $db->query("select * from ".TBL_ATTACHMENT." where bug_id = $bugid");
- if ($rs->numRows()) {
- while ($rs->fetchInto($att)) {
- if (@is_readable(ATTACHMENT_PATH."/{$row['project_id']}/$bugid-{$att['file_name']}")) {
- $attachments[] = $att;
- }
+ if (!ereg('^[0-9]+$',$bugid) or
+ !$row = $db->getRow(sprintf($QUERY['bug-show-bug'], $bugid,
+ $restricted_projects))) {
+ show_text($STRING['bugbadnum'],true);
+ return;
}
- }
- // Show the comments
- $t->assign(array(
- 'attachments' => $attachments,
- 'comments' => $db->getAll('select comment_text, c.created_date, login'
- .' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER
- ." where bug_id = $bugid and c.created_by = user_id order by c.created_date")
- ));
+ prev_next_links($bugid, isset($_gv['pos']) ? $_gv['pos'] : 0);
+ $t->assign($row);
+ $t->assign(array(
+ 'error' => $error,
+ 'already_voted' => $db->getOne("select count(*) from ".TBL_BUG_VOTE.
+ " where bug_id = $bugid and user_id = $u"),
+ 'num_votes' => $db->getOne("select count(*) from ".TBL_BUG_VOTE.
+ " where bug_id = $bugid"),
+ 'bug_dependencies' => delimit_list(', ', $db->getCol('select '.
+ db_concat("'<a href=\"$me?op=show&bugid='", 'depends_on', '\'">#\'',
+ 'depends_on', '\'</a>\'').' from '.TBL_BUG_DEPENDENCY.
+ " where bug_id = $bugid")),
+ ));
+
+ // Show the attachments
+ $attachments = array();
+ $rs = $db->query("select * from ".TBL_ATTACHMENT." where bug_id = $bugid");
+ if ($rs->numRows()) {
+ while ($rs->fetchInto($att)) {
+ if (@is_readable(ATTACHMENT_PATH."/{$row['project_id']}/$bugid-{$att['file_name']}")) {
+ $attachments[] = $att;
+ }
+ }
+ }
+
+ // Show the comments
+ $t->assign(array(
+ 'attachments' => $attachments,
+ 'comments' => $db->getAll('select comment_text, c.created_date, login'.
+ ' from '.TBL_COMMENT.' c, '.TBL_AUTH_USER.
+ " where bug_id = $bugid and c.created_by = user_id order by c.created_date")
+ ));
- $t->wrap('bugdisplay.html', 'viewbug');
+ $t->wrap('bugdisplay.html', 'viewbug');
}
function show_projects() {
|
|
From: Jirka P. <fi...@us...> - 2002-06-13 15:20:24
|
Update of /cvsroot/phpbt/phpbt/inc/db In directory usw-pr-cvs1:/tmp/cvs-serv27840/phpbt/inc/db Modified Files: mysql.php Log Message: Update for function show_bug. Not tested. Index: mysql.php =================================================================== RCS file: /cvsroot/phpbt/phpbt/inc/db/mysql.php,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- mysql.php 13 Jun 2002 14:26:36 -0000 1.9 +++ mysql.php 13 Jun 2002 15:20:22 -0000 1.10 @@ -77,12 +77,14 @@ 'left join '.TBL_AUTH_USER.' lastmodifier on b.last_modified_by = lastmodifier.user_id '. 'left join '.TBL_RESOLUTION.' resolution on b.resolution_id = resolution.resolution_id, '. TBL_SEVERITY.' severity, '.TBL_STATUS.' status, '.TBL_OS.' os, '. - TBL_VERSION.' version, '.TBL_COMPONENT.' component, '.TBL_PROJECT.' project '. + TBL_VERSION.' version, '.TBL_COMPONENT.' component, '. + TBL_PROJECT.' project, '.TBL_SITE.' site '. 'where b.severity_id = severity.severity_id '. 'and b.status_id = status.status_id and b.os_id = os.os_id '. 'and b.version_id = version.version_id '. 'and b.component_id = component.component_id '. 'and b.project_id = project.project_id and %s '. + 'and b.site_id = site.site_id '. 'and bug_id <> %s '. 'order by %s %s, bug_id asc', 'bug-show-bug' => 'select b.*, reporter.login as reporter, '. @@ -91,7 +93,7 @@ 'left join '.TBL_AUTH_USER.' owner on b.assigned_to = owner.user_id '. 'left join '.TBL_AUTH_USER.' reporter on b.created_by = reporter.user_id '. 'left join '.TBL_RESOLUTION.' r on b.resolution_id = r.resolution_id, '. - TBL_SEVERITY.' sv, '.TBL_STATUS.' st '. + TBL_SEVERITY.' sv, '.TBL_STATUS.' st, '.TBL_SITE.' site '. 'where bug_id = %s and b.project_id not in (%s) '. 'and b.severity_id = sv.severity_id and b.status_id = st.status_id', 'functions-bug-cc' => 'select b.user_id, login '. |