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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/upload.tt (-14 / +16 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
                });
482
            }).on("hidden.bs.tooltip", function(){
482
                $(".get-file").tooltip({
483
                $(this).attr("data-original-title", _( "Copy link to this file" ) );
483
                    delay: { "show": 100, "hide": 500 }
484
            });
484
                }).on("hidden.bs.tooltip", function(){
485
                    $(this).attr("data-original-title", _( "Copy link to this file" ) );
486
                });
487
            }
485
        });
488
        });
486
    </script>
489
    </script>
487
[% END %]
490
[% END %]
488
- 

Return to bug 27594