Signed-off-by: Aline Manera <alinefm(a)linux.vnet.ibm.com>
---
model/storagevolumes.py | 2 +-
ui/js/src/kimchi.guest_storage_add.main.js | 7 +++++--
ui/pages/i18n.json.tmpl | 1 +
3 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/model/storagevolumes.py b/model/storagevolumes.py
index 83f38e2..e037e35 100644
--- a/model/storagevolumes.py
+++ b/model/storagevolumes.py
@@ -154,7 +154,7 @@ class StorageVolumesModel(object):
pool.createXML(xml, 0)
except libvirt.libvirtError as e:
raise OperationFailed("KCHVOL0007E",
- {'name': name, 'pool': pool,
+ {'name': name, 'pool': pool_name,
'err': e.get_error_message()})
vol_info = StorageVolumeModel(conn=self.conn,
diff --git a/ui/js/src/kimchi.guest_storage_add.main.js
b/ui/js/src/kimchi.guest_storage_add.main.js
index fb7fed3..4b5c154 100644
--- a/ui/js/src/kimchi.guest_storage_add.main.js
+++ b/ui/js/src/kimchi.guest_storage_add.main.js
@@ -341,9 +341,12 @@ kimchi.guest_storage_add_main = function() {
setTimeout(monitorTask, 2000);
$(submitButton).prop('disabled', true);
} else if (status === "failed") {
- var errText = result['reason'] ||
+ var errText = result['message'] ||
result['responseJSON']['reason'];
- $(submitButton).prop('disabled', true);
+ $(submitButton).text(i18n['KCHVMCD6002M']);
+ $(submitButton).prop('disabled', false);
+ $(capacityTextbox).prop('disabled', false);
+ $(formatTextbox).prop('disabled', false);
wok.message.error(errText, '#alert-modal-container2');
}
});
diff --git a/ui/pages/i18n.json.tmpl b/ui/pages/i18n.json.tmpl
index 95c5600..e152989 100644
--- a/ui/pages/i18n.json.tmpl
+++ b/ui/pages/i18n.json.tmpl
@@ -71,6 +71,7 @@
"KCHVM0003E": "$_("Current CPUs value cannot be higher than Max
CPU value")",
"KCHVMCD6001M": "$_("This CDROM will be detached permanently and
you can re-attach it. Continue to detach it?")",
+ "KCHVMCD6002M": "$_("Attach")",
"KCHVMCD6003M": "$_("Attaching...")",
"KCHVMCD6009M": "$_("This disk will be detached permanently and
you can re-attach it. Continue to detach it?")",
--
2.5.5