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

(-)a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss (-10 / +43 lines)
Lines 1668-1693 dd { Link Here
1668
    + #menu {
1668
    + #menu {
1669
        margin-right: 0;
1669
        margin-right: 0;
1670
    }
1670
    }
1671
1672
    > div {
1673
        border-right: 1px solid #B9D8D9;
1674
        width: 100%;
1675
    }
1671
}
1676
}
1672
1677
1673
#patronbasics {
1678
/* Patron image */
1674
    div {
1679
1675
        background: transparent url("../img/patron-blank.min.svg") 10px 5px no-repeat;
1680
.patronimage-container {
1676
        border: 1px solid #CCCCCC;
1681
    padding: .2em;
1682
    position: relative;
1683
1684
    &:hover {
1685
        .patronimage {
1686
            opacity: .8;
1687
        }
1688
1689
        .patronimage-controls {
1690
            opacity: 1;
1691
        }
1692
    }
1693
}
1694
1695
.patronimage {
1696
    display: block;
1697
    max-width: 160px;
1698
    opacity: 1;
1699
    transition: .2s ease;
1700
1701
    .empty {
1702
        background: transparent url( "../img/patron-blank.min.svg" ) center 5px no-repeat;
1677
        height: 125px;
1703
        height: 125px;
1678
        margin: .3em 0 .3em .3em;
1704
        margin: .3em 0 .3em .3em;
1679
        padding: 0;
1705
        padding: 0;
1680
        width: 105px;
1706
        width: 80%;
1681
    }
1707
    }
1682
}
1708
}
1683
1709
1684
#patronimage {
1710
.patronimage-controls {
1685
    border: 1px solid #CCCCCC;
1711
    left: 50%;
1686
    margin: .3em 0 .3em .3em;
1712
    opacity: 0;
1687
    max-width: 140px;
1713
    position: absolute;
1688
    padding: .2em;
1714
    text-align: center;
1715
    top: 80%;
1716
    transform: translate( -50%, -50% );
1717
    transition: .5s ease;
1689
}
1718
}
1690
1719
1720
.patronimage-control {
1721
    padding: 1em 2em;
1722
 }
1723
1691
.patronviews {
1724
.patronviews {
1692
    border-right: 1px solid #000;
1725
    border-right: 1px solid #000;
1693
    border-top: 1px solid #000;
1726
    border-top: 1px solid #000;
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/circ-menu.inc (-15 / +38 lines)
Lines 1-22 Link Here
1
[% USE Koha %]
1
[% USE Koha %]
2
[% IF ( patron.borrowernumber ) %]
2
[% IF ( patron.borrowernumber ) %]
3
<div class="patroninfo"><h5>[% INCLUDE 'patron-title.inc' %]</h5>
3
<div class="patroninfo"><h5>[% INCLUDE 'patron-title.inc' %]</h5>
4
<!--[if IE 6]>
4
5
<style type="tex/css">img { width: expression(this.width > 140 ? 140: true);
5
[% IF ( patronimages ) %]
6
}</style>
6
    <div>
7
<![endif]-->
7
        <div class="patronimage-container">
8
            [% IF ( patron.image ) %]
9
                <img src="/cgi-bin/koha/members/patronimage.pl?borrowernumber=[% patron.borrowernumber | uri %]" class="patronimage" alt="[% patron.firstname | html %] [% patron.surname | html %] ([% patron.cardnumber | html %])" />
10
                <div class="patronimage-controls">
11
                    <div class="patronimage-control"><a data-borrowernumber="[% patron.borrowernumber | uri %]" class="btn btn-default btn-sm edit-patronimage" title="Edit patron image" href="#"><i class="fa fa-pencil"></i> Edit</a></div>
12
                </div>
13
            [% ELSE %]
14
                <div class="patronimage empty"></div>
15
                <div class="patronimage-controls">
16
                    <div class="patronimage-control"><a data-borrowernumber="[% patron.borrowernumber | uri %]" class="btn btn-default btn-sm edit-patronimage" title="Add patron image" href="#"><i class="fa fa-plus"></i> Add</a></div>
17
                </div>
18
            [% END %]
19
        </div>
20
    </div>
21
[% END %]
22
8
<ul class="patronbriefinfo">
23
<ul class="patronbriefinfo">
9
    [% IF ( patronimages ) %]
10
        [% IF ( patron.image ) %]
11
            <li>
12
                <img src="/cgi-bin/koha/members/patronimage.pl?borrowernumber=[% patron.borrowernumber | uri %]" id="patronimage" alt="[% patron.firstname | html %] [% patron.surname | html %] ([% patron.cardnumber | html %])" />
13
            </li>
14
        [% ELSE %]
15
            <li id="patronbasics">
16
                <div></div>
17
            </li>
18
        [% END %]
19
    [% END %]
20
    [% IF !(Koha.Preference('HidePersonalPatronDetailOnCirculation')) %]
24
    [% IF !(Koha.Preference('HidePersonalPatronDetailOnCirculation')) %]
21
        [% SWITCH Koha.Preference( 'AddressFormat' ) %]
25
        [% SWITCH Koha.Preference( 'AddressFormat' ) %]
22
            [% CASE 'de' %]
26
            [% CASE 'de' %]
Lines 125-128 Link Here
125
        <li><a href="/cgi-bin/koha/ill/ill-requests.pl?borrowernumber=[% patron.borrowernumber | html %]">Interlibrary loans</a></li>
129
        <li><a href="/cgi-bin/koha/ill/ill-requests.pl?borrowernumber=[% patron.borrowernumber | html %]">Interlibrary loans</a></li>
126
    [% END %]
130
    [% END %]
127
</ul></div>
131
</ul></div>
132
133
<!-- Modal -->
134
<div class="modal" id="patronImageEdit" tabindex="-1" role="dialog" aria-labelledby="patronImageEditLabel">
135
    <div class="modal-dialog" role="document">
136
        <div class="modal-content">
137
            <div class="modal-header">
138
                <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
139
                <h4 class="modal-title" id="patronImageEditLabel">Modal title</h4>
140
            </div>
141
            <div class="modal-body">
142
                <img src="[% interface %]/[% theme %]/img/spinner-small.gif" alt="" />
143
            </div>
144
            <div class="modal-footer">
145
                <button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
146
            </div>
147
        </div>
148
    </div>
149
</div>
150
128
[% END %]
151
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/js/members-menu.js (-1 / +13 lines)
Lines 82-87 $(document).ready(function(){ Link Here
82
    $("#select_patron_messages").on("change",function(){
82
    $("#select_patron_messages").on("change",function(){
83
        $("#borrower_message").val( $(this).val() );
83
        $("#borrower_message").val( $(this).val() );
84
    });
84
    });
85
86
    $(".edit-patronimage").on("click", function(e){
87
        e.preventDefault();
88
        var borrowernumber = $(this).data("borrowernumber");
89
        $.get("/cgi-bin/koha/members/moremember.pl", { borrowernumber : borrowernumber }, function( data ){
90
            var image_form = $(data).find("#picture-upload");
91
            image_form.show().find(".cancel").remove();
92
            $("#patronImageEdit .modal-body").html( image_form );
93
        });
94
        var modalTitle = $(this).attr("title");
95
        $("#patronImageEdit .modal-title").text(modalTitle);
96
        $("#patronImageEdit").modal("show");
97
    });
85
});
98
});
86
99
87
function confirm_updatechild() {
100
function confirm_updatechild() {
88
- 

Return to bug 20809