[Kimchi-devel] [PATCH] [Kimchi] Edit template storage path should start with "/"
Lucio Correia
luciojhc at linux.vnet.ibm.com
Thu Nov 3 11:16:20 UTC 2016
Reviewed-By: Lucio Correia <luciojhc at linux.vnet.ibm.com>
On 02/11/2016 06:58, rajgupta at linux.vnet.ibm.com wrote:
> From: Rajat Gupta <rajat.triumph at gmail.com>
>
> Edit template storage path should start with "/"
>
> Signed-off-by: Rajat Gupta <rajat.triumph at gmail.com>
> ---
> ui/js/src/kimchi.template_edit_main.js | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/ui/js/src/kimchi.template_edit_main.js b/ui/js/src/kimchi.template_edit_main.js
> index 1a6e473..758201f 100644
> --- a/ui/js/src/kimchi.template_edit_main.js
> +++ b/ui/js/src/kimchi.template_edit_main.js
> @@ -339,7 +339,8 @@ kimchi.template_edit_main = function() {
> });
>
> $(storageRow + ' input.storage-path').on('change input keyup',function(){
> - if($(storageRow + ' input.storage-path').val()){
> + var storagepath = $(storageRow + ' input.storage-path').val();
> + if( storagepath && storagepath.charAt(0) == '/'){
> $(storageRow + ' span.storage-path').removeClass('has-error');
> }else{
> $(storageRow + ' span.storage-path').addClass('has-error');
>
--
Lucio Correia
Software Engineer
IBM LTC Brazil
More information about the Kimchi-devel
mailing list