webpackJsonp([77],{"5gao":function(t,a){},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"),l={name:"app-detail",props:{brandId:{type:String,default:function(){return""}}},data:function(){return{projectName:"",wxEnterpriseRelatedId:sessionStorage.getItem("userInfos")?JSON.parse(sessionStorage.getItem("userInfos")).wxEnterpriseId:"",myCustomData:{salesGoodsFlag:!1,notSalesGoodsFlag:!1,showPriceFlag:!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",showPriceFlag:a.myCustomData.showPriceFlag?1:"0"};Object(r.f)("/haoban-app-aggregation-web/save-goods-setting",e).then(function(t){var e=t.data;a.loading=!1,a.getCustomerSet(),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.f)("/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=1==e.result.salesGoodsFlag,a.myCustomData.notSalesGoodsFlag=1==e.result.notSalesGoodsFlag,a.myCustomData.showPriceFlag=1==e.result.showPriceFlag)}).catch(function(t){a.$message.error({duration:1e3,message:t.message})})}},watch:{brandId:function(t,a){t&&this.getCustomerSet(this.brandId)}},mounted:function(){this.brandId&&this.getCustomerSet(this.brandId)},components:{}},i={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("div",{staticClass:"m-b-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("未上架商品")])],1),t._v(" "),e("div",[e("el-switch",{model:{value:t.myCustomData.showPriceFlag,callback:function(a){t.$set(t.myCustomData,"showPriceFlag",a)},expression:"myCustomData.showPriceFlag"}}),e("span",{staticClass:"font-14 color-303133 p-l-10"},[t._v("商品详情屏蔽价格")]),e("span",{staticClass:"font-12 color-909399 p-l-10"},[t._v("注：开启后，商品列表及商品详情中会屏蔽价格字段。关闭后显示价格。")])],1),t._v(" "),e("div",{staticClass:"m-t-46"},[t.$getButtonLimit(t.$buttonCode.saveGoodsSet)?e("el-button",{attrs:{"limit-code":t.$buttonCode.saveGoodsSet,type:"primary",loading:t.loading,disabled:t.$store.state.wxEnterpriseType},on:{click:function(a){return t.submit("searchFlag")}}},[t._v("保 存")]):t._e()],1)])])},staticRenderFns:[]};var d=e("VU/8")(l,i,!1,function(t){e("5gao")},"data-v-551cb015",null);a.default=d.exports}});