View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0019638 | mantisbt | filters | public | 2015-04-19 08:26 | 2015-09-06 17:37 |
Reporter | atrol | Assigned To | dregad | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 1.3.0-beta.3 | ||||
Target Version | 1.3.0-beta.3 | Fixed in Version | 1.3.0-beta.3 | ||
Summary | 0019638: Filtering by users throws error | ||||
Description | Filtering by "Reporter", "Monitored By" or "Assigned To" does no longer work but throws error APPLICATION ERROR 0000401 | ||||
Tags | No tags attached. | ||||
No time for a deeper look at the moment. Might be a side effect from 0019574. |
|
Reminder sent to: dregad You missed at least to change this part of function print_user_option_list |
|
Oops. Bad testing. That being said, I never thought about this case, because the function's documentation doesn't mention that $p_user_id can actually be an array of IDs... |
|
??
After this change you can no longer index the array by integer i starting from 0 |
|
No, git bisect indicates that the problem is caused by commit 1ddb4008, which is the logic adding the user to the list. When called from bug edit page, we have a single user id (integer), but filters send an array of user id's, so user_get_row chokes. |
|
Which doesn't necessarily mean that there isn't also a problem with the loop as well, I'll test that. |
|
Yep, it's an issue as well, but only when printing a user list for All Projects - the selection list turns out blank, unless there happen to be users with IDs matching the $i sequence number (which was actually the case in my dev box, so I didn't notice the problem). Good catch ! |
|
Just updated the tracker, seems to work properly now. Let me know if you find other issues. |
|
Looks good at first sight. |
|
MantisBT: master feb65adc 2015-04-20 14:51 Details Diff |
Fix printing user lists from filters Commit 1ddb400815dd847adbb302f1dda9b1fe3fdc5945 introduced a regression, preventing the users list from being printed on view_all_bug_page.php. This is due to the fact that when called by filters, $p_user_id is actually an array of id's, a case that was not documented and not considered when developping the fix for issue 0017574. Fixes 0019638 |
Affected Issues 0017574, 0019638 |
|
mod - core/print_api.php | Diff File | ||
MantisBT: master e2391f6f 2015-04-20 15:10 Details Diff |
Fix regression printing user lists for all projects This was introduced by commit c0976d063973a97b1ba4a5c3b017d3b3ddab59bc (see issue 0019574); the while loop used to build the associative array to remove duplicate users from the list failed to take into consideration that the array returned by project_get_all_user_rows() is no longer 0-based... Fixes 0019638 |
Affected Issues 0019574, 0019638 |
|
mod - core/print_api.php | Diff File |