mirror of
https://framagit.org/les/gancio.git
synced 2025-01-31 16:42:22 +01:00
minor
This commit is contained in:
parent
f6f4ef9b1c
commit
bf95c26394
6 changed files with 21 additions and 17 deletions
|
@ -1,7 +1,7 @@
|
||||||
<template lang="pug" functional>
|
<template lang="pug" functional>
|
||||||
v-card.h-event.event
|
v-card.h-event.event
|
||||||
nuxt-link(:to='`/event/${props.event.id}`')
|
nuxt-link(:to='`/event/${props.event.id}`')
|
||||||
v-img.align-end.white--text(:src="`/media/thumb/${props.event.image_path}`"
|
v-img.align-end.white--text(:src="`/media/thumb/${props.event.image_path || 'logo.png' }`"
|
||||||
gradient="to bottom, rgba(0,0,0,.1), rgba(0,0,0,.7), rgba(0,0,0,.9)"
|
gradient="to bottom, rgba(0,0,0,.1), rgba(0,0,0,.7), rgba(0,0,0,.9)"
|
||||||
height="250" position="top top" )
|
height="250" position="top top" )
|
||||||
v-card-title.text-h6.p-name {{props.event.title}}
|
v-card-title.text-h6.p-name {{props.event.title}}
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
v-card-subtitle {{$t('admin.event_confirm_description')}}
|
v-card-subtitle {{$t('admin.event_confirm_description')}}
|
||||||
v-card-text
|
v-card-text
|
||||||
v-data-table(
|
v-data-table(
|
||||||
|
:hide-default-footer='unconfirmedEvents.length<10'
|
||||||
:items='unconfirmedEvents'
|
:items='unconfirmedEvents'
|
||||||
:headers='headers')
|
:headers='headers')
|
||||||
template(v-slot:item.actions='{ item }')
|
template(v-slot:item.actions='{ item }')
|
||||||
|
|
|
@ -66,16 +66,17 @@ export default {
|
||||||
try {
|
try {
|
||||||
const users = await $axios.$get('/users')
|
const users = await $axios.$get('/users')
|
||||||
const unconfirmedEvents = await $axios.$get('/event/unconfirmed')
|
const unconfirmedEvents = await $axios.$get('/event/unconfirmed')
|
||||||
return { users, unconfirmedEvents }
|
return { users, unconfirmedEvents, selectedTab: 0 }
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error(e)
|
console.error(e)
|
||||||
return { users: [], unconfirmedEvents: [] }
|
return { users: [], unconfirmedEvents: [], selectedTab: 0 }
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
description: '',
|
description: '',
|
||||||
unconfirmedEvents: []
|
unconfirmedEvents: [],
|
||||||
|
selectedTab: 0
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
|
|
@ -4,7 +4,7 @@ v-row
|
||||||
mode='dateTime'
|
mode='dateTime'
|
||||||
is24hr
|
is24hr
|
||||||
:input-debounce="200"
|
:input-debounce="200"
|
||||||
:min='today'
|
:min-date='new Date()'
|
||||||
:minute-increment="5"
|
:minute-increment="5"
|
||||||
is-dark
|
is-dark
|
||||||
is-expanded
|
is-expanded
|
||||||
|
@ -25,9 +25,9 @@ v-row
|
||||||
v-date-picker.col-md-4(
|
v-date-picker.col-md-4(
|
||||||
mode='dateTime'
|
mode='dateTime'
|
||||||
is24hr
|
is24hr
|
||||||
|
:min-date='new Date()'
|
||||||
:minute-increment="5"
|
:minute-increment="5"
|
||||||
:input-debounce="200"
|
:input-debounce="200"
|
||||||
:min='today'
|
|
||||||
is-dark
|
is-dark
|
||||||
is-expanded
|
is-expanded
|
||||||
@input='v => change("due", v)'
|
@input='v => change("due", v)'
|
||||||
|
@ -90,7 +90,6 @@ export default {
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
today: dayjs().format('YYYY-MM-DD'),
|
|
||||||
frequency: '',
|
frequency: '',
|
||||||
frequencies: [
|
frequencies: [
|
||||||
{ value: '1w', text: this.$t('event.each_week') },
|
{ value: '1w', text: this.$t('event.each_week') },
|
||||||
|
|
|
@ -15,6 +15,8 @@ v-container
|
||||||
:src='imgPath'
|
:src='imgPath'
|
||||||
:lazy-src='thumbImgPath'
|
:lazy-src='thumbImgPath'
|
||||||
v-if='event.image_path')
|
v-if='event.image_path')
|
||||||
|
.p-description.text-body-1.px-5.mt-5(v-else v-html='event.description')
|
||||||
|
|
||||||
//- template(v-slot:placeholder)
|
//- template(v-slot:placeholder)
|
||||||
//- v-row(
|
//- v-row(
|
||||||
//- class="fill-height ma-0"
|
//- class="fill-height ma-0"
|
||||||
|
@ -33,13 +35,13 @@ v-container
|
||||||
time.dt-start.text-h6(:datetime='event.start_datetime|unixFormat("YYYY-MM-DD HH:mm")')
|
time.dt-start.text-h6(:datetime='event.start_datetime|unixFormat("YYYY-MM-DD HH:mm")')
|
||||||
v-icon mdi-calendar
|
v-icon mdi-calendar
|
||||||
b.ml-2 {{event|when}}
|
b.ml-2 {{event|when}}
|
||||||
div.subtitle-1 {{event.start_datetime|from}}
|
div.text-subtitle-1 {{event.start_datetime|from}}
|
||||||
small(v-if='event.parentId') ({{event|recurrentDetail}})
|
small(v-if='event.parentId') ({{event|recurrentDetail}})
|
||||||
|
|
||||||
.text-h6.p-location
|
.text-h6.p-location
|
||||||
v-icon mdi-map-marker
|
v-icon mdi-map-marker
|
||||||
b.vcard.ml-2 {{event.place.name}}
|
b.vcard.ml-2 {{event.place.name}}
|
||||||
p.adr {{event.place.address}}
|
.text-subtitle-1.adr {{event.place.address}}
|
||||||
|
|
||||||
//- info & actions
|
//- info & actions
|
||||||
v-toolbar
|
v-toolbar
|
||||||
|
@ -59,7 +61,7 @@ v-container
|
||||||
:href='`/api/event/${event.id}.ics`')
|
:href='`/api/event/${event.id}.ics`')
|
||||||
v-icon mdi-calendar-export
|
v-icon mdi-calendar-export
|
||||||
|
|
||||||
.p-description.text-body-1.px-5(v-html='event.description')
|
.p-description.text-body-1.px-5(v-if='event.image_path' v-html='event.description')
|
||||||
v-chip.p-category.ml-1(v-for='tag in event.tags' color='primary'
|
v-chip.p-category.ml-1(v-for='tag in event.tags' color='primary'
|
||||||
outlined :key='tag' v-text='tag')
|
outlined :key='tag' v-text='tag')
|
||||||
|
|
||||||
|
@ -236,11 +238,7 @@ export default {
|
||||||
return '/media/' + this.event.image_path
|
return '/media/' + this.event.image_path
|
||||||
},
|
},
|
||||||
thumbImgPath () {
|
thumbImgPath () {
|
||||||
if (this.event.image_path) {
|
return this.settings.baseurl + '/media/thumb/' + this.event.image_path
|
||||||
return this.settings.baseurl + '/media/thumb/' + this.event.image_path
|
|
||||||
} else {
|
|
||||||
return this.settings.baseurl + '/logo.png'
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
is_mine () {
|
is_mine () {
|
||||||
if (!this.$auth.user) {
|
if (!this.$auth.user) {
|
||||||
|
|
|
@ -40,16 +40,17 @@ export default {
|
||||||
end: null,
|
end: null,
|
||||||
filters: { show_recurrent: store.state.settings.allow_recurrent_event && store.state.settings.recurrent_event_visible }
|
filters: { show_recurrent: store.state.settings.allow_recurrent_event && store.state.settings.recurrent_event_visible }
|
||||||
})
|
})
|
||||||
return { events }
|
return { events, first: true }
|
||||||
},
|
},
|
||||||
data ({ $store }) {
|
data ({ $store }) {
|
||||||
return {
|
return {
|
||||||
|
first: true,
|
||||||
date: dayjs().format('YYYY-MM-DD'),
|
date: dayjs().format('YYYY-MM-DD'),
|
||||||
events: [],
|
events: [],
|
||||||
start: dayjs().unix(),
|
start: dayjs().unix(),
|
||||||
end: null,
|
end: null,
|
||||||
filters: { tags: [], places: [], show_recurrent: $store.state.settings.allow_recurrent_event && $store.state.settings.recurrent_event_visible },
|
filters: { tags: [], places: [], show_recurrent: $store.state.settings.allow_recurrent_event && $store.state.settings.recurrent_event_visible },
|
||||||
selectedDay: null,
|
selectedDay: null
|
||||||
// intersecting: {}
|
// intersecting: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -94,6 +95,10 @@ export default {
|
||||||
this.updateEvents()
|
this.updateEvents()
|
||||||
},
|
},
|
||||||
monthChange ({ year, month }) {
|
monthChange ({ year, month }) {
|
||||||
|
if (this.first) {
|
||||||
|
this.first = false
|
||||||
|
return
|
||||||
|
}
|
||||||
this.selectedDay = null
|
this.selectedDay = null
|
||||||
|
|
||||||
// check if current month is selected
|
// check if current month is selected
|
||||||
|
|
Loading…
Reference in a new issue