Changeset 1232 for trunk


Ignore:
Timestamp:
04/19/13 17:19:20 (11 years ago)
Author:
nanardon
Message:

take care to multivalue attributes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LATMOS-Accounts-Web/lib/LATMOS/Accounts/Web/Controller/Create.pm

    r1105 r1232  
    4444    } 
    4545    foreach my $attr (@{$info->{ask} || []}) { 
    46         $info->{contents}{$attr} = $c->req->param($form->attr_field_name($attr)); 
     46        my @vals = $c->req->param($form->attr_field_name($attr)); 
     47        $info->{contents}{$attr} = @vals > 1 ? \@vals : $vals[0]; 
    4748    } 
    4849    my $ochelper = $base->ochelper($otype); 
Note: See TracChangeset for help on using the changeset viewer.