Skip to content
Snippets Groups Projects
Verified Commit e3ad9427 authored by Jonathan Weth's avatar Jonathan Weth :keyboard:
Browse files

Merge branch 'refactor/calendar-overview' of...

Merge branch 'refactor/calendar-overview' of edugit.org:AlekSIS/official/AlekSIS-Core into refactor/calendar-overview
parents d7e2ad27 9cb8cd39
No related branches found
No related tags found
1 merge request!1304Refactor calendar overview in more different components
Pipeline #141846 failed
......@@ -8,7 +8,9 @@
class="fc-my-auto"
>
<template #item="item">
<slot name="item" v-bind="item" />
<slot name="item" v-bind="item">
{{ item.item[itemName] }}
</slot>
</template>
<template #append-outer>
<v-btn icon @click="menu = true">
......@@ -176,6 +178,9 @@ export default {
default: "actions.create",
},
},
mounted() {
this.$apollo.queries.items.refetch();
},
};
</script>
......
......@@ -317,6 +317,10 @@
"saved": "Alle Änderungen sind gespeichert.",
"updating": "Änderungen werden synchronisiert."
},
"generic_messages": {
"error": "Es ist ein Fehler aufgetreten. Bitte versuchen Sie es erneut.",
"success": "Der Vorgang wurde erfolgreich beendet."
},
"weekdays": {
"A_0": "Montag",
"A_1": "Dienstag",
......
......@@ -283,6 +283,10 @@
"object_delete_success": "The object was deleted successfully.",
"objects_delete_success": "The objects were deleted successfully."
},
"generic_messages": {
"error": "An error occurred. Please try again.",
"success": "The operation has been finished successfully."
},
"rooms": {
"menu_title": "Rooms",
"title_plural": "Rooms",
......
......@@ -18,6 +18,34 @@ const aleksisMixin = {
handler: handler,
});
},
$toast(messageKey, state, timeout) {
this.$root.snackbarItems.push({
id: crypto.randomUUID(),
timeout: timeout || 5000,
messageKey: this.$t(messageKey),
color: state || "error",
});
},
$toastError(messageKey, timeout) {
this.$toast(
messageKey || "generic_messages.error",
"error",
timeout,
);
},
$toastSuccess(messageKey, timeout) {
this.$toast(
messageKey || "generic_messages.success",
"success",
timeout,
)
},
$toastInfo(messageKey, timeout) {
this.$toast(messageKey, "info", timeout);
},
$toastWarning(messageKey, timeout) {
this.$toast(messageKey, "warning", timeout);
}
},
mounted() {
this.$emit("mounted");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment