From 80c748682a862615605d9af58fe8e48e4f1981ad Mon Sep 17 00:00:00 2001 From: bfederle Date: Tue, 26 Jun 2012 13:43:16 -0700 Subject: [PATCH] CS-15290: Fix 'Path' field validation Original patch by: olga.smola reviewed-by: brian --- ui/scripts/system.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/ui/scripts/system.js b/ui/scripts/system.js index f6a5540a6e0..2cba42bbd5b 100644 --- a/ui/scripts/system.js +++ b/ui/scripts/system.js @@ -7531,7 +7531,8 @@ //$('li[input_group="nfs"]', $dialogAddPool).show(); $form.find('.form-item[rel=path]').css('display', 'inline-block'); //$dialogAddPool.find("#add_pool_path_container").find("label").text(g_dictionary["label.path"]+":"); - $form.find('.form-item[rel=path]').find(".name").find("label").text("Path:"); + var $required = $form.find('.form-item[rel=path]').find(".name").find("label span"); + $form.find('.form-item[rel=path]').find(".name").find("label").text("Path:").prepend($required); //$('li[input_group="iscsi"]', $dialogAddPool).hide(); $form.find('.form-item[rel=iqn]').hide(); @@ -7553,7 +7554,8 @@ //$('li[input_group="nfs"]', $dialogAddPool).show(); $form.find('.form-item[rel=path]').css('display', 'inline-block'); //$dialogAddPool.find("#add_pool_path_container").find("label").text(g_dictionary["label.path"]+":"); - $form.find('.form-item[rel=path]').find(".name").find("label").text("Path:"); + var $required = $form.find('.form-item[rel=path]').find(".name").find("label span"); + $form.find('.form-item[rel=path]').find(".name").find("label").text("Path:").prepend($required); //$('li[input_group="iscsi"]', $dialogAddPool).hide(); $form.find('.form-item[rel=iqn]').hide(); @@ -7574,8 +7576,9 @@ //$('li[input_group="nfs"]', $dialogAddPool).show(); $form.find('.form-item[rel=path]').css('display', 'inline-block'); - //$dialogAddPool.find("#add_pool_path_container").find("label").text(g_dictionary["label.SR.name"]+":"); - $form.find('.form-item[rel=path]').find(".name").find("label").text("SR Name-Label:"); + //$dialogAddPool.find("#add_pool_path_container").find("label").text(g_dictionary["label.SR.name"]+":"); + var $required = $form.find('.form-item[rel=path]').find(".name").find("label span"); + $form.find('.form-item[rel=path]').find(".name").find("label").text("SR Name-Label:").prepend($required); //$('li[input_group="iscsi"]', $dialogAddPool).hide(); $form.find('.form-item[rel=iqn]').hide(); @@ -7656,7 +7659,8 @@ //$('li[input_group="nfs"]', $dialogAddPool).show(); $form.find('.form-item[rel=path]').css('display', 'inline-block'); - $form.find('.form-item[rel=path]').find(".name").find("label").text("Path:"); + var $required = $form.find('.form-item[rel=path]').find(".name").find("label span"); + $form.find('.form-item[rel=path]').find(".name").find("label").text("Path:").prepend($required); //$('li[input_group="iscsi"]', $dialogAddPool).hide(); $form.find('.form-item[rel=iqn]').hide();