proxmox-backup/www/VersionInfo.js
Thomas Lamprecht 8acd4d9afc ui: some more eslint auto-fixes
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2020-09-25 18:34:54 +02:00

33 lines
513 B
JavaScript

Ext.define('PBS.view.main.VersionInfo', {
extend: 'Ext.Component',
xtype: 'versioninfo',
makeApiCall: true,
data: {
version: false,
},
tpl: [
'Backup Server',
'<tpl if="version">',
' {version}-{release}',
'</tpl>',
],
initComponent: function() {
var me = this;
me.callParent();
if (me.makeApiCall) {
Proxmox.Utils.API2Request({
url: '/version',
method: 'GET',
success: function(response) {
me.update(response.result.data);
},
});
}
},
});