Commit e40f0346 authored by Korko's avatar Korko
Browse files

Fixes #101 - Handle exclusions via form submit

parent b0da212a
Pipeline #190038 passed with stage
in 13 minutes and 10 seconds
......@@ -8319,11 +8319,6 @@
"duplexer2": "0.0.2"
}
},
"multiple-select": {
"version": "1.5.1",
"resolved": "https://registry.npmjs.org/multiple-select/-/multiple-select-1.5.1.tgz",
"integrity": "sha512-VPEEd0jWZ/MhbfA2iC9yxk06MyKD21HMHs5Nw/wxE3bJmrY2JL+UJZdnV9nrOLIraJSrw8FTwpAWYYlOrXViPA=="
},
"mute-stream": {
"version": "0.0.7",
"resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.7.tgz",
......
......@@ -8291,7 +8291,7 @@ footer .row {
display: inline-block;
float: none; }
.navbar-nav > li:nth-child(2) {
margin-right: 110px; }
margin-right: 140px; }
.navbar-nav > li.btn-group {
margin: 0 15px; } }
......
......@@ -8291,7 +8291,7 @@ footer .row {
display: inline-block;
float: none; }
.navbar-nav > li:nth-child(2) {
margin-right: 110px; }
margin-right: 140px; }
.navbar-nav > li.btn-group {
margin: 0 15px; } }
......
......@@ -8291,7 +8291,7 @@ footer .row {
display: inline-block;
float: none; }
.navbar-nav > li:nth-child(2) {
margin-right: 110px; }
margin-right: 140px; }
.navbar-nav > li.btn-group {
margin: 0 15px; } }
......
<template>
<select multiple="multiple" :name="name">
<option v-for="option in options" :value="option.value" :key="option.id || option.value">{{ option.text }}</option>
</select>
</template>
<script>
var jQuery = require('jquery');
require('multiple-select');
export default {
props: ['name', 'options', 'value', 'placeholder'],
mounted: function() {
jQuery(this.$el).multipleSelect({selectAll: false, filter: true, placeholder: this.placeholder, ellipsis: true});
},
updated: function() {
jQuery(this.$el).multipleSelect('refresh');
}
}
</script>
<style>
select {
min-width: 300px;
}
</style>
......@@ -19,7 +19,10 @@
</div>
</td>
<td class="row border-right text-left participant-exclusions-wrapper">
<multiselect :name="'exclusions['+idx+'][]'" :options="participantNames" v-model="exclusions" track-by="value" label="text" placeholder="@lang('form.exclusions.placeholder')" :multiple="true"></multiselect>
<multiselect :options="participantNames" v-model="exclusions" track-by="value" label="text" placeholder="@lang('form.exclusions.placeholder')" :multiple="true"></multiselect>
<select style="display:none" :name="'exclusions['+idx+'][]'" multiple>
<option v-for="participantName in participantNames" :value="participantName.value" :selected="exclusions.find(a => (a.value === participantName.value))"></option>
</select>
</td>
<td class="row participant-remove-wrapper">
<button type="button" class="btn btn-danger participant-remove" :disabled="participants.length <= 3" @click="$emit('delete')">
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment