Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2018-08-07 01:21:39 +0300
committerFatih Acet <acetfatih@gmail.com>2018-08-07 01:21:39 +0300
commita8c9cd41d2f3dd4b1606aae94a551f35dfd6a708 (patch)
treec672d177e7dad767d5eecc7c750e6688f86af8ef
parentac1d83c56b4aa550761a13f25d7650c94194553f (diff)
Update CreateItemDropdown class to allow the glDropdown filterRemote option
-rw-r--r--app/assets/javascripts/create_item_dropdown.js3
-rw-r--r--app/assets/javascripts/environments/components/environment_item.vue3
2 files changed, 4 insertions, 2 deletions
diff --git a/app/assets/javascripts/create_item_dropdown.js b/app/assets/javascripts/create_item_dropdown.js
index 42e9e568170..8ef9aa7f529 100644
--- a/app/assets/javascripts/create_item_dropdown.js
+++ b/app/assets/javascripts/create_item_dropdown.js
@@ -12,6 +12,7 @@ export default class CreateItemDropdown {
this.fieldName = options.fieldName;
this.onSelect = options.onSelect || (() => {});
this.getDataOption = options.getData;
+ this.getDataRemote = !!options.filterRemote;
this.createNewItemFromValueOption = options.createNewItemFromValue;
this.$dropdown = options.$dropdown;
this.$dropdownContainer = this.$dropdown.parent();
@@ -29,7 +30,7 @@ export default class CreateItemDropdown {
this.$dropdown.glDropdown({
data: this.getData.bind(this),
filterable: true,
- remote: false,
+ filterRemote: this.getDataRemote,
search: {
fields: ['text'],
},
diff --git a/app/assets/javascripts/environments/components/environment_item.vue b/app/assets/javascripts/environments/components/environment_item.vue
index 21cf92d1bc5..11e3b781e5a 100644
--- a/app/assets/javascripts/environments/components/environment_item.vue
+++ b/app/assets/javascripts/environments/components/environment_item.vue
@@ -116,7 +116,8 @@ export default {
this.model &&
this.hasLastDeploymentKey &&
this.model.last_deployment &&
- this.model.last_deployment.deployable
+ this.model.last_deployment.deployable &&
+ this.model.last_deployment.deployable.retry_path
);
},