]> git.proxmox.com Git - proxmox-backup.git/blobdiff - www/Dashboard.js
ui: fingerprint: add copy button
[proxmox-backup.git] / www / Dashboard.js
index 9ac30b212583b855c81bf6da5abd2a4a7fa49bd5..23bdd5413be54f1b56f8065649f751ba02baa16b 100644 (file)
@@ -105,13 +105,23 @@ Ext.define('PBS.Dashboard', {
                items: [
                    {
                        xtype: 'textfield',
+                       inputId: 'fingerprintField',
                        value: fingerprint,
                        editable: false,
                    },
                ],
                buttons: [
                    {
-                       text: gettext("OK"),
+                       xtype: 'button',
+                       handler: function(b) {
+                           var el = document.getElementById('fingerprintField');
+                           el.select();
+                           document.execCommand("copy");
+                       },
+                       text: gettext('Copy')
+                   },
+                   {
+                       text: gettext("Close"),
                        handler: function() {
                            this.up('window').close();
                        },