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:
authorRobert Speicher <rspeicher@gmail.com>2021-01-20 22:34:23 +0300
committerRobert Speicher <rspeicher@gmail.com>2021-01-20 22:34:23 +0300
commit6438df3a1e0fb944485cebf07976160184697d72 (patch)
tree00b09bfd170e77ae9391b1a2f5a93ef6839f2597 /app/assets/javascripts/integrations
parent42bcd54d971da7ef2854b896a7b34f4ef8601067 (diff)
Add latest changes from gitlab-org/gitlab@13-8-stable-eev13.8.0-rc42
Diffstat (limited to 'app/assets/javascripts/integrations')
-rw-r--r--app/assets/javascripts/integrations/edit/components/dynamic_field.vue2
-rw-r--r--app/assets/javascripts/integrations/edit/components/integration_form.vue5
-rw-r--r--app/assets/javascripts/integrations/edit/components/jira_trigger_fields.vue4
-rw-r--r--app/assets/javascripts/integrations/edit/components/override_dropdown.vue2
-rw-r--r--app/assets/javascripts/integrations/edit/store/getters.js4
-rw-r--r--app/assets/javascripts/integrations/integration_settings_form.js7
6 files changed, 13 insertions, 11 deletions
diff --git a/app/assets/javascripts/integrations/edit/components/dynamic_field.vue b/app/assets/javascripts/integrations/edit/components/dynamic_field.vue
index 9dde1ed1055..f568f7e6d3d 100644
--- a/app/assets/javascripts/integrations/edit/components/dynamic_field.vue
+++ b/app/assets/javascripts/integrations/edit/components/dynamic_field.vue
@@ -92,7 +92,7 @@ export default {
return isEmpty(this.value) && this.required;
},
options() {
- return this.choices.map(choice => {
+ return this.choices.map((choice) => {
return {
value: choice[1],
text: choice[0],
diff --git a/app/assets/javascripts/integrations/edit/components/integration_form.vue b/app/assets/javascripts/integrations/edit/components/integration_form.vue
index c6f8ba8dcb2..ac8a64d5f3b 100644
--- a/app/assets/javascripts/integrations/edit/components/integration_form.vue
+++ b/app/assets/javascripts/integrations/edit/components/integration_form.vue
@@ -59,9 +59,6 @@ export default {
showReset() {
return this.isInstanceOrGroupLevel && this.propsSource.resetPath;
},
- saveButtonKey() {
- return `save-button-${this.isDisabled}`;
- },
},
methods: {
...mapActions([
@@ -120,7 +117,6 @@ export default {
<div v-if="isEditable" class="footer-block row-content-block">
<template v-if="isInstanceOrGroupLevel">
<gl-button
- :key="saveButtonKey"
v-gl-modal.confirmSaveIntegration
category="primary"
variant="success"
@@ -134,7 +130,6 @@ export default {
</template>
<gl-button
v-else
- :key="saveButtonKey"
category="primary"
variant="success"
type="submit"
diff --git a/app/assets/javascripts/integrations/edit/components/jira_trigger_fields.vue b/app/assets/javascripts/integrations/edit/components/jira_trigger_fields.vue
index 123d794912a..bc005aa16e9 100644
--- a/app/assets/javascripts/integrations/edit/components/jira_trigger_fields.vue
+++ b/app/assets/javascripts/integrations/edit/components/jira_trigger_fields.vue
@@ -91,6 +91,8 @@ export default {
<gl-form-group
v-show="showEnableComments"
:label="s__('Integrations|Comment settings:')"
+ label-for="service[comment_on_event_enabled]"
+ class="gl-pl-6"
data-testid="comment-settings"
>
<input
@@ -106,6 +108,8 @@ export default {
<gl-form-group
v-show="showEnableComments && enableComments"
:label="s__('Integrations|Comment detail:')"
+ label-for="service[comment_detail]"
+ class="gl-pl-9"
data-testid="comment-detail"
>
<input name="service[comment_detail]" type="hidden" :value="commentDetail" />
diff --git a/app/assets/javascripts/integrations/edit/components/override_dropdown.vue b/app/assets/javascripts/integrations/edit/components/override_dropdown.vue
index c31dada8d2f..4e2c37ac7f3 100644
--- a/app/assets/javascripts/integrations/edit/components/override_dropdown.vue
+++ b/app/assets/javascripts/integrations/edit/components/override_dropdown.vue
@@ -40,7 +40,7 @@ export default {
},
data() {
return {
- selected: dropdownOptions.find(x => x.value === this.override),
+ selected: dropdownOptions.find((x) => x.value === this.override),
};
},
computed: {
diff --git a/app/assets/javascripts/integrations/edit/store/getters.js b/app/assets/javascripts/integrations/edit/store/getters.js
index 310d970c73e..39e14de2d0d 100644
--- a/app/assets/javascripts/integrations/edit/store/getters.js
+++ b/app/assets/javascripts/integrations/edit/store/getters.js
@@ -1,6 +1,6 @@
-export const isInheriting = state => (state.defaultState === null ? false : !state.override);
+export const isInheriting = (state) => (state.defaultState === null ? false : !state.override);
-export const isDisabled = state => state.isSaving || state.isTesting || state.isResetting;
+export const isDisabled = (state) => state.isSaving || state.isTesting || state.isResetting;
export const propsSource = (state, getters) =>
getters.isInheriting ? state.defaultState : state.customState;
diff --git a/app/assets/javascripts/integrations/integration_settings_form.js b/app/assets/javascripts/integrations/integration_settings_form.js
index 14d6f133d27..861655a6a64 100644
--- a/app/assets/javascripts/integrations/integration_settings_form.js
+++ b/app/assets/javascripts/integrations/integration_settings_form.js
@@ -1,4 +1,5 @@
import $ from 'jquery';
+import { delay } from 'lodash';
import axios from '../lib/utils/axios_utils';
import { __, s__ } from '~/locale';
import toast from '~/vue_shared/plugins/global_toast';
@@ -22,7 +23,7 @@ export default class IntegrationSettingsForm {
document.querySelector('.js-vue-integration-settings'),
document.querySelector('.js-vue-default-integration-settings'),
);
- eventHub.$on('toggle', active => {
+ eventHub.$on('toggle', (active) => {
this.formActive = active;
this.toggleServiceState();
});
@@ -43,7 +44,9 @@ export default class IntegrationSettingsForm {
const formValid = this.$form.get(0).checkValidity() || this.formActive === false;
if (formValid) {
- this.$form.submit();
+ delay(() => {
+ this.$form.trigger('submit');
+ }, 100);
} else {
eventHub.$emit('validateForm');
this.vue.$store.dispatch('setIsSaving', false);