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

(-)a/installer/data/mysql/updatedatabase.pl (+7 lines)
Lines 7824-7829 if ( CheckVersion($DBversion) ) { Link Here
7824
    SetVersion($DBversion);
7824
    SetVersion($DBversion);
7825
}
7825
}
7826
7826
7827
$DBversion = "XXX";
7828
if ( CheckVersion($DBversion) ) {
7829
    $dbh->do("ALTER TABLE `borrowers` ADD COLUMN `contactprincipal` VARCHAR(45) NULL DEFAULT NULL;");
7830
    print "Upgrade to $DBversion done (Add the contactprincipal column to the borrowers table)\n";
7831
    SetVersion($DBversion);
7832
}
7833
7827
7834
7828
=head1 FUNCTIONS
7835
=head1 FUNCTIONS
7829
7836
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt (+26 lines)
Lines 634-639 Link Here
634
        <input type="text" id="fax" name="fax" value="[% fax %]" class="[% focusAction %]" />
634
        <input type="text" id="fax" name="fax" value="[% fax %]" class="[% focusAction %]" />
635
	  [% IF ( mandatoryfax ) %]<span class="required">Required</span>[% END %]
635
	  [% IF ( mandatoryfax ) %]<span class="required">Required</span>[% END %]
636
    </li>
636
    </li>
637
    <li>
638
        <label for="contactprincipal">Main Contact Method</label>
639
        <select id="contactprincipal" name="contactprincipal">
640
            <option value=""></option>
641
        [% FOREACH contactprincipalloo IN contactprincipalloop %]
642
            [% IF ( contactprincipalloo.currentis_phone ) %]
643
                <option value="phone" [% IF ( contactprincipalloo.selected ) %]selected="selected"[% END %]>Phone (home)</option>
644
            [% END %]
645
            [% IF ( contactprincipalloo.currentis_phonepro ) %]
646
                <option value="phonepro" [% IF ( contactprincipalloo.selected ) %]selected="selected"[% END %]>Phone (work)</option>
647
            [% END %]
648
            [% IF ( contactprincipalloo.currentis_mobile ) %]
649
                <option value="mobile" [% IF ( contactprincipalloo.selected ) %]selected="selected"[% END %]>Phone (cell)</option>
650
            [% END %]
651
            [% IF ( contactprincipalloo.currentis_email ) %]
652
                <option value="email" [% IF ( contactprincipalloo.selected ) %]selected="selected"[% END %]>Email (home)</option>
653
            [% END %]
654
            [% IF ( contactprincipalloo.currentis_emailpro ) %]
655
                <option value="emailpro" [% IF ( contactprincipalloo.selected ) %]selected="selected"[% END %]>Email (work)</option>
656
            [% END %]
657
            [% IF ( contactprincipalloo.currentis_fax ) %]
658
                <option value="fax" [% IF ( contactprincipalloo.selected ) %]selected="selected"[% END %]>Fax</option>
659
            [% END %]
660
       [% END %]
661
       </select>
662
    </li>
637
        [% END %]
663
        [% END %]
638
	</ol>
664
	</ol>
639
  </fieldset>
665
  </fieldset>
(-)a/members/memberentry.pl (-1 / +12 lines)
Lines 526-531 foreach (qw(C A S P I X)) { Link Here
526
$template->param('typeloop' => \@typeloop,
526
$template->param('typeloop' => \@typeloop,
527
        no_categories => $no_categories);
527
        no_categories => $no_categories);
528
if($no_categories){ $no_add = 1; }
528
if($no_categories){ $no_add = 1; }
529
530
my @contactprincipalloop;
531
foreach (qw(phone phonepro mobile email emailpro fax)) {
532
	push @contactprincipalloop,{
533
        'code' => $_,
534
        'selected' => (defined($borrower_data->{'contactprincipal'}) &&
535
            $_ eq $borrower_data->{'contactprincipal'}),
536
        'currentis_' . $_ => 1
537
	};
538
}
539
$template->param('contactprincipalloop' => \@contactprincipalloop);
540
529
# test in city
541
# test in city
530
if ( $guarantorid ) {
542
if ( $guarantorid ) {
531
    $select_city = getidcity($data{city});
543
    $select_city = getidcity($data{city});
532
- 

Return to bug 11879