minor
This commit is contained in:
@@ -28,7 +28,8 @@
|
||||
v-tab
|
||||
v-badge(:value='!!unconfirmedEvents.length' :content='unconfirmedEvents.length') {{$t('common.events')}}
|
||||
v-tab-item
|
||||
Events(:unconfirmedEvents='unconfirmedEvents')
|
||||
Events(:unconfirmedEvents='unconfirmedEvents'
|
||||
@confirmed='id => { unconfirmedEvents = unconfirmedEvents.filter(e => e.id !== id)}')
|
||||
|
||||
//- ANNOUNCEMENTS
|
||||
v-tab {{$t('common.announcements')}}
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
:hide-no-data="!place._name"
|
||||
:search-input.sync="place._name"
|
||||
persistent-hint
|
||||
:value="value.place"
|
||||
:value="value.name"
|
||||
:items="places"
|
||||
item-text='name'
|
||||
@change='selectPlace')
|
||||
@@ -42,7 +42,6 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
selectPlace (p) {
|
||||
console.error(p)
|
||||
const place = p && this.places.find(place => place.id === p.id)
|
||||
if (place && place.address) {
|
||||
this.place.name = p.name
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
</template>
|
||||
<script>
|
||||
import { mapActions, mapState } from 'vuex'
|
||||
import _ from 'lodash'
|
||||
import dayjs from 'dayjs'
|
||||
import Editor from '@/components/Editor'
|
||||
import List from '@/components/List'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template lang='pug'>
|
||||
div
|
||||
v-btn(text color='primary' v-if='event.is_visible' @click='toggle(false)') {{$t(`common.${event.parentId?'skip':'hide'}`)}}
|
||||
v-btn(text color='primary' v-else @click='toggle(false)') {{$t('common.confirm')}}
|
||||
v-btn(text color='success' v-else @click='toggle(false)') {{$t('common.confirm')}}
|
||||
v-btn(text color='primary' @click='$router.push(`/add/${event.id}`)') {{$t('common.edit')}}
|
||||
v-btn(text color='primary' v-if='!event.parentId' @click='remove(false)') {{$t('common.remove')}}
|
||||
|
||||
@@ -41,7 +41,7 @@ export default {
|
||||
const is_visible = parent ? this.event.parent.is_visible : this.event.is_visible
|
||||
const method = is_visible ? 'unconfirm' : 'confirm'
|
||||
try {
|
||||
await this.$axios.$get(`/event/${method}/${id}`)
|
||||
await this.$axios.$put(`/event/${method}/${id}`)
|
||||
if (parent) {
|
||||
this.event.parent.is_visible = !is_visible
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user