summaryrefslogtreecommitdiffstats
path: root/webapp/src/components/EventModuleEdit.vue
diff options
context:
space:
mode:
Diffstat (limited to 'webapp/src/components/EventModuleEdit.vue')
-rw-r--r--webapp/src/components/EventModuleEdit.vue16
1 files changed, 9 insertions, 7 deletions
diff --git a/webapp/src/components/EventModuleEdit.vue b/webapp/src/components/EventModuleEdit.vue
index 40b2b87..225614a 100644
--- a/webapp/src/components/EventModuleEdit.vue
+++ b/webapp/src/components/EventModuleEdit.vue
@@ -214,7 +214,7 @@
v-on="on"
></v-text-field>
</template>
- <v-date-picker color="primary" header-color="primary" v-model="startDate" @input="startDatePick()" first-day-of-week="1"></v-date-picker>
+ <v-date-picker color="primary" header-color="primary" v-model="startDate" @input="startDatePick()" first-day-of-week="1" :locale="locale"></v-date-picker>
</v-menu>
</v-flex>
<v-flex xs12 md5 offset-md1>
@@ -236,7 +236,7 @@
v-on="on"
></v-text-field>
</template>
- <v-date-picker color="primary" header-color="primary" :min="startDate" v-model="endDate" @input="endDatePick()" first-day-of-week="1"></v-date-picker>
+ <v-date-picker color="primary" header-color="primary" :min="startDate" v-model="endDate" @input="endDatePick()" first-day-of-week="1" :locale="locale"></v-date-picker>
</v-menu>
</v-flex>
<v-flex xs12 md5>
@@ -266,6 +266,7 @@
color="primary"
header-color="primary"
@click:minute="startTimeMenu = false"
+ :locale="locale"
></v-time-picker>
</v-menu>
</v-flex>
@@ -297,6 +298,7 @@
color="primary"
header-color="primary"
@click:minute="endTimeMenu = false"
+ :locale="locale"
></v-time-picker>
</v-menu>
</v-flex>
@@ -383,11 +385,9 @@
<v-card-actions>
<v-spacer></v-spacer>
<v-btn flat @click.native="$store.commit('events/setDialog', { show : false } )">{{ $t('cancel') }}</v-btn>
- <v-btn :color="dialog.info.id ? 'primary' : 'success'" v-show="step == 1" @click="submit" type="submit">{{ dialog.info.id ? $t('save') : $t('create') }}</v-btn>
+ <v-btn :color="dialog.info.id ? 'primary' : 'success'" @click="submit" type="submit">{{ dialog.info.id ? $t('save') : $t('create') }}</v-btn>
<v-btn color="primary" v-show="step == 1" @click.native="completeStepOne()">{{ $t('continue') }}</v-btn>
- <v-btn :color="dialog.info.id ? 'primary' : 'success'" v-show="step == 2" @click="submit" type="submit">{{ dialog.info.id ? $t('save') : $t('create') }}</v-btn>
<v-btn color="primary" v-show="step == 2 && groups.length > 0" @click.native="completeStepTwo()">{{ $t('continue') }}</v-btn>
- <v-btn :color="dialog.info.id ? 'primary' : 'success'" v-show="step == 3" @click="submit" type="submit">{{ dialog.info.id ? $t('save') : $t('create') }}</v-btn>
</v-card-actions>
</v-card>
</template>
@@ -449,7 +449,8 @@ export default {
},
computed: {
...mapState('events', ['dialog', 'configList']),
- ...mapState('groups', ['groupList', 'clientList'])
+ ...mapState('groups', ['groupList', 'clientList']),
+ locale () { return this.$store.state.settings.locale }
},
watch: {
step (val) {
@@ -590,7 +591,8 @@ export default {
}
await this.loadChilds()
// Submit
- await this.$http.post('/api/events/' + this.dialog.info.id, {
+ const url = this.dialog.info.id === undefined ? '/api/events' : '/api/events/' + this.dialog.info.id
+ await this.$http.post(url, {
name: this.name,
description: this.description,
groups: this.groups.map(x => x.id),