Третий этап
This commit is contained in:
1 parent
a0edc64f1c
commit
ababe895c1
2 files changed
+16
-3
No files matched your search
BIN
Binary file not shown.
@@ -50,15 +50,28 @@ export default {
|
|||||||
axiosApiInstance.get('api/general_vacation/generalvacation/')
|
axiosApiInstance.get('api/general_vacation/generalvacation/')
|
||||||
.then(data => {
|
.then(data => {
|
||||||
|
|
||||||
|
for (let x in data.data) {
|
||||||
|
|
||||||
|
data.data[x].map(e=>{
|
||||||
|
let d = new Date(e.planned_date)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// console.log(, 'e---------d.addDays(e.count_days)--------e')
|
||||||
|
calendarOptions.events.push({ title: x, start: e.planned_date, end: new Date(d.setDate(d.getDate() + e.count_days)).toISOString().split('T')[0]})
|
||||||
|
}
|
||||||
|
|
||||||
|
)
|
||||||
|
|
||||||
|
}
|
||||||
console.log(data.data , 'genvacation--------------------');
|
console.log(data.data , 'genvacation--------------------');
|
||||||
calendarOptions.events = [{ title: 'Отпуск', start: '2023-09-01', end: '2023-09-25'}]
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
f_generalvacation()
|
f_generalvacation()
|
||||||
console.log(typeof(huf), 'hu--------------');
|
|
||||||
|
|
||||||
})
|
})
|
||||||
// genvacation.value[0].planned_date
|
// genvacation.value[0].planned_date
|
||||||
|
|||||||
Reference in new issue
Block a user