P-42 Насадить рыбу на v-select
This commit is contained in:
1 parent
ab8811773f
commit
b6f0b33d9f
6 files changed
+308
-101
No files matched your search
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<v-list density="compact">
|
||||
<v-list density="compact" class="calen">
|
||||
<v-list-group value="Admin">
|
||||
<template v-slot:activator="{ props }">
|
||||
<v-list-item v-bind="props">
|
||||
@@ -19,18 +19,28 @@
|
||||
</template>
|
||||
|
||||
<v-list-item
|
||||
v-for="(x, i) in mycalendar"
|
||||
v-for="(x, i) in calendar"
|
||||
:key="i"
|
||||
:title="x.name"
|
||||
:value="x.name"
|
||||
:title="x.cl_name"
|
||||
:value="x.cl_name"
|
||||
@click.stop=""
|
||||
>
|
||||
<template v-slot:prepend="{ isActive }">
|
||||
<template v-slot:append>
|
||||
|
||||
<v-btn
|
||||
size="x-small"
|
||||
icon="mdi-pen"
|
||||
variant="text"
|
||||
@click.stop="editCreatedCalendar(x.id)"
|
||||
></v-btn>
|
||||
</template>
|
||||
<!-- <template v-slot:prepend="{ isActive }">
|
||||
<v-checkbox-btn
|
||||
:color="x.color"
|
||||
:model-value="isActive"
|
||||
v-model="x.chek"
|
||||
/>
|
||||
</template>
|
||||
</template> -->
|
||||
</v-list-item>
|
||||
</v-list-group>
|
||||
<calendar-create
|
||||
@@ -42,7 +52,7 @@
|
||||
|
||||
<script>
|
||||
import { ref, onMounted, computed } from "vue";
|
||||
import calendarCreate from "./calendar-create.vue";
|
||||
import calendarCreate from "@/components/calendar_of_events/calendar-create.vue";
|
||||
|
||||
export default {
|
||||
components: { calendarCreate },
|
||||
@@ -53,6 +63,34 @@ export default {
|
||||
{ name: "Дни рождения", chek: true, id: 0, color: "yellow" },
|
||||
];
|
||||
|
||||
const editCreatedCalendar = (id) => {
|
||||
console.log(id, '-----------------')
|
||||
showDialog.value = true
|
||||
}
|
||||
|
||||
const calendar = ref([
|
||||
{
|
||||
cl_color: "#F44336",
|
||||
cl_descr: "Малюсенький календарь",
|
||||
cl_name: "Мой первый календарь",
|
||||
editor: true,
|
||||
participant : [
|
||||
{editor:0, user: 107},
|
||||
{editor: 1, user: 125}
|
||||
],
|
||||
events:{
|
||||
date_end: "2024-06-29T12:20:28+03:00",
|
||||
date_start: "2024-05-29T12:20:24+03:00",
|
||||
description: "Описание такое описание",
|
||||
event: 1,
|
||||
id: 1,
|
||||
name: "Первое событие в календаре",
|
||||
period: null
|
||||
},
|
||||
id: 1
|
||||
}]
|
||||
)
|
||||
|
||||
const mycalendar = ref([
|
||||
{ name: "Портал ЦОД2", chek: false, id: 1, color: "red" },
|
||||
{ name: "Личный календарь", chek: true, id: 2, color: "green" },
|
||||
@@ -63,9 +101,21 @@ export default {
|
||||
subscribe,
|
||||
selected,
|
||||
showDialog,
|
||||
calendar,
|
||||
editCreatedCalendar
|
||||
};
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style></style>
|
||||
<style>
|
||||
|
||||
.calen .v-list-group--prepend {
|
||||
--parent-padding: 0px;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.calen .v-list-item-title {
|
||||
font-size: 14px;
|
||||
}
|
||||
</style>
|
||||
Reference in new issue
Block a user