Skip to content

Commit

Permalink
Fixed user update bug with both timestamps being set.
Browse files Browse the repository at this point in the history
git-svn-id: http://mantisbt.svn.sourceforge.net/svnroot/mantisbt/trunk@65 f5dc347c-c33d-0410-90a0-b07cc1902cb9
  • Loading branch information
Kenzaburo Ito committed Dec 11, 2000
1 parent 694bc5f commit 5757ed0
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
4 changes: 3 additions & 1 deletion ChangeLog
Expand Up @@ -35,10 +35,12 @@ To Do:
* Added 'feedback' status - indicates that it requires more information
* Added show Mantis version capability
* Fixed bug with Bugnote Add button showing up in the wrong places
* Fixed bug with SQL queries updating both submitted and last updated dates on bugs
* Fixed bug with SQL queries updating both submitted and last access dates on users
* Modified version to be an enum.
* Modified ordering methods in manage account
* Modified viewing preferences
* Made enum displays (category, status, etc) easier to maintain via print_lists();
* Made enum displays (category, status, etc) easier to maintain via print_lists()
* Renamed access_level_check_greater() to access_level_check_greater_or_equal()
* Renamed $g_bug_view_all_page $g_bug_view_all_page $g_bug_view_all_page
to $g_view_bug_all_page $g_view_bug_page $g_view_bug_advanced_page
Expand Down
10 changes: 9 additions & 1 deletion core_API.php
Expand Up @@ -369,9 +369,17 @@ function login_cookie_check( $p_redirect_url="" ) {
header( "Location: $g_logout_page" );
}

### grab creation date to protect from change
### Suspect a bug in mysql.. not sure. Same deal for bug updates
$query = "SELECT date_created
FROM $g_mantis_user_table
WHERE cookie_string='$g_string_cookie_val'";
$result = mysql_query( $query );
$t_date_created = mysql_result( $result, 0 );

### update last_visit date
$query = "UPDATE $g_mantis_user_table
SET last_visit=NOW()
SET last_visit=NOW(), date_created='$t_date_created'
WHERE cookie_string='$g_string_cookie_val'";
$result = mysql_query( $query );
db_mysql_close();
Expand Down
2 changes: 1 addition & 1 deletion view_bug_all_page.php3
Expand Up @@ -90,7 +90,7 @@
<? print_list( "status", $f_show_status ) ?>
</select>
Show: <input type=text name=f_limit_view size=3 maxlength=7 value="<? echo $f_limit_view ?>">
Changed: <input type=text name=f_show_changed size=3 maxlength=7 value="<? echo $f_show_changed ?>">
Changed(hrs): <input type=text name=f_show_changed size=3 maxlength=7 value="<? echo $f_show_changed ?>">
<input type=submit value=" Filter ">
</td>
</form>
Expand Down

0 comments on commit 5757ed0

Please sign in to comment.