KMP-4: - Retrieve the zpush version from the About() service request and show it in the settings
This commit is contained in:
17
js/MDM.js
17
js/MDM.js
@ -3,7 +3,7 @@ Ext.namespace('Zarafa.plugins.mdm');
|
||||
/**
|
||||
* @class Zarafa.plugins.mdm.MDM
|
||||
* @extends Zarafa.core.Plugin
|
||||
*
|
||||
*
|
||||
* Plugin which lists all devices connected to a Kopano account with Z-Push.
|
||||
* The user can wipe, resync, remove a device using buttons in the WebApp.
|
||||
*/
|
||||
@ -26,19 +26,30 @@ Zarafa.plugins.mdm.MDM = Ext.extend(Zarafa.core.Plugin, {
|
||||
initPlugin : function()
|
||||
{
|
||||
this.registerInsertionPoint('context.settings.categories', this.createSettingCategory, this);
|
||||
this.registerInsertionPoint('settings.versioninformation', this.createVersionInfo, this);
|
||||
Zarafa.plugins.mdm.MDM.superclass.initPlugin.apply(this, arguments);
|
||||
},
|
||||
|
||||
/**
|
||||
* Creates a category in settings for Z-Push
|
||||
* @return {mdmsettingscategory}
|
||||
* @return {mdmsettingscategory}
|
||||
*/
|
||||
createSettingCategory: function() {
|
||||
return [{
|
||||
xtype : 'Zarafa.plugins.mdm.mdmsettingscategory'
|
||||
}];
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Creates a displayField that will show the version of the Z-Push server
|
||||
*/
|
||||
createVersionInfo : function() {
|
||||
var version = container.getSettingsModel().get('zarafa/v1/plugins/mdm/zpush-server-version', true);
|
||||
return {
|
||||
fieldLabel : _('Z-Push', 'plugin_mdm'),
|
||||
value : version
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
Zarafa.onReady(function() {
|
||||
|
Reference in New Issue
Block a user