|
Lines 991-1009
sub add_request {
Link Here
|
| 991 |
if column_exists( 'illrequests', 'batch_id' ); |
991 |
if column_exists( 'illrequests', 'batch_id' ); |
| 992 |
$request->store; |
992 |
$request->store; |
| 993 |
|
993 |
|
| 994 |
while ( my ( $type, $value ) = each %{$request_details} ) { |
994 |
my @request_details_array = map { |
| 995 |
if ( $value && length $value > 0 ) { |
995 |
{ |
| 996 |
Koha::ILL::Request::Attribute->new( |
996 |
'type' => $_, |
| 997 |
{ |
997 |
'value' => $request_details->{$_}, |
| 998 |
illrequest_id => $request->illrequest_id, |
|
|
| 999 |
column_exists( 'illrequestattributes', 'backend' ) ? ( backend => "Standard" ) : (), |
| 1000 |
type => $type, |
| 1001 |
value => $value, |
| 1002 |
readonly => 0 |
| 1003 |
} |
| 1004 |
)->store; |
| 1005 |
} |
998 |
} |
| 1006 |
} |
999 |
} keys %{$request_details}; |
|
|
1000 |
$request->extended_attributes( \@request_details_array ); |
| 1007 |
|
1001 |
|
| 1008 |
return $request; |
1002 |
return $request; |
| 1009 |
} |
1003 |
} |
| 1010 |
- |
|
|