summaryrefslogtreecommitdiffstats
path: root/install/ui/association.js
diff options
context:
space:
mode:
Diffstat (limited to 'install/ui/association.js')
-rw-r--r--install/ui/association.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/install/ui/association.js b/install/ui/association.js
index 3d75072a..47d8db17 100644
--- a/install/ui/association.js
+++ b/install/ui/association.js
@@ -177,14 +177,17 @@ IPA.association_adder_dialog = function(spec) {
var other_entity = IPA.get_entity(that.other_entity);
var pkey_attr = other_entity.metadata.primary_key;
+ var selected = that.get_selected_values();
+
var results = data.result;
for (var i=0; i<results.count; i++) {
var result = results.result[i];
var pkey = result[pkey_attr][0];
- if (that.exclude.indexOf(pkey) < 0) {
- that.add_available_value(result);
- }
+ if (that.exclude.indexOf(pkey) >= 0) continue;
+ if (selected.indexOf(pkey) >= 0) continue;
+
+ that.add_available_value(result);
}
}