From: djfiander Date: Sun, 2 Nov 2008 19:40:44 +0000 (+0000) Subject: Add (untested) support for including public notes and gap X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=610d71d6bc292c5844b2163b395e3fb6e6175640;p=Evergreen.git Add (untested) support for including public notes and gap indicators in the formatted holding display. git-svn-id: svn://svn.open-ils.org/ILS/trunk@11023 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Utils/MFHD/Holding.pm b/Open-ILS/src/perlmods/OpenILS/Utils/MFHD/Holding.pm index 0ce0fe008d..a29498d76a 100755 --- a/Open-ILS/src/perlmods/OpenILS/Utils/MFHD/Holding.pm +++ b/Open-ILS/src/perlmods/OpenILS/Utils/MFHD/Holding.pm @@ -35,10 +35,10 @@ sub new { } elsif ($key =~ /[i-m]/) { $self->{CHRON}->{$key} = $val; if (!exists $caption->{CHRONS}->{$key}) { - carp "Holding specified enumeration level '$key' not included in caption $caption->{LINK}"; + warn "Holding '$seqno' specified enumeration level '$key' not included in caption $caption->{LINK}"; } } elsif ($key eq 'o') { - carp '$o specified prior to first enumeration' + warn '$o specified prior to first enumeration' unless defined($last_enum); $self->{ENUMS}->{$last_enum}->{UNIT} = $val; $last_enum = undef; @@ -79,6 +79,18 @@ sub format { } } + # Public Note + $str .= ' '. $caption->{ENUMS}->{'z'} if (exists $caption->{ENUMS}->{'z'}); + + # Breaks in the sequence + if ($self->{BREAK} eq 'n') { + $str .= ' non-gap break'; + } elsif ($self->{BREAK} eq 'g') { + $str .= ' gap'; + } elsif ($self->{BREAK}) { + warn "unrecognized break indicator '$self->{BREAK}'"; + } + return $str; }