Lines 44-55
my $budgetid = C4::Budgets::AddBudget(
Link Here
|
44 |
my $budget = C4::Budgets::GetBudget( $budgetid ); |
44 |
my $budget = C4::Budgets::GetBudget( $budgetid ); |
45 |
|
45 |
|
46 |
my $bibrec1 = MARC::Record->new(); |
46 |
my $bibrec1 = MARC::Record->new(); |
47 |
$bibrec1->append_fields( |
47 |
if (C4::Context->preference('marcflavour') eq 'UNIMARC') { |
48 |
MARC::Field->new('020', '', '', 'a' => '1234567890'), |
48 |
$bibrec1->append_fields( |
49 |
MARC::Field->new('100', '', '', 'a' => 'Shakespeare, Billy'), |
49 |
MARC::Field->new('010', '', '', 'a' => '1234567890'), |
50 |
MARC::Field->new('245', '', '', 'a' => 'Bug 8854'), |
50 |
MARC::Field->new('200', '', '', 'f' => 'Shakespeare, Billy'), |
51 |
MARC::Field->new('260', '', '', 'b' => 'Scholastic Publishing', c => 'c2012'), |
51 |
MARC::Field->new('200', '', '', 'a' => 'Bug 8854'), |
52 |
); |
52 |
MARC::Field->new('210', '', '', 'c' => 'Scholastic Publishing', d => '2012'), |
|
|
53 |
); |
54 |
} else { |
55 |
$bibrec1->append_fields( |
56 |
MARC::Field->new('020', '', '', 'a' => '1234567890'), |
57 |
MARC::Field->new('100', '', '', 'a' => 'Shakespeare, Billy'), |
58 |
MARC::Field->new('245', '', '', 'a' => 'Bug 8854'), |
59 |
MARC::Field->new('260', '', '', 'b' => 'Scholastic Publishing', c => '2012'), |
60 |
); |
61 |
} |
62 |
|
53 |
my ($biblionumber1, $biblioitemnumber1) = AddBiblio($bibrec1, ''); |
63 |
my ($biblionumber1, $biblioitemnumber1) = AddBiblio($bibrec1, ''); |
54 |
my ($biblionumber2, $biblioitemnumber2) = AddBiblio(MARC::Record->new, ''); |
64 |
my ($biblionumber2, $biblioitemnumber2) = AddBiblio(MARC::Record->new, ''); |
55 |
my ($biblionumber3, $biblioitemnumber3) = AddBiblio(MARC::Record->new, ''); |
65 |
my ($biblionumber3, $biblioitemnumber3) = AddBiblio(MARC::Record->new, ''); |
Lines 62-68
my $order1 = Koha::Acquisition::Order->new(
Link Here
|
62 |
budget_id => $budget->{budget_id}, |
72 |
budget_id => $budget->{budget_id}, |
63 |
} |
73 |
} |
64 |
)->store; |
74 |
)->store; |
65 |
my $ordernumber1 = $order1->ordernumber; |
|
|
66 |
|
75 |
|
67 |
my $order2 = Koha::Acquisition::Order->new( |
76 |
my $order2 = Koha::Acquisition::Order->new( |
68 |
{ |
77 |
{ |
Lines 72-78
my $order2 = Koha::Acquisition::Order->new(
Link Here
|
72 |
budget_id => $budget->{budget_id}, |
81 |
budget_id => $budget->{budget_id}, |
73 |
} |
82 |
} |
74 |
)->store; |
83 |
)->store; |
75 |
my $ordernumber2 = $order2->ordernumber; |
|
|
76 |
|
84 |
|
77 |
my $order3 = Koha::Acquisition::Order->new( |
85 |
my $order3 = Koha::Acquisition::Order->new( |
78 |
{ |
86 |
{ |
Lines 84-90
my $order3 = Koha::Acquisition::Order->new(
Link Here
|
84 |
rrp => 42, |
92 |
rrp => 42, |
85 |
} |
93 |
} |
86 |
)->store; |
94 |
)->store; |
87 |
my $ordernumber3 = $order3->ordernumber; |
|
|
88 |
|
95 |
|
89 |
my $invoiceid1 = AddInvoice(invoicenumber => 'invoice1', booksellerid => $booksellerid, unknown => "unknown"); |
96 |
my $invoiceid1 = AddInvoice(invoicenumber => 'invoice1', booksellerid => $booksellerid, unknown => "unknown"); |
90 |
my $invoiceid2 = AddInvoice(invoicenumber => 'invoice2', booksellerid => $booksellerid, unknown => "unknown", |
97 |
my $invoiceid2 = AddInvoice(invoicenumber => 'invoice2', booksellerid => $booksellerid, unknown => "unknown", |