html部分        

 <span class="delete" @click="showFiguredelete(index)">×</span>

js部分

showFiguredelete(index){

                var that=this;

//console.log(index)

            console.log(that.staffinfoForm.showFigure[index])

                that.staffinfoForm.showFigure.splice(index,1)

            }

 

 

 

 

css部分

    .delete{

        width: 20px;

        height: 20px;

        position: absolute;

        top: -30px;

        font-size: 18px;

        color: red;

        right: -10px;

        cursor:pointer;

        

    }

Logo

前往低代码交流专区

更多推荐