View | Details | Raw Unified | Return to bug 30070
Collapse All | Expand All

(-)a/Koha/Edifact/File.pm (-6 / +7 lines)
Lines 38-44 Returns the I<Koha::Acquisition::Bookseller> associated with this edifact file Link Here
38
sub vendor {
38
sub vendor {
39
    my ($self) = @_;
39
    my ($self) = @_;
40
    my $vendor_rs = $self->_result->vendor;
40
    my $vendor_rs = $self->_result->vendor;
41
    return Koha::Acquisition::Bookseller->_new_from_dbic( $vendor_rs );
41
    return unless $vendor_rs;
42
    return Koha::Acquisition::Bookseller->_new_from_dbic($vendor_rs);
42
}
43
}
43
44
44
=head3 basket
45
=head3 basket
Lines 50-58 Returns the I<Koha::Acquisition::Basket> associated with this edifact file. Link Here
50
=cut
51
=cut
51
52
52
sub basket {
53
sub basket {
53
    my ( $self )  = @_;
54
    my ($self) = @_;
54
    my $basket_rs = $self->_result->basketno;
55
    my $basket_rs = $self->_result->basketno;
55
    return Koha::Acquisition::Basket->_new_from_dbic( $basket_rs );
56
    return unless $basket_rs;
57
    return Koha::Acquisition::Basket->_new_from_dbic($basket_rs);
56
}
58
}
57
59
58
=head3 to_api_mapping
60
=head3 to_api_mapping
Lines 64-71 on the API. Link Here
64
66
65
sub to_api_mapping {
67
sub to_api_mapping {
66
    return {
68
    return {
67
        message_type  => 'type',
69
        message_type => 'type',
68
        basketno => 'basket_id',
70
        basketno     => 'basket_id',
69
    };
71
    };
70
}
72
}
71
73
72
- 

Return to bug 30070