Bug 4133 Ensure that orders have a valid quantity received
[koha.git] / test.pl
blobe4bab7b4205b84e8aa4a068da72fb8bb7066d7e9
1 #!/usr/bin/perl
3 use strict;
4 use warnings;
6 my $string = $ARGV[0];
8 # Getting the marcfields as an array
9 my @marcfieldsarray = split('\|', $string);
11 # Separating the marcfields from the the user-supplied headers
12 my @marcfields;
13 foreach (@marcfieldsarray) {
14 my @result = split('=', $_);
15 if (scalar(@result) == 2) {
16 push @marcfields, { header => $result[0], field => $result[1] };
17 } else {
18 push @marcfields, { field => $result[0] }
22 use Data::Dumper;
23 print Dumper(@marcfields);
26 foreach (@marcfields) {
27 print $_->{field};