]>
git.proxmox.com Git - pve-manager.git/blob - www/manager6/dc/Support.js
1 Ext
. define ( 'PVE.dc.Support' , {
2 extend
: 'Ext.panel.Panel' ,
3 alias
: 'widget.pveDcSupport' ,
5 invalidHtml
: '<h1>No valid subscription</h1>' + PVE
. Utils
. noSubKeyHtml
,
7 communityHtml
: 'Please use the public community <a target="_blank" href="http://forum.proxmox.com">forum</a> for any questions.' ,
9 activeHtml
: 'Please use our <a target="_blank" href="https://my.proxmox.com">support portal</a> for any questions. You can also use the public community <a target="_blank" href="http://forum.proxmox.com">forum</a> to get additional information.' ,
11 bugzillaHtml
: '<h1>Bug Tracking</h1>Our bug tracking system is available <a target="_blank" href="https://bugzilla.proxmox.com">here</a>.' ,
13 docuHtml
: '<h1>Documentation</h1>Complete documentation, tutorials, videos and more is available at our <a target="_blank" href="http://pve.proxmox.com/wiki/Documentation">wiki</a>.' ,
15 updateActive : function ( data
) {
18 var html
= '<h1>' + data
. productname
+ '</h1>' + me
. activeHtml
;
19 html
+= '<br><br>' + me
. docuHtml
;
20 html
+= '<br><br>' + me
. bugzillaHtml
;
25 updateCommunity : function ( data
) {
28 var html
= '<h1>' + data
. productname
+ '</h1>' + me
. communityHtml
;
29 html
+= '<br><br>' + me
. docuHtml
;
30 html
+= '<br><br>' + me
. bugzillaHtml
;
35 updateInactive : function ( data
) {
37 me
. update ( me
. invalidHtml
);
40 initComponent : function () {
43 var reload = function () {
44 PVE
. Utils
. API2Request ({
45 url
: '/nodes/localhost/subscription' ,
48 failure : function ( response
, opts
) {
49 Ext
. Msg
. alert ( gettext ( 'Error' ), response
. htmlStatus
);
50 me
. update ( 'Unable to load subscription status' + ": " + response
. htmlStatus
);
52 success : function ( response
, opts
) {
53 var data
= response
. result
. data
;
55 if ( data
. status
=== 'Active' ) {
56 if ( data
. level
=== 'c' ) {
57 me
. updateCommunity ( data
);
59 me
. updateActive ( data
);
62 me
. updateInactive ( data
);
70 bodyStyle
: 'padding:10px' ,