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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/upload.tt (-14 / +15 lines)
Lines 469-487 Link Here
469
                SubmitMe('new');
469
                SubmitMe('new');
470
            });
470
            });
471
471
472
            $(".get-file").on("click", function(e){
472
            if ( window.isSecureContext ) {
473
                e.preventDefault();
473
                $(".get-file").on("click", function(e){
474
                if( navigator.clipboard && navigator.clipboard.writeText){
474
                    e.preventDefault();
475
                    navigator.clipboard.writeText( $(this).attr("href") );
475
                    if( navigator.clipboard && navigator.clipboard.writeText){
476
                    $(this).attr("data-original-title", _( "Link copied to the clipboard" ) )
476
                        navigator.clipboard.writeText( $(this).attr("href") );
477
                        .tooltip("show");
477
                        $(this).attr("data-original-title", _( "Link copied to the clipboard" ) )
478
                }
478
                            .tooltip("show");
479
            });
479
                    }
480
            $(".get-file").tooltip({
480
                });
481
                delay: { "show": 100, "hide": 500 }
481
                $(".get-file").tooltip({
482
            }).on("hidden.bs.tooltip", function(){
482
                    delay: { "show": 100, "hide": 500 }
483
                $(this).attr("data-original-title", _( "Copy link to this file" ) );
483
                }).on("hidden.bs.tooltip", function(){
484
            });
484
                    $(this).attr("data-original-title", _( "Copy link to this file" ) );
485
                });
486
            }
485
        });
487
        });
486
    </script>
488
    </script>
487
[% END %]
489
[% END %]
488
- 

Return to bug 27594