vue点击查看详情

vue点击查看详情title 查看下级 render h obj gt return h Button props type primary on

大家好,我是讯享网,很高兴认识大家。
title: '查看下级', render:(h,obj)=>{ 
    return h("Button",{ 
    props:{ 
    type:'primary', }, on:{ 
    click:()=>{ 
    this.$router.push({ 
    'path':"/classfiy/list", query:{ 
    id:obj.row.id } }); } } },"查看下级") } 

讯享网

2.监听


讯享网

讯享网watch:{ 
    "$route.query"(val){ 
    if(val.id>0){ 
    this.isChild=true; }else{ 
    this.isChild=false; } this.list(); } }, 

3.查询

page(num){ 
    // alert(num);//这里的数字num是页码 this.list(num); }, async list(page=1){ 
    this.loading=true; let param={ 
    page:page }; if(this.$route.query.id>0){ 
    param["id"]=this.$route.query.id; }; param[this.search.type]=this.search.value; let $res=await this.$api.classfiy.lists(param); if($res){ 
    this.data1=$res; } }, 
小讯
上一篇 2025-04-06 21:23
下一篇 2025-03-12 14:54

相关推荐

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容,请联系我们,一经查实,本站将立刻删除。
如需转载请保留出处:https://51itzy.com/kjqy/33849.html