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

(-)a/Koha/ILL/Backend/Standard.pm (+2 lines)
Lines 1017-1022 sub add_request { Link Here
1017
    $request->extended_attributes( \@request_details_array );
1017
    $request->extended_attributes( \@request_details_array );
1018
    $request->add_unauthenticated_data( $params->{other} ) if $unauthenticated_request;
1018
    $request->add_unauthenticated_data( $params->{other} ) if $unauthenticated_request;
1019
1019
1020
    $request->after_created;
1021
1020
    return $request;
1022
    return $request;
1021
}
1023
}
1022
1024
(-)a/Koha/ILL/Request.pm (-1 / +53 lines)
Lines 925-930 sub mark_completed { Link Here
925
        $self->status('COMP');
925
        $self->status('COMP');
926
        $self->status_alias( $params->{status_alias} ) if $params->{status_alias};
926
        $self->status_alias( $params->{status_alias} ) if $params->{status_alias};
927
        $self->completed( dt_from_string() );
927
        $self->completed( dt_from_string() );
928
        $self->after_completed();
928
        $self->store;
929
        $self->store;
929
        return {
930
        return {
930
            stage => 'commit',
931
            stage => 'commit',
Lines 2142-2147 sub store { Link Here
2142
    return $ret;
2143
    return $ret;
2143
}
2144
}
2144
2145
2146
=head3 after_completed
2147
2148
    $request->after_completed;
2149
2150
Actions to be done after the request has been completed
2151
2152
=cut
2153
2154
sub after_completed {
2155
    my ($self) = @_;
2156
2157
    C4::Stats::UpdateStats(
2158
        {
2159
            borrowernumber => $self->borrowernumber // undef,
2160
            branch         => $self->branchcode,
2161
            categorycode   => $self->patron ? $self->patron->categorycode : undef,
2162
            ccode          => undef,
2163
            illrequest_id  => $self->illrequest_id,
2164
            itemnumber     => undef,
2165
            itemtype       => undef,
2166
            location       => undef,
2167
            type           => 'illreq_comp',
2168
        }
2169
    );
2170
}
2171
2172
=head3 after_created
2173
2174
    $request->after_created;
2175
2176
Actions to be done after the request has been fully created
2177
2178
=cut
2179
2180
sub after_created {
2181
    my ($self) = @_;
2182
2183
    C4::Stats::UpdateStats(
2184
        {
2185
            borrowernumber => $self->borrowernumber // undef,
2186
            branch         => $self->branchcode,
2187
            categorycode   => $self->patron ? $self->patron->categorycode : undef,
2188
            ccode          => undef,
2189
            illrequest_id  => $self->illrequest_id,
2190
            itemnumber     => undef,
2191
            itemtype       => undef,
2192
            location       => undef,
2193
            type           => 'illreq_created',
2194
        }
2195
    );
2196
}
2197
2145
=head3 requested_partners
2198
=head3 requested_partners
2146
2199
2147
    my $partners_string = $request->requested_partners;
2200
    my $partners_string = $request->requested_partners;
2148
- 

Return to bug 37901