Minor: fix start and end parameters for session composable

pull/4771/head
Daniel Gayoso González 1 year ago
parent 2daeb7aa19
commit aa164335e0
  1. 4
      assets/vue/views/user/sessions/Past.vue
  2. 2
      assets/vue/views/user/sessions/Upcoming.vue
  3. 4
      assets/vue/views/user/sessions/session.js

@ -18,8 +18,8 @@ const store = useStore()
let user = computed(() => store.getters['security/getUser'])
let start = DateTime.local().minus({days: 360}).toISO()
let end = DateTime.local().toISO()
let start = DateTime.local().minus({days: 360})
let end = DateTime.local()
const {sessions} = useSession(user, start, end)
</script>

@ -17,7 +17,7 @@ const store = useStore();
let user = computed(() => store.getters['security/getUser']);
let start = DateTime.local().toISO()
let start = DateTime.local()
const {sessions} = useSession(user, start)
</script>

@ -34,7 +34,7 @@ const includeStartDateIfExist = (variables, start) => {
if (!DateTime.isDateTime(start)) {
console.error("You should pass a DateTime instance to useSession start parameter")
}
variables.afterStartDate = start
variables.afterStartDate = start.toISO()
}
return variables
@ -45,7 +45,7 @@ const includeEndDateIfExist = (variables, end) => {
if (!DateTime.isDateTime(end)) {
console.error("You should pass a DateTime instance to useSession end parameter")
}
variables.beforeEndDate = end
variables.beforeEndDate = end.toISO()
}
return variables

Loading…
Cancel
Save