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

(-)a/installer/data/mysql/updatedatabase.pl (+11 lines)
Lines 4932-4937 if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { Link Here
4932
    SetVersion($DBversion);
4932
    SetVersion($DBversion);
4933
}
4933
}
4934
4934
4935
4936
4937
4938
4939
$DBversion = "3.07.00.XXX";
4940
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
4941
    $dbh->do("INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES('SubscriptionDuplicateDroppedInput','','','List of fields which must not be rewritten when a subscription is duplicated (Separated by semicolon)','Free')");
4942
    print "Upgrade to $DBversion done (Add System Preferences SubscriptionDuplicateDroppedInput)\n";
4943
    SetVersion($DBversion);
4944
}
4945
4935
=head1 FUNCTIONS
4946
=head1 FUNCTIONS
4936
4947
4937
=head2 DropAllForeignKeys($table)
4948
=head2 DropAllForeignKeys($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/serials.pref (+3 lines)
Lines 47-49 Serials: Link Here
47
              simplified: a summary
47
              simplified: a summary
48
              full: a full list
48
              full: a full list
49
        - of the serial issues.
49
        - of the serial issues.
50
    -
51
        - List of fields which must not be rewritten when a subscription is duplicated (Separated by semicolon)
52
        - pref: SubscriptionDuplicateDroppedInput
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-add.tt (-1 / +11 lines)
Lines 944-949 $(document).ready(function() { Link Here
944
    $('#numberpattern').change( function() { 
944
    $('#numberpattern').change( function() { 
945
        reset_num_pattern(); 
945
        reset_num_pattern(); 
946
    });
946
    });
947
948
    var node;
949
    [% FOREACH field IN dont_export_field_loop %]
950
        node = $("#[% field.fieldid %]");
951
        if ( $(node).is('input') || $(node).is('textarea') ) {
952
            $(node).val("");
953
        } else if ( $(node).is('select') ) {
954
            $(node).find("option:first").attr('selected','selected');
955
        }
956
    [% END %]
947
});
957
});
948
//]]>
958
//]]>
949
</script>
959
</script>
Lines 1333-1339 $(document).ready(function() { Link Here
1333
					[% IF ( subtype_numberlength ) %]<option value="numberlength" selected="selected">[% ELSE %]<option value="numberlength">[% END %] Number of issues</option>					
1343
					[% IF ( subtype_numberlength ) %]<option value="numberlength" selected="selected">[% ELSE %]<option value="numberlength">[% END %] Number of issues</option>					
1334
					[% IF ( subtype_weeklength ) %]<option value="weeklength" selected="selected">[% ELSE %]<option value="weeklength">[% END %] Number of weeks</option>					
1344
					[% IF ( subtype_weeklength ) %]<option value="weeklength" selected="selected">[% ELSE %]<option value="weeklength">[% END %] Number of weeks</option>					
1335
                </select>
1345
                </select>
1336
                <input type="text" name="sublength" value="[% sublength %]" size="3" onkeypress="return check_input(event)" /> (enter amount in numerals)
1346
                <input type="text" id="numberlength" name="sublength" value="[% sublength %]" size="3" onkeypress="return check_input(event)" /> (enter amount in numerals)
1337
            <span class="required">Required</span>
1347
            <span class="required">Required</span>
1338
        </li>
1348
        </li>
1339
        <li>
1349
        <li>
(-)a/serials/subscription-add.pl (-1 / +6 lines)
Lines 113-118 if ($op eq 'modify' || $op eq 'dup' || $op eq 'modsubscription') { Link Here
113
                    firstacquiyear => substr($firstissuedate,0,4),
113
                    firstacquiyear => substr($firstissuedate,0,4),
114
                    );
114
                    );
115
    }
115
    }
116
117
    if ( $op eq 'dup' ) {
118
        my $dont_copy_fields = C4::Context->preference('SubscriptionDuplicateDroppedInput');
119
        my @fields_id = map { fieldid => $_ }, split ';', $dont_copy_fields;
120
        $template->param( dont_export_field_loop => \@fields_id );
121
    }
116
}
122
}
117
123
118
my $onlymine=C4::Context->preference('IndependantBranches') &&
124
my $onlymine=C4::Context->preference('IndependantBranches') &&
119
- 

Return to bug 5354