| 1 |
- (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-9a8ab2f0"],{"2b8e":function(e,t,s){"use strict";s.d(t,"m",(function(){return n})),s.d(t,"n",(function(){return r})),s.d(t,"a",(function(){return a})),s.d(t,"d",(function(){return l})),s.d(t,"b",(function(){return o})),s.d(t,"c",(function(){return c})),s.d(t,"e",(function(){return f})),s.d(t,"k",(function(){return d})),s.d(t,"l",(function(){return u})),s.d(t,"f",(function(){return m})),s.d(t,"i",(function(){return h})),s.d(t,"j",(function(){return p})),s.d(t,"h",(function(){return g})),s.d(t,"g",(function(){return v}));var i=s("f175");const n=()=>i.a.get("settings.delivery.delivery_way/getConfig"),r=e=>i.a.post("settings.delivery.delivery_way/setConfig",e),a=e=>i.a.post("/settings.delivery.express/add",e),l=e=>i.a.post("/settings.delivery.express/edit",e),o=e=>i.a.post("/settings.delivery.express/del",e),c=e=>i.a.get("/settings.delivery.express/detail",{params:e}),f=e=>i.a.get("/settings.delivery.express/lists",{params:e}),d=()=>i.a.get("settings.delivery.logistics_config/getLogisticsConfig"),u=e=>i.a.post("settings.delivery.logistics_config/setLogisticsConfig",e),m=e=>i.a.post("settings.delivery.freight/add",e),h=e=>i.a.post("settings.delivery.freight/edit",e),p=e=>i.a.get("settings.delivery.freight/lists",{params:e}),g=e=>i.a.get("settings.delivery.freight/detail",{params:e}),v=e=>i.a.post("settings.delivery.freight/del",e)},"39d7":function(e,t,s){"use strict";s("87ab")},"837d":function(e,t,s){"use strict";s.r(t);var i=s("9ab4"),n=s("2b8e"),r=s("1b40"),a=s("0a6d");let l=class extends r.e{constructor(){super(...arguments),this.form={express:{is_express:0,express_name:""},selffetch:{is_selffetch:0,selffetch_name:""}},this.mode="快递发货",this.customName=""}closeDialog(){this.$refs.dialog.close()}openDialog(e,t){switch(this.mode=e,this.form=t,e){case"快递发货":this.customName=t.express.express_name;break;default:this.customName=t.selffetch.selffetch_name}this.$refs.dialog.open()}async handleConfirm(){switch(this.mode){case"快递发货":this.form.express.express_name=this.customName;break;default:this.form.selffetch.selffetch_name=this.customName}await Object(n.n)({...this.form.express,...this.form.selffetch}),this.closeDialog()}};l=Object(i.a)([Object(r.a)({components:{LsDialog:a.a}})],l);var o=l,c=s("2877"),f=Object(c.a)(o,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",[s("ls-dialog",{ref:"dialog",attrs:{title:"自定义名称",width:"440px",top:"30vh",async:!0},on:{confirm:e.handleConfirm,cancel:e.closeDialog}},[s("div",{staticClass:"p-r-20"},[s("el-form",{ref:"form",attrs:{model:e.form,"label-width":"80px",size:"small"}},[s("el-form-item",{attrs:{label:"配送方式"}},[s("el-input",{attrs:{disabled:""},model:{value:e.mode,callback:function(t){e.mode=t},expression:"mode"}})],1),s("el-form-item",{attrs:{label:"自定义名称"}},[s("el-input",{attrs:{placeholder:"请输入自定义名称"},model:{value:e.customName,callback:function(t){e.customName=t},expression:"customName"}}),s("div",{staticClass:"xs muted"},[e._v("修改名称之后,手机端和PC端将显示自定义的名称")])],1)],1)],1)])],1)}),[],!1,null,"3818ac98",null).exports;let d=class extends r.e{constructor(){super(...arguments),this.form={express:{is_express:0,express_name:""},selffetch:{is_selffetch:0,selffetch_name:""}}}handleChange(e,t){if(!e&&!this.form.express.is_express&&!this.form.selffetch.is_selffetch)return this.$message.warning("至少启用一种配送方式"),this.form.express.is_express=1,void(this.form.selffetch.is_selffetch=1);Object(n.n)({...this.form.express,...this.form.selffetch})}getLogisticsConfig(){Object(n.m)().then(e=>{this.form=e})}openDialog(e){this.$refs.customName.openDialog(e,this.form)}created(){this.getLogisticsConfig()}};d=Object(i.a)([Object(r.a)({components:{CustomName:f}})],d);var u=d,m=(s("39d7"),Object(c.a)(u,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"delivery-index"},[s("div",{staticClass:"delivery-item"},[s("div",{staticClass:"delivery-item__header flex row-between"},[s("div",{staticClass:"nr weight-500"},[e._v(" "+e._s(e.form.express.express_name)+" "),s("el-button",{staticClass:"ls-edit",staticStyle:{padding:"0"},attrs:{type:"text",icon:"el-icon-edit"},on:{click:function(t){return e.openDialog("快递发货")}}})],1),s("el-switch",{attrs:{"active-value":1,"inactive-value":0},on:{change:function(t){return e.handleChange(t,"is_express")}},model:{value:e.form.express.is_express,callback:function(t){e.$set(e.form.express,"is_express",t)},expression:"form.express.is_express"}})],1),s("div",{staticClass:"delivery-item__content flex row-between"},[s("div",{staticClass:"muted"},[e._v("启用快递发货后,买家下单可以选择快递发货,由卖家安排快递送货上门")]),s("div",{staticClass:"btns"},[s("el-button",{attrs:{type:"text",size:"small"},on:{click:function(t){return e.$router.push("/setting/delivery/freight")}}},[e._v("运费模版")]),s("el-button",{attrs:{type:"text",size:"small"},on:{click:function(t){return e.$router.push("/setting/delivery/express")}}},[e._v("快递公司")]),s("el-button",{attrs:{type:"text",size:"small"},on:{click:function(t){return e.$router.push("/setting/delivery/logistics")}}},[e._v("物流接口")])],1)])]),s("div",{staticClass:"delivery-item m-t-16"},[s("div",{staticClass:"delivery-item__header flex row-between"},[s("div",{staticClass:"nr weight-500"},[e._v(" "+e._s(e.form.selffetch.selffetch_name)+" "),s("el-button",{staticClass:"ls-edit",staticStyle:{padding:"0"},attrs:{type:"text",icon:"el-icon-edit"},on:{click:function(t){return e.openDialog("上门自提")}}})],1),s("el-switch",{attrs:{"active-value":1,"inactive-value":0},on:{change:function(t){return e.handleChange(t,"is_selffetch")}},model:{value:e.form.selffetch.is_selffetch,callback:function(t){e.$set(e.form.selffetch,"is_selffetch",t)},expression:"form.selffetch.is_selffetch"}})],1),s("div",{staticClass:"delivery-item__content flex row-between"},[s("div",{staticClass:"muted"},[e._v(" 启用上门自提后,买家下单可以选择就近门店自提点,卖家需要确保指定的自提点商品库存充足。 ")]),s("div",{staticClass:"btns"},[s("el-button",{attrs:{type:"text",size:"small"},on:{click:function(t){return e.$router.push("/selffetch/selffetch_shop")}}},[e._v("查看自提点")])],1)])]),s("CustomName",{ref:"customName"})],1)}),[],!1,null,"26d5e1ad",null));t.default=m.exports},"87ab":function(e,t,s){}}]);
|