webpackJsonp([53],{XrL3:function(t,a,e){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var s=e("3E4D"),o=e("Ch4/"),n=e("PI0u"),r=e("P9l9"),d={name:"app-detail",props:{brandId:{type:String,default:function(){return""}},tabType:{type:String,default:function(){return"1"}},activeGroupId:{type:String,default:function(){return""}}},data:function(){return{projectName:"",wxEnterpriseRelatedId:localStorage.getItem("userInfos")?JSON.parse(localStorage.getItem("userInfos")).wxEnterpriseId:"",myCustomData:{salesGoodsFlag:!1,notSalesGoodsFlag:!1},activeId:"1",loading:!1}},methods:{submit:Object(n.a)(function(t){this.loading=!0,this.setData(t)},500),setData:function(t){var a=this,e={enterpriseId:a.brandId,salesGoodsFlag:a.myCustomData.salesGoodsFlag?1:"0",notSalesGoodsFlag:a.myCustomData.notSalesGoodsFlag?1:"0"};Object(r.d)("/haoban-app-aggregation-web/save-goods-setting",e).then(function(t){var e=t.data;a.loading=!1,1!=e.errorCode?o.a.errorMsg(e):s.a.showmsg("保存成功","success")}).catch(function(t){a.loading=!1,a.$message.error({duration:1e3,message:t.message})})},getCustomerSet:function(t){var a=this,e={enterpriseId:a.brandId,wxEnterpriseRelatedId:a.wxEnterpriseRelatedId};Object(r.d)("/haoban-app-aggregation-web/find-goods-setting",e).then(function(t){var e=t.data;1!=e.errorCode?o.a.errorMsg(e):e.result&&(a.myCustomData.salesGoodsFlag=!!e.result.salesGoodsFlag,a.myCustomData.notSalesGoodsFlag=!!e.result.notSalesGoodsFlag)}).catch(function(t){a.$message.error({duration:1e3,message:t.message})})}},watch:{brandId:function(t,a){t&&this.getCustomerSet(this.brandId)}},mounted:function(){this.$emit("showTab","1"),this.brandId&&this.getCustomerSet(this.brandId)},components:{}},l={render:function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"app-detail-wrap"},[e("div",{staticClass:"app-detail-pane border-box p-20"},[e("span",{staticClass:"font-14 p-r-10"},[t._v("商品展示：")]),t._v(" "),e("el-checkbox",{model:{value:t.myCustomData.salesGoodsFlag,callback:function(a){t.$set(t.myCustomData,"salesGoodsFlag",a)},expression:"myCustomData.salesGoodsFlag"}},[t._v("已上架商品")]),e("el-checkbox",{model:{value:t.myCustomData.notSalesGoodsFlag,callback:function(a){t.$set(t.myCustomData,"notSalesGoodsFlag",a)},expression:"myCustomData.notSalesGoodsFlag"}},[t._v("未上架商品")]),t._v(" "),e("div",{staticClass:"m-t-46"},[e("el-button",{attrs:{type:"primary",loading:t.loading},on:{click:function(a){t.submit("searchFlag")}}},[t._v("保 存")])],1)],1)])},staticRenderFns:[]};var i=e("VU/8")(d,l,!1,function(t){e("debw")},"data-v-55e105b0",null);a.default=i.exports},debw:function(t,a){}});