From 80e51f7ee6818c788f578cb805fc319d8e943f94 Mon Sep 17 00:00:00 2001 From: Emmanuel Kasper Date: Tue, 14 Jun 2016 11:41:43 +0200 Subject: [PATCH] Add a toplevel pointer to the PVE admin guide Since the Admin Guide is now delivered with each standard PVE installation, link it from the support tab Initial idea was to include the chapters list in the panel itself but a simple link renders better because: * linking to toplevel allows to show that pdf and epub are also available * the chapter list is long and would need scrolling on laptop displays * since a click opens the documentation in another tab, table of content and content would be in two different tabs, which is not intuitive --- www/manager6/dc/Support.js | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/www/manager6/dc/Support.js b/www/manager6/dc/Support.js index 86b656cd..d55ed011 100644 --- a/www/manager6/dc/Support.js +++ b/www/manager6/dc/Support.js @@ -1,6 +1,7 @@ Ext.define('PVE.dc.Support', { extend: 'Ext.panel.Panel', alias: 'widget.pveDcSupport', + pveGuidePath: '/pve-docs/index.html', invalidHtml: '

No valid subscription

' + PVE.Utils.noSubKeyHtml, @@ -10,13 +11,21 @@ Ext.define('PVE.dc.Support', { bugzillaHtml: '

Bug Tracking

Our bug tracking system is available here.', - docuHtml: '

Documentation

Complete documentation, tutorials, videos and more is available at our wiki.', + docuHtml: function() { + var me = this; + var guideUrl = window.location.origin + me.pveGuidePath; + var text = Ext.String.format('

Documentation

' + + 'The official Proxmox VE Administration Guide' + + ' is included with this installation and can be browsed at ' + + '{0}', guideUrl); + return text; + }, updateActive: function(data) { var me = this; var html = '

' + data.productname + '

' + me.activeHtml; - html += '

' + me.docuHtml; + html += '

' + me.docuHtml(); html += '

' + me.bugzillaHtml; me.update(html); @@ -26,7 +35,7 @@ Ext.define('PVE.dc.Support', { var me = this; var html = '

' + data.productname + '

' + me.communityHtml; - html += '

' + me.docuHtml; + html += '

' + me.docuHtml(); html += '

' + me.bugzillaHtml; me.update(html);