Lines 204-209
sub require_params {
Link Here
|
204 |
return @values; |
204 |
return @values; |
205 |
} |
205 |
} |
206 |
|
206 |
|
|
|
207 |
=head2 optional_params |
208 |
|
209 |
my @values = C4::Service->optional_params( @params ); |
210 |
|
211 |
Check that each of of the parameters specified in @params was sent in the |
212 |
request, then return their values in that order. If any were not sent in |
213 |
the request, undef is returned for that value. |
214 |
|
215 |
=cut |
216 |
|
217 |
sub optional_params { |
218 |
my ( $class, @params ) = @_; |
219 |
|
220 |
my @values; |
221 |
|
222 |
for my $param ( @params ) { |
223 |
if ( !defined( $query->param( $param ) ) ) { |
224 |
push @values, undef; |
225 |
} else { |
226 |
push @values, $query->param( $param ); |
227 |
} |
228 |
} |
229 |
|
230 |
return @values; |
231 |
} |
232 |
|
207 |
=head2 dispatch |
233 |
=head2 dispatch |
208 |
|
234 |
|
209 |
C4::Service->dispatch( |
235 |
C4::Service->dispatch( |
210 |
- |
|
|