(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-f3bf4a9a"],{"0782":function(t,e,i){},"0bab":function(t,e,i){},"0e0d":function(t,e,i){},1635:function(t,e,i){"use strict";var s=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"mockups"},[i("my-img",{staticClass:"mockups-left",attrs:{"big-image":!0,src:t.value,alt:"product image"}}),i("div",{staticClass:"mockups-right"},[i("div",{staticClass:"mockups-title"},[t._v("Select title image view")]),i("div",{staticClass:"mockups-list"},t._l(t.images,(function(e,s){return i("div",{key:s,staticClass:"mockups-item"},[i("div",{class:["mockups-item-img-box","div-hover",{"div-select tag":e.url===t.value}],on:{click:function(i){return t.onSelectImg(e)}}},[i("my-img",{staticClass:"mockups-item-img",attrs:{src:e.url,"show-on-server":e.showOnServer},on:{"update:showOnServer":function(i){return t.$set(e,"showOnServer",i)},"update:show-on-server":function(i){return t.$set(e,"showOnServer",i)},showOnServerClick:function(i){return t.showOnServerClick(e)}}})],1)])})),0)])],1)},o=[],n=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"image-container"},[t.isAlive&&t.finImageUrl?s("el-image",{style:t.imageStyle,attrs:{src:t.finImageUrl,alt:t.alt},on:{load:t.loadSuccess,click:t.showPreview,error:t.loadFail}}):t._e(),t.bigImage?t._e():s("div",{staticClass:"show-on-server-box",on:{click:function(e){return e.preventDefault(),e.stopPropagation(),t.showOnServerClick.apply(null,arguments)}}},[t.showOnServer?t._e():s("img",{staticClass:"icon",attrs:{src:i("ee78")}}),t.showOnServer?s("img",{staticClass:"icon",attrs:{src:i("9486")}}):t._e()]),t.showOnServer||t.bigImage?t._e():s("div",{staticClass:"mask"},[t.showOnServer?t._e():s("span",{staticClass:"mask-text"},[t._v(" Not visible in the store ")])]),s("el-dialog",{attrs:{visible:t.dialogVisible},on:{"update:visible":function(e){t.dialogVisible=e}}},[s("img",{attrs:{src:t.src,width:"100%",alt:""}})])],1)},r=[],a={name:"MyImg",props:{src:{type:String,default:()=>i("e803")},alt:{type:String,default:"image"},width:{type:Number,default:200},height:{type:Number,default:200},quality:{type:Number,default:80},noCompress:{type:Boolean,default:!1},preview:{type:Boolean,default:!1},imageStyle:{type:Object,default:()=>{}},showOnServer:{type:Boolean,default:!1},bigImage:{type:Boolean,default:!1}},data(){return{finImageUrl:"",failCount:0,isAlive:!0,dialogVisible:!1}},watch:{src(){this.urlChange()}},mounted(){this.urlChange()},methods:{showOnServerClick(){this.$emit("showOnServerClick")},showPreview(){this.preview&&(this.dialogVisible=!0)},endWith(t,e){var i=t.length-e.length;return i>=0&&t.indexOf(e,i)===i},reload(){this.isAlive=!1,this.$nextTick(()=>this.isAlive=!0)},urlChange(){this.failCount=0,this.loadFail()},loadSuccess(){},loadFail(t){this.src?(this.failCount=this.failCount+1,1!==this.failCount?2!==this.failCount?this.finImageUrl=i("e803"):this.finImageUrl=this.src:this.noCompress?this.finImageUrl=this.src:this.endWith(this.src,"jpg")||this.endWith(this.src,"jpeg")||this.endWith(this.src,"png")?this.finImageUrl=this.src+`?x-oss-process=image/resize,w_${this.width},h_${this.height}/format,webp/quality,q_${this.quality}`:this.finImageUrl=this.src):this.finImageUrl=""}}},l=a,c=(i("6795"),i("2877")),u=Object(c["a"])(l,n,r,!1,null,"518f0d8a",null),d=u.exports,p={name:"Mockups",components:{MyImg:d},props:{images:{type:Array,default:()=>[]},value:{type:String,default:null}},data(){return{currentIndex:0}},watch:{currentIndex(t){this.$emit("change",this.images[t].url)},images:{handler(){this.$emit("images:updated",this.images)}}},methods:{onSelectImg(t){t.showOnServer&&this.$emit("input",t.url)},showOnServerClick(t){t.showOnServer=!t.showOnServer}}},h=p,f=(i("4d38"),Object(c["a"])(h,s,o,!1,null,"7aa79a7a",null));e["a"]=f.exports},"182a":function(t,e,i){"use strict";i("bd08")},"21f7":function(t,e,i){},"34ec":function(t,e,i){"use strict";i("570a")},"365b":function(t,e,i){"use strict";i("0bab")},"3a78":function(t,e,i){t.exports=i.p+"static/img/empyImage.6280cd62.svg"},"3f74":function(t,e,i){"use strict";i("819a")},"48c2":function(t,e,i){"use strict";var s=function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.variantList?i("div",{staticClass:"variants-box"},[t._m(0),i("div",{staticClass:"variants-title"},[t._v("Pricing")]),i("div",{staticClass:"variants-button-box"},[i("div",{staticClass:"button-box"},[i("el-button",{attrs:{disabled:!t.skuIds.length},on:{click:function(e){return t.showEdit("retailPrice")}}},[t._v("Edit price")]),i("el-button",{attrs:{disabled:!t.skuIds.length},on:{click:function(e){return t.showEdit("profit")}}},[t._v("Edit profit")]),i("el-button",{attrs:{disabled:!t.skuIds.length},on:{click:function(e){return t.showEdit("compareAtPrice")}}},[t._v("Edit compare at price")]),i("el-button",{attrs:{disabled:!t.skuIds.length},on:{click:function(e){return t.showEdit("profitMargin")}}},[t._v("Edit profit margin")]),i("el-button",{attrs:{disabled:!t.skuIds.length},on:{click:function(e){return t.showEdit("additionalPrice")}}},[t._v("Edit additional fees")])],1),i("div",{staticClass:"switch-box"},[i("div",{staticClass:"text"},[t._v("Compare at price")]),i("el-switch",{model:{value:t.showCompareAtPriceRow,callback:function(e){t.showCompareAtPriceRow=e},expression:"showCompareAtPriceRow"}})],1)]),i("el-form-item",{attrs:{prop:"variantList"}},[i("el-table",{staticClass:"variants-table",attrs:{data:t.variantList,"row-style":t.tableRowStyle},on:{"selection-change":t.handleSelectionChange}},[i("el-table-column",{attrs:{type:"selection",width:"55"}}),t._l(t.variantList[0].skuList,(function(e,s){return[i("el-table-column",{key:s,attrs:{label:e.label},scopedSlots:t._u([{key:"default",fn:function(e){return[e.row.skuList&&e.row.skuList.length?i("div",[t._v(t._s(e.row.skuList[s].value))]):t._e()]}}],null,!0)})]})),i("el-table-column",{attrs:{prop:"costs",label:"Production Cost"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticClass:"input-box"},[i("div",{staticClass:"input-tag"},[t._v("USD")]),i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,controls:!1,disabled:""},model:{value:e.row.costs,callback:function(i){t.$set(e.row,"costs",i)},expression:"scope.row.costs"}})],1)]}}],null,!1,458063697)}),i("el-table-column",{attrs:{prop:"profit",label:"Profit"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticClass:"input-box"},[i("div",{staticClass:"input-tag"},[t._v("USD")]),i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,controls:!1,min:0},on:{input:function(i){return t.profitComputed(e.row)}},model:{value:e.row.profit,callback:function(i){t.$set(e.row,"profit",i)},expression:"scope.row.profit"}})],1)]}}],null,!1,4126958023)}),i("el-table-column",{attrs:{prop:"profitMargin",label:"Profit margin"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticClass:"input-box"},[i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,max:9999,min:-9999,controls:!1},on:{input:function(i){return t.profitMarginComputed(e.row)}},model:{value:e.row.profitMargin,callback:function(i){t.$set(e.row,"profitMargin",i)},expression:"scope.row.profitMargin"}}),i("div",{staticClass:"input-tag"},[t._v("%")])],1)]}}],null,!1,3548064671)}),i("el-table-column",{attrs:{prop:"additionalPrice",label:"Additional Fees"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticClass:"input-box"},[i("div",{staticClass:"input-tag"},[t._v("USD")]),i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,controls:!1},on:{input:function(i){return t.additionalFeesComputed(e.row)}},model:{value:e.row.additionalPrice,callback:function(i){t.$set(e.row,"additionalPrice",i)},expression:"scope.row.additionalPrice"}})],1)]}}],null,!1,852812851)}),t.showCompareAtPriceRow?i("el-table-column",{key:"compareAtPrice",attrs:{prop:"compareAtPrice",label:"Compare at price"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticClass:"input-box"},[i("div",{staticClass:"input-tag"},[t._v("USD")]),i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,min:e.row.retailPrice,controls:!1},model:{value:e.row.compareAtPrice,callback:function(i){t.$set(e.row,"compareAtPrice",i)},expression:"scope.row.compareAtPrice"}})],1)]}}],null,!1,1319474822)}):t._e(),i("el-table-column",{attrs:{prop:"retailPrice",label:"Your Price"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticClass:"input-box"},[i("div",{staticClass:"input-tag"},[t._v("USD")]),i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,controls:!1,min:e.row.costs+e.row.additionalPrice},on:{input:function(i){return t.retailPriceComputed(e.row)}},model:{value:e.row.retailPrice,callback:function(i){t.$set(e.row,"retailPrice",i)},expression:"scope.row.retailPrice"}})],1)]}}],null,!1,2578629936)}),i("el-table-column",{attrs:{label:"Synchronous Sku"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("el-radio-group",{model:{value:e.row.checked,callback:function(i){t.$set(e.row,"checked",i)},expression:"scope.row.checked"}},[i("el-radio",{attrs:{label:!0}},[t._v("Yes")]),i("el-radio",{attrs:{label:!1}},[t._v("No")])],1)]}}],null,!1,3279884005)})],2)],1),i("el-dialog",{attrs:{visible:t.dialogVisible,"close-on-click-modal":!1,"append-to-body":"",width:"30%"},on:{"update:visible":function(e){t.dialogVisible=e}}},[i("div",{staticClass:"dialog-title",attrs:{slot:"title"},slot:"title"},[t._v("edit")]),i("el-form",{ref:"editForm",attrs:{model:t.editForm,rules:t.editRules,"label-width":"100px","label-position":"top"},nativeOn:{submit:function(e){return e.preventDefault(),t.editPrice("editForm")}}},["profitMargin"===t.currentKey?i("div",{staticClass:"input-box"},[i("el-form-item",{attrs:{prop:"num"}},[i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,max:9999,min:-9999,controls:!1},model:{value:t.editForm.num,callback:function(e){t.$set(t.editForm,"num",e)},expression:"editForm.num"}})],1),i("div",{staticClass:"input-tag"},[t._v("%")])],1):i("div",{staticClass:"input-box"},[i("div",{staticClass:"input-tag"},[t._v("USD")]),i("el-form-item",{attrs:{prop:"num"}},[i("el-input-number",{staticClass:"input-content",staticStyle:{width:"100%"},attrs:{precision:2,max:9999,min:-9999,controls:!1},model:{value:t.editForm.num,callback:function(e){t.$set(t.editForm,"num",e)},expression:"editForm.num"}})],1)],1)]),i("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[i("el-button",{on:{click:t.close}},[t._v("close")]),i("el-button",{attrs:{loading:t.editLoading,type:"primary"},on:{click:function(e){return t.editPrice("editForm")}}},[t._v("Edit")])],1)],1)],1):t._e()},o=[function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"variants-text"},[i("div",{staticClass:"text"},[t._v("Your retail price = (product cost) * (100% + profit margin) + additional fees")]),i("div",{staticClass:"text"},[t._v("We recommend that you select several major sales countries.Add shipping costs to your retail price to make it free shipping to customers inyour primary sales countries.")]),i("div",{staticClass:"text"},[t._v("You can then set up shipping profiles on your store. Main sales countries: freeshipping, other shipping areas: some shipping costs will be added accordingly")])])}],n={name:"Variants",props:{variantList:{type:Array,default:()=>[]},customProductInfo:{type:Object,default:()=>({})}},data(){return{showCompareAtPriceRow:!0,skuIds:[],dialogVisible:!1,currentKey:"",editLoading:!1,editForm:{num:0},editRules:{num:[{required:!0,message:"The 1Num field is required",trigger:"blur"}]}}},computed:{skuType(){return(t,e)=>this.customProductInfo.option1Name===t?e.option1Value:this.customProductInfo.option2Name===t?e.option2Value:this.customProductInfo.option3Name===t?e.option3Value:""},skuList(){return t=>{const e=[];return t.option1Value&&e.push({label:this.customProductInfo.option1Name,value:t.option1Value}),t.option2Value&&e.push({label:this.customProductInfo.option2Name,value:t.option2Value}),t.option3Value&&e.push({label:this.customProductInfo.option3Name,value:t.option3Value}),e}},profitComputed(){return t=>(t.retailPrice=Number(t.profit)+Number(t.costs)+Number(t.additionalPrice),t.profitMargin=Number(t.profit)/Number(t.costs+t.profit)*100,t.profit)},retailPriceComputed(){return t=>(t.profit=t.retailPrice-t.costs-t.additionalPrice,t.profit<=0?(t.profit=0,t.profitMargin=0):t.profitMargin=Number(t.profit)/Number(t.costs+t.profit)*100,t.retailPrice)},profitMarginComputed(){return t=>{const e=Number(t.profitMargin)/100;return t.profit=e*Number(t.costs)/(1-e),t.retailPrice=Number(t.profit)+Number(t.costs)+Number(t.additionalPrice),t.profitMargin}},additionalFeesComputed(){return t=>(t.retailPrice=Number(t.profit)+Number(t.costs)+Number(t.additionalPrice),t.profit=t.retailPrice-t.costs-t.additionalPrice,t.profit<=0?(t.profit=0,t.profitMargin=0):t.profitMargin=Number(t.profit)/Number(t.costs+t.profit)*100,t.additionalPrice)},haveDropshipped(){return this.customProductInfo&&this.customProductInfo.id}},watch:{variantList:{handler(t){t.forEach(t=>(t.skuList=this.skuList(t),t)),this.changeForm()},deep:!0,immediate:!1},skuIds:{handler(){this.changeForm()},deep:!0}},methods:{handleSelectionChange(t){this.skuIds=t.map(t=>t.skuId)},tableRowStyle({row:t,rowIndex:e}){return t.checked?{}:{background:"#faf9f9 !important",color:"gray","text-decoration":"line-through","font-weight":"lighter"}},close(){this.editLoading=!1,this.dialogVisible=!1,this.editForm.num=0},showEdit(t){this.dialogVisible=!0,this.currentKey=t},editPrice(t){this.$refs[t].validate(async t=>{t&&(this.editLoading=!0,this.variantList.forEach(t=>{this.skuIds.forEach(e=>{t.skuId===e&&(t[this.currentKey]=this.editForm.num)})}),this.close())})},changeForm(){const t=this.variantList.map(t=>{const e={skuId:t.skuId,retailPrice:t.retailPrice,compareAtPrice:t.compareAtPrice,costs:t.costs,checked:t.checked};return e});this.$emit("change",t)}}},r=n,a=(i("84c1"),i("2877")),l=Object(a["a"])(r,s,o,!1,null,"fae977ba",null);e["a"]=l.exports},"4bdd":function(t,e,i){"use strict";i("e8fe")},"4d38":function(t,e,i){"use strict";i("21f7")},"4f85":function(t,e,i){"use strict";var s=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",[i("el-tag",{staticClass:"product-tag",staticStyle:{color:"black"},attrs:{color:t.isSelectNew?"gray":"white"},on:{click:t.newLabelClick}},[t._v("New")]),t._l(t.labels,(function(e,s){return i("el-tag",{key:e.name+s,staticClass:"product-tag",style:{color:"black"},attrs:{color:e.checked?"gray":"white"},on:{click:function(e){return t.onLabelClick(s)}}},[t._v(t._s(e.name))])}))],2)},o=[],n=i("6d68"),r={name:"ProductTagsSelector",data(){return{labels:[],isSelectNew:!1}},mounted(){this.getLabels()},methods:{async getLabels(){const t=await Object(n["b"])();if(this.labels=t.data.records,this.labels&&this.labels.length)for(const e of this.labels)e.checked=!1},onLabelClick(t){var e=Object.assign({},this.labels[t]);e.checked=!e.checked,this.$set(this.labels,t,e),this.emitChange()},newLabelClick(){this.isSelectNew=!this.isSelectNew,this.emitChange()},emitChange(){var t={};if(t.isSelectNew=this.isSelectNew,t.labelIds=[],this.labels&&this.labels.length)for(const e of this.labels)e.checked&&t.labelIds.push(e.id);this.$emit("change",t)}}},a=r,l=(i("34ec"),i("2877")),c=Object(l["a"])(a,s,o,!1,null,"3672090d",null);e["a"]=c.exports},"526f":function(t,e,i){"use strict";i.d(e,"e",(function(){return u})),i.d(e,"d",(function(){return d})),i.d(e,"f",(function(){return p})),i.d(e,"c",(function(){return h})),i.d(e,"a",(function(){return f})),i.d(e,"g",(function(){return m})),i.d(e,"b",(function(){return g}));var s=i("2b0e");const o=s["default"].prototype.$isServer,n=/([\:\-\_]+(.))/g,r=/^moz([A-Z])/,a=o?0:Number(document.documentMode),l=function(t){return(t||"").replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g,"")},c=function(t){return t.replace(n,(function(t,e,i,s){return s?i.toUpperCase():i})).replace(r,"Moz$1")},u=function(){return!o&&document.addEventListener?function(t,e,i){t&&e&&i&&t.addEventListener(e,i,!1)}:function(t,e,i){t&&e&&i&&t.attachEvent("on"+e,i)}}(),d=function(){return!o&&document.removeEventListener?function(t,e,i){t&&e&&t.removeEventListener(e,i,!1)}:function(t,e,i){t&&e&&t.detachEvent("on"+e,i)}}(),p=function(t,e,i){var s=function(){i&&i.apply(this,arguments),d(t,e,s)};u(t,e,s)};function h(t,e){if(!t||!e)return!1;if(-1!==e.indexOf(" "))throw new Error("className should not contain space.");return t.classList?t.classList.contains(e):(" "+t.className+" ").indexOf(" "+e+" ")>-1}function f(t,e){if(t){for(var i=t.className,s=(e||"").split(" "),o=0,n=s.length;o{var e={};return t&&"[object Function]"===e.toString.call(t)};"object"===typeof Int8Array||!s["default"].prototype.$isServer&&"function"===typeof document.childNodes||(o=function(t){return"function"===typeof t||!1});Object.prototype.hasOwnProperty;const n=function(){return!s["default"].prototype.$isServer&&!!window.navigator.userAgent.match(/firefox/i)},r=function(t){const e=/([^-])([A-Z])/g;return t.replace(e,"$1-$2").replace(e,"$1-$2").toLowerCase()};function a(t){let e=!1;return function(...i){e||(e=!0,window.requestAnimationFrame(s=>{t.apply(this,i),e=!1}))}}},"7a97":function(t,e,i){t.exports=i.p+"static/img/empty.74e11ed5.webp"},"819a":function(t,e,i){},"82c4":function(t,e,i){},"84c1":function(t,e,i){"use strict";i("b490")},"8f76":function(t,e,i){"use strict";i.r(e);var s=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"dropshinpper-box default-main",attrs:{id:"dropshinpper-box"}},[t.dropshinpperList.length?[s("el-row",{staticClass:"table-title",attrs:{gutter:5}},[s("el-col",{attrs:{span:8}},[s("el-checkbox",{staticClass:"check-all",attrs:{size:"medium",indeterminate:t.selectAllIndeterminate},on:{change:t.onCheckAll}}),t.selectDropshippers.length?s("span",{staticClass:"check-text"},[t._v("Selected "+t._s(t.selectDropshippers.length)+" of "+t._s(t.dropshinpperList.length))]):s("span",{staticClass:"check-text"},[t._v("Select ALL")])],1),s("el-col",{staticClass:"global-buttons",attrs:{span:16}},[s("el-button",{directives:[{name:"loading",rawName:"v-loading",value:t.editListingsLoading,expression:"editListingsLoading"}],attrs:{disabled:!t.editListingsBtnValid},on:{click:t.toEditListings}},[t._v("Edit listings")])],1)],1),t._l(t.dropshinpperList,(function(e,o){return s("div",{key:e.id,staticClass:"dropshinpper-item"},[s("div",{staticClass:"check-container"},[s("el-checkbox",{staticClass:"check",on:{change:function(e){return t.onProductCheckChange(o)}},model:{value:t.dropshinpperList[o].checked,callback:function(e){t.$set(t.dropshinpperList[o],"checked",e)},expression:"dropshinpperList[index].checked"}})],1),s("my-img",{staticClass:"dropshinpper-item-left",attrs:{src:e.mainImageUrl}}),s("div",{staticClass:"dropshinpper-item-right"},[e.failReason?s("el-alert",{attrs:{type:"error",title:e.failReason}}):t._e(),s("div",{staticClass:"dropshinpper-item-title"},[t._v(t._s(e.title))]),s("div",{staticClass:"dropshinpper-item-attr"},[t._v(t._s(e.optionInfo))]),s("div",{staticClass:"dropshinpper-item-tip",domProps:{innerHTML:t._s(e.blankContent)}})],1),s("div",{staticClass:"dropshinpper-item-tool"},[e.status===t.enums.customProductStatusEnum.PUBLISHING.value?s("el-button",{staticClass:"dropshinpper-item-tool-item",attrs:{type:"info"}},[t._v(" Publishing ... ")]):e.status===t.enums.customProductStatusEnum.WAIT_PUBLISH.value?s("el-button",{staticClass:"dropshinpper-item-tool-item",attrs:{type:"warning"}},[t._v(" Wait For Publish ... ")]):e.status===t.enums.customProductStatusEnum.UNPUBLISHED.value?s("el-button",{staticClass:"dropshinpper-item-tool-item",attrs:{type:"primary"},on:{click:function(i){return t.release(e)}}},[t._v(" Publish ")]):e.status===t.enums.customProductStatusEnum.PUBLISH_FAIL.value?s("el-button",{staticClass:"dropshinpper-item-tool-item",attrs:{type:"primary"},on:{click:function(i){return t.release(e)}}},[t._v(" Publish Fail,Try again ")]):e.status!==t.enums.customProductStatusEnum.PUBLISHED.value||e.isHiddenInStore?e.status===t.enums.customProductStatusEnum.PUBLISHED.value&&e.isHiddenInStore?s("el-button",{staticClass:"dropshinpper-item-tool-item"},[t._v(" hidden ")]):t._e():s("el-button",{staticClass:"dropshinpper-item-tool-item",on:{click:function(i){return t.openStoreUrl(e)}}},[t._v(" See in Store ")]),s("el-button",{staticClass:"dropshinpper-item-tool-item",on:{click:function(i){return t.toEdit(e.blankProductId,e.id)}}},[t._v("Edit listing")]),s("div",{staticClass:"dropshinpper-item-tool-item",on:{click:function(e){return t.showToolFn(o)}}},[s("img",{staticClass:"div-hover",attrs:{src:i("60fc"),alt:"more"}}),s("div",{directives:[{name:"show",rawName:"v-show",value:t.showTool&&t.showToolIndex===o,expression:"showTool && showToolIndex === index"}],staticClass:"tool-marks"}),s("transition",{attrs:{name:"el-zoom-in-top"}},[s("div",{directives:[{name:"show",rawName:"v-show",value:t.showTool&&t.showToolIndex===o,expression:"showTool && showToolIndex === index"}],staticClass:"show-tool"},[e.status===t.enums.customProductStatusEnum.PUBLISHED.value?s("div",{staticClass:"show-tool-item div-hover",on:{click:function(i){e.isHiddenInStore?t.showOnShopify(e.id):t.hideOnShopify(e.id)}}},[t._v(" "+t._s(e.isHiddenInStore?"show on "+t.shopTypeName:"Hide on "+t.shopTypeName)+" ")]):t._e(),s("div",{staticClass:"show-tool-item div-hover",on:{click:function(i){return t.deleteShopify(e.id)}}},[t._v("Delete")])])])],1)],1)],1)})),s("el-pagination",{staticClass:"pagination",attrs:{background:"",layout:"prev, pager, next, sizes","page-sizes":[10,20,30,40],total:t.query.total,"hide-on-single-page":""},on:{"size-change":t.handleSizeChange,"current-change":t.handleCurrentChange}})]:[s("el-empty",{staticStyle:{margin:"0 auto"},attrs:{image:i("7a97"),"image-size":300,description:"No product yet"}})],s("batch-distribution",{ref:"BatchDistribution",attrs:{"load-blank-product-data":!1,show:t.batchDistributionDialog.show},on:{"update:show":function(e){return t.$set(t.batchDistributionDialog,"show",e)},success:t.onEditListingsSuccess}})],2)},o=[],n=i("2f69"),r=i("f13c"),a=i.n(r);const l={PUBLISHING:{text:"发布中",value:99},WAIT_PUBLISH:{text:"等待发布中",value:97},PUBLISH_FAIL:{text:"发布失败",value:98},PUBLISHED:{text:"已发布",value:2},UNPUBLISHED:{text:"未发布",value:1}};var c=l,u=i("8f8f"),d=function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.show?i("div",{ref:"bathcDistributionDialog",staticClass:"batch-distribution-dialog",attrs:{id:"batch-distribution-dialog"}},[i("el-card",{staticClass:"batch-distribution-dialog-card",attrs:{id:"batch-distribution-dialog-card",shadow:"always"}},[i("div",{staticClass:"batch-distribution-dialog-card-title",attrs:{id:"batch-distribution-dialog-title"}},[t._v("Configuration jewelry box")]),i("i",{staticClass:"el-icon-close close cursor-pointer",on:{click:function(e){return e.target!==e.currentTarget?null:t.hiddenDialog.apply(null,arguments)}}}),i("el-divider"),i("store-details",{attrs:{"fittings-id":t.dropshinpperForm.fittingsId,"blank-fittings-level":t.dropshinpperForm.blankFittingsLevel,"level-fittings":t.fittingses,"show-store-info":!1,"show-blank-greeting-card":!1},on:{"update:fittingsId":function(e){return t.$set(t.dropshinpperForm,"fittingsId",e)},"update:fittings-id":function(e){return t.$set(t.dropshinpperForm,"fittingsId",e)},"update:blankFittingsLevel":function(e){return t.$set(t.dropshinpperForm,"blankFittingsLevel",e)},"update:blank-fittings-level":function(e){return t.$set(t.dropshinpperForm,"blankFittingsLevel",e)}}}),i("div",{staticClass:"dropshinpper-button"},[i("el-button",{attrs:{disabled:t.doing},on:{click:t.hiddenDialog}},[t._v("Cancel")]),i("el-button",{directives:[{name:"loading",rawName:"v-loading",value:t.doing,expression:"doing"}],attrs:{disabled:t.doing,type:"primary"},on:{click:t.toSave}},[t._v("Save")])],1)],1)],1):t._e()},p=[],h=i("afad"),f=i("b0dc"),m={name:"ConfigurationJewelryBox",components:{StoreDetails:h["a"]},data(){return{show:!1,customProductIds:[],fittingses:[],dropshinpperForm:{hiddenInStore:!1,blankFittingsLevel:1,collectionId:"",fittingsId:null},dropshinpperRules:{hiddenInStore:[{required:!0,message:"The HiddenInStore field is required",trigger:"blur"}],blankFittingsLevel:[{required:!0,message:"The BlankFittingsLevel field is required",trigger:"blur"}]},doing:!1}},mounted(){this.loadBlankFittings()},methods:{init({customProductIds:t}){this.customProductIds=t,this.show=!0},hiddenDialog(){this.$refs.bathcDistributionDialog.className+=" hidden-dialog",setTimeout(()=>{this.show=!1},500)},loadBlankFittings(){Object(f["a"])({fittingAll:!0}).then(t=>{if(200===t.code){var e=t.data.records||[];this.fittingses=e,this.fittingses&&this.fittingses.length&&(this.dropshinpperForm.fittingsId=this.fittingses[0].id)}})},toSave(){this.doing=!0;var t={};t.customProductIds=this.customProductIds,t.fittingsLevel=this.dropshinpperForm.blankFittingsLevel,t.fittingsId=this.dropshinpperForm.fittingsId,Object(n["e"])(t).then(t=>{200===t.code&&(this.$message.success("Save success"),this.hiddenDialog(),this.$emit("save"))}).finally(()=>{this.doing=!1})}}},g=m,b=(i("182a"),i("2877")),v=Object(b["a"])(g,d,p,!1,null,"07de4ff6",null),I=(v.exports,function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.show?i("div",{ref:"bathcDistributionDialog",staticClass:"batch-distribution-dialog",attrs:{id:"batch-distribution-dialog"}},[i("el-card",{staticClass:"batch-distribution-dialog-card",attrs:{id:"batch-distribution-dialog-card",shadow:"always"}},[i("div",{staticClass:"batch-distribution-dialog-card-title",attrs:{id:"batch-distribution-dialog-title"}},[t._v("Configuration greeting card")]),i("i",{staticClass:"el-icon-close close cursor-pointer",on:{click:function(e){return e.target!==e.currentTarget?null:t.hiddenDialog.apply(null,arguments)}}}),i("el-divider"),i("store-details",{attrs:{"greeting-cards":t.greetingCards,"blank-greeting-card-id":t.blankGreetingCardId,"show-store-info":!1,"show-package":!1,"show-blank-greeting-card":!0},on:{"update:blankGreetingCardId":function(e){t.blankGreetingCardId=e},"update:blank-greeting-card-id":function(e){t.blankGreetingCardId=e}}}),i("div",{staticClass:"dropshinpper-button"},[i("el-button",{attrs:{disabled:t.doing},on:{click:t.hiddenDialog}},[t._v("Cancel")]),i("el-button",{directives:[{name:"loading",rawName:"v-loading",value:t.doing,expression:"doing"}],attrs:{disabled:t.doing,type:"primary"},on:{click:t.toSave}},[t._v("Save")])],1)],1)],1):t._e()}),y=[],C=i("623f"),k={name:"ConfigurationGreetingCard",components:{StoreDetails:h["a"]},data(){return{show:!1,customProductIds:[],greetingCards:[],blankGreetingCardId:null,doing:!1}},mounted(){this.loadGreetingCards()},methods:{async loadGreetingCards(){var t=await Object(C["m"])({});this.greetingCards=t.data||[]},init({customProductIds:t}){this.customProductIds=t,this.show=!0},hiddenDialog(){this.$refs.bathcDistributionDialog.className+=" hidden-dialog",setTimeout(()=>{this.show=!1},500)},toSave(){this.doing=!0;var t={};t.customProductIds=this.customProductIds,t.blankGreetingCardId=this.blankGreetingCardId,Object(n["f"])(t).then(t=>{200===t.code&&(this.$message.success("Save success"),this.hiddenDialog(),this.$emit("save"))}).finally(()=>{this.doing=!1})}}},w=k,S=(i("fa34"),Object(b["a"])(w,I,y,!1,null,"f6eccb20",null)),P=(S.exports,i("2f62")),D=i("e661"),L={name:"DropshinpperList",components:{BatchDistribution:u["a"]},data(){return{query:{total:0,current:1,size:10,keyword:"",status:"",isHiddenInStore:""},dropshinpperList:[],enums:{customProductStatusEnum:c},showTool:!1,showToolIndex:0,publishStatusInterval:!1,selectAll:!1,selectAllIndeterminate:!1,batchDistributionDialog:{show:!1},editListingsLoading:!1}},computed:{...Object(P["b"])("user",{currentShop:"getCurrentShop"}),selectDropshippers(){var t=[];if(this.dropshinpperList&&this.dropshinpperList.length)for(const e of this.dropshinpperList)e.checked&&t.push(e);return t},batchPublishBtnValid(){return this.selectDropshippers.length},editListingsBtnValid(){if(!this.selectDropshippers.length)return!1;for(const t of this.selectDropshippers)if(t.isCustomDesignFittings)return!1;return!0},configurationJewelryBoxBtnValid(){if(!this.selectDropshippers.length)return!1;for(const t of this.selectDropshippers)if(t.isCustomDesignFittings)return!1;return!0},configurationGreetingCardBtnValid(){if(!this.selectDropshippers.length)return!1;for(const t of this.selectDropshippers)if(t.isCustomDesignFittings)return!1;return!0},shopTypeName(){return this.currentShop.shopType===D["a"].SHOPIFY.value?"shopify":this.currentShop.shopType===D["a"].ETSY.value?"etsy":this.currentShop.shopType===D["a"].WOOCOMMERCE.value?"woocommerce":"common"}},async created(){await this.getList()},methods:{async startPublishStatusInternal(){if(this.dropshinpperList&&this.dropshinpperList.length){var t=[];for(const e of this.dropshinpperList)e.publishId&&t.push(e.publishId);t.length>0&&await this.getPublishStatuses(t)}},async getPublishStatuses(t){var e={};e.customProductPublishIds=t;var i=await Object(n["o"])(e);if(i.data.records&&i.data.records.length){var s=!1;for(const t of i.data.records)3===t.status&&(this.$message.error("publish failure"),s=!0),2===t.status&&(s=!0);s?this.getList(!1):setTimeout(this.startPublishStatusInternal,1e3)}},reloadList(){this.query.current=1,this.getList()},async getList(t=!0){const e=await Object(n["k"])(this.query);var i=e.data.records||[];for(const s of i)s.checked=!1;this.dropshinpperList=i,this.selectAll=!1,this.selectAllIndeterminate=!1,this.query.total=e.data.total,t&&a.a.scrollTo("#dropshinpper-box",500,{offset:-120,easing:"ease-in-out"}),setTimeout(this.startPublishStatusInternal,1e3)},showToolFn(t){this.showToolIndex=t,this.showTool=!this.showTool},hideOnShopify(t){const e=this.$loading();this.$confirm(`Are you sure you want to hide on ${this.shopTypeName}?`,"tip",{confirmButtonText:"Yes",cancelButtonText:"Cancel",type:"warning"}).then(async()=>{await Object(n["g"])(t),e.close(),this.getList(),this.$message({type:"success",message:"success!"})}).catch(()=>{e.close(),this.$message({type:"info",message:"cancel"})})},showOnShopify(t){const e=this.$loading();this.$confirm(`Are you sure you want to show on ${this.shopTypeName}?`,"tip",{confirmButtonText:"Yes",cancelButtonText:"Cancel",type:"warning"}).then(async()=>{await Object(n["r"])(t),this.getList(),e.close(),this.$message({type:"success",message:"success!"})}).catch(()=>{e.close(),this.$message({type:"info",message:"cancel"})})},deleteShopify(t){this.$confirm(`Are you sure you want to delete on ${this.shopTypeName}?`,"tip",{confirmButtonText:"Yes",cancelButtonText:"Cancel",type:"warning"}).then(async()=>{await Object(n["q"])(t),this.getList(),this.$message({type:"success",message:"success!"})}).catch(()=>{this.$message({type:"info",message:"cancel"})})},toEdit(t,e){this.callNewPage(`/Dropshinpper/${t}/${e}`)},async release(t){await this.publish(t.id),this.getList(!1)},openStoreUrl(t){window.open(t.productStoreUrl)},async publish(t){const e=await Object(n["l"])({customProductId:t});return e.data.customProductPublishId},handleSizeChange(t){this.query.size=t,this.getList()},handleCurrentChange(t){this.query.current=t,this.getList()},onCheckAll(t){if(t)for(const e of this.dropshinpperList)e.checked=!0;else for(const e of this.dropshinpperList)e.checked=!1;this.selectAllIndeterminate=!1,this.dropshinpperList.splice()},onProductCheckChange(){this.dropshinpperList.splice();let t=0;for(const e of this.dropshinpperList)e.checked&&(t+=1);this.selectAll=t>0&&t===this.dropshinpperList.length,this.selectAllIndeterminate=t>0&&t{t&&this.$emit("save",this.dropshinpperForm)})}}},I=v,y=(i("9b98"),i("2877")),C=Object(y["a"])(I,h,f,!1,null,"fb70e02e",null),k=C.exports,w=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"dropshinpper-detail"},[i("el-form",{ref:"dropshinpperForm",attrs:{model:t.dropshinpperForm,rules:t.dropshinpperRules,"label-width":"100px","label-position":"top"}},[i("div",{staticClass:"dropshinpper-card"},[i("div",{staticClass:"dropshinpper-card-title"},[t._v("Store details")]),t.blankProductIdList?i("StoreDetails",{attrs:{"greeting-cards":t.greetingCards,"fittings-id":t.dropshinpperForm.fittingsId,"blank-fittings-level":t.dropshinpperForm.blankFittingsLevel,"default-logistics-type":t.defaultLogisticsType,"collection-id":t.dropshinpperForm.collectionId,"hidden-in-store":t.dropshinpperForm.hiddenInStore,"blank-greeting-card-id":t.dropshinpperForm.blankGreetingCardId,"level-fittings":t.fittingses,"blank-product-id-list":t.blankProductIdList,"fittings-id-list":t.fittingsIdList},on:{"update:fittingsId":function(e){return t.$set(t.dropshinpperForm,"fittingsId",e)},"update:fittings-id":function(e){return t.$set(t.dropshinpperForm,"fittingsId",e)},"update:blankFittingsLevel":function(e){return t.$set(t.dropshinpperForm,"blankFittingsLevel",e)},"update:blank-fittings-level":function(e){return t.$set(t.dropshinpperForm,"blankFittingsLevel",e)},"update:defaultLogisticsType":function(e){t.defaultLogisticsType=e},"update:default-logistics-type":function(e){t.defaultLogisticsType=e},"update:collectionId":function(e){return t.$set(t.dropshinpperForm,"collectionId",e)},"update:collection-id":function(e){return t.$set(t.dropshinpperForm,"collectionId",e)},"update:hiddenInStore":function(e){return t.$set(t.dropshinpperForm,"hiddenInStore",e)},"update:hidden-in-store":function(e){return t.$set(t.dropshinpperForm,"hiddenInStore",e)},"update:blankGreetingCardId":function(e){return t.$set(t.dropshinpperForm,"blankGreetingCardId",e)},"update:blank-greeting-card-id":function(e){return t.$set(t.dropshinpperForm,"blankGreetingCardId",e)},"update:fittingsIdList":function(e){t.fittingsIdList=e},"update:fittings-id-list":function(e){t.fittingsIdList=e}}}):t._e()],1),i("div",{staticClass:"dropshinpper-button"},[i("el-button",{attrs:{disabled:t.doing},on:{click:t.toBack}},[t._v("Previous")]),i("el-button",{directives:[{name:"loading",rawName:"v-loading",value:t.doing,expression:"doing"}],attrs:{disabled:t.doing,type:"primary"},on:{click:t.toSave}},[t._v("Bulk distribution")])],1)])],1)},S=[],P=i("afad"),D=i("b0dc"),L=i("623f"),x={name:"StoreDetail",components:{StoreDetails:P["a"]},props:{blankProductIdList:{type:Array,default:()=>[]}},data(){return{fittingsIdList:[],defaultLogisticsType:1,fittingses:[],greetingCards:[],dropshinpperForm:{hiddenInStore:!1,blankFittingsLevel:1,collectionId:"",fittingsId:null,blankGreetingCardId:null,fittingsIdList:[]},dropshinpperRules:{hiddenInStore:[{required:!0,message:"The HiddenInStore field is required",trigger:"blur"}],blankFittingsLevel:[{required:!0,message:"The BlankFittingsLevel field is required",trigger:"blur"}]},doing:!1}},mounted(){this.loadBlankFittings(),this.loadGreetingCards()},methods:{async loadGreetingCards(){var t=await Object(L["m"])({});this.greetingCards=t.data||[]},loadBlankFittings(){Object(D["a"])({fittingAll:!0}).then(t=>{if(200===t.code){var e=t.data.records||[];this.fittingses=e,this.fittingses&&this.fittingses.length&&(this.dropshinpperForm.fittingsId=this.fittingses[0].id)}})},toBack(){this.$emit("back")},toSave(){this.$refs.dropshinpperForm.validate(t=>{t&&(this.$emit("save",{blankFittingsLevel:this.dropshinpperForm.blankFittingsLevel,fittingsId:this.dropshinpperForm.fittingsId,collectionId:this.dropshinpperForm.collectionId,hiddenInStore:this.dropshinpperForm.hiddenInStore,blankGreetingCardId:this.dropshinpperForm.blankGreetingCardId,fittingsIdList:this.fittingsIdList,defaultLogisticsType:this.defaultLogisticsType}),this.doing=!0)})}}},A=x,_=(i("3f74"),Object(y["a"])(A,w,S,!1,null,"1c636e14",null)),F=_.exports,$={name:"BatchDistributionDialog",components:{ProductTagsSelector:a["a"],MInputNumber:p["a"],DropshipDetail:k,StoreDetail:F},filters:{profileFilter(t){if(null==t.bulkDistributionDefaultPriceRate||null==t.bulkDistributionDefaultPriceAdd){if(t.dropShippingForm){let e=-1/0,i=1/0;for(const s of t.dropShippingForm.variantList){const t=Number(s.retailPrice)-Number(s.costs);t>e&&(e=t),ts&&(s=t.costs),t.costs{this.$emit("update:show",!1)},500)},handleCurrentChange(t){this.page.current=t,this.getProducts()},async getProducts(){if(!this.loadBlankProductData)return;this.productLoading=!0;var t={isDropshipped:!1};t.isNew=this.isSelectNew,t.labelIds=this.selectLabelIds,t.current=this.page.current,t.size=this.page.size;const e=await Object(n["c"])(t);this.productLoading=!1,this.page.total=e.data.total,this.productList=[];for(const i of e.data.records)i.checked=!1,i.bulkDistributionDefaultPriceRate=100*this.userInfo.bulkDistributionDefaultPriceRate,i.bulkDistributionDefaultPriceAdd=this.userInfo.bulkDistributionDefaultPriceAdd,i.bulkDistributionCompareAtPriceRate=100*this.userInfo.bulkDistributionCompareAtPriceRate,this.productList.push(i);this.scrollToTop()},scrollToTop(){u.a.scrollTo("#batch-distribution-dialog-title",500,{offset:-120,easing:"ease-in-out",container:"#batch-distribution-dialog-card"})},reloadProducts(){this.page.current=1,this.getProducts()},onSelectLabelChange({isSelectNew:t,labelIds:e}){this.isSelectNew=t,this.selectLabelIds=e,this.reloadProducts()},onCheckAll(t){if(t)for(const e of this.productList)e.checked=!0;else for(const e of this.productList)e.checked=!1;this.selectAllIndeterminate=!1,this.productList.splice()},onProductCheckChange(){this.productList.splice();let t=0;for(const e of this.productList)e.checked&&(t+=1);this.selectAll=t>0&&t===this.productList.length,this.selectAllIndeterminate=t>0&&t{const e=Number(t.retailPrice)-Number(t.costs),i=Number(t.profit)/Number(t.costs)*100;t.profit=e,t.profitMargin=i})),t},async toEditMore(t){var e=this.productList[t];await this.loadProductDetail(e),null!=e.bulkDistributionDefaultPriceRate&&null!=e.bulkDistributionDefaultPriceAdd&&e.dropShippingForm.variantList.forEach(t=>{const i=t.costs*e.bulkDistributionDefaultPriceRate/100+e.bulkDistributionDefaultPriceAdd,s=Number(t.profit)/Number(t.costs)*100;t.retailPrice=Object(d["d"])(t.costs+i),t.profit=i,t.profitMargin=s}),null!=e.bulkDistributionCompareAtPriceRate&&e.dropShippingForm.variantList.forEach(t=>{t.compareAtPrice=t.costs*e.bulkDistributionCompareAtPriceRate/100,t.compareAtPrice=Object(d["d"])(t.compareAtPrice)}),this.$refs.dropshipDetail.init({detail:e.dropShippingDetailInfo,form:e.dropShippingForm}),this.dropShippingDetailForm.productInfoIndex=t,this.dropShippingDetailForm.productInfo=e,this.showComponent=this.showComponentEnum.DROPSHIP_DETAIL,this.scrollToTop()},onDropshipDetailSave(t){this.productList[this.dropShippingDetailForm.productInfoIndex].dropShippingForm=t,this.productList[this.dropShippingDetailForm.productInfoIndex].custom=!0,this.productList[this.dropShippingDetailForm.productInfoIndex].bulkDistributionDefaultPriceRate=void 0,this.productList[this.dropShippingDetailForm.productInfoIndex].bulkDistributionDefaultPriceAdd=void 0,this.productList[this.dropShippingDetailForm.productInfoIndex].bulkDistributionCompareAtPriceRate=void 0,this.showComponent=this.showComponentEnum.MAIN,this.scrollToTop()},onDropshipDetailBack(){this.showComponent=this.showComponentEnum.MAIN,this.scrollToTop()},async toContinue(){this.showComponent=this.showComponentEnum.STORE_DETAIL},async onStoreDetailSave({blankFittingsLevel:t,collectionId:e,fittingsId:i,blankGreetingCardId:s,hiddenInStore:o,fittingsIdList:n,defaultLogisticsType:a}){var l={},c=[];l.records=c;for(const r of this.selectProducts){var u={};u.blankProductId=r.id,r.dropShippingForm&&(u.mainImageUrl=r.dropShippingForm.mainImageUrl,u.title=r.dropShippingForm.title,u.description=r.dropShippingForm.description,u.isAddMertic=r.dropShippingForm.isAddMertic,u.tags=r.dropShippingForm.tags,u.variantList=r.dropShippingForm.variantList),u.defaultLogisticsType=a,u.fittingsIdList=n,u.blankGreetingCardId=s,u.hiddenInStore=o,u.blankFittingsLevel=t,u.fittingsId=i,u.collectionId=e,u.bulkDistributionDefaultPriceRate=r.bulkDistributionDefaultPriceRate,u.bulkDistributionDefaultPriceRate&&(u.bulkDistributionDefaultPriceRate=Object(d["d"])(u.bulkDistributionDefaultPriceRate/100)),u.bulkDistributionDefaultPriceAdd=r.bulkDistributionDefaultPriceAdd,u.bulkDistributionCompareAtPriceRate=r.bulkDistributionCompareAtPriceRate,u.bulkDistributionCompareAtPriceRate&&(u.bulkDistributionCompareAtPriceRate=Object(d["d"])(u.bulkDistributionCompareAtPriceRate/100)),c.push(u)}var p=await Object(r["j"])(l);200===p.code?(p=await Object(r["p"])({customProductIds:p.data}),200===p.code?(this.$message.success("Bulk distribution success!"),this.hiddenDialog(),this.$emit("success"),this.callNewPage("/DropshinpperList")):this.$message.error(p.msg)):this.$message.error(p.msg)},onStoreDetailBack(){this.showComponent=this.showComponentEnum.MAIN,this.scrollToTop()},toEditProfit(){this.editProfitDialog.bulkDistributionDefaultPriceRate=void 0,this.editProfitDialog.bulkDistributionDefaultPriceAdd=void 0,this.editProfitDialog.show=!0},doEditProfit(){for(const t of this.selectProducts)t.custom||(t.bulkDistributionDefaultPriceRate=this.editProfitDialog.bulkDistributionDefaultPriceRate,t.bulkDistributionDefaultPriceAdd=this.editProfitDialog.bulkDistributionDefaultPriceAdd);this.editProfitDialog.show=!1},toEditComparePrice(){this.editComparePriceDialog.bulkDistributionCompareAtPriceRate=void 0,this.editComparePriceDialog.show=!0},doEditComparePrice(){for(const t of this.selectProducts)t.custom||(t.bulkDistributionCompareAtPriceRate=this.editComparePriceDialog.bulkDistributionCompareAtPriceRate);this.editComparePriceDialog.show=!1}}},T=$,O=(i("365b"),Object(y["a"])(T,s,o,!1,null,"56a531f1",null));e["a"]=O.exports},9486:function(t,e,i){t.exports=i.p+"static/img/eyes-icon.96da6581.svg"},9791:function(t,e,i){"use strict";i("0e0d")},"9b98":function(t,e,i){"use strict";i("aaaa")},"9dd6":function(t,e,i){"use strict";i("67f7")},a3c1:function(t,e){t.exports="data:image/webp;base64,UklGRl4FAABXRUJQVlA4WAoAAAAQAAAAdwAAdwAAQUxQSKwDAAABoC0AjNo4UqDOOoylpdibOOu6Y8ejP2iPmZmZmZmZ6ZvwC5iZma80ydqS5p4jAoIbSYqkiM7l7d49aPwB0Fusdrd5QRipROtERWHgbetWiyDchYGvMKPKHyxIpdjzE8xp7PeK8mgOUyQxHTZl/VoXYyRULS5IwR1qJFYPRdyojzQyqNdq3FTWkM21Cuu/zmKKjKaLRTa6CplVHR42BSjAoMzRUSQowrhJzqJGIepFWsoTFOSE8lWVCEUZOXQdY4zCVC5VzzhFcSZ1ElopCjRtUdzeH5El/013ikKdujlxYhRrnK+dcoSCjcp5CFC0QZ5OGYW7mH0I0tLRzawDboLiTTZlojAzBtn3mj5a4SBLW4kdJBmaWkVLXNmQmrYFXduIdbTG9Y26DLTI5nzmNGFbC3W0yvo8RnYxmjfJ0Owc9+ZhpJW4cvqM47/c8/7BSOjq7IiQcHPiN3v27HlnF2VnWTDpcOfkb/cc8DUktG3iM3Pad0Z+OJ0S36CU8nLGj2ZOo51Nlw7Q483ZPxn57lSktXcAj5Xzfjby7SlIjHeAmJMLfjVzEv0kHgAqnLn4NyPfnIj0VnjnVZf9buQrjmCf9Zkr/zBzPHLgASg2rvnTyJfHMW0BQEFzccNfRj5nCuqCy5Wb/jZzDHLpdpi49R8jHx+FbLS38nDnTI5APrYMWbjnXyMfHoaMrI44uP8/Ix+wBkcTBh42896hzLuHIT2Pz+Rg5CXcSc5TZt49CJnZmVDz/B7Dt9iDSUrMKzPZjeyk9mLvHXtfssPaiuztr8ac/TNvGVk7Hg15x98Pj2BkK/d8g7F0uOdXnzLOr4rs80muogvWzp8lrBe+ZFovyFgfsZS+vetBIevfbxjWv3LW++TFE7S/Qb3R0BO0n/Md9X6OqP0r0uLL2q97lXRQMClM7duftHY/1v79Zxhbtt9u7/mCrecpE5hLyyZaMN/QHkJ7zwdtPQ9d/f84/4WBHfQhixM7msiEY8FDiQPZbImvULcgq8vSWYLMFELZrBcgu46SjHIgjwuCK0gqkM/qVCrTKuS1kcokrUN+W6nItIDCusA3JHWg0VXSiF2g0olkscMBOsuBJIISkLpdzBihtwO1jVhIHQ2gtzyWwLgMLHbZH4y7wGVpibVKvVQCRl3GSVfgArNNpjbGTRBg1SOvRvtVEKKzSNpjq0UHJFlfnRKNPCt1EGehPcz9djVsF0Colb6f+Snl9ysg3GK1u80LwkglWicqCgNvW7daBHIBVlA4IIwBAAAwDQCdASp4AHgAPm02l0kkIqIhIRgI6IANiWlu4XSRKvP7qDPlAboHeA4QYvpmWen/YA/TjqbfsR7AH6Vhmn3hzWFa/ICinUlF59l2+pmeoEtWA0ih8kFTD7r8QiQOqyxQRR0QKyePqqgwqou2Z94c1SAA/v+u+ALTvN2vfzXxgw+Y2JNSRLeB9RX/IlCJnXR/CuwGh3Bb88v3diUb773rXPyA9ksow/j8X279RDsy57Cd1o8A032Tkk5OceLhHGcrNqVk/4W5GnK7kcOHv08ccDdf4lsomAGio00oCPpQ/8p7O1e0Bx8AINGXcn9kfz33i0+Pbzt/D+GasWSj93PDP/x7guedVe3fzdDsYtVPB0G02Gnf1MB9F4N8ZRFXU2jRZNE5s1bJi3Y8GIQDTgmIub6JQm0TD4dwu1bgYOwxZkRvdxDzSbKn3cyzwHki00dcvpgchFARAyj5zaGIJ1/S3S2n956v1vTsBgaHVCd/Zo/2e6dTxaFp1qdvR5/agCFvmXzHwZvfIAAAAAA="},a8ad:function(t,e){t.exports="data:image/webp;base64,UklGRkwFAABXRUJQVlA4WAoAAAAQAAAAdwAAdwAAQUxQSKcDAAABoGZb29q2eg2VIzOWQrISK1FVSdb3zqCXmZmZmZmZaVA0AmZm5lv64kgv/I8ICG7bSJIkzz1TtWcqXf0DoLdc7+8YB2EUp8akcRQG4x39ehmEOzfyY8xp7I/mpFIe+CkWNPEHZXm0vQxJzLy2rF/rfIKExvNzUnA9g8QaT8Sd5qpBBs1Kg5vaCrK5UmP915nPkNFsvsxGP0Zm4x4PWwIUYFDlKBQpijBpkzNvUIhmnpbqGgpyjfJdtQhFGTl0hTFBYcYuVWWcojjTJgmdDAWadSjuH7iITPG77hSFOnUL4iQo1qTYPNUIBRtVixCgaIMiRRmFO59/CTLSMe28C26K4k235KK0YQ3S954hqnCUZ65UB2mOqZZRiUub0jBaMI3NWEc1rm9WMlCR7dnMmELbDE1UZXMWq7pYndVkGEqOfOtE/kFclppx2Ad7vzqJPcsbV4SUkD3v7t2799tT2ItlyaaHhLy+96Dfncadro1PyVk/Wfn+TGZ8iwptx3zmj1Z+Opu5m64cZIBIm++t/HwebwYHGSOxp9v55UJWxgehb9VP/c7KrxezNvEAUEOkz7dWfr+UMzWmvuoUO39cycjw4CscnvS1lT+vYX0hRp58ZeWv6/i2AKBkkMcT7fx9E9uaVHKRy+O/sPLPrcik20O+fGbl3zu4lobtyOfRn9i5h4dtHnLmIyv/3c+z9vO2Vkfa+f8hliaLuYM94kM7j3HsHobInPftPEVPuBuZPWxDniVnd4rcHvreXsuXyHu7DPnztp3XqFsdARzChYAH73I94H/Le2xv2cX9ScaBuOvVB4z1asJbnz/krM8e67LAuh55atff7T0+jv2Et9/o6e2vymz95Bfs/aTa/lnv8YLe4yO9x4Nqj3/1Hu/r3d/Qu5+jdv9K7X5dz6Y01bc/qXY/Vv/+M0yU7bfrPb+g9XzKGsyko4kOzDbUQ6j3/KDW86HLis//bu5IB0PI45qOKXLhKHgqdSCfHfEDmg7kdVE6C5CbUiib9RLk14klEztQxDnBA6Q1KGZ9KpVpHYraymSSNaG4HZHJOkBhU+AH0ibQ6MbSSFyg0olkscsBOquBJIIKkLpTzBphdgK1rUTIGC2gtzqRwKQKLPbZn0z6wGVlgXVIs1ABRl3Gpitwgdk20xyTNgiwPiYfxvh1EKIzT1qx43kHJNlcnhKtPEtNEGep6xX+eOx1SyDU2tDP/VLsD2sg3HK9v2MchFGcGpPGURiMd/TrZSAXAABWUDggfgEAABANAJ0BKngAeAA+bTaXSSQioiEiFAjQgA2JaW7hdJEovd4ZQG6B3gOEGMkZjvqX2AP1A6mH7Y+wB+lYfKF7pQuLTjdh4ly53S18X7Tjaob6usGMe3rwDP+6AXlT8xq2edji0ghnyt5e6ULi043cAVYAAP7/rvgJH5q/rfjkf8S3LI7zZjEh5uHI6Olf/5cr+xifjZBULN/mhv3zU/ETiPZT9LjsZqpy3CzaggHfLdh8MlU5MIDTWBIwUBAqlZ6REHhp2pmA5TIWuQIR6+Pe5tV26YWeW8bJRNvW6vsNFx2C/d0ewAHMPZBWzJpltdPyebv+xk6bH59If66rP2Idi7gpRUMf7IXm70puwGh3Bb87yqXpzjUZ/0AwbZsf2sB0VarmIYI7aRSffLGc8m4LWYlBr+pad+Zuer/zwf0x6RexSohW6Y8Cm8e36TZtZqncfIY/ZH5t5yaiUWjL22DYAEn/03ubv+MPcyl1ZsKLdKDvh483v7xmojD4ugAAAAA="},aaaa:function(t,e,i){},afad:function(t,e,i){"use strict";var s=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"upgrade-box"},[s("div",{staticClass:"row"},[s("div",{staticClass:"default-shipping"},[t._v("default shipping")]),s("div",{staticClass:"shipping-detail",attrs:{slot:"reference"},on:{click:t.showShippingRateInfoClick},slot:"reference"},[t._v("Shipping Price Details")])]),s("ShippingRates",{directives:[{name:"show",rawName:"v-show",value:t.showShippingRateInfo,expression:"showShippingRateInfo"}],staticStyle:{"margin-bottom":"40px"},attrs:{"detail-info":t.detail}}),s("div",{staticClass:"row"},[s("el-checkbox-group",{attrs:{size:"large"},model:{value:t.shippingMethod,callback:function(e){t.shippingMethod=e},expression:"shippingMethod"}},[s("el-checkbox",{staticClass:"checkbox",attrs:{label:1},on:{change:function(e){return t.shippingChange(1)}}},[t._v("Standard logistics")]),s("el-checkbox",{staticClass:"checkbox",attrs:{label:2},on:{change:function(e){return t.shippingChange(2)}}},[t._v("Fast shipping")])],1)],1),t.category2List&&t.category2List.length>0?s("div",{staticClass:"order-fitting-row"},[s("div",{staticClass:"box"},[s("el-collapse",{attrs:{value:t.openCollapseList}},t._l(t.category2List,(function(e){return s("el-collapse-item",{key:e.key,attrs:{name:e.key}},[s("template",{slot:"title"},[s("div",{staticClass:"collapse-header"},[s("div",{staticClass:"collapse-header-left"},[s("span",[t._v(t._s(e.label))])]),s("div",{staticClass:"collapse-header-right"},[s("span",{staticClass:"text"},[t._v(" "+t._s(e.radioKey?"checked":"unchecked")+" ")])])])]),s("div",{staticClass:"collapse-item-box"},[s("el-radio-group",{staticStyle:{width:"100%"},model:{value:e.radioKey,callback:function(i){t.$set(e,"radioKey",i)},expression:"category.radioKey"}},t._l(t.orderListMap.get(e.key),(function(e){return s("div",{key:e.radioKey,staticClass:"item",on:{click:function(i){return i.stopPropagation(),i.preventDefault(),t.orderRadioClick(e)}}},[s("el-radio",{staticClass:"radio-box",attrs:{label:e.radioKey}},[s("img",{staticClass:"item-image",attrs:{alt:e.title,src:e.mainImageUrl},on:{click:function(i){return i.preventDefault(),i.stopPropagation(),t.showImgList([e.mainImageUrl])}}}),s("div",{staticClass:"item-content"},[s("div",[t._v(t._s(e.title))]),1===e.stockingStrategy?s("div",[t._v(" ("+t._s(e.price?"US$ "+e.price:"free")+") ")]):t._e()]),2===e.stockingStrategy?s("div",{staticClass:"inventory",on:{click:function(t){t.stopPropagation(),t.preventDefault()}}},[s("span",[t._v("Your inventory "+t._s(e.inventory?e.inventory:0)+" pic")]),!e.inventory||e.inventory=2&&1===t.currentFittingsLevel?s("div",{staticClass:"upgrade-tip-top-box"},[s("div",{staticClass:"upgrade-tip-top"},[s("div",{staticStyle:{"align-items":"baseline"}},[s("img",{staticClass:"upgrade-tip-icon",attrs:{src:i("522c"),alt:"tip"}})]),s("div",{staticClass:"upgrade-tip-text"},[t._v("This jewelry box needs to subscribe to the premium service, you can get more advanced jewelry packaging at a lower price than the market, so as to better serve your customers, which will be more beneficial to promote your brand")])])]):t._e(),s("div",{staticClass:"upgrade-img-box"},[s("img",{staticClass:"upgrade-img-icon div-hover last",attrs:{src:i("a3c1")},on:{click:function(e){return t.moveFn("last")}}}),s("my-img",{staticClass:"upgrade-img",attrs:{src:t.showImg}}),s("img",{staticClass:"upgrade-img-icon div-hover next",attrs:{src:i("a8ad")},on:{click:function(e){return t.moveFn("next")}}})],1),t.fittingsLevel>=2&&1===t.currentFittingsLevel?s("div",{staticClass:"upgrade-btns"},[s("el-button",{on:{click:t.toSubcriptionDetail}},[t._v("Details")]),s("el-button",{attrs:{type:"primary"},on:{click:t.toSubcription}},[t._v("Subscription")])],1):t._e(),s("subscription-action",{ref:"SubscriptionAction"})],1)},u=[],d=i("7f5a"),p={name:"StoreDetailsDialog",components:{SubscriptionAction:d["a"]},props:{value:{type:Boolean,default:!1},imageUrls:{type:Array,default:()=>[]},fittingsLevel:{type:Number,default:null}},data(){return{dialogVisible:!1,imgIndex:0}},computed:{showImg(){var t;return(null===(t=this.imageUrls)||void 0===t?void 0:t[this.imgIndex])||""},...Object(l["b"])("user",{currentFittingsLevel:"getFittingsLevel"})},watch:{value(t){this.dialogVisible=t},dialogVisible(t){this.$emit("input",t)}},methods:{moveFn(t){"next"===t?this.imgIndex[]},greetingCards:{type:Array,default:()=>[]},fittingsIdList:{type:Array,default:()=>[]},fittingsId:{type:Number,default:null},blankProductIdList:{type:Array,default:()=>[]},customProductId:{type:Number,default:null},blankGreetingCardId:{type:Number,default:null},defaultLogisticsType:{type:Number,default:1},blankFittingsLevel:{type:Number,default:null},hiddenInStore:{type:Boolean,default:!1},collectionId:{type:String,default:""},showStoreInfo:{type:Boolean,default:!0},showBlankGreetingCard:{type:Boolean,default:!0},showPackage:{type:Boolean,default:!0}},data(){return{road:!0,showShippingRateInfo:!1,detail:{},orderListMap:new Map,category2:y["a"],openCollapseList:[],category2List:[],customCollectionList:[],fittingsImgDialog:{show:!1,logoUrl:null,fittings:null},showStoreDetailsDialog:!1,storeDetailsDialog:{show:!1,imageUrls:[],fittingsLevel:null},showImgListTag:!1,currentImgList:[],orderSelectedFittingIds:[],itemSelectedFittingIds:[],skuCategory2List:[],skuListMap:new Map,shippingMethod:[this.defaultLogisticsType]}},computed:{...Object(l["b"])("user",{currentShop:"getCurrentShop",fittingsLevel:"getFittingsLevel",fittingsLogoUrl:"getFittingsLogoUrl"})},watch:{blankProductIdList:{async handler(){this.road&&(await this.getBindFittingsList(),await this.getProductDetail())},deep:!0,immediate:!0},category2List:{handler(t){const e=[];t.forEach(t=>{t.object&&e.push(t.object.customProductId?t.object.customProductId:t.object.blankProductId)}),this.orderSelectedFittingIds=e},deep:!0,immediate:!0},skuCategory2List:{handler(t){const e=[];t.forEach(t=>{t.object&&e.push(t.object.customProductId?t.object.customProductId:t.object.blankProductId)}),this.itemSelectedFittingIds=e},deep:!0,immediate:!0},orderSelectedFittingIds:{handler(t){this.$emit("update:fittingsIdList",this.itemSelectedFittingIds.concat(t))},deep:!0,immediate:!0},itemSelectedFittingIds:{handler(t){this.$emit("update:fittingsIdList",this.orderSelectedFittingIds.concat(t))},deep:!0,immediate:!0}},mounted(){this.shippingChange(this.defaultLogisticsType),this.getCustomCollectionList()},methods:{toCustomAccessories(){this.callNewPage("/CustomAccessories")},showImgList(t){t&&t.length>0&&(this.currentImgList=t,this.showImgListTag=!0)},toReplenishInventory(t){localStorage.setItem("toReplenishInventoryObject",JSON.stringify(t)),this.callNewPage("/MyCustomAccessories/")},showShippingRateInfoClick(){this.showShippingRateInfo=!this.showShippingRateInfo},async getProductDetail(){if(!this.blankProductIdList||0===this.blankProductIdList.length)return;const t=this.blankProductIdList[0],e=await Object(r["a"])({handle:t,shippingRateInfos:!0});this.detail=e.data,this.road=!1},async getBindFittingsList(){if(!this.blankProductIdList||0===this.blankProductIdList.length)return;console.log("blankProductIdList: ",this.blankProductIdList);const t=[];this.blankProductIdList.forEach(e=>{const i={blankProductId:e};this.customProductId&&(i.customProductId=this.customProductId),t.push(i)});const e=await Object(a["g"])({records:t});let i=[];const s=e.data.orderLevelItemList,o=e.data.skuLevelItemList[0].fittingsList;i=o.concat(s),this.road=!1,this.orderListMap=new Map;const n=new Map;for(let r=0;r{const e=t[1];return this.openCollapseList.push(e.key),e})},orderRadioClick(t){if(2===t.stockingStrategy&&t.inventorye.id===t)[0],i=e.level;if(i>this.fittingsLevel)return this.showStoreDetailsDialogFn(e.showImageUrls,e.level),this.$emit("update:blankFittingsLevel",this.levelFittings[0].level),void this.$emit("update:fittingsId",this.levelFittings[0].id);this.$emit("update:blankFittingsLevel",i)}else this.$emit("update:blankFittingsLevel",null)},onBlankGreetingCardChange(t){if(t)if(1===this.fittingsLevel){const e=this.greetingCards.filter(e=>e.id===t)[0];this.showStoreDetailsDialogFn(e.showImageUrls,2),this.$emit("update:blankGreetingCardId",null)}else this.$emit("update:blankGreetingCardId",t);else this.$emit("update:blankGreetingCardId",null)},onCollectionIdChange(t){this.$emit("update:collectionId",t)},onHiddenInStoreChange(t){this.$emit("update:hiddenInStore",t)}}},k=C,w=(i("9791"),Object(f["a"])(k,s,o,!1,null,"32c1d3ca",null));e["a"]=w.exports},b0dc:function(t,e,i){"use strict";i.d(e,"a",(function(){return o}));var s=i("66a5");const o=t=>Object(s["a"])({url:"/shopapi/blankFittings/list",method:"post",data:t})},b490:function(t,e,i){},b4c1:function(t,e,i){"use strict";var s=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{class:["el-input-number",t.inputNumberSize?"el-input-number--"+t.inputNumberSize:"",{"is-disabled":t.inputNumberDisabled},{"is-without-controls":!t.controls},{"is-controls-right":t.controlsAtRight}],on:{dragstart:function(t){t.preventDefault()}}},[t.controls?i("span",{directives:[{name:"repeat-click",rawName:"v-repeat-click",value:t.decrease,expression:"decrease"}],staticClass:"el-input-number__decrease",class:{"is-disabled":t.minDisabled},attrs:{role:"button"},on:{keydown:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.decrease.apply(null,arguments)}}},[i("i",{class:"el-icon-"+(t.controlsAtRight?"arrow-down":"minus")})]):t._e(),t.controls?i("span",{directives:[{name:"repeat-click",rawName:"v-repeat-click",value:t.increase,expression:"increase"}],staticClass:"el-input-number__increase",class:{"is-disabled":t.maxDisabled},attrs:{role:"button"},on:{keydown:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.increase.apply(null,arguments)}}},[i("i",{class:"el-icon-"+(t.controlsAtRight?"arrow-up":"plus")})]):t._e(),i("el-input",{ref:"input",attrs:{value:t.displayValue,placeholder:t.placeholder,disabled:t.inputNumberDisabled,size:t.inputNumberSize,max:t.max,min:t.min,name:t.name,label:t.label},on:{blur:t.handleBlur,focus:t.handleFocus,input:t.handleInput,change:t.handleInputChange},nativeOn:{keydown:[function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"up",38,e.key,["Up","ArrowUp"])?null:(e.preventDefault(),t.increase.apply(null,arguments))},function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"down",40,e.key,["Down","ArrowDown"])?null:(e.preventDefault(),t.decrease.apply(null,arguments))}]}},[t._t("suffix",null,{slot:"suffix"})],2)],1)},o=[],n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{class:["textarea"===t.type?"el-textarea":"el-input",t.inputSize?"el-input--"+t.inputSize:"",{"is-disabled":t.inputDisabled,"is-exceed":t.inputExceed,"el-input-group":t.$slots.prepend||t.$slots.append,"el-input-group--append":t.$slots.append,"el-input-group--prepend":t.$slots.prepend,"el-input--prefix":t.$slots.prefix||t.prefixIcon,"el-input--suffix":t.$slots.suffix||t.suffixIcon||t.clearable||t.showPassword}],on:{mouseenter:function(e){t.hovering=!0},mouseleave:function(e){t.hovering=!1}}},["textarea"!==t.type?[t.$slots.prepend?i("div",{staticClass:"el-input-group__prepend"},[t._t("prepend")],2):t._e(),"textarea"!==t.type?i("input",t._b({ref:"input",staticClass:"el-input__inner",attrs:{tabindex:t.tabindex,type:t.showPassword?t.passwordVisible?"text":"password":t.type,disabled:t.inputDisabled,readonly:t.readonly,autocomplete:t.autoComplete||t.autocomplete,"aria-label":t.label},on:{compositionstart:t.handleCompositionStart,compositionupdate:t.handleCompositionUpdate,compositionend:t.handleCompositionEnd,input:t.handleInput,focus:t.handleFocus,blur:t.handleBlur,change:t.handleChange}},"input",t.$attrs,!1)):t._e(),t.$slots.prefix||t.prefixIcon?i("span",{staticClass:"el-input__prefix"},[t._t("prefix"),t.prefixIcon?i("i",{staticClass:"el-input__icon",class:t.prefixIcon}):t._e()],2):t._e(),t.getSuffixVisible()?i("span",{staticClass:"el-input__suffix"},[i("span",{staticClass:"el-input__suffix-inner"},[t.showClear&&t.showPwdVisible&&t.isWordLimitVisible?t._e():[t._t("suffix"),t.suffixIcon?i("i",{staticClass:"el-input__icon",class:t.suffixIcon}):t._e()],t.showClear?i("i",{staticClass:"el-input__icon el-icon-circle-close el-input__clear",on:{mousedown:function(t){t.preventDefault()},click:t.clear}}):t._e(),t.showPwdVisible?i("i",{staticClass:"el-input__icon el-icon-view el-input__clear",on:{click:t.handlePasswordVisible}}):t._e(),t.isWordLimitVisible?i("span",{staticClass:"el-input__count"},[i("span",{staticClass:"el-input__count-inner"},[t._v(" "+t._s(t.textLength)+"/"+t._s(t.upperLimit)+" ")])]):t._e()],2),t.validateState?i("i",{staticClass:"el-input__icon",class:["el-input__validateIcon",t.validateIcon]}):t._e()]):t._e(),t.$slots.append?i("div",{staticClass:"el-input-group__append"},[t._t("append")],2):t._e()]:i("textarea",t._b({ref:"textarea",staticClass:"el-textarea__inner",style:t.textareaStyle,attrs:{tabindex:t.tabindex,disabled:t.inputDisabled,readonly:t.readonly,autocomplete:t.autoComplete||t.autocomplete,"aria-label":t.label},on:{compositionstart:t.handleCompositionStart,compositionupdate:t.handleCompositionUpdate,compositionend:t.handleCompositionEnd,input:t.handleInput,focus:t.handleFocus,blur:t.handleBlur,change:t.handleChange}},"textarea",t.$attrs,!1)),t.isWordLimitVisible&&"textarea"===t.type?i("span",{staticClass:"el-input__count"},[t._v(t._s(t.textLength)+"/"+t._s(t.upperLimit))]):t._e()],2)},r=[];function a(t,e,i){this.$children.forEach(s=>{var o=s.$options.componentName;o===t?s.$emit.apply(s,[e].concat(i)):a.apply(s,[t,e].concat([i]))})}var l={methods:{dispatch(t,e,i){var s=this.$parent||this.$root,o=s.$options.componentName;while(s&&(!o||o!==t))s=s.$parent,s&&(o=s.$options.componentName);s&&s.$emit.apply(s,[e].concat(i))},broadcast(t,e,i){a.call(this,t,e,i)}}},c=(i("6bd7"),{mounted(){},methods:{getMigratingConfig(){return{props:{},events:{}}}}});let u;const d="\n height:0 !important;\n visibility:hidden !important;\n overflow:hidden !important;\n position:absolute !important;\n z-index:-1000 !important;\n top:0 !important;\n right:0 !important\n",p=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing"];function h(t){const e=window.getComputedStyle(t),i=e.getPropertyValue("box-sizing"),s=parseFloat(e.getPropertyValue("padding-bottom"))+parseFloat(e.getPropertyValue("padding-top")),o=parseFloat(e.getPropertyValue("border-bottom-width"))+parseFloat(e.getPropertyValue("border-top-width")),n=p.map(t=>`${t}:${e.getPropertyValue(t)}`).join(";");return{contextStyle:n,paddingSize:s,borderSize:o,boxSizing:i}}function f(t,e=1,i=null){u||(u=document.createElement("textarea"),document.body.appendChild(u));let{paddingSize:s,borderSize:o,boxSizing:n,contextStyle:r}=h(t);u.setAttribute("style",`${r};${d}`),u.value=t.value||t.placeholder||"";let a=u.scrollHeight;const l={};"border-box"===n?a+=o:"content-box"===n&&(a-=s),u.value="";let c=u.scrollHeight-s;if(null!==e){let t=c*e;"border-box"===n&&(t=t+s+o),a=Math.max(t,a),l.minHeight=t+"px"}if(null!==i){let t=c*i;"border-box"===n&&(t=t+s+o),a=Math.min(t,a)}return l.height=a+"px",u.parentNode&&u.parentNode.removeChild(u),u=null,l}var m=i("eab7");function g(t){const e=/([(\uAC00-\uD7AF)|(\u3130-\u318F)])+/gi;return e.test(t)}var b={name:"ElInput",componentName:"ElInput",mixins:[l,c],inheritAttrs:!1,inject:{elForm:{default:""},elFormItem:{default:""}},data(){return{textareaCalcStyle:{},hovering:!1,focused:!1,isComposing:!1,passwordVisible:!1}},props:{value:[String,Number],size:String,resize:String,form:String,disabled:Boolean,readonly:Boolean,type:{type:String,default:"text"},autosize:{type:[Boolean,Object],default:!1},autocomplete:{type:String,default:"off"},autoComplete:{type:String,validator(t){return!0}},validateEvent:{type:Boolean,default:!0},suffixIcon:String,prefixIcon:String,label:String,clearable:{type:Boolean,default:!1},showPassword:{type:Boolean,default:!1},showWordLimit:{type:Boolean,default:!1},tabindex:String},computed:{_elFormItemSize(){return(this.elFormItem||{}).elFormItemSize},validateState(){return this.elFormItem?this.elFormItem.validateState:""},needStatusIcon(){return!!this.elForm&&this.elForm.statusIcon},validateIcon(){return{validating:"el-icon-loading",success:"el-icon-circle-check",error:"el-icon-circle-close"}[this.validateState]},textareaStyle(){return Object(m["a"])({},this.textareaCalcStyle,{resize:this.resize})},inputSize(){return this.size||this._elFormItemSize||(this.$ELEMENT||{}).size},inputDisabled(){return this.disabled||(this.elForm||{}).disabled},nativeInputValue(){return null===this.value||void 0===this.value?"":String(this.value)},showClear(){return this.clearable&&!this.inputDisabled&&!this.readonly&&this.nativeInputValue&&(this.focused||this.hovering)},showPwdVisible(){return this.showPassword&&!this.inputDisabled&&!this.readonly&&(!!this.nativeInputValue||this.focused)},isWordLimitVisible(){return this.showWordLimit&&this.$attrs.maxlength&&("text"===this.type||"textarea"===this.type)&&!this.inputDisabled&&!this.readonly&&!this.showPassword},upperLimit(){return this.$attrs.maxlength},textLength(){return"number"===typeof this.value?String(this.value).length:(this.value||"").length},inputExceed(){return this.isWordLimitVisible&&this.textLength>this.upperLimit}},watch:{value(t){this.$nextTick(this.resizeTextarea),this.validateEvent&&this.dispatch("ElFormItem","el.form.change",[t])},nativeInputValue(){this.setNativeInputValue()},type(){this.$nextTick(()=>{this.setNativeInputValue(),this.resizeTextarea(),this.updateIconOffset()})}},methods:{focus(){this.getInput().focus()},blur(){this.getInput().blur()},getMigratingConfig(){return{props:{icon:"icon is removed, use suffix-icon / prefix-icon instead.","on-icon-click":"on-icon-click is removed."},events:{click:"click is removed."}}},handleBlur(t){this.focused=!1,this.$emit("blur",t),this.validateEvent&&this.dispatch("ElFormItem","el.form.blur",[this.value])},select(){this.getInput().select()},resizeTextarea(){if(this.$isServer)return;const{autosize:t,type:e}=this;if("textarea"!==e)return;if(!t)return void(this.textareaCalcStyle={minHeight:f(this.$refs.textarea).minHeight});const i=t.minRows,s=t.maxRows;this.textareaCalcStyle=f(this.$refs.textarea,i,s)},setNativeInputValue(){const t=this.getInput();t&&t.value!==this.nativeInputValue&&(t.value=this.nativeInputValue)},handleFocus(t){this.focused=!0,this.$emit("focus",t)},handleCompositionStart(){this.isComposing=!0},handleCompositionUpdate(t){const e=t.target.value,i=e[e.length-1]||"";this.isComposing=!g(i)},handleCompositionEnd(t){this.isComposing&&(this.isComposing=!1,this.handleInput(t))},handleInput(t){this.isComposing||t.target.value!==this.nativeInputValue&&(this.$emit("input",t.target.value),this.$nextTick(this.setNativeInputValue))},handleChange(t){this.$emit("change",t.target.value)},calcIconOffset(t){let e=[].slice.call(this.$el.querySelectorAll(".el-input__"+t)||[]);if(!e.length)return;let i=null;for(let n=0;n{this.focus()})},getInput(){return this.$refs.input||this.$refs.textarea},getSuffixVisible(){return this.$slots.suffix||this.suffixIcon||this.showClear||this.showPassword||this.isWordLimitVisible||this.validateState&&this.needStatusIcon}},created(){this.$on("inputSelect",this.select)},mounted(){this.setNativeInputValue(),this.resizeTextarea(),this.updateIconOffset()},updated(){this.$nextTick(this.updateIconOffset)}},v=b,I=i("2877"),y=Object(I["a"])(v,n,r,!1,null,null,null),C=y.exports;C.install=function(t){t.component(C.name,C)};var k=C,w=function(t){return{methods:{focus(){this.$refs[t].focus()}}}},S=i("526f"),P={bind(t,e,i){let s,o=null;const n=()=>i.context[e.expression].apply(),r=()=>{Date.now()-s<100&&n(),clearInterval(o),o=null};Object(S["e"])(t,"mousedown",t=>{0===t.button&&(s=Date.now(),Object(S["f"])(document,"mouseup",r),clearInterval(o),o=setInterval(n,100))})}},D={name:"MInputNumber",directives:{repeatClick:P},components:{ElInput:k},mixins:[w("input")],inject:{elForm:{default:""},elFormItem:{default:""}},props:{step:{type:Number,default:1},stepStrictly:{type:Boolean,default:!1},max:{type:Number,default:1/0},min:{type:Number,default:-1/0},value:{},disabled:Boolean,size:String,controls:{type:Boolean,default:!0},controlsPosition:{type:String,default:""},name:String,label:String,placeholder:String,precision:{type:Number,validator(t){return t>=0&&t===parseInt(t,10)}}},data(){return{currentValue:0,userInput:null}},computed:{minDisabled(){return this._decrease(this.value,this.step)this.max},numPrecision(){const{value:t,step:e,getPrecision:i,precision:s}=this,o=i(e);return void 0!==s?(o>s&&console.warn("[Element Warn][InputNumber]precision should not be less than the decimal places of step"),s):Math.max(i(t),o)},controlsAtRight(){return this.controls&&"right"===this.controlsPosition},_elFormItemSize(){return(this.elFormItem||{}).elFormItemSize},inputNumberSize(){return this.size||this._elFormItemSize||(this.$ELEMENT||{}).size},inputNumberDisabled(){return this.disabled||!!(this.elForm||{}).disabled},displayValue(){if(null!==this.userInput)return this.userInput;let t=this.currentValue;if("number"===typeof t){if(this.stepStrictly){const e=this.getPrecision(this.step),i=Math.pow(10,e);t=Math.round(t/this.step)*i*this.step/i}void 0!==this.precision&&(t=t.toFixed(this.precision))}return t}},watch:{value:{immediate:!0,handler(t){let e=void 0===t?t:Number(t);if(void 0!==e){if(isNaN(e))return;if(this.stepStrictly){const t=this.getPrecision(this.step),i=Math.pow(10,t);e=Math.round(e/this.step)*i*this.step/i}void 0!==this.precision&&(e=this.toPrecision(e,this.precision))}e>=this.max&&(e=this.max),e<=this.min&&(e=this.min),this.currentValue=e,this.userInput=null,this.$emit("input",e)}}},mounted(){const t=this.$refs.input.$refs.input;t.setAttribute("role","spinbutton"),t.setAttribute("aria-valuemax",this.max),t.setAttribute("aria-valuemin",this.min),t.setAttribute("aria-valuenow",this.currentValue),t.setAttribute("aria-disabled",this.inputNumberDisabled)},updated(){if(!this.$refs||!this.$refs.input)return;const t=this.$refs.input.$refs.input;t.setAttribute("aria-valuenow",this.currentValue)},methods:{toPrecision(t,e){return void 0===e&&(e=this.numPrecision),parseFloat(Math.round(t*Math.pow(10,e))/Math.pow(10,e))},getPrecision(t){if(void 0===t)return 0;const e=t.toString(),i=e.indexOf(".");let s=0;return-1!==i&&(s=e.length-i-1),s},_increase(t,e){if("number"!==typeof t&&void 0!==t)return this.currentValue;const i=Math.pow(10,this.numPrecision);return this.toPrecision((i*t+i*e)/i)},_decrease(t,e){if("number"!==typeof t&&void 0!==t)return this.currentValue;const i=Math.pow(10,this.numPrecision);return this.toPrecision((i*t-i*e)/i)},increase(){if(this.inputNumberDisabled||this.maxDisabled)return;const t=this.value||0,e=this._increase(t,this.step);this.setCurrentValue(e)},decrease(){if(this.inputNumberDisabled||this.minDisabled)return;const t=this.value||0,e=this._decrease(t,this.step);this.setCurrentValue(e)},handleBlur(t){this.$emit("blur",t)},handleFocus(t){this.$emit("focus",t)},setCurrentValue(t){const e=this.currentValue;"number"===typeof t&&void 0!==this.precision&&(t=this.toPrecision(t,this.precision)),t>=this.max&&(t=this.max),t<=this.min&&(t=this.min),e!==t&&(this.userInput=null,this.$emit("input",t),this.$emit("change",t,e),this.currentValue=t)},handleInput(t){this.userInput=t},handleInputChange(t){const e=""===t?void 0:Number(t);isNaN(e)&&""!==t||this.setCurrentValue(e),this.userInput=null},select(){this.$refs.input.select()}}},L=D,x=Object(I["a"])(L,s,o,!1,null,null,null);e["a"]=x.exports},b5a3:function(t,e,i){"use strict";i("0782")},bd08:function(t,e,i){},cd9e:function(t,e,i){"use strict";var s=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"description-box"},[i("div",{staticClass:"description-title"},[t._v("Product Description")]),i("el-form-item",{staticStyle:{"margin-top":"24px"},attrs:{label:"product title",prop:"title"}},[i("el-input",{model:{value:t.customProductInfo.title,callback:function(e){t.$set(t.customProductInfo,"title",e)},expression:"customProductInfo.title"}})],1),i("el-form-item",{attrs:{label:"description",prop:"description"}},[t.currentShop.shopType===t.enums.shopTypeEnum.ETSY.value?i("el-input",{attrs:{autosize:{minRows:2,maxRows:8},type:"textarea"},model:{value:t.customProductInfo.description,callback:function(e){t.$set(t.customProductInfo,"description",e)},expression:"customProductInfo.description"}}):i("Wangeditor",{model:{value:t.customProductInfo.description,callback:function(e){t.$set(t.customProductInfo,"description",e)},expression:"customProductInfo.description"}})],1),i("div",{staticClass:"description-title"},[t._v("Tags")]),i("el-input",{staticClass:"tag-input",attrs:{placeholder:"Add tag"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.addTag.apply(null,arguments)}},model:{value:t.tempDescriptionForm.tag,callback:function(e){t.$set(t.tempDescriptionForm,"tag",e)},expression:"tempDescriptionForm.tag"}}),i("div",{staticClass:"tag-box"},t._l(t.customProductInfo.tags,(function(e,s){return i("div",{key:s,staticClass:"tag-item"},[i("div",[t._v(t._s(e))]),i("i",{staticClass:"el-icon-close del-tag div-hover",on:{click:function(e){return t.delTag(s)}}})])})),0),t.showStoreInfo?i("div",{staticClass:"store-info"},[i("div",{staticClass:"store-title"},[t._v("Shopify Categories")]),i("div",{staticClass:"store-sub-title"},[t._v("Select One Or Multiple Categories To Publish Your Product")]),i("el-select",{staticClass:"customCollection-list",attrs:{value:t.collectionId,placeholder:"",clearable:""},on:{change:t.onCollectionIdChange}},t._l(t.customCollectionList,(function(t){return i("el-option",{key:t.id,attrs:{label:t.title,value:t.id}})})),1)],1):t._e()],1)},o=[],n=i("448e"),r=i("e661"),a=i("2f62"),l=i("2f69"),c={name:"Description",components:{Wangeditor:n["a"]},props:{customProductInfo:{type:Object,default:()=>({})},collectionId:{type:String,default:""},showStoreInfo:{type:Boolean,default:!0}},data(){return{customCollectionList:[],tempDescriptionForm:{tag:""},enums:{shopTypeEnum:r["a"]}}},computed:{...Object(a["b"])("user",{currentShop:"getCurrentShop"})},watch:{customProductInfo:{handler(t){this.$emit("change",t)},deep:!0}},mounted(){this.getCustomCollectionList()},methods:{async getCustomCollectionList(){if(!this.showStoreInfo)return;const t=await Object(l["b"])();this.customCollectionList=t.data.items},onCollectionIdChange(t){this.$emit("update:collectionId",t)},addTag(){const t=this.tempDescriptionForm.tag;this.customProductInfo.tags.push(t),this.tempDescriptionForm.tag=""},delTag(t){this.customProductInfo.tags.splice(t,1)}}},u=c,d=(i("4bdd"),i("2877")),p=Object(d["a"])(u,s,o,!1,null,"4d7d6b60",null);e["a"]=p.exports},d4afd:function(t,e,i){},e8fe:function(t,e,i){},eab7:function(t,e,i){"use strict";e["a"]=function(t){for(let e=1,i=arguments.length;e0?i=l:e=l}while(Math.abs(a)>o&&++c=s?m(e,d,t,i):0===p?d:f(e,o,o+a,t,i)}return function(t){return 0===t?0:1===t?1:p(u(t),e,o)}},v={ease:[.25,.1,.25,1],linear:[0,0,1,1],"ease-in":[.42,0,1,1],"ease-out":[0,0,.58,1],"ease-in-out":[.42,0,.58,1]},I=!1;try{var y=Object.defineProperty({},"passive",{get:function(){I=!0}});window.addEventListener("test",null,y)}catch(N){}var C={$:function(t){return"string"!==typeof t?t:document.querySelector(t)},on:function(t,e,i){var s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{passive:!1};e instanceof Array||(e=[e]);for(var o=0;o2&&void 0!==arguments[2]?arguments[2]:{};if("object"===t(D)?L=D:"number"===typeof D&&(L.duration=D),e=C.$(m),!e)return console.warn("[vue-scrollto warn]: Trying to scroll to an element that is not on the page: "+m);if(i=C.$(L.container||w.container),s=L.hasOwnProperty("duration")?L.duration:w.duration,n=L.hasOwnProperty("lazy")?L.lazy:w.lazy,o=L.easing||w.easing,r=L.hasOwnProperty("offset")?L.offset:w.offset,a=L.hasOwnProperty("force")?!1!==L.force:w.force,l=L.hasOwnProperty("cancelable")?!1!==L.cancelable:w.cancelable,c=L.onStart||w.onStart,u=L.onDone||w.onDone,d=L.onCancel||w.onCancel,p=void 0===L.x?w.x:L.x,h=void 0===L.y?w.y:L.y,"function"===typeof r&&(r=r(e,i)),f=N(i),g=O(i),E(),P=!1,!a){var _="body"===i.tagName.toLowerCase()?document.documentElement.clientHeight||window.innerHeight:i.offsetHeight,F=g,$=F+_,j=I-r,R=j+e.offsetHeight;if(j>=F&&R<=$)return void(u&&u(e))}if(c&&c(e),S||y)return"string"===typeof o&&(o=v[o]||v["ease"]),A=b.apply(b,o),C.on(i,k,T,{passive:!0}),window.requestAnimationFrame(B),function(){x=null,P=!0};u&&u(e)}return V},D=P(),L=[];function x(t){for(var e=0;e