Bug 34478: ILL OPAC: create -> add_form

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Pedro Amorim 2024-02-02 15:16:02 +00:00 committed by Jonathan Druart
parent 6d0cb2648e
commit ed38820597
Signed by: jonathan.druart
GPG key ID: A085E712BEF0E0F0
2 changed files with 4 additions and 4 deletions

View file

@ -100,7 +100,7 @@
</select>
</fieldset>
<fieldset class="action">
<input type="hidden" name="op" value="create" />
<input type="hidden" name="op" value="add_form" />
<input type="submit" class="btn btn-sm btn-primary" value="Next" />
</fieldset>
</form>
@ -120,11 +120,11 @@
</button>
<div id="backend-dropdown-options" class="dropdown-menu nojs" aria-labelledby="ill-backend-dropdown">
[% FOREACH backend IN backends %]
<a class="dropdown-item" href="/cgi-bin/koha/opac-illrequests.pl?op=create&amp;backend=[% backend | uri %]">[% backend | html %]</a>
<a class="dropdown-item" href="/cgi-bin/koha/opac-illrequests.pl?op=add_form&amp;backend=[% backend | uri %]">[% backend | html %]</a>
[% END %]
</div>
[% ELSE %]
<a id="ill-new" class="btn btn-primary" href="/cgi-bin/koha/opac-illrequests.pl?op=create&amp;backend=[% backends.0 | html %]">
<a id="ill-new" class="btn btn-primary" href="/cgi-bin/koha/opac-illrequests.pl?op=add_form&amp;backend=[% backends.0 | html %]">
<i class="fa fa-plus" aria-hidden="true"></i> Create a new request
</a>
[% END %]

View file

@ -68,7 +68,7 @@ my $op = $params->{'op'} // $params->{'method'} // 'list';
show_param_deprecation_message('"create" op is DEPRECATED in favor of "cud-create".') if ( $op eq 'create' );
$op = 'cud-create' if $op eq 'create';
$op = 'cud-create' if $op eq 'create' || $op eq 'add_form';
my ( $illrequest_id, $request );
if ( $illrequest_id = $params->{illrequest_id} ) {