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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt (-6 / +18 lines)
Lines 474-485 legend:hover { Link Here
474
                                                            </li>
474
                                                            </li>
475
475
476
                                                            <li>
476
                                                            <li>
477
                                                                <label for="guarantor_relationship">Relationship: </label>
477
                                                                <label for="guarantor_relationship"[% UNLESS empty_relationship_allowed %] class="required"[% END %]>Relationship: </label>
478
                                                                <select class="new_guarantor_relationship" name="new_guarantor_relationship">
478
                                                                <select class="new_guarantor_relationship" name="new_guarantor_relationship"[% UNLESS empty_relationship_allowed %] required="required"[% END %]>
479
                                                                    <option value="" selected>Empty option</option>
479
                                                                    [% FOREACH pr IN possible_relationships.split('\|') %]
480
                                                                    [% FOREACH pr IN possible_relationships.split('\|') %]
480
                                                                        <option value="[% pr | html %]">[% pr | html %]</option>
481
                                                                        [% IF pr != "" %]
482
                                                                            <option value="[% pr | html %]">[% pr | html %]</option>
483
                                                                        [% END %]
481
                                                                    [% END %]
484
                                                                    [% END %]
482
                                                                </select>
485
                                                                </select>
486
                                                                [% UNLESS empty_relationship_allowed %]
487
                                                                    <span class="required">Required</span>
488
                                                                [% END %]
483
                                                            </li>
489
                                                            </li>
484
490
485
                                                            <li>
491
                                                            <li>
Lines 510-521 legend:hover { Link Here
510
                                                    </li>
516
                                                    </li>
511
517
512
                                                    <li>
518
                                                    <li>
513
                                                        <label for="guarantor_relationship">Relationship: </label>
519
                                                        <label for="guarantor_relationship"[% UNLESS empty_relationship_allowed %] class="required"[% END %]>Relationship: </label>
514
                                                        <select class="new_guarantor_relationship" name="new_guarantor_relationship">
520
                                                        <select class="new_guarantor_relationship" name="new_guarantor_relationship"[% UNLESS empty_relationship_allowed %] required="required"[% END %]>
521
                                                            <option value="" selected></option>
515
                                                            [% FOREACH pr IN possible_relationships.split('\|') %]
522
                                                            [% FOREACH pr IN possible_relationships.split('\|') %]
516
                                                                <option value="[% pr | html %]">[% pr | html %]</option>
523
                                                                [% IF pr != "" %]
524
                                                                    <option value="[% pr | html %]">[% pr | html %]</option>
525
                                                                [% END %]
517
                                                            [% END %]
526
                                                            [% END %]
518
                                                        </select>
527
                                                        </select>
528
                                                        [% UNLESS empty_relationship_allowed %]
529
                                                            <span class="required">Required</span>
530
                                                        [% END %]
519
                                                    </li>
531
                                                    </li>
520
532
521
                                                    <li>
533
                                                    <li>
(-)a/members/memberentry.pl (-1 / +4 lines)
Lines 107-112 my @messages; Link Here
107
## Deal with guarantor stuff
107
## Deal with guarantor stuff
108
$template->param( relationships => scalar $patron->guarantor_relationships ) if $patron;
108
$template->param( relationships => scalar $patron->guarantor_relationships ) if $patron;
109
109
110
my @relations = split /,|\|/, C4::Context->preference('borrowerRelationship');
111
my $empty_relationship_allowed = grep {$_ eq ""} @relations;
112
$template->param( empty_relationship_allowed => $empty_relationship_allowed );
113
110
my $guarantor_id = $input->param('guarantor_id');
114
my $guarantor_id = $input->param('guarantor_id');
111
my $guarantor = undef;
115
my $guarantor = undef;
112
$guarantor = Koha::Patrons->find( $guarantor_id ) if $guarantor_id;
116
$guarantor = Koha::Patrons->find( $guarantor_id ) if $guarantor_id;
113
- 

Return to bug 25322