Lines 251-257
if ( $step == 5 ) {
Link Here
|
251 |
branchcode => $branchcode, |
251 |
branchcode => $branchcode, |
252 |
categorycode => $categorycode, |
252 |
categorycode => $categorycode, |
253 |
itemtype => $itemtype, |
253 |
itemtype => $itemtype, |
254 |
maxissueqty => $maxissueqty, |
|
|
255 |
renewalsallowed => $renewalsallowed, |
254 |
renewalsallowed => $renewalsallowed, |
256 |
renewalperiod => $renewalperiod, |
255 |
renewalperiod => $renewalperiod, |
257 |
issuelength => $issuelength, |
256 |
issuelength => $issuelength, |
Lines 262-272
if ( $step == 5 ) {
Link Here
|
262 |
my $issuingrule = Koha::IssuingRule->new($params); |
261 |
my $issuingrule = Koha::IssuingRule->new($params); |
263 |
eval { $issuingrule->store; }; |
262 |
eval { $issuingrule->store; }; |
264 |
|
263 |
|
265 |
unless ($@) { |
264 |
if ($@) { |
266 |
push @messages, { code => 'success_on_insert_circ_rule' }; |
|
|
267 |
} |
268 |
else { |
269 |
push @messages, { code => 'error_on_insert_circ_rule' }; |
265 |
push @messages, { code => 'error_on_insert_circ_rule' }; |
|
|
266 |
} else { |
267 |
|
268 |
eval { |
269 |
Koha::CirculationRules->set_rules( |
270 |
{ |
271 |
categorycode => $categorycode, |
272 |
itemtype => $itemtype, |
273 |
branchcode => $branchcode, |
274 |
rules => { |
275 |
maxissueqty => $maxissueqty, |
276 |
} |
277 |
} |
278 |
); |
279 |
}; |
280 |
|
281 |
unless ($@) { |
282 |
push @messages, { code => 'success_on_insert_circ_rule' }; |
283 |
} |
284 |
else { |
285 |
push @messages, { code => 'error_on_insert_circ_rule' }; |
286 |
} |
270 |
} |
287 |
} |
271 |
} |
288 |
} |
272 |
|
289 |
|
273 |
- |
|
|