Update event-calendar.vue
This commit is contained in:
1 parent
849cb65efb
commit
597c6b5136
1 file changed
+23
-22
@@ -61,8 +61,7 @@
|
||||
<template #arrow-next>
|
||||
<v-icon icon="mdi-menu-right"></v-icon>
|
||||
</template>
|
||||
<template #today-button>
|
||||
</template>
|
||||
<template #today-button> </template>
|
||||
</vue-cal>
|
||||
</v-card>
|
||||
</v-col>
|
||||
@@ -72,36 +71,38 @@
|
||||
<script>
|
||||
import VueCal from "vue-cal";
|
||||
import "vue-cal/dist/vuecal.css";
|
||||
import { ref, onMounted } from "vue";
|
||||
import { ref } from "vue";
|
||||
import { axiosApiInstance } from "@/utils/axios-api";
|
||||
|
||||
export default {
|
||||
components: { VueCal },
|
||||
|
||||
setup() {
|
||||
const events = ref([]);
|
||||
const events = ref([
|
||||
|
||||
]);
|
||||
function f_generalvacation() {
|
||||
axiosApiInstance
|
||||
.get("api/general_vacation/generalvacation/")
|
||||
.then((data) => {
|
||||
for (let x in data.data) {
|
||||
if (x == "План-график") {
|
||||
data.data[x].map((e) => {
|
||||
events.value.push({
|
||||
name: e.name,
|
||||
start: e.start_work_period,
|
||||
end: e.end_work_period,
|
||||
content: e.name,
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
// axiosApiInstance
|
||||
// .get("api/general_vacation/generalvacation/")
|
||||
// .then((data) => {
|
||||
// for (let x in data.data) {
|
||||
// if (x == "План-график") {
|
||||
// data.data[x].map((e) => {
|
||||
// events.value.push({
|
||||
// name: e.name,
|
||||
// start: e.start_work_period,
|
||||
// end: e.end_work_period,
|
||||
// content: e.name,
|
||||
// });
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
|
||||
f_generalvacation();
|
||||
});
|
||||
|
||||
|
||||
const selectedDate = ref(null);
|
||||
|
||||
|
||||
Reference in new issue
Block a user