[fix] remove comment
This commit is contained in:
parent
3b68182a29
commit
efb695c9ee
1 changed files with 5 additions and 4 deletions
|
@ -37,8 +37,6 @@
|
|||
//- TODO (ics of recurrent events)
|
||||
el-menu-item(v-if='!event.recurrent')
|
||||
a.d-block(:href='`${settings.baseurl}/api/event/${event.id}.ics`') {{$t('common.add_to_calendar')}}
|
||||
//- el-button(plain size='mini' type='primary'
|
||||
//- icon='el-icon-document' ) {{$t('common.send_via_mail')}}
|
||||
EventAdmin(v-if='is_mine' :event='event')
|
||||
hr
|
||||
|
||||
|
@ -115,12 +113,15 @@ export default {
|
|||
]
|
||||
}
|
||||
},
|
||||
async asyncData ({ $axios, params, error }) {
|
||||
async asyncData ({ $axios, params, error, store }) {
|
||||
try {
|
||||
const [ id, start_datetime ] = params.id.split('_')
|
||||
const event = await $axios.$get(`/event/${id}`)
|
||||
event.start_datetime = start_datetime ? Number(start_datetime) : event.start_datetime
|
||||
event.end_datetime = event.end_datetime
|
||||
const now = new Date()
|
||||
const events = await $axios.$get(`/event/${now.getMonth()}/${now.getFullYear()}`)
|
||||
store.commit('setEvents', events)
|
||||
return { event, id: Number(id) }
|
||||
} catch (e) {
|
||||
error({ statusCode: 404, message: 'Event not found' })
|
||||
|
|
Loading…
Reference in a new issue