During the vue loop, the value is passed to the subcomponent, and it is not worth the change.

problem description

< div class= "rl-list-box" vmurf = "(item, index) in infoList": key= "item.index" >

                <contentBox2 :currentDate="item"></contentBox2>

< / div >
infoList is an array. I pass each value in it to a component contentBox2 separately, and then call an interface based on each id in this component.

the environmental background of the problems and what methods you have tried

watch cannot listen, computed method will be called, but watch will not be called,

related codes

/ / Please paste the code text below (do not replace the code with pictures)
infoList:
{
"TotalCount": 6,
"Code": 200,
"Msg": null,
"Data": [
{
"id": "54580529f28c48dc9b22b0becf6bd605",
"face_set_id": "5",
"name": "unknown",
"gender": "unknown",
"race": "",
"address": "4",
"birthday": "",
"tel": ",
" remark ":",
"face_ids": [
"0186769c365e4c32b73eb92bc9fec375",
"107ba55fbc544b0c908838bc6ea1aff2"
],
"GetFaceImageID": null
},
{
"id": "93c9341ab90e4b9594bbcab5ad0299d7",
"face_set_id": "5",
"name": "2",

"address": "2",
"birthday": "",
"tel": "",
"remark": ",
" face_ids ": [
" 23fcb410f69a4f0aa189799b3df51187 ",
" e199e164476f429897ce0d9e9556901b "
],
" GetFaceImageID ": null
}
]
}

watch of child components

watch: {
    current: {
        handler: function (val) {
            console.log(val, "watch")
            if (!!val && val.face_ids.length > 0) {
                this.getPhoto(val.face_ids[0]);
            }
        },
        deep: true
    },
    // current(val) {
    //     console.log(val, "watch")
    //     if (!!val && val.face_ids.length > 0) {
    //         this.getPhoto(val.face_ids[0]);
    //     }
    // },

}

computed: {

    current() {
        return this.currentDate
    },
},    

what result do you expect? What is the error message actually seen?

period

Aug.18,2021

vmurf = "(item, index) in infoList .Data "

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b422e4-2c5fc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b422e4-2c5fc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?