List:Eventum General Discussion« Previous MessageNext Message »
From:Bryan Alsdorf Date:March 16 2005 1:58am
Subject:Re: Bug updating an issue
View as plain text  
I thought I had fixed that, but I guess I didn't. It is fixed now in 
bitkeeper and will be in 1.5.2

Regards,
/bryan

Jeffrey D. Wheelhouse wrote:
> I'm still getting this on pages where the issue is not assigned to 
> anyone.  The browser is Firefox and it does not appear to be submitting 
> the empty list if the assignments[] field is not populated.
> 
> Here's the HTML it's parsing:
> 
> <input type="hidden" name="keep_assignments" value="no">
> <select size="4" multiple class="default" name="assignments[]" 
> onChange="javascript:showSelections('update_form', 'assignments[]');">
> <option label="Jeff Wheelhouse" value="2">Jeff Wheelhouse</option>
> <option label="..." value="9">...</option>
> <option label="..." value="12">...</option>
> <option label="..." value="14">...</option>
> <option label="..." value="13">...</option>
> </select>
> 
> If I have even one person on the issue, it's fine.
> 
> The patch below seems to handle it.
> 
> Jeff
> 
> --- orig/include/class.issue.php
> +++ mod/include/class.issue.php
> @@ -1060,7 +1060,9 @@
>          if (@$HTTP_POST_VARS["keep_assignments"] == "no") {
>              // only change the issue-user associations if there really 
> were any changes
>              $old_assignees = $current['assigned_users'];
> -            $new_assignees = @$HTTP_POST_VARS['assignments'];
> +            if (isset($HTTP_POST_VARS['assignments']))
> +              $new_assignees = @$HTTP_POST_VARS['assignments'];
> +            else $new_assignees = array();
>              $assignment_notifications = array();
> 
>              // remove people from the assignment list, if appropriate
> 
> 

-- 
Bryan Alsdorf, Software Engineer
MySQL AB, www.mysql.com

Are you MySQL certified?  www.mysql.com/certification
Thread
Bug updating an issueJeffrey D. Wheelhouse13 Mar
  • RE: Bug updating an issueJoao Prado Maia14 Mar
    • Re: Bug updating an issueJeffrey D. Wheelhouse14 Mar
      • Re: Bug updating an issueBryan Alsdorf14 Mar
        • Re: Bug updating an issueElan Ruusamäe14 Mar
          • Re: Bug updating an issueJeffrey D. Wheelhouse14 Mar
          • RE: Bug updating an issueJoao Prado Maia14 Mar
            • Re: Bug updating an issueJeffrey D. Wheelhouse15 Mar
              • Re: Bug updating an issueBryan Alsdorf16 Mar
      • RE: Bug updating an issueJoao Prado Maia14 Mar