https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17371

--- Comment #7 from Jiri Kozlovsky <[email protected]> ---
Comment on attachment 55898
  --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=55898
Bug 17371 - REST API: add CRUD for biblios

Review of attachment 55898:
 --> 
(https://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=17371&attachment=55898)
-----------------------------------------------------------------

Nice work by the way!

::: Koha/REST/V1/Biblio.pm
@@ +45,5 @@
> +    my $biblio = Koha::Biblios->find($args->{biblionumber});
> +    unless ($biblio) {
> +        return $c->$cb({error => "Biblio not found"}, 404);
> +    }
> +    return $c->$cb({ biblio => $biblio->unblessed, items => 
> $biblio->items->unblessed }, 200);

Does this respect OpacHiddenItems preference?

@@ +79,5 @@
> +
> +        # mark as onhold if item marked as hold
> +        if (scalar(@{$holds}) > 0) {
> +            $item->{status} = "onhold";
> +        }

I'm missing the next statement after one of the conditions succeeds. I can see
no reason to check for another condition, which can result in not necessary DB
querying.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to