Skip to content

Commit 2e645d1

Browse files
author
Jessica Wang
committed
bug 9795: Copy Template Dialog, Copy ISO Dialog - fix a bug that entries in zone dropdown are duplicated when the dialog pops up the 2nd time.
1 parent 8901d0e commit 2e645d1

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

‎ui/scripts/cloud.core.iso.js‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,8 @@ function initAddIsoDialog() {
109109
$.ajax({
110110
data: createURL("command=listZones&available=true"),
111111
dataType: "json",
112-
success: function(json) {
112+
success: function(json) {
113+
g_zoneIds = [];
113114
var zones = json.listzonesresponse.zone;
114115
if (zones != null && zones.length > 0) {
115116
for (var i = 0; i < zones.length; i++) {

‎ui/scripts/cloud.core.template.js‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,8 @@ function afterLoadTemplateJSP() {
217217
$.ajax({
218218
data: createURL("command=listZones&available=true"),
219219
dataType: "json",
220-
success: function(json) {
220+
success: function(json) {
221+
g_zoneIds = [];
221222
var zones = json.listzonesresponse.zone;
222223
if (zones != null && zones.length > 0) {
223224
for (var i = 0; i < zones.length; i++) {

0 commit comments

Comments
 (0)