(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-552b17a4"],{"0ebc":function(t,e,a){"use strict";a.r(e);var n=a("797f"),l={data:()=>({table:{currentPage:1,pageSizes:[10],total:0,data:null},chooseID:"",types:[{label:"首页按钮",value:"index_tab"},{label:"首页图片",value:"index_image"},{label:"发布页",value:"send"},{label:"我的页面",value:"my_page"},{label:"PC首页左边广告",value:"pc_index_ad"},{label:"PC首页右边广告",value:"pc_index_ad_right"},{label:"交友首页",value:"match_friend"},{label:"侧边栏导航",value:"slide_nav"}]}),methods:{handleSizeChange(t){},handleCurrentChange(t){},getData(){Object(n.n)({location:this.chooseID}).then(t=>{this.table.total=t.data.length,this.table.data=t.data;for(var e=0;e<this.table.data.length;e++)"web"==this.table.data[e].type&&(this.table.data[e].type="网页"),"app"==this.table.data[e].type&&(this.table.data[e].type="程序");for(e=0;e<t.data.length;e++)t.data[e].status=1==t.data[e].status;if(""!=this.chooseID){var a=[];for(e=0;e<t.data.length;e++)t.data[e].location==this.chooseID&&a.push(t.data[e]);this.table.data=a}})},updateStatus(t,e){Object(n.o)({id:t,status:1==e})},jumpEdit(t){this.$router.push({path:"/label/indexNav/edit",query:{id:t}})},checkType:t=>"index_image"==t?"图片":"index_tab"==t?"按钮":void 0,del(t){this.$confirm("此操作将永久删除该内容, 是否继续?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(()=>{Object(n.l)({id:t}).then(t=>{this.$message({type:"success",message:"删除成功!"}),this.getData()})}).catch(()=>{})},change(){this.getData()},jumpAdd(){this.$router.push({path:"/label/indexNav/add",query:{}})}},mounted(){this.getData()}},r=a("2877"),u=Object(r.a)(l,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{},[a("div",{staticClass:"ls-card m-b-12"},[a("span",{staticStyle:{"margin-right":"10px"}},[t._v("选择位置")]),t._l(t.types,(function(e,n){return a("el-button",{key:n,attrs:{size:"mini",type:t.chooseID==e.value?"danger":"primary"},on:{click:function(a){t.chooseID=e.value,t.getData()}}},[t._v(t._s(e.label))])})),a("el-button",{attrs:{size:"mini",type:"primary"},on:{click:t.jumpAdd}},[t._v("新建")])],2),a("el-table",{staticStyle:{width:"100%"},attrs:{data:null==t.table.data?[]:t.table.data}},[a("el-table-column",{attrs:{prop:"id",label:"ID",width:"80"}}),a("el-table-column",{attrs:{prop:"name",label:"标题"}}),a("el-table-column",{attrs:{label:"图片"},scopedSlots:t._u([{key:"default",fn:function(t){return[a("el-image",{staticStyle:{width:"80px",height:"80px"},attrs:{src:t.row.image}})]}}])}),a("el-table-column",{attrs:{prop:"path",label:"跳转路径"}}),a("el-table-column",{attrs:{prop:"type",label:"跳转的类型"}}),a("el-table-column",{attrs:{label:"显示模式"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(t.checkType(e.row.location))+" ")]}}])}),a("el-table-column",{attrs:{label:"状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("el-switch",{on:{change:function(a){return t.updateStatus(e.row.id,e.row.status)}},model:{value:e.row.status,callback:function(a){t.$set(e.row,"status",a)},expression:"scope.row.status"}})]}}])}),a("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("el-button",{attrs:{type:"text"},on:{click:function(a){return t.jumpEdit(e.row.id)}}},[t._v("编辑")]),a("el-button",{attrs:{type:"text"},on:{click:function(a){return t.del(e.row.id)}}},[t._v("删除")])]}}])})],1)],1)}),[],!1,null,null,null);e.default=u.exports},"797f":function(t,e,a){"use strict";a.d(e,"i",(function(){return l})),a.d(e,"h",(function(){return r})),a.d(e,"g",(function(){return u})),a.d(e,"j",(function(){return s})),a.d(e,"f",(function(){return o})),a.d(e,"n",(function(){return i})),a.d(e,"m",(function(){return d})),a.d(e,"o",(function(){return c})),a.d(e,"k",(function(){return p})),a.d(e,"l",(function(){return b})),a.d(e,"d",(function(){return h})),a.d(e,"c",(function(){return f})),a.d(e,"e",(function(){return m})),a.d(e,"b",(function(){return g})),a.d(e,"a",(function(){return v}));var n=a("6b2d");const l=t=>n.a.get("/banner/list",{params:t}),r=t=>n.a.get("/banner/detail",{params:t}),u=t=>n.a.get("/banner/del",{params:t}),s=t=>n.a.post("/banner/update",t),o=t=>n.a.post("/banner/create",t),i=t=>n.a.get("/nav/list",{params:t}),d=t=>n.a.get("/nav/detail",{params:t}),c=t=>n.a.post("/nav/update",t),p=t=>n.a.post("/nav/create",t),b=t=>n.a.get("/nav/del",{params:t}),h=t=>n.a.get("/appBottomMenu/list",{params:t}),f=t=>n.a.get("/appBottomMenu/details",{params:t}),m=t=>n.a.post("/appBottomMenu/update",t),g=t=>n.a.get("/AppBottomMenu/del",{params:t}),v=t=>n.a.post("/appBottomMenu/create",t)}}]);