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

(-)a/admin/biblio_framework.pl (+3 lines)
Lines 53-62 if ( $op eq 'add_form' ) { Link Here
53
    my $frameworkcode = $input->param('frameworkcode');
53
    my $frameworkcode = $input->param('frameworkcode');
54
    my $frameworktext = $input->param('frameworktext');
54
    my $frameworktext = $input->param('frameworktext');
55
    my $is_a_modif    = $input->param('is_a_modif');
55
    my $is_a_modif    = $input->param('is_a_modif');
56
    my $is_fast_add   = $input->param('is_fast_add') || 0;
56
57
57
    if ($is_a_modif) {
58
    if ($is_a_modif) {
58
        my $framework = Koha::BiblioFrameworks->find($frameworkcode);
59
        my $framework = Koha::BiblioFrameworks->find($frameworkcode);
59
        $framework->frameworktext($frameworktext);
60
        $framework->frameworktext($frameworktext);
61
        $framework->is_fast_add($is_fast_add);
60
        eval { $framework->store; };
62
        eval { $framework->store; };
61
        if ($@) {
63
        if ($@) {
62
            push @messages, { type => 'error', code => 'error_on_update' };
64
            push @messages, { type => 'error', code => 'error_on_update' };
Lines 67-72 if ( $op eq 'add_form' ) { Link Here
67
        my $framework = Koha::BiblioFramework->new(
69
        my $framework = Koha::BiblioFramework->new(
68
            {   frameworkcode => $frameworkcode,
70
            {   frameworkcode => $frameworkcode,
69
                frameworktext => $frameworktext,
71
                frameworktext => $frameworktext,
72
                is_fast_add   => $is_fast_add,
70
            }
73
            }
71
        );
74
        );
72
        eval { $framework->store; };
75
        eval { $framework->store; };
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/biblio_framework.tt (-2 / +16 lines)
Lines 137-142 Link Here
137
                    <input type="text" name="frameworktext" id="description" size="40" maxlength="80" value="[% framework.frameworktext | html %]" required="required" class="required" />
137
                    <input type="text" name="frameworktext" id="description" size="40" maxlength="80" value="[% framework.frameworktext | html %]" required="required" class="required" />
138
                    <span class="required">Required</span>
138
                    <span class="required">Required</span>
139
                </li>
139
                </li>
140
                <li>
141
                    <label for="is_fast_add">Use as a Fast Add framework: </label>
142
                    [% IF framework.frameworkcode == 'FA' %]
143
                        <input type="checkbox" name="is_fast_add" id="is_fast_add" value="1" checked disabled/>
144
                    [% ELSIF framework.is_fast_add %]
145
                        <input type="checkbox" name="is_fast_add" id="is_fast_add" value="1" checked/>
146
                    [% ELSE %]
147
                        <input type="checkbox" name="is_fast_add" id="is_fast_add" value="1"/>
148
                    [% END %]
149
                </li>
140
            </ol>
150
            </ol>
141
        </fieldset>
151
        </fieldset>
142
        <fieldset class="action">
152
        <fieldset class="action">
Lines 252-258 Link Here
252
    [% FOREACH loo IN frameworks %]
262
    [% FOREACH loo IN frameworks %]
253
        <tr>
263
        <tr>
254
            <td>[% loo.frameworkcode | html %]</td>
264
            <td>[% loo.frameworkcode | html %]</td>
255
            <td>[% loo.frameworktext | html %]</td>
265
            <td>
266
                [% loo.frameworktext | html %]
267
                [% IF loo.is_fast_add %]
268
                <span class="badge rounded-pill bg-secondary float-end">Fast Add</span>
269
                [% END %]
270
            </td>
256
            <td>
271
            <td>
257
              <div class="btn-group dropup">
272
              <div class="btn-group dropup">
258
                <a class="btn btn-default btn-xs dropdown-toggle" id="frameworkactions[% loo.frameworkcode | html %]" role="button" data-bs-toggle="dropdown" href="#">
273
                <a class="btn btn-default btn-xs dropdown-toggle" id="frameworkactions[% loo.frameworkcode | html %]" role="button" data-bs-toggle="dropdown" href="#">
259
- 

Return to bug 32773