父级页面:

<template>   
    <div>            
        <v-sidebar @parentPopme="popTimeline"></v-sidebar>                    
        <!--步骤条-->             
        <el-footer v-if="lesteps">                   
        	<step-for-build></step-for-build>
        </el-footer> 
    </div>
</template>
<script>
export default {
	data(){
		return {
			lesteps:false,
		}
	},
	methods:{
		popTimeline(val){
			this.lesteps= !this.lesteps;
		}
	}
}
</script>

子级页面:

<template>  
    <el-tooltip content="步骤条" placement="top" effect="light">    
    	<el-button  icon="el-icon-edit" @click="articlesteps"></el-button>    
    </el-tooltip>                    
</template>
<script>
export default {
	methods:{
		articlesteps(){
           this.$emit("parentPopme",'');
         },
	}
}
</script>
Logo

前往低代码交流专区

更多推荐