View | Details | Raw Unified | Return to bug 38061
Collapse All | Expand All

(-)a/C4/Serials.pm (-97 / +103 lines)
Lines 325-331 sub GetFullSubscription { Link Here
325
            aqbooksellers.name as aqbooksellername,
325
            aqbooksellers.name as aqbooksellername,
326
            biblio.title as bibliotitle,
326
            biblio.title as bibliotitle,
327
            subscription.branchcode AS branchcode,
327
            subscription.branchcode AS branchcode,
328
            subscription.subscriptionid AS subscriptionid
328
            subscription.subscriptionid AS subscriptionid,
329
            subscription.preselect_issues_in_collections_table AS preselect_issues_in_collections_table
329
  FROM      serial 
330
  FROM      serial 
330
  LEFT JOIN subscription ON 
331
  LEFT JOIN subscription ON 
331
          (serial.subscriptionid=subscription.subscriptionid )
332
          (serial.subscriptionid=subscription.subscriptionid )
Lines 370-376 sub PrepareSerialsData { Link Here
370
371
371
    foreach my $subs ( @{$lines} ) {
372
    foreach my $subs ( @{$lines} ) {
372
        $subs->{ "status" . $subs->{'status'} } = 1;
373
        $subs->{ "status" . $subs->{'status'} } = 1;
373
        if ( grep { $_ == $subs->{status} } ( EXPECTED, LATE, MISSING_STATUSES, CLAIMED ) ) {
374
        if ( $subs->{preselect_issues_in_collections_table} && grep { $_ == $subs->{status} }
375
            ( EXPECTED, LATE, MISSING_STATUSES, CLAIMED ) )
376
        {
374
            $subs->{"checked"} = 1;
377
            $subs->{"checked"} = 1;
375
        }
378
        }
376
        if ($add_itemnumbers) {
379
        if ($add_itemnumbers) {
Lines 470-476 sub GetFullSubscriptionsFromBiblionumber { Link Here
470
            biblio.title as bibliotitle,
473
            biblio.title as bibliotitle,
471
            subscription.branchcode AS branchcode,
474
            subscription.branchcode AS branchcode,
472
            subscription.subscriptionid AS subscriptionid,
475
            subscription.subscriptionid AS subscriptionid,
473
            subscription.location AS location
476
            subscription.location AS location,
477
            subscription.preselect_issues_in_collections_table AS preselect_issues_in_collections_table
474
  FROM      serial 
478
  FROM      serial 
475
  LEFT JOIN subscription ON 
479
  LEFT JOIN subscription ON 
476
          (serial.subscriptionid=subscription.subscriptionid)
480
          (serial.subscriptionid=subscription.subscriptionid)
Lines 1341-1398 returns the number of rows affected Link Here
1341
1345
1342
sub ModSubscription {
1346
sub ModSubscription {
1343
    my (
1347
    my (
1344
        $auser,         $branchcode,       $aqbooksellerid,    $cost,          $aqbudgetid, $startdate,
1348
        $auser,         $branchcode,      $aqbooksellerid,    $cost,          $aqbudgetid, $startdate,
1345
        $periodicity,   $firstacquidate,   $irregularity,      $numberpattern, $locale,
1349
        $periodicity,   $firstacquidate,  $irregularity,      $numberpattern, $locale,
1346
        $numberlength,  $weeklength,       $monthlength,       $lastvalue1,    $innerloop1,
1350
        $numberlength,  $weeklength,      $monthlength,       $lastvalue1,    $innerloop1,
1347
        $lastvalue2,    $innerloop2,       $lastvalue3,        $innerloop3,    $status,
1351
        $lastvalue2,    $innerloop2,      $lastvalue3,        $innerloop3,    $status,
1348
        $biblionumber,  $callnumber,       $notes,             $letter,        $manualhistory,
1352
        $biblionumber,  $callnumber,      $notes,             $letter,        $manualhistory,
1349
        $internalnotes, $serialsadditems,  $staffdisplaycount, $opacdisplaycount,
1353
        $internalnotes, $serialsadditems, $staffdisplaycount, $opacdisplaycount,
1350
        $graceperiod,   $location,         $enddate,           $subscriptionid, $skip_serialseq,
1354
        $graceperiod,   $location,        $enddate,           $subscriptionid, $skip_serialseq,
1351
        $itemtype,      $previousitemtype, $mana_id,           $ccode,          $published_on_template
1355
        $itemtype, $previousitemtype, $mana_id, $ccode, $published_on_template, $preselect_issues_in_collections_table
1352
    ) = @_;
1356
    ) = @_;
1353
1357
1354
    my $subscription = Koha::Subscriptions->find($subscriptionid);
1358
    my $subscription = Koha::Subscriptions->find($subscriptionid);
1355
    $subscription->set(
1359
    $subscription->set(
1356
        {
1360
        {
1357
            librarian             => $auser,
1361
            librarian                             => $auser,
1358
            branchcode            => $branchcode,
1362
            branchcode                            => $branchcode,
1359
            aqbooksellerid        => $aqbooksellerid,
1363
            aqbooksellerid                        => $aqbooksellerid,
1360
            cost                  => $cost,
1364
            cost                                  => $cost,
1361
            aqbudgetid            => $aqbudgetid,
1365
            aqbudgetid                            => $aqbudgetid,
1362
            biblionumber          => $biblionumber,
1366
            biblionumber                          => $biblionumber,
1363
            startdate             => $startdate,
1367
            startdate                             => $startdate,
1364
            periodicity           => $periodicity,
1368
            periodicity                           => $periodicity,
1365
            numberlength          => $numberlength,
1369
            numberlength                          => $numberlength,
1366
            weeklength            => $weeklength,
1370
            weeklength                            => $weeklength,
1367
            monthlength           => $monthlength,
1371
            monthlength                           => $monthlength,
1368
            lastvalue1            => $lastvalue1,
1372
            lastvalue1                            => $lastvalue1,
1369
            innerloop1            => $innerloop1,
1373
            innerloop1                            => $innerloop1,
1370
            lastvalue2            => $lastvalue2,
1374
            lastvalue2                            => $lastvalue2,
1371
            innerloop2            => $innerloop2,
1375
            innerloop2                            => $innerloop2,
1372
            lastvalue3            => $lastvalue3,
1376
            lastvalue3                            => $lastvalue3,
1373
            innerloop3            => $innerloop3,
1377
            innerloop3                            => $innerloop3,
1374
            status                => $status,
1378
            status                                => $status,
1375
            notes                 => $notes,
1379
            notes                                 => $notes,
1376
            letter                => $letter,
1380
            letter                                => $letter,
1377
            firstacquidate        => $firstacquidate,
1381
            firstacquidate                        => $firstacquidate,
1378
            irregularity          => $irregularity,
1382
            irregularity                          => $irregularity,
1379
            numberpattern         => $numberpattern,
1383
            numberpattern                         => $numberpattern,
1380
            locale                => $locale,
1384
            locale                                => $locale,
1381
            callnumber            => $callnumber,
1385
            callnumber                            => $callnumber,
1382
            manualhistory         => $manualhistory,
1386
            manualhistory                         => $manualhistory,
1383
            internalnotes         => $internalnotes,
1387
            internalnotes                         => $internalnotes,
1384
            serialsadditems       => $serialsadditems,
1388
            serialsadditems                       => $serialsadditems,
1385
            staffdisplaycount     => $staffdisplaycount,
1389
            staffdisplaycount                     => $staffdisplaycount,
1386
            opacdisplaycount      => $opacdisplaycount,
1390
            opacdisplaycount                      => $opacdisplaycount,
1387
            graceperiod           => $graceperiod,
1391
            graceperiod                           => $graceperiod,
1388
            location              => $location,
1392
            location                              => $location,
1389
            enddate               => $enddate,
1393
            enddate                               => $enddate,
1390
            skip_serialseq        => $skip_serialseq,
1394
            skip_serialseq                        => $skip_serialseq,
1391
            itemtype              => $itemtype,
1395
            itemtype                              => $itemtype,
1392
            previousitemtype      => $previousitemtype,
1396
            previousitemtype                      => $previousitemtype,
1393
            mana_id               => $mana_id,
1397
            mana_id                               => $mana_id,
1394
            ccode                 => $ccode,
1398
            ccode                                 => $ccode,
1395
            published_on_template => $published_on_template,
1399
            published_on_template                 => $published_on_template,
1400
            preselect_issues_in_collections_table => $preselect_issues_in_collections_table,
1396
        }
1401
        }
1397
    )->store;
1402
    )->store;
1398
1403
Lines 1425-1482 the id of this new subscription Link Here
1425
1430
1426
sub NewSubscription {
1431
sub NewSubscription {
1427
    my (
1432
    my (
1428
        $auser,           $branchcode,        $aqbooksellerid,   $cost,          $aqbudgetid, $biblionumber,
1433
        $auser,                 $branchcode,        $aqbooksellerid,   $cost,          $aqbudgetid, $biblionumber,
1429
        $startdate,       $periodicity,       $numberlength,     $weeklength,    $monthlength,
1434
        $startdate,             $periodicity,       $numberlength,     $weeklength,    $monthlength,
1430
        $lastvalue1,      $innerloop1,        $lastvalue2,       $innerloop2,    $lastvalue3,
1435
        $lastvalue1,            $innerloop1,        $lastvalue2,       $innerloop2,    $lastvalue3,
1431
        $innerloop3,      $status,            $notes,            $letter,        $firstacquidate, $irregularity,
1436
        $innerloop3,            $status,            $notes,            $letter,        $firstacquidate, $irregularity,
1432
        $numberpattern,   $locale,            $callnumber,       $manualhistory, $internalnotes,
1437
        $numberpattern,         $locale,            $callnumber,       $manualhistory, $internalnotes,
1433
        $serialsadditems, $staffdisplaycount, $opacdisplaycount, $graceperiod,
1438
        $serialsadditems,       $staffdisplaycount, $opacdisplaycount, $graceperiod,
1434
        $location,        $enddate,           $skip_serialseq,   $itemtype, $previousitemtype, $mana_id, $ccode,
1439
        $location,              $enddate,           $skip_serialseq,   $itemtype, $previousitemtype, $mana_id, $ccode,
1435
        $published_on_template,
1440
        $published_on_template, $preselect_issues_in_collections_table
1436
    ) = @_;
1441
    ) = @_;
1437
    my $dbh = C4::Context->dbh;
1442
    my $dbh = C4::Context->dbh;
1438
1443
1439
    my $subscription = Koha::Subscription->new(
1444
    my $subscription = Koha::Subscription->new(
1440
        {
1445
        {
1441
            librarian             => $auser,
1446
            librarian                             => $auser,
1442
            branchcode            => $branchcode,
1447
            branchcode                            => $branchcode,
1443
            aqbooksellerid        => $aqbooksellerid,
1448
            aqbooksellerid                        => $aqbooksellerid,
1444
            cost                  => $cost,
1449
            cost                                  => $cost,
1445
            aqbudgetid            => $aqbudgetid,
1450
            aqbudgetid                            => $aqbudgetid,
1446
            biblionumber          => $biblionumber,
1451
            biblionumber                          => $biblionumber,
1447
            startdate             => $startdate,
1452
            startdate                             => $startdate,
1448
            periodicity           => $periodicity,
1453
            periodicity                           => $periodicity,
1449
            numberlength          => $numberlength,
1454
            numberlength                          => $numberlength,
1450
            weeklength            => $weeklength,
1455
            weeklength                            => $weeklength,
1451
            monthlength           => $monthlength,
1456
            monthlength                           => $monthlength,
1452
            lastvalue1            => $lastvalue1,
1457
            lastvalue1                            => $lastvalue1,
1453
            innerloop1            => $innerloop1,
1458
            innerloop1                            => $innerloop1,
1454
            lastvalue2            => $lastvalue2,
1459
            lastvalue2                            => $lastvalue2,
1455
            innerloop2            => $innerloop2,
1460
            innerloop2                            => $innerloop2,
1456
            lastvalue3            => $lastvalue3,
1461
            lastvalue3                            => $lastvalue3,
1457
            innerloop3            => $innerloop3,
1462
            innerloop3                            => $innerloop3,
1458
            status                => $status,
1463
            status                                => $status,
1459
            notes                 => $notes,
1464
            notes                                 => $notes,
1460
            letter                => $letter,
1465
            letter                                => $letter,
1461
            firstacquidate        => $firstacquidate,
1466
            firstacquidate                        => $firstacquidate,
1462
            irregularity          => $irregularity,
1467
            irregularity                          => $irregularity,
1463
            numberpattern         => $numberpattern,
1468
            numberpattern                         => $numberpattern,
1464
            locale                => $locale,
1469
            locale                                => $locale,
1465
            callnumber            => $callnumber,
1470
            callnumber                            => $callnumber,
1466
            manualhistory         => $manualhistory,
1471
            manualhistory                         => $manualhistory,
1467
            internalnotes         => $internalnotes,
1472
            internalnotes                         => $internalnotes,
1468
            serialsadditems       => $serialsadditems,
1473
            serialsadditems                       => $serialsadditems,
1469
            staffdisplaycount     => $staffdisplaycount,
1474
            staffdisplaycount                     => $staffdisplaycount,
1470
            opacdisplaycount      => $opacdisplaycount,
1475
            opacdisplaycount                      => $opacdisplaycount,
1471
            graceperiod           => $graceperiod,
1476
            graceperiod                           => $graceperiod,
1472
            location              => $location,
1477
            location                              => $location,
1473
            enddate               => $enddate,
1478
            enddate                               => $enddate,
1474
            skip_serialseq        => $skip_serialseq,
1479
            skip_serialseq                        => $skip_serialseq,
1475
            itemtype              => $itemtype,
1480
            itemtype                              => $itemtype,
1476
            previousitemtype      => $previousitemtype,
1481
            previousitemtype                      => $previousitemtype,
1477
            mana_id               => $mana_id,
1482
            mana_id                               => $mana_id,
1478
            ccode                 => $ccode,
1483
            ccode                                 => $ccode,
1479
            published_on_template => $published_on_template,
1484
            published_on_template                 => $published_on_template,
1485
            preselect_issues_in_collections_table => $preselect_issues_in_collections_table,
1480
        }
1486
        }
1481
    )->store;
1487
    )->store;
1482
    $subscription->discard_changes;
1488
    $subscription->discard_changes;
(-)a/Koha/Schema/Result/Subscription.pm (-6 / +17 lines)
Lines 341-346 collection code to assign to serial items Link Here
341
341
342
Template Toolkit syntax to generate the default "Published on (text)" field when receiving an issue this serial
342
Template Toolkit syntax to generate the default "Published on (text)" field when receiving an issue this serial
343
343
344
=head2 preselect_issues_in_collections_table
345
346
  data_type: 'tinyint'
347
  default_value: 0
348
  is_nullable: 0
349
350
yes / no if the subscription should preselect issues in the collections table
351
344
=cut
352
=cut
345
353
346
__PACKAGE__->add_columns(
354
__PACKAGE__->add_columns(
Lines 434-439 __PACKAGE__->add_columns( Link Here
434
  { data_type => "varchar", is_nullable => 1, size => 80 },
442
  { data_type => "varchar", is_nullable => 1, size => 80 },
435
  "published_on_template",
443
  "published_on_template",
436
  { data_type => "text", is_nullable => 1 },
444
  { data_type => "text", is_nullable => 1 },
445
  "preselect_issues_in_collections_table",
446
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
437
);
447
);
438
448
439
=head1 PRIMARY KEY
449
=head1 PRIMARY KEY
Lines 586-593 __PACKAGE__->has_many( Link Here
586
);
596
);
587
597
588
598
589
# Created by DBIx::Class::Schema::Loader v0.07051 @ 2024-11-11 14:57:59
599
# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-05-09 08:07:54
590
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1Ht7Nfl870dv1NOs4vr04g
600
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:TZz+AyW1pPFbUMdo2mneuw
591
601
592
__PACKAGE__->has_many(
602
__PACKAGE__->has_many(
593
  "additional_field_values",
603
  "additional_field_values",
Lines 604-613 __PACKAGE__->has_many( Link Here
604
);
614
);
605
615
606
__PACKAGE__->add_columns(
616
__PACKAGE__->add_columns(
607
    '+closed'          => { is_boolean => 1 },
617
    '+closed'                                => { is_boolean => 1 },
608
    '+manualhistory'   => { is_boolean => 1 },
618
    '+manualhistory'                         => { is_boolean => 1 },
609
    '+serialsadditems' => { is_boolean => 1 },
619
    '+serialsadditems'                       => { is_boolean => 1 },
610
    '+skip_serialseq'  => { is_boolean => 1 },
620
    '+skip_serialseq'                        => { is_boolean => 1 },
621
    '+preselect_issues_in_collections_table' => { is_boolean => 1 },
611
);
622
);
612
623
613
1;
624
1;
(-)a/installer/data/mysql/atomicupdate/bug_38061-collections_preselect_column.pl (+19 lines)
Line 0 Link Here
1
use Modern::Perl;
2
use Koha::Installer::Output qw(say_warning say_success say_info);
3
4
return {
5
    bug_number  => "38061",
6
    description =>
7
        "Add a column to determine whether a subscription's issues should be preselected in the collections table",
8
    up => sub {
9
        my ($args) = @_;
10
        my ( $dbh, $out ) = @$args{qw(dbh out)};
11
12
        if ( !column_exists( 'subscription', 'preselect_issues_in_collections_table' ) ) {
13
            $dbh->do(
14
                q{ ALTER TABLE subscription ADD COLUMN `preselect_issues_in_collections_table` tinyint(1) NOT NULL DEFAULT 0 COMMENT 'yes / no if the subscription should preselect issues in the collections table' AFTER published_on_template}
15
            );
16
            say_success( $out, "Added column 'subscription.preselect_issues_in_collections_table'" );
17
        }
18
    },
19
};
(-)a/installer/data/mysql/kohastructure.sql (+1 lines)
Lines 6496-6501 CREATE TABLE `subscription` ( Link Here
6496
  `mana_id` int(11) DEFAULT NULL,
6496
  `mana_id` int(11) DEFAULT NULL,
6497
  `ccode` varchar(80) DEFAULT NULL COMMENT 'collection code to assign to serial items',
6497
  `ccode` varchar(80) DEFAULT NULL COMMENT 'collection code to assign to serial items',
6498
  `published_on_template` text DEFAULT NULL COMMENT 'Template Toolkit syntax to generate the default "Published on (text)" field when receiving an issue this serial',
6498
  `published_on_template` text DEFAULT NULL COMMENT 'Template Toolkit syntax to generate the default "Published on (text)" field when receiving an issue this serial',
6499
  `preselect_issues_in_collections_table` tinyint(1) NOT NULL DEFAULT 0 COMMENT 'yes / no if the subscription should preselect issues in the collections table',
6499
  PRIMARY KEY (`subscriptionid`),
6500
  PRIMARY KEY (`subscriptionid`),
6500
  KEY `subscription_ibfk_1` (`periodicity`),
6501
  KEY `subscription_ibfk_1` (`periodicity`),
6501
  KEY `subscription_ibfk_2` (`numberpattern`),
6502
  KEY `subscription_ibfk_2` (`numberpattern`),
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-add.tt (+9 lines)
Lines 286-291 Link Here
286
                                [% END %]
286
                                [% END %]
287
                            </div>
287
                            </div>
288
                        </li>
288
                        </li>
289
                        <li>
290
                            <label for="preselect_issues_in_collections_table">Pre-select issues in the collections table:</label>
291
                            [% IF (preselect_issues_in_collections_table) %]
292
                                <input type="checkbox" id="preselect_issues_in_collections_table" name="preselect_issues_in_collections_table" checked="checked" />
293
                            [% ELSE %]
294
                                <input type="checkbox" id="preselect_issues_in_collections_table" name="preselect_issues_in_collections_table" />
295
                            [% END %]
296
                            <div class="hint">Determines whether the checkboxes in the left hand column of the collections table will be automatically checked based on the issue's status.</div>
297
                        </li>
289
                    </ol>
298
                    </ol>
290
                </fieldset>
299
                </fieldset>
291
                <fieldset class="action">
300
                <fieldset class="action">
(-)a/serials/subscription-add.pl (-49 / +52 lines)
Lines 326-354 sub redirect_add_subscription { Link Here
326
    my $subtype   = $query->param('subtype');
326
    my $subtype   = $query->param('subtype');
327
    my $sublength = $query->param('sublength');
327
    my $sublength = $query->param('sublength');
328
    my ( $numberlength, $weeklength, $monthlength ) = GetSubscriptionLength( $subtype, $sublength );
328
    my ( $numberlength, $weeklength, $monthlength ) = GetSubscriptionLength( $subtype, $sublength );
329
    my $add1                  = $query->param('add1');
329
    my $add1                                  = $query->param('add1');
330
    my $lastvalue1            = $query->param('lastvalue1');
330
    my $lastvalue1                            = $query->param('lastvalue1');
331
    my $innerloop1            = $query->param('innerloop1');
331
    my $innerloop1                            = $query->param('innerloop1');
332
    my $innerloop2            = $query->param('innerloop2');
332
    my $innerloop2                            = $query->param('innerloop2');
333
    my $lastvalue2            = $query->param('lastvalue2');
333
    my $lastvalue2                            = $query->param('lastvalue2');
334
    my $lastvalue3            = $query->param('lastvalue3');
334
    my $lastvalue3                            = $query->param('lastvalue3');
335
    my $innerloop3            = $query->param('innerloop3');
335
    my $innerloop3                            = $query->param('innerloop3');
336
    my $status                = 1;
336
    my $status                                = 1;
337
    my $biblionumber          = $query->param('biblionumber');
337
    my $biblionumber                          = $query->param('biblionumber');
338
    my $callnumber            = $query->param('callnumber');
338
    my $callnumber                            = $query->param('callnumber');
339
    my $notes                 = $query->param('notes');
339
    my $notes                                 = $query->param('notes');
340
    my $internalnotes         = $query->param('internalnotes');
340
    my $internalnotes                         = $query->param('internalnotes');
341
    my $letter                = $query->param('letter');
341
    my $letter                                = $query->param('letter');
342
    my $manualhistory         = $query->param('manualhist') ? 1 : 0;
342
    my $manualhistory                         = $query->param('manualhist') ? 1 : 0;
343
    my $serialsadditems       = $query->param('serialsadditems');
343
    my $serialsadditems                       = $query->param('serialsadditems');
344
    my $staffdisplaycount     = $query->param('staffdisplaycount');
344
    my $staffdisplaycount                     = $query->param('staffdisplaycount');
345
    my $opacdisplaycount      = $query->param('opacdisplaycount');
345
    my $opacdisplaycount                      = $query->param('opacdisplaycount');
346
    my $location              = $query->param('location');
346
    my $location                              = $query->param('location');
347
    my $itemtype              = $query->param('itemtype');
347
    my $itemtype                              = $query->param('itemtype');
348
    my $previousitemtype      = $query->param('previousitemtype');
348
    my $previousitemtype                      = $query->param('previousitemtype');
349
    my $skip_serialseq        = $query->param('skip_serialseq');
349
    my $skip_serialseq                        = $query->param('skip_serialseq');
350
    my $ccode                 = $query->param('ccode');
350
    my $ccode                                 = $query->param('ccode');
351
    my $published_on_template = $query->param('published_on_template');
351
    my $published_on_template                 = $query->param('published_on_template');
352
    my $preselect_issues_in_collections_table = $query->param('preselect_issues_in_collections_table') ? 1 : 0;
352
353
353
    my $mana_id;
354
    my $mana_id;
354
    if ( $query->param('mana_id') ne "" ) {
355
    if ( $query->param('mana_id') ne "" ) {
Lines 376-382 sub redirect_add_subscription { Link Here
376
        join( ";", @irregularity ), $numberpattern,    $locale,         $callnumber,
377
        join( ";", @irregularity ), $numberpattern,    $locale,         $callnumber,
377
        $manualhistory,             $internalnotes,    $serialsadditems,
378
        $manualhistory,             $internalnotes,    $serialsadditems,
378
        $staffdisplaycount,         $opacdisplaycount, $graceperiod, $location, $enddate,
379
        $staffdisplaycount,         $opacdisplaycount, $graceperiod, $location, $enddate,
379
        $skip_serialseq,            $itemtype,         $previousitemtype, $mana_id, $ccode, $published_on_template
380
        $skip_serialseq,            $itemtype,         $previousitemtype, $mana_id, $ccode, $published_on_template,
381
        $preselect_issues_in_collections_table
380
    );
382
    );
381
    if (    ( C4::Context->preference('Mana') == 1 )
383
    if (    ( C4::Context->preference('Mana') == 1 )
382
        and ( grep { $_ eq "subscription" } split( /,/, C4::Context->preference('AutoShareWithMana') ) ) )
384
        and ( grep { $_ eq "subscription" } split( /,/, C4::Context->preference('AutoShareWithMana') ) ) )
Lines 435-463 sub redirect_mod_subscription { Link Here
435
    my $subtype   = $query->param('subtype');
437
    my $subtype   = $query->param('subtype');
436
    my $sublength = $query->param('sublength');
438
    my $sublength = $query->param('sublength');
437
    my ( $numberlength, $weeklength, $monthlength ) = GetSubscriptionLength( $subtype, $sublength );
439
    my ( $numberlength, $weeklength, $monthlength ) = GetSubscriptionLength( $subtype, $sublength );
438
    my $locale                = $query->param('locale');
440
    my $locale                                = $query->param('locale');
439
    my $lastvalue1            = $query->param('lastvalue1');
441
    my $lastvalue1                            = $query->param('lastvalue1');
440
    my $innerloop1            = $query->param('innerloop1');
442
    my $innerloop1                            = $query->param('innerloop1');
441
    my $lastvalue2            = $query->param('lastvalue2');
443
    my $lastvalue2                            = $query->param('lastvalue2');
442
    my $innerloop2            = $query->param('innerloop2');
444
    my $innerloop2                            = $query->param('innerloop2');
443
    my $lastvalue3            = $query->param('lastvalue3');
445
    my $lastvalue3                            = $query->param('lastvalue3');
444
    my $innerloop3            = $query->param('innerloop3');
446
    my $innerloop3                            = $query->param('innerloop3');
445
    my $status                = 1;
447
    my $status                                = 1;
446
    my $callnumber            = $query->param('callnumber');
448
    my $callnumber                            = $query->param('callnumber');
447
    my $notes                 = $query->param('notes');
449
    my $notes                                 = $query->param('notes');
448
    my $internalnotes         = $query->param('internalnotes');
450
    my $internalnotes                         = $query->param('internalnotes');
449
    my $letter                = $query->param('letter');
451
    my $letter                                = $query->param('letter');
450
    my $manualhistory         = $query->param('manualhist') ? 1 : 0;
452
    my $manualhistory                         = $query->param('manualhist') ? 1 : 0;
451
    my $serialsadditems       = $query->param('serialsadditems');
453
    my $serialsadditems                       = $query->param('serialsadditems');
452
    my $staffdisplaycount     = $query->param('staffdisplaycount');
454
    my $staffdisplaycount                     = $query->param('staffdisplaycount');
453
    my $opacdisplaycount      = $query->param('opacdisplaycount');
455
    my $opacdisplaycount                      = $query->param('opacdisplaycount');
454
    my $graceperiod           = $query->param('graceperiod') || 0;
456
    my $graceperiod                           = $query->param('graceperiod') || 0;
455
    my $location              = $query->param('location');
457
    my $location                              = $query->param('location');
456
    my $itemtype              = $query->param('itemtype');
458
    my $itemtype                              = $query->param('itemtype');
457
    my $previousitemtype      = $query->param('previousitemtype');
459
    my $previousitemtype                      = $query->param('previousitemtype');
458
    my $skip_serialseq        = $query->param('skip_serialseq');
460
    my $skip_serialseq                        = $query->param('skip_serialseq');
459
    my $ccode                 = $query->param('ccode');
461
    my $ccode                                 = $query->param('ccode');
460
    my $published_on_template = $query->param('published_on_template');
462
    my $published_on_template                 = $query->param('published_on_template');
463
    my $preselect_issues_in_collections_table = $query->param('preselect_issues_in_collections_table') ? 1 : 0;
461
464
462
    my $mana_id;
465
    my $mana_id;
463
    if ( $query->param('mana_id') ne "" ) {
466
    if ( $query->param('mana_id') ne "" ) {
Lines 494-500 sub redirect_mod_subscription { Link Here
494
        $status,           $biblionumber,   $callnumber,       $notes,      $letter,
497
        $status,           $biblionumber,   $callnumber,       $notes,      $letter,
495
        $manualhistory,    $internalnotes,  $serialsadditems,  $staffdisplaycount,
498
        $manualhistory,    $internalnotes,  $serialsadditems,  $staffdisplaycount,
496
        $opacdisplaycount, $graceperiod,    $location,         $enddate, $subscriptionid,
499
        $opacdisplaycount, $graceperiod,    $location,         $enddate, $subscriptionid,
497
        $skip_serialseq,   $itemtype,       $previousitemtype, $mana_id, $ccode, $published_on_template
500
        $skip_serialseq,   $itemtype,       $previousitemtype, $mana_id, $ccode, $published_on_template,
501
        $preselect_issues_in_collections_table
498
    );
502
    );
499
503
500
    my @additional_fields =
504
    my @additional_fields =
501
- 

Return to bug 38061