Поиск в кароточке

This commit is contained in:
iriska-gri committed 2023-11-07 15:35:46 +03:00
1 parent 2e7c29c065
commit 52b78f5fcb
3 files changed
+17 -12

No files matched your search

+10 -7
View File
@@ -90,12 +90,12 @@ flat
<v-row class="bggrad">
<v-col class="text-center text-black_and_white">
<!-- {{result[0].pos}} -->
{{t_dailyRound.position}}
</v-col>
</v-row>
<v-row>
<v-col class="pa-0 mb-3">
<!-- <my-helper :pretext="t_dailyRound[0]"/> -->
<!-- <my-helper :pretext="t_dailyRound.position"/> -->
<v-textarea
v-model="searchname"
clearable
@@ -209,10 +209,11 @@ export default {
idpos.value=pos
dialogDetailRound.value=!dialogDetailRound.value
axiosApiInstance.get(`api/general_vacation/dailyload/?id=${pos}`).then(data => {
console.log(data, '-------------------data');
t_dailyRound.value = data.data
result.value=JSON.parse(JSON.stringify(data.data))
result.value=JSON.parse(JSON.stringify(data.data.daily))
})
}
@@ -238,16 +239,18 @@ export default {
axiosApiInstance.get('api/general_vacation/dailyload/')
.then(data => {
t_daily.value = data.data
t_daily.value = data.data.daily
})
}
const filterItems = (query) => {
console.log(t_dailyRound.value['daily'], '----------t_dailyRound.value');
result.value={}
Object.keys(t_dailyRound.value).map(el1 => {
let myarr = t_dailyRound.value[el1].filter((el) =>el.fio.toLowerCase().includes(query.toLowerCase()))
Object.keys(t_dailyRound.value['daily']).map(el1 => {
let myarr = t_dailyRound.value['daily'][el1].filter((el) =>el.fio.toLowerCase().includes(query.toLowerCase()))
if(myarr.length>0)
{
@@ -268,7 +271,7 @@ export default {
}
else {
result.value = JSON.parse(JSON.stringify(t_dailyRound.value))
result.value = JSON.parse(JSON.stringify(t_dailyRound.value['daily']))
}