[pve-devel] [PATCH manager 3/5] Add renderer for audio devices

Tim Marx t.marx at proxmox.com
Tue Jul 16 13:33:36 CEST 2019


> 
>  
> Signed-off-by: Aaron Lauterer <a.lauterer at proxmox.com>
> ---
>  www/manager6/Utils.js | 15 +++++++++++++++
>  1 file changed, 15 insertions(+)
> 
> diff --git a/www/manager6/Utils.js b/www/manager6/Utils.js
> index 946b8709..3980b750 100644
> --- a/www/manager6/Utils.js
> +++ b/www/manager6/Utils.js
> @@ -467,6 +467,21 @@ Ext.define('PVE.Utils', { utilities: {
>  	return res;
>      },
>  
> +    render_audio_device: function (value) {
> +	if (!value) {
> +	    return Proxmox.Utils.defaultText;
> +	}
> +	var audio = PVE.Parser.parsePropertyString(value);
> +
> +	if (!audio.type) {
> +	    text = Proxmox.Utils.defaultText;

text isn't defined in this context.
Does it even make sense to return "default", I'm not sure what this would mean in this context? 

> +	}
> +	else {

code style

> +	    return audio.type;
> +	}
> +	return value;
> +    },
> +
>      extractFormActionError: function(action) {
>  	var msg;
>  	switch (action.failureType) {
> -- 
> 2.20.1
> 
> 
> _______________________________________________
> pve-devel mailing list
> pve-devel at pve.proxmox.com
> https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel




More information about the pve-devel mailing list