/[webpac2]/trunk/lib/WebPAC/Normalize.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/lib/WebPAC/Normalize.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 317 by dpavlin, Fri Dec 23 21:37:05 2005 UTC revision 333 by dpavlin, Sat Dec 31 13:42:11 2005 UTC
# Line 470  sub fill_in { Line 470  sub fill_in {
470          }          }
471    
472          my $found = 0;          my $found = 0;
473            my $just_single = 1;
474    
475          my $eval_code;          my $eval_code;
476          # remove eval{...} from beginning          # remove eval{...} from beginning
# Line 481  sub fill_in { Line 482  sub fill_in {
482    
483          # do actual replacement of placeholders          # do actual replacement of placeholders
484          # repeatable fields          # repeatable fields
485          $format =~ s/v(\d+)(?:\^(\w))?/$self->get_data(\$rec,$1,$2,$i,\$found)/ges;          if ($format =~ s/v(\d+)(?:\^(\w))?/$self->get_data(\$rec,$1,$2,$i,\$found)/ges) {
486                    $just_single = 0;
487            }
488            
489          # non-repeatable fields          # non-repeatable fields
490          $format =~ s/s(\d+)(?:\^(\w))?/$self->get_data(\$rec,$1,$2,0,\$found)/ges;          if ($format =~ s/s(\d+)(?:\^(\w))?/$self->get_data(\$rec,$1,$2,0,\$found)/ges) {
491                    return if ($i > 0 && $just_single);
492            }
493    
494          if ($found) {          if ($found) {
495                  $log->debug("format: $format");                  $log->debug("format: $format");

Legend:
Removed from v.317  
changed lines
  Added in v.333

  ViewVC Help
Powered by ViewVC 1.1.26