1"use strict";(self.webpackChunkamzup_web_main=self.webpackChunkamzup_web_main||[]).push([["11065"],{39489:function(e,t,a){a.d(t,{A:function(){return l}}),a(25259),a(77949),a(18577),a(5092),a(937);var r,i,s=a(59335),n=a(74943),o={name:"TableColumnsResizeMixins",data:function(){return{storageName:"",storageSingleName:"",specialName:"",mixinsTableWidth:{}}},computed:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},(0,s.mapState)("System",{accountInfo:function(e){return e.user}})),mounted:function(){this.resizeNameInit(),this.resizableInit()},methods:{resizeNameSet:function(e){this.specialName=e||""},resizeNameInit:function(){var e=this.$route.name,t=this.accountInfo?this.accountInfo:{},a=t?t.id:"",r="",i="";e&&(r=this.specialName?"".concat(e,"_").concat(this.specialName):e),a&&(i="".concat(a,"_t_w_resize")),this.storageName=i,this.storageSingleName=r},resizableInit:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];e&&(this.mixinsTableWidth={});var t=JSON.parse(JSON.stringify(this.mixinsTableWidth));if(this.storageSingleName&&this.storageName){(0,n.ImM)(this.accountInfo.mobile,this.accountInfo.id,"".concat(this.accountInfo.mobile,"_t_w_resize"));var a=this.$utils.storageAction.objGet(this.storageName),r=a?a[this.storageSingleName]:null;a&&r&&Object.keys(r).forEach(function(e){e&&(t[e]="".concat(r[e],"px"))})}this.mixinsTableWidth=t},resizableChange:function(e){var t=e.column;if(this.storageSingleName&&this.storageName&&t.params&&t.params.columnName){var a=t.params.columnName,r=t.resizeWidth;(0,n.ImM)(this.accountInfo.mobile,this.accountInfo.id,"".concat(this.accountInfo.mobile,"_t_w_resize"));var i=this.$utils.storageAction.objGet(this.storageName);i||(i={}),i[this.storageSingleName]||(i[this.storageSingleName]={}),i[this.storageSingleName][a]=r,this.$utils.storageAction.objSet(this.storageName,i),this.mixinsTableWidth||this.resizableInit(),this.mixinsTableWidth[a]=r}}}},l=(0,a(28644).A)(o,r,i,!1,null,null,null).exports},30969:function(e,t,a){a.r(t),a.d(t,{default:function(){return l}}),a(75038),a(5092),a(20767),a(48075),a(77949),a(937);var r=a(82505),i=a(85399),s=a(5221),n=a(49973),o={name:"LogisticsBillNosPopover",components:{SinglePopover:r.A,ToolsLine:n.A},mixins:[i.A],props:{permission:{type:String,default:""},options:{type:Object,default:function(){return{popoverDetailWidth:300,maxLength:200,showWordLimit:!0,className:""}}},rowProp:{type:Object,default:function(){return{}}},isShowMulti:{type:Boolean,default:!1}},data:function(){return{track17List:[],trackQuery:1,divIndex:0}},methods:{removeTrack:function(){var e=document.getElementById("trackContainer");e&&e.remove()},doTrack:function(e,t){this.divIndex=t,this.trackContainerId=e},handleChange:function(e){var t=this.trackContainerId,a=this.track17List.find(function(e){return e.trackingNo===t})||{},r=a.logisticsCompanyName,i=(Number.isNaN(Number("".concat(a.logisticsCompanyCode)))?null:a.logisticsCompanyCode)||s.Tp[r];if(e&&t){var n="//www.17track.net/externalcall.js";this.removeTrack(),document.getElementsByTagName("script").forEach(function(e){e.src===n&&e.remove()});var o=document.createElement("script");o.type="text/javascript",o.src=n,document.getElementsByTagName("head")[0].appendChild(o);var l=document.getElementById(t+this.rowProp.id+this.divIndex),c=document.createElement("div");c.id="trackContainer",l.appendChild(c),o.onload=function(){window.YQV5.trackSingle({YQ_ContainerId:"trackContainer",YQ_Num:t,YQ_Fc:i,YQ_Lang:"",YQ_Height:560,YQ_RmAD:!0})}}},trackPopoverShow:function(){var e;this.divIndex=0,this.trackQuery=1,this.trackContainerId=null==(e=this.track17List[0])?void 0:e.trackingNo,this.handleChange(!0)},handleTrackTextClick:function(){var e=this;this.track17List=this.rowProp.logisticsBillNos||[],this.$nextTick(function(){e.$refs.trackQueryRef&&(e.$refs.trackQueryRef.showPopover({$el:e.$el}),e.$refs.trackQueryRef.customElement({$el:e.$el}),e.$refs.trackQueryRef.$nextTick(function(){var t;null==(t=e.$refs.trackQueryRef.$refs.singlePopover)||t.doShow()}))})},handleMultiTrackClick:function(e){var t=this;this.track17List=[e],this.$nextTick(function(){t.$refs.trackQueryRef&&(t.$refs.trackQueryRef.showPopover({$el:t.$el}),t.$refs.trackQueryRef.customElement({$el:t.$el}),t.$refs.trackQueryRef.$nextTick(function(){var e;null==(e=t.$refs.trackQueryRef.$refs.singlePopover)||e.doShow()}))})}}},l=(0,a(28644).A)(o,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"flex overflow_h"},[e.isShowMulti?[e.rowProp.logisticsBillNos&&e.rowProp.logisticsBillNos.length?[a("div",{staticClass:"pointer flex center_align overflow_h",on:{click:e.handleTrackTextClick}},[a("ToolsLine",{attrs:{f_blue:"",isCopy:"",label:e.rowProp.logisticsBillNos[0].trackingNo}})],1),e._v(" "),e.rowProp.logisticsBillNos.length>1?[a("el-popover",{attrs:{placement:"bottom",trigger:"hover","popper-class":"track_multi_popover",width:200}},[a("div",{staticClass:"ml_2 pointer",attrs:{slot:"reference"},slot:"reference"},[a("i",{staticClass:"icon_sf_down_line f_16 f_grey_icon"})]),e._v(" "),a("div",{staticClass:"track_multi_list"},e._l(e.rowProp.logisticsBillNos,function(t,r){return a("div",{key:r,staticClass:"track_multi_item",on:{click:function(a){return e.handleMultiTrackClick(t)}}},[a("ToolsLine",{attrs:{f_blue:"",isCopy:"",label:t.trackingNo}})],1)}),0)])]:e._e()]:a("span",[e._v("-")]),e._v(" "),a("SinglePopover",{ref:"trackQueryRef",attrs:{options:{trigger:"click",placement:"bottom",isScrollEvent:!1}},on:{show:e.trackPopoverShow}},[a("div",[a("el-collapse",{staticClass:"logistics_collapse",attrs:{accordion:""},on:{change:e.handleChange},model:{value:e.trackQuery,callback:function(t){e.trackQuery=t},expression:"trackQuery"}},e._l(e.track17List,function(t,r){return a("el-collapse-item",{key:r,staticClass:"logistics_items",attrs:{name:r+1}},[a("div",{staticClass:"logistics_title",attrs:{slot:"title"},slot:"title"},[a("div",{staticClass:"w_140 line_clamp logistics_jump",on:{click:function(a){return e.doTrack(t.trackingNo,r)}}},[a("div",{staticClass:"logistics_left"},[a("div",[e._v(e._s(e.$t("main.components.dialog.track.query.carrier.label",{name:t.logisticsCompanyName})))]),e._v(" "),a("div",[e._v(e._s(e.$t("main.components.dialog.track.query.tracking.label",{no:t.trackingNo})))])]),e._v(" "),a("el-button",{staticClass:"logistics_right",attrs:{type:"text"}},[e._v(e._s(e.$t("main.components.dialog.track.query.button")))])],1
1)]),e._v(" "),a("div",{staticClass:"logistics_content",attrs:{id:t.trackingNo+e.rowProp.id+r}})])}),1)],1)])]:[e.rowProp.logisticsBillNos&&e.rowProp.logisticsBillNos.length?a("div",{directives:[{name:"single-popover",rawName:"v-single-popover",value:{refName:"trackQueryRef",data:e.rowProp.logisticsBillNos,dataName:"track17List"},expression:"{refName: 'trackQueryRef', data: rowProp.logisticsBillNos, dataName: 'track17List'}"}],staticClass:"pointer flex center_align flex_1 overflow_h"},[a("ToolsLine",{attrs:{f_blue:"",isCopy:"",label:e.rowProp.logisticsBillNos[0].trackingNo}}),e._v(" "),a("i",{staticClass:"icon_sf_down_line f_16 f_grey_icon"})],1):a("span",[e._v("-")]),e._v(" "),a("SinglePopover",{ref:"trackQueryRef",attrs:{options:{trigger:"click",placement:"bottom",isScrollEvent:!1}},on:{show:e.trackPopoverShow}},[a("div",[a("el-collapse",{staticClass:"logistics_collapse",attrs:{accordion:""},on:{change:e.handleChange},model:{value:e.trackQuery,callback:function(t){e.trackQuery=t},expression:"trackQuery"}},e._l(e.track17List,function(t,r){return a("el-collapse-item",{key:r,staticClass:"logistics_items",attrs:{name:r+1}},[a("div",{staticClass:"logistics_title",attrs:{slot:"title"},slot:"title"},[a("div",{staticClass:"w_140 line_clamp logistics_jump",on:{click:function(a){return e.doTrack(t.trackingNo,r)}}},[a("div",{staticClass:"logistics_left"},[a("div",[e._v(e._s(e.$t("main.components.dialog.track.query.carrier.label",{name:t.logisticsCompanyName})))]),e._v(" "),a("div",[e._v(e._s(e.$t("main.components.dialog.track.query.tracking.label",{no:t.trackingNo})))])]),e._v(" "),a("el-button",{staticClass:"logistics_right",attrs:{type:"text"}},[e._v(e._s(e.$t("main.components.dialog.track.query.button")))])],1)]),e._v(" "),a("div",{staticClass:"logistics_content",attrs:{id:t.trackingNo+e.rowProp.id+r}})])}),1)],1)])]],2)},[],!1,null,"6d5b73bf",null).exports},9107:function(e,t,a){a.d(t,{A:function(){return c}}),a(47424),a(59622);var r=a(49680),i=a(52854),s=a(42271),n=a(53169);function o(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}var l={name:"ExclusiveTypeSelect",emits:["change"],props:{type:{type:String,default:""},data:{type:Object,default:function(){return{}}},customFields:{type:Object,default:function(){return{platform:"platform",shopId:"shopId",fnSku:"fnSku"}}},isDetail:{type:Boolean,default:!1},platform:String},components:{SfSelect:i.A},computed:{isShareOrShopExclusive:function(){var e=this.exclusiveType,t=this.actualPlatform,a=this.actualShopId,i=(t===n.Er||!t)&&!a,o=[s.GQ.share,s.GQ.shop];return i||(0,r.isNil)(e)||o.includes(e)},exclusiveTypeText:function(){var e;return(o(e={},s.GQ.share,this.$t("main.components.exclusive.type.select.shared")),o(e,s.GQ.shop,this.$t("main.components.exclusive.type.select.shop.exclusive")),o(e,s.GQ.shopFnsku,this.$t("main.components.exclusive.type.select.shop.fnsku.exclusive")),o(e,s.GQ.fnsku,this.$t("main.components.exclusive.type.select.fnsku.exclusive")),e)[this.exclusiveType]||"-"},actualPlatform:function(){var e=this.customFields.platform;return this.data[e||"platform"]},actualShopId:function(){var e=this.customFields.shopId;return this.data[e||"shopId"]},actualFnSku:function(){var e=this.customFields.fnSku;return this.data[e||"fnSku"]},computedExclusiveType:function(){var e=this.exclusiveType,t=this.actualPlatform,a=this.actualShopId,r=this.actualFnSku;return t&&t!==n.Er||a||r?t&&a&&!r?e=s.GQ.shop:t&&a&&r&&[s.GQ.share,s.GQ.shop].includes(e)&&(e=s.GQ.fnsku):e=s.GQ.share,e}},watch:{type:{handler:function(e){this.exclusiveType=e}},computedExclusiveType:{handler:function(e){this.exclusiveType=e,this.syncExclusiveType(e)}}},data:function(){return{exclusiveTypeOptions:s.ZK,exclusiveType:s.GQ.fnsku,changeType:s.y3}},methods:{syncExclusiveType:function(e){e===s.GQ.fnsku?this.$emit("update:platform",n.Er):e===s.GQ.shopFnsku&&this.$emit("update:platform",n.RE),this.$emit("update:type",e)},handleManualExclusiveTypeChange:function(e){this.syncExclusiveType(e),this.$emit("change",e,this.changeType.manual)},initExclusiveType:function(){var e,t=this.actualPlatform,a=this.actualShopId,i=this.actualFnSku,o=!!((!t||t===n.Er)&&!a&&!i);(0,r.isNil)(this.data.exclusiveType)?o?e=s.GQ.share:t&&a&&!i?e=s.GQ.shop:t&&a&&i&&(e=s.GQ.fnsku):e=this.data.exclusiveType,this.exclusiveType=e,this.syncExclusiveType(this.exclusiveType)}},created:function(){var e=this;this.$nextTick(function(){e.initExclusiveType()})}},c=(0,a(28644).A)(l,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"exclusive_type_select-warpper"},[e.isDetail||e.isShareOrShopExclusive?a("span",[e._v(e._s(e.exclusiveTypeText))]):a("sf-select",{attrs:{width:"160",placeholder:e.$t("main.components.exclusive.type.select.placeholder"),options:e.exclusiveTypeOptions},on:{"on-change":e.handleManualExclusiveTypeChange},model:{value:e.exclusiveType,callback:function(t){e.exclusiveType=t},expression:"exclusiveType"}})],1)},[],!1,null,null,null).exports},84472:function(e,t,a){a.d(t,{A:function(){return r}});var r=(0,a(28644).A)({name:"mskuList",props:{list:{type:String,default:""}}},function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("span",[this._v(this._s(this.list||"-"))])])},[],!1,null,null,null).exports},4535:function(e,t,a){a.d(t,{A:function(){return r}}),a(20767);var r=(0,a(28644).A)({name:"RadioGroup",props:{value:{type:[String,Number,Boolean],default:""},options:{type:Object,default:function(){return{options:[],permission:[]}}}},computed:{isNotEmpty:function(){return this.$utils.isNotEmpty}},methods:{handleClick:function(e){this.$emit("input",e),this.$emit("change",e)}}},function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-radio-group",{staticClass:"el_radio_group_box",attrs:{value:e.value},on:{input:e.handleClick}},e._l(e.options.options,function(t){var r=t.name,i=t.value,s=t.num;return a("el-radio-button",{key:r,attrs:{label:i}},[a("span",[e._v(e._s(r))]),e._v(" "),e.isNotEmpty(s)?a("span",[e._v("("+e._s(s)+")")]):e._e(
1)])}),1)},[],!1,null,"44052ba1",null).exports},71196:function(e,t,a){a.r(t),a.d(t,{default:function(){return tS}}),a(5092),a(10327),a(77949),a(25259);var r,i,s,n,o,l,c,u=a(19294),h=a(59335),p=a(23573),f=a(41534);a(88208),a(937);var m=a(9527),v=a(30969),d=a(49973);a(21927),a(37040),a(48741),a(72860);var b=a(52559),g=a(30799),y=a(94768);function _(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r}var w=new Map([["purchaseNo",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.purchase.no"),field:"purchaseNo",width:140,fixed:"left",params:{columnName:"purchaseNo",fixedVisible:!0,defaultFixed:!0},slots:{default:"purchaseNo_default"}}],["createTime",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.create.time"),field:"createTime",minWidth:150,resizable:!0,params:{columnName:"createTime"},formatter:function(e){var t=e.cellValue;return y.Ay.formatEmptyValue(t)},showOverflow:"tooltip"}],["supplier",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.supplier"),field:"supplier",minWidth:100,params:{columnName:"supplier"},slots:{default:"supplier_default"}}],["warehouseName",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.warehouse"),field:"warehouseName",minWidth:120,params:{columnName:"warehouseName"},slots:{default:"warehouse_default"}}],["purchaserName",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.purchaser"),field:"purchaserName",minWidth:100,params:{columnName:"purchaserName"},formatter:function(e){var t=e.cellValue;return y.Ay.formatEmptyValue(t)},showOverflow:"tooltip"}],["mainImage",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.purchase.product"),field:"mainImage",width:200,resizable:!0,params:{order:9,columnName:"mainImage"},slots:{default:"mainImage_default"}}],["totalNum",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.purchase.quantity"),field:"totalNum",resizable:!0,minWidth:100,align:"right",showFooterOverflow:!0,params:{order:14,columnName:"totalNum"},formatter:function(e){var t=e.cellValue;return y.Ay.formatEmptyValue(t,0)},slots:{footer:"totalNum_footer",default:"totalNum_default"}}],["waitNum",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.wait.arrival.quantity"),field:"waitNum",resizable:!0,minWidth:100,align:"right",params:{order:16,columnName:"waitNum"},formatter:function(e){var t=e.cellValue;return y.Ay.formatEmptyValue(t,0)},showOverflow:"tooltip"}],["logistics",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.tracking.no"),field:"logistics",minWidth:160,params:{order:3,columnName:"logistics"},slots:{default:"logistics_default",footer:"logistics_footer"}}],["tradeId",{title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.order.no.1688"),field:"tradeId",minWidth:190,params:{order:2,columnName:"tradeId"},slots:{default:"tradeId_default"}}],["operation",{width:(0,b.n)("100"),field:"operation",title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.operation"),fixed:"right",resizable:!1,params:{order:35,columnName:"operation",fixedVisible:!0},slots:{default:"operation_default"}}]]),S=a(61933),k=a(97668);function N(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}var C={name:"TableList",components:{ProductListField:S.A,PopoverContainer:m.A,TrackQuery:v.default,ToolsLine:d.A},mixins:[{name:"receiptOrderColumnsMixins",data:function(){return{vxeGridTableColumnList:[],isSpecialColumn:!0,totalArrivalNumCol:{field:"totalArrivalNumCol",align:"right",params:{},slots:{default:"totalArrivalNumCol_default"}},abnormalNumCol:{field:"abnormalNumCol",align:"right",params:{},slots:{default:"abnormalNumCol_default"}}}},created:function(){this.initColumnsList()},methods:{initColumnsList:function(){var e,t=this.$dcopy(w);this.vxeGridTableColumnList=function(e){if(Array.isArray(e))return _(e)}(e=t.values())||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return _(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return _(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}}}],props:{purchaseOrderBtn:Function},computed:{isEmptyValue:function(){return this.$utils.isEmptyValue}},data:function(){return{waresDetailGroup:0,orderLogisticsInfo:[],tableData:[]}},methods:{showWaresDetail:function(e){(0,k.h)({commodityId:null==e?void 0:e.commodityId,row:e,context:this})},getOrderLogisticsInfo:function(e){var t;return(t=function(){var t,a,r,i,s;return function(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}(this,function(n){switch(n.label){case 0:t=this,a=e.orderId,n.label=1;case 1:if(n.trys.push([1,4,5,6]),this.tableData.forEach(function(e){0===e.isContent&&(t.$set(e,"orderLogisticsInfoVisible",!1),t.$set(e,"requestLoading",!1))}),!(e.logisticsBillNos&&e.logisticsBillNos.length))return[3,3];return this.$set(e,"requestLoading",!0),this.$set(e,"orderLogisticsInfoVisible",!0),[4,this.$http.getAliOrderLogisticsStepApi({id:a})];case 2:r=n.sent(),e.requestLoading&&(i=[],r.forEach(function(e){var t,a;i.push((t=function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},e),a=a={more:e.logisticsStepList.length>1,showLogisticsStepList:e.logisticsStepList.length>1?[e.logisticsStepList[0],{}]:e.logisticsStepList},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t}
1)(Object(a)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(a,e))}),t))}),this.orderLogisticsInfo=i,this.$set(e,"requestLoading",!1)),n.label=3;case 3:return[3,6];case 4:return s=n.sent(),this.$message.handle(s),[3,6];case 5:return[7];case 6:return[2]}})},function(){var e=this,a=arguments;return new Promise(function(r,i){var s=t.apply(e,a);function n(e){N(s,r,i,n,o,"next",e)}function o(e){N(s,r,i,n,o,"throw",e)}n(void 0)})}).call(this)},showOrHiddenRowLogisticsInfo:function(e){e.more?e.showLogisticsStepList=this.$dcopy(e.logisticsStepList):e.showLogisticsStepList=[this.$dcopy(e.logisticsStepList[0]),{}],e.more=!e.more},doRefresh:function(){this.$emit("doRefresh")},tableHandle:function(e,t){this.$emit("tableHandle",e,t)},toAliSitePage:function(e){window.open(e,"_blank")},tableDataInit:function(e){var t,a=this;return null==(t=this.$refs.purchaseListTable)?void 0:t.loadData(e).then(function(){a.tableData=e})}},created:function(){this.tableData=[]}},$=a(28644),O=(0,$.A)(C,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"page_list"},[a("vxe-grid",{ref:"purchaseListTable",staticClass:"purchase_list_table PageListMouseWheelClassNew vxe_table_row_height_48",attrs:{columns:e.vxeGridTableColumnList,height:"100%","highlight-current-row":"","highlight-hover-row":"",resizable:"","show-header-overflow":"","show-overflow":"ellipsis","tooltip-config":{theme:"light"}},scopedSlots:e._u([{key:"purchaseNo_default",fn:function(e){return[a("ToolsLine",{attrs:{isCopy:"",label:e.row.purchaseNo}})]}},{key:"tradeId_default",fn:function(t){var r=t.row;return[r.alibabaOrderSource?a("span",[a("a",{attrs:{href:r.alibabaOrderSource,target:"_blank"}},[e._v(e._s(r.tradeId))]),e._v(" "),a("i",{staticClass:"icon_wang",class:{wang_show:r.tradeId},on:{click:function(t){return e.toAliSitePage(r.sellerIminPlatform)}}})]):a("span",[e._v("-")])]}},{key:"logistics_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex line_clamp center_align"},[r.isOrder?[r.logisticsBillNos&&r.logisticsBillNos.length?a("popover-container",{attrs:{data:r.logisticsBillNos,"show-empty":!1,placement:"bottom",trigger:"manual"},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("div",{staticClass:"flex center_align",on:{click:function(t){return t.preventDefault(),t.stopPropagation(),e.getOrderLogisticsInfo(r)}}},[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.logisticsBillNos[0].trackingNo,expression:"row.logisticsBillNos[0].trackingNo",arg:"light",modifiers:{isShow:!0}
1}],staticClass:"t_l line_clamp_max_w mr_2 pointer flex_1 overflow_h"},[a("ToolsLine",{attrs:{isCopy:"",label:r.logisticsBillNos[0].trackingNo}})],1),e._v(" "),a("i",{staticClass:"icon_sf_down_line f_16"})])]},proxy:!0}],null,!0),model:{value:r.orderLogisticsInfoVisible,callback:function(t){e.$set(r,"orderLogisticsInfoVisible",t)},expression:"row.orderLogisticsInfoVisible"}},[e._v(" "),a("div",{staticClass:"logistics_info_box"},[r.requestLoading?a("div",{directives:[{name:"loading",rawName:"v-loading",value:r.requestLoading,expression:"row.requestLoading"}],staticClass:"flex_1 flex center_align center_just",attrs:{"element-loading-spinner":"icon_load_mid"}},[a("span",[e._v(e._s(e.$t("main.common.loading.data")))])]):r.logisticsBillNos&&r.logisticsBillNos.length?a("div",{staticClass:"flex_1"},[a("div",{staticClass:"imitate_table ali_order_popover_table"},[a("div",{staticClass:"header"},[a("div",{staticClass:"w150"},[e._v(e._s(e.$t("main.components.track.dialog.tracking.no")))]),e._v(" "),a("div",{staticClass:"w150"},[e._v(e._s(e.$t("main.components.print.label.logistics.provider")))]),e._v(" "),a("div",{staticClass:"w300 pl_16"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.logistics.tracking")))])]),e._v(" "),a("div",{staticClass:"body_box"},e._l(e.orderLogisticsInfo,function(t,r){return a("div",{key:r,staticClass:"body"},[a("div",{staticClass:"w150"},[e._v(e._s(t.logisticsBillNo))]),e._v(" "),a("div",{staticClass:"w150"},[e._v(e._s(t.logisticsCompanyName))]),e._v(" "),a("div",{staticClass:"w300"},[a("div",{staticClass:"step_item",class:{more:t.more}},[a("el-steps",{staticClass:"delivery_step",attrs:{direction:"vertical"}},e._l(t.showLogisticsStepList,function(t,r){return a("el-step",{key:r},[a("div",{staticClass:"d_b",attrs:{slot:"title"},slot:"title"},[e._v("\n "+e._s(t.remark)+"\n ")]),e._v(" "),a("div",{attrs:{slot:"description"},slot:"description"},[e._v("\n "+e._s(t.acceptTime)+"\n ")]),e._v(" "),a("i",{staticClass:"icon_circle",attrs:{slot:"icon"},slot:"icon"})])}),1)],1),e._v(" "),t.showLogisticsStepList&&t.showLogisticsStepList.length>1?a("div",{staticClass:"show_hidden_btn"},[a("el-button",{staticClass:"ml_24 text_btn_show_hidden",attrs:{round:"",size:"mini",type:"text"},on:{click:function(a){return e.showOrHiddenRowLogisticsInfo(t)}}},[a("span",{staticClass:"btn_text"},[e._v(e._s(t.more?e.$t("main.common.more"):e.$t("main.common.collapse")))])])],1):e._e()])])}),0)])]):a("div",{staticClass:"flex_1 flex center_align center_just"},[a("span",[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.order.logistics.empty")))])])])]):e._e()]:[a("TrackQuery",{attrs:{rowProp:r}})]],2)]}},{key:"supplier_default",fn:function(t){var r=t.row,i=t.rowIndex;return[a("popover-container",{attrs:{data:r.supplierName,"show-empty":!1,trigger:"hover"},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("span",{staticClass:"line_clamp_max_w"},[a("span",{directives:[{name:"field-right",rawName:"v-field-right",value:{permission:"supplier"},expression:"{ permission: 'supplier' }"}],key:i},[e._v(e._s(e.isEmptyValue(r.supplierName)))])])]},proxy:!0}],null,!0)})]}},{key:"warehouse_default",fn:function(t){var r=t.row;return[a("popover-container",{attrs:{data:r.warehouseName,"show-empty":!1,trigger:"hover"},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("span",{staticClass:"line_clamp_max_w"},[e._v(e._s(e.isEmptyValue(r.warehouseName)))])]},proxy:!0}],null,!0)})]}},{key:"mainImage_default",fn:function(t){var r=t.row;return[a("ProductListField",{attrs:{products:r.items,"total-size":r.itemCount,row:r,isScanned:!0},on:{clickSku:function(t){return e.showWaresDetail(t)}}})]}},{key:"totalNum_default",fn:function(t){var r=t.row;return[a("div",[e._v(e._s(r.totalNum))])]}},{key:"operation_default",fn:function(t){var r=t.row;return[a("el-button",{attrs:{size:"mini",type:"text"},on:{click:function(t){return e.purchaseOrderBtn("check",r)}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.select")))])]}}])})],1)},[],!1,null,"df1c6016",null).exports;a(18577),a(86754),a(31731),a(86201);var x=a(69868),P=a(38855),T=a(50606),A=a(52854),D=a(10937),L=a(77069);function I(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}var j={name:"FilterBar",components:{LazyScrollSelect:x.A,SearchBar:D.A,BaseDatePickerGroup:P.A,WarehouseSelectorNew:T.A,SfSelect:A.A},computed:(i=I({},(0,h.mapState)("PublicApiControl",{allSupplierData:function(e){return e.allSupplierData},allCreatorData:function(e){return e.allCreatorData}}),(0,h.mapState)("Socket",{allowPurchaseToOverseasWarehouseStatus:function(e){return e.allowPurchaseToOverseasWarehouseStatus}})),s=s={warehouseTypes:function(){return this.allowPurchaseToOverseasWarehouseStatus?[1,3]:[1]},supplierOptions:function(){var e=this.allSupplierData,t=[{value:-1,label:this.$t("main.warehouse.scan.arrive.filter.no.supplier")}];return e&&Object.keys(e).forEach(function(a){t.push({value:+a,label:e[a]})}),{type:"multiple",filterable:!0,clearable:!0,placeholder:this.$t("common.supplier"),options:t}},purchaserOptions:function(){var e=this.allCreatorData||{},t=[];return Object.keys(e).forEach(function(a){t.push({value:+a,label:e[a]})}),{type:"multiple",clearable:!0,filterable:!0,options:t,placeholder:this.$t("main.warehouse.scan.arrive.purchase.purchaser")}}},Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(s)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t}
1)(Object(s)).forEach(function(e){Object.defineProperty(i,e,Object.getOwnPropertyDescriptor(s,e))}),i),watch:{},data:function(){var e={multiType:!0};return{pickerConfig:{dateType:"daterange",valueFormat:"yyyy-MM-dd",startPlaceholder:this.$t("common.start.time"),endPlaceholder:this.$t("common.end.time"),dateVal:[]},filter:{searchTimeType:"createTime",arrivalStatus:[],warehouseList:[],supplierIds:[],purchaserIds:[],status:[]},searchOptions:{width:300,searchFiledOptions:[I({label:(0,L._)("main.warehouse.scan.arrive.filter.purchase.no"),value:"purchaseNo"},e),{label:(0,L._)("main.warehouse.scan.arrive.filter.product.name"),value:"commodityName"},I({label:"SKU",value:"commoditySku"},e),I({label:"FNSKU",value:"fnsku"},e),{label:(0,L._)("main.warehouse.scan.arrive.filter.remark"),value:"remark"},{label:(0,L._)("main.warehouse.scan.arrive.filter.product.remark"),value:"itemRemark"},I({label:(0,L._)("main.warehouse.scan.arrive.filter.tracking.no"),value:"logisticsBillNo"},e),I({label:(0,L._)("main.warehouse.scan.arrive.filter.1688.order.no"),value:"tradeId"},e)],searchFiledWidth:110},searchTimeTypeOptions:Object.freeze({placeholder:this.$t("common.please.select"),options:[{label:"\u521B\u5EFA\u65F6\u95F4",value:"createTime"},{label:"\u9996\u6B21\u5230\u8D27\u65F6\u95F4",value:"firstArrivalTime"},{label:"\u5168\u90E8\u5230\u8D27\u65F6\u95F4",value:"allArrivalTime"},{label:"\u4E0B\u5355\u65F6\u95F4",value:"orderTime"},{label:"\u9884\u8BA1\u5230\u8D27\u65F6\u95F4",value:"expectArrivalTime"}]})}},methods:{getFilter:function(){return this.$dcopy(this.filter)},onFilterUpdate:function(e,t){var a=null;"warehouse"===t&&(e?this.filter.warehouseIds=e.join():this.filter.warehouseIds=null),"date"===t&&(this.filter.start=e?e[0]:"",this.filter.end=e?e[1]:""),"search"===t&&(a=e.changeType,e&&e.searchField&&e.searchValue?(this.filter.searchType=e.searchField,this.filter.searchContent=e.searchValue):(this.filter.searchType=null,this.filter.searchContent=null)),"noChange"!==a&&this.$emit("on-change")},filterReset:function(){this.filter={searchTimeType:"createTime"},this.$refs.warehouseSelectorRef.setData([]),this.$refs.baseDatePickerRef.setData([]),this.$refs.searchBarRef.setData({searchField:"purchaseNo",searchValue:""}),this.$emit("on-change")}}},B=(0,$.A)(j,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"page_screen"},[a("div",{staticClass:"new_filter_bar",attrs:{"data-type":"filter"}},[a("WarehouseSelectorNew",{ref:"warehouseSelectorRef",attrs:{isMulti:"",clearable:"",filterable:"",isPermission:!0,placeholder:e.$t("main.warehouse.scan.arrive.purchase.column.purchase.warehouse"),"warehouse-types":e.warehouseTypes},on:{"on-change":function(t){return e.onFilterUpdate(t,"warehouse")}},model:{value:e.filter.warehouseList,callback:function(t){e.$set(e.filter,"warehouseList",t)},expression:"filter.warehouseList"}}),e._v(" "),a("lazy-scroll-select",{attrs:{options:e.supplierOptions},on:{"on-change":e.onFilterUpdate},model:{value:e.filter.supplierIds,callback:function(t){e.$set(e.filter,"supplierIds",t)},expression:"filter.supplierIds"}}),e._v(" "),a("lazy-scroll-select",{attrs:{options:e.purchaserOptions},on:{"on-change":e.onFilterUpdate},model:{value:e.filter.purchaserIds,callback:function(t){e.$set(e.filter,"purchaserIds",t)},expression:"filter.purchaserIds"}}),e._v(" "),a("BaseDatePickerGroup",{ref:"baseDatePickerRef",attrs:{pickerConfig:e.pickerConfig,pickWidth:"220px",clearable:!0},on:{"on-change":function(t){return e.onFilterUpdate(t,"date")}}},[a("SfSelect",e._b({ref:"timeTypeRef",staticClass:"picker_group_selector",on:{"on-change":e.onFilterUpdate},model:{value:e.filter.searchTimeType,callback:function(t){e.$set(e.filter,"searchTimeType",t)},expression:"filter.searchTimeType"}},"SfSelect",e.searchTimeTypeOptions,!1))],1),e._v(" "),a("SearchBar",{ref:"searchBarRef",attrs:{options:e.searchOptions},on:{"on-change":function(t){return e.onFilterUpdate(t,"search")}}}),e._v(" "),a("el-button",{staticClass:"search-more-reset",attrs:{type:"text"},on:{click:e.filterReset}},[e._v(e._s(e.$t("common.reset")))])],1)])},[],!1,null,"19044e9a",null).exports,E=a(2576);function V(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function R(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){V(s,r,i,n,o,"next",e)}function o(e){V(s,r,i,n,o,"throw",e)}n(void 0)})}}function F(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}var Q={name:"addPurchaserDlg",components:{FilterBar:B,Layout:u.A,purchaseListTable:O,Pagination:E.A},props:{dialogVisible:{type:Boolean,default:!1}},computed:{},watch:{dialogVisible:function(e){var t=this;e&&this.$nextTick(function(){t.doRefresh()})}},data:function(){return{dialogLoading:!1,filterData:{pageNo:1,pageSize:20,status:[1]},paginator:{currentPage:1,pageSize:20,totalResult:0}}},methods:(n=function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},(0,h.mapActions)("PublicApiControl",["publicApiControl"])),o=o={doClose
1:function(){this.$emit("update:dialogVisible",!1)},doRefresh:function(){return R(function(){var e,t,a;return F(this,function(r){switch(r.label){case 0:e=this,this.dialogLoading=!0,Object.assign(t=this.$refs.purchaseFilterBar.getFilter(),this.filterData),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.$http.getPurchasePage(t)];case 2:return a=r.sent(),this.$nextTick(function(){e.$refs.tableDataRef.tableDataInit(a.rows).then(function(){e.$publicApiControl.get(["allSupplierData","allShopSiteList","allCreatorData"])})}),this.paginator={currentPage:a.pageNo,pageSize:a.pageSize,totalResult:a.totalSize},this.dialogLoading=!1,[3,4];case 3:return r.sent(),this.dialogLoading=!0,[3,4];case 4:return[2]}})}).call(this)},purchaseOrderBtn:function(e){return R(function(e){var t,a=arguments;return F(this,function(r){return t=a.length>1&&void 0!==a[1]?a[1]:{},"check"===e&&(this.$emit("checkPurchaseNo",t.purchaseNo),this.doClose()),[2]})}).apply(this,arguments)},onPageChange:function(e){return R(function(e){var t,a;return F(this,function(r){return t=e.currentPage,a=e.pageSize,this.filterData.pageNo=parseInt(t,10),this.filterData.pageSize=a,this.doRefresh(),[2]})}).apply(this,arguments)}},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(o)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(o,e))}),n)},q=(0,$.A)(Q,function(){var e=this,t=e.$createElement,a=e._self._c||t;return e.dialogVisible?a("el-dialog",{directives:[{name:"loading",rawName:"v-loading",value:e.dialogLoading,expression:"dialogLoading"}],attrs:{modal:!1,visible:e.dialogVisible,"custom-class":"dialog_huge remark_dialog",title:e.$t("main.warehouse.scan.arrive.purchase.select.purchase.order"),"close-on-click-modal":!1},on:{"update:visible":function(t){e.dialogVisible=t},close:e.doClose}},[a("Layout",{scopedSlots:e._u([{key:"content",fn:function(){return[a("FilterBar",{ref:"purchaseFilterBar",attrs:{filterData:e.filterData,lass:"page_screen"},on:{"update:filterData":function(t){e.filterData=t},"update:filter-data":function(t){e.filterData=t},"on-change":e.doRefresh}}),e._v(" "),a("keep-alive",[a("purchaseListTable",{ref:"tableDataRef",attrs:{"purchase-order-btn":e.purchaseOrderBtn},on:{doRefresh:e.doRefresh,tableHandle:e.tableHandle}})],1),e._v(" "),a("div",{staticClass:"page_paging layout_box_footer"},[a("Pagination",{attrs:{paginator:e.paginator},on:{"page-change":e.onPageChange}})],1)]},proxy:!0}],null,!1,0x886b3bf5)})],1):e._e()},[],!1,null,null,null).exports;a(40486),a(915),a(81902);var W=a(26027),U=a(5221),M=a(16368),H=a(53169),z=a(24782);function G(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function K(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){G(s,r,i,n,o,"next",e)}function o(e){G(s,r,i,n,o,"throw",e)}n(void 0)})}}function Y(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function J(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}var X="purchaseAutoPrintOnConfirmConfig",Z={components:{LazySelect:W.A},data:function(){return{printConf:{autoPrint:!1},printersOptions:{width:130,filterable:!0,placeholder:this.$t("main.warehouse.scan.arrive.placeholder.select.printer"),options:[]},printTemplateOptions:{width:130,filterable:!0,placeholder:this.$t("main.warehouse.scan.arrive.placeholder.select.print.template"),options:[]}}},computed:Y({},(0,h.mapState)("Socket",{shelfFlag:function(e){return e.shelfFlag}})),methods:{onSelUpdate:function(e,t){"autoPrint"===t?this.autoPrintChange(e):this.saveConfig(e,t)},getFnSkuTableList:function(){return K(function(){var e;return J(this,function(t){switch(t.label){case 0:return[4,(0,M.n5)({templateType:"sku"})];
1case 1:return(e=t.sent()).forEach(function(e){e.label=e.templateName,e.value=e.id}),this.printTemplateOptions.options=e,[2]}})}).call(this)},autoPrintChange:function(e){var t=this;e?(this.$loading(),this.websocketConnect().then(function(e){return K(function(){return J(this,function(t){switch(t.label){case 0:return[4,this.saveConfig(!0,"autoPrint")];case 1:return t.sent(),e.send(JSON.stringify({requestID:"8CA3B96A",version:"1.0",action:"getPrinters"})),[2]}})}).call(t)}).catch(function(){window.btnClick=t.btnClick,t.$sfMessage.confirm(" <div>".concat(t.$t("main.warehouse.scan.arrive.printer.plugin.enable.tip"),"</div>\n <div>").concat(t.$t("main.warehouse.scan.arrive.printer.plugin.installed.enable"),"</div>\n <div>").concat(t.$t("main.warehouse.scan.arrive.printer.plugin.not.installed.prefix"),'<span class="pointer f_blue" onclick="btnClick()">').concat(t.$t("main.warehouse.scan.arrive.printer.plugin.download"),"</span></div>\n "),t.$t("common.tip"),{confirmButtonText:t.$t("main.warehouse.scan.arrive.recheck"),cancelButtonText:t.$t("common.cancel"),customClass:"scan_warning",dangerouslyUseHTMLString:!0,type:"warning",beforeClose:function(e,a,r){return K(function(){return J(this,function(t){switch(t.label){case 0:if("confirm"!==e)return[3,1];return this.autoPrintChange(!0),r(),[3,3];case 1:return this.printConf.autoPrint=!1,this.printConf.printer="",r(),[4,this.saveConfig(!1,"autoPrint")];case 2:t.sent(),t.label=3;case 3:return[2]}})}).call(t)}})}).finally(function(){t.$loading().close()})):(this.printConf.printer="",this.saveConfig("","printer"),this.saveConfig(!1,"autoPrint"),this.getPrinterOptions([]))},btnClick:function(){window.open("https://download-10001658.cos.ap-shanghai.myqcloud.com/tool/dxm_printer_1.0.9.zip","_blank")},saveConfig:function(e,t){var a=this.getConfig();a[t]=e,this.$utils.storageAction.set(X,JSON.stringify(a))},getConfig:function(){var e={};try{var t,a=null!=(t=this.$utils.storageAction.get(X))?t:"{}";e=JSON.parse(a)}catch(t){e={}}return e},getPrinterOptions:function(e){this.printersOptions.options=null==e?void 0:e.map(function(e){return{label:e,value:e}})},getTemplateObj:function(){var e=this,t=null;return this.printTemplateOptions.options.forEach(function(a){e.printConf.templateId===a.value&&(t=a)}),t},websocketConnect:function(){return K(function(){var e;return J(this,function(t){return e=this,[2,new Promise(function(t,a){var r=new WebSocket(U.b4);r.onopen=function(){t(r)},r.onmessage=e.websocketOnmessage,r.onerror=function(){a(r)},e.websock=r})]})}).call(this)},websocketOnmessage:function(e){var t=JSON.parse(e.data);"getPrinters"===t.action&&this.getPrinterOptions(t.printers)},startAutoPrint:function(e){return K(function(){var t,a,r;return J(this,function(i){switch(i.label){case 0:if(!this.printConf.autoPrint)return[3,10];if(!this.printConf.printer)return this.$message.error(this.$t("main.warehouse.scan.arrive.validation.select.printer")),[2];if(!this.printConf.templateId)return this.$message.error(this.$t("main.warehouse.scan.arrive.validation.select.print.template")),[2];i.label=1;case 1:return i.trys.push([1,9,,10]),(t={}).templateData=this.getTemplateObj(),[4,this.handleDataToTemplate(null==e?void 0:e.scanList)];case 2:t.detailsData=i.sent(),i.label=3;case 3:return i.trys.push([3,5,,6]),[4,this.enrichWarehouseAndShelf(t.detailsData)];case 4:case 5:return i.sent(),[3,6];case 6:return[4,(0,M.uw)(t)];case 7:return a=i.sent(),[4,this.autoPrintHandle(a)];case 8:return i.sent(),[3,10];case 9:return r=i.sent(),this.$message.handle(r),[3,10];case 10:return[2]}})}).call(this)},applyShelfNoFromRecommend:function(e){return K(function(){var t,a,r,i,s,n,o,l,c,u,h,p,f,m;return J(this,function(v){switch(v.label){case 0:if(v.trys.push([0,2,,3]),s=e.commodityId,n=e.warehouseId,o=e.platform,l=e.shopId,c=e.fnsku,u=e.fnSku,!n)return[2];return p="-"!==(h=c||u)?h:"",f=[{commodityId:s,warehouseId:n,platform:o||H.Er,shopId:l,fnsku:p}],[4,(0,M.rD)(f)];case 1:return e.shelfNo=(null==(m=v.sent())||null==(i=m[0])||null==(r=i.available)||null==(a=r.related)||null==(t=a[0])?void 0:t.shelfNo)||"",[3,3];case 2:return v.sent(),[3,3];case 3:return[2]}})})()},enrichWarehouseAndShelf:function(e){return K(function(){var t;return J(this,function(a){switch(a.label){case 0:if(t=this,!e.length||!this.shelfFlag)return[2];return[4,Promise.allSettled(e.map(function(e){return t.applyShelfNoFromRecommend(e)}))];case 1:return a.sent(),[2]}})}).call(this)},handleDataToTemplate:function(e){return K(function(){var t,a,r,i,s,n,o,l;return J(this,function(c){switch(c.label){case 0:return t={},a=[],r=[],i={},(null!=e?e:[]).map(function(e){var s;return(null!=(s=null==e?void 0:e.item)?s:[]).map(function(s){a.push(s.sku),r.push(s.id);var n,o=null!=(n=t[s.sku])?n:0;return t[s.sku]=o+s.waitNum,i[s.sku]=e.platform,s}),e}),[4,(0,M.jC)({skuList:a})];case 1:return s=c.sent(),[4,this.$http.getInfoForPrintItemSku({itemIdList:r})];case 2:return n=c.sent(),o={}
1,null==n||n.forEach(function(e){var t;null==(t=e.purchaseSkus)||t.forEach(function(e){o[e.commodityCode+e.commoditySku]=Y({},e)})}),l=[],s.map(function(e){var a,r,s,n,c,u=null!=(s=o[e.commodityCode+e.sku])?s:{};return e.printNum=t[e.sku],l.push((a=Y({},u,e),r=r={platform:null!=(n=null!=(c=i[e.sku])?c:e.platform)?n:u.platform},Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(r)).forEach(function(e){Object.defineProperty(a,e,Object.getOwnPropertyDescriptor(r,e))}),a)),e}),[2,l]}})}).call(this)},autoPrintHandle:function(e){return K(function(){var t,a,r,i,s,n,o;return J(this,function(l){switch(l.label){case 0:t="".concat(new Date().getTime(),"print.pdf"),a=new window.File([e],t,{type:"application/pdf"}),l.label=1;case 1:return l.trys.push([1,5,,6]),[4,this.$http.getCosSign({scopeName:z.A,fileName:t})];case 2:return i=(r=l.sent()).url,s=r.sign,[4,this.$http.uploadFile("".concat(i,"?").concat(s),a)];case 3:return l.sent(),[4,this.$http.getDownloadInfo({fileUrl:r.url})];case 4:return n=l.sent(),this.websock.send(JSON.stringify({requestID:new Date().getTime()+Math.random().toString(36),version:"1.0",action:"print",singlePrint:!0,task:{taskID:new Date().getTime()+Math.random().toString(36),notifyMode:"oneByOne",printer:this.printConf.printer,documents:[{documentID:new Date().getTime()+Math.random().toString(36),url:n.downloadUrl,fileName:n.downloadUrl}]}})),[3,6];case 5:return o=l.sent(),this.$message.handle(o),[3,6];case 6:return[2]}})}).call(this)}},created:function(){var e=this;this.printConf=this.getConfig(),this.$nextTick(function(){e.autoPrintChange(e.printConf.autoPrint),e.getFnSkuTableList()})}},ee=(0,$.A)(Z,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"ml_24",attrs:{id:"purchase_auto_print"}},[a("el-checkbox",{staticClass:"lh_16",on:{change:function(t){return e.onSelUpdate(t,"autoPrint")}},model:{value:e.printConf.autoPrint,callback:function(t){e.$set(e.printConf,"autoPrint",t)},expression:"printConf.autoPrint"}},[a("div",{staticClass:"lh_16"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.auto.print.after.confirm.purchase")))])]),e._v(" "),a("div",{staticClass:"printerList ml_5"},[a("lazy-select",{attrs:{disabled:!e.printConf.autoPrint,options:e.printersOptions},on:{"on-change":function(t){return e.onSelUpdate(t,"printer")}},model:{value:e.printConf.printer,callback:function(t){e.$set(e.printConf,"printer",t)},expression:"printConf.printer"}})],1),e._v(" "),a("div",{staticClass:"printTemplateList ml_5"},[a("lazy-select",{attrs:{options:e.printTemplateOptions},on:{"on-change":function(t){return e.onSelUpdate(t,"templateId")}},model:{value:e.printConf.templateId,callback:function(t){e.$set(e.printConf,"templateId",t)},expression:"printConf.templateId"}})],1)],1)},[],!1,null,"b1ecb80c",null).exports;function et(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}var ea={name:"ScanPage",mixins:[f.A],components:{purchaseListDlg:q,PurchaseAutoPrint:ee},data:function(){return{purchaseNum:"",checkoutPurchaseOrderVisible:!1}},mounted:function(){this.$refs.scanInput.focus()},methods:{checkPurchaseNo:function(e){this.purchaseNum=e,this.handleSubmit()},handleSubmit:function(){var e;return(e=function(){var e,t,a,r;return function(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}(this,function(i){switch(i.label){case 0:if(i.trys.push([0,2,,3]),!this.purchaseNum)return this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.purchase.order.or.tracking.no.first")),[2];return this.$loading(),[4,this.$http.purchaseSearchNew({purchaseNoTrackingNo:this.purchaseNum})];case 1:return a=i.sent(),null==(t=this.$refs.purchaseAutoPrintRef)||null==(e=t.startAutoPrint)||e.call(t,a),this.$emit("setPurchaseData",a),this.$loading().close(),this.handleVideo(this.$t("main.warehouse.scan.arrive.purchase.success")),[3,3];case 2:return r=i.sent(),this.$loading().close(),this.handleVideo(this.$t("main.warehouse.scan.arrive.purchase.failure")),this.$message.handle(r),[3,3];case 3:return[2]}})},function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){et(s,r,i,n,o,"next",e)}function o(e){et(s,r,i,n,o,"throw",e)}n(void 0)})}).call(this)},checkoutPurchaseOrder:function(){this.checkoutPurchaseOrderVisible=!0}}},er=(0,$.A)(ea,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"scan_wrap flex"},[a("div",{staticClass:"scan_left"},[a("span",{staticClass:"title"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.info")))])]),e._v(" "),a("div",{staticClass:"scan_right"},[a("div",{staticClass:"input_box flex center_align"},[a("input",{directives:[{name:"model",rawName:"v-model",value:e.purchaseNum,expression:"purchaseNum"}],ref:"scanInput",staticClass:"scan_right_input",attrs:{placeholder:e.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.purchase.order.or.tracking.no")},domProps:{value:e.purchaseNum},on:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSubmit.apply(null,arguments)},input:function(t){t.target.composing||(e.purchaseNum=t.target.value)}}}),e._v(" "),a("button",{staticClass:"submitBtn",on:{click:e.handleSubmit}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.confirm")))]),e._v(" "),a("el-button",{staticClass:"textBtn",attrs:{type:"text"},on:{click:e.checkoutPurchaseOrder}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.select.purchase.order")))]),e._v(" "),a("PurchaseAutoPrint",{ref:"purchaseAutoPrintRef"})],1),e._v(" "),a("div",{staticClass:"model_data_no"},[a("div",[a("div",{staticClass:"f_12 f_gray"},[a("p",[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.no.data")))]),e._v(" "),a("p",[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.purchase.order.or.tracking.no.first")))])])])])]),e._v(" "),a("purchaseListDlg",{attrs:{dialogVisible:e.checkoutPurchaseOrderVisible},on:{"update:dialogVisible":function(t){e.checkoutPurchaseOrderVisible=t},"update:dialog-visible":function(t){e.checkoutPurchaseOrderVisible=t},checkPurchaseNo:e.checkPurchaseNo}})],1)},[],!1,null,"3aeee1da",null).exports;a(19592),a(15456),a(71934),a(20767),a(93893);var ei="skuIdentificationCode",es="fnsku",en="commodityCode",eo=[{label:"SKU",value:ei},{label:"FNSKU",value:es},{label:(0,g.Tl)("main.warehouse.scan.arrive.purchase.product.code"),value:en}],el=a(4535),ec=a(72129),eu=a(80009),eh=a(57741),ep=a(67915),ef=a(20314),em=a(58604),ev=a(60019),ed=a(84472),eb=a(8757),eg={name:"ArrivedList",components:{ImgBox:ep.A,MskuList:ed.A,DynamicColumn:ef.A,ToolsLine:d.A},props:{receiveList:{type:Array}},computed:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},(0,h.mapState)("Socket",{purchaseQualityStatus:function(e){return e.purchaseQualityStatus}})),methods:{showWaresDetail:function(e){(0,k.h)({commodityId:null==e?void 0:e.commodityId,row:e,context:this})}},created:function(){var e=(0,eb.B)("\u5F85\u5230\u8D27>\u91C7\u8D2D\u5355\u626B\u63CF\u5230\u8D27>\u5230\u8D27\u8BB0\u5F55");this.controller=new em.A(e,[new ev.A({id:"table",name:"Table",host:this,columns:[{title:(0,L._)("main.warehouse.scan.arrive.column.purchase.no"),field:"purchaseNo",minWidth:120},{title:(0,L._)("main.warehouse.scan.arrive.column.arrival.time"),field:"createTime",minWidth:150},{title:(0,L._)("main.warehouse.scan.arrive.column.arrival.record.no"),field:"purchaseRecordNo",minWidth:120},{title:(0,L._)("common.image"),field:"mainImage",slots:{default:"mainImage"}},{title:(0,L._)("main.warehouse.scan.arrive.column.product.name.sku"),field:"commodityName",slots:{default:"commodityName"}},{title:(0,L._)("main.warehouse.scan.arrive.column.product.code.identification.code"),field:"commodityCode",slots:{default:"commodityCode"}},{title:(0,L._)("main.warehouse.scan.arrive.column.shop.fnsku"),field:"shopName",slots:{default:"shopName"}},{title:"MSKU",field:"msku",slots:{default:"msku"}},{title:(0,L._)("main.warehouse.scan.arrive.column.receiver"),field:"createName"},{title:(0,L._)("main.warehouse.scan.arrive.column.arrival.quantity"),field:"arrivals"},{title:(0,L._)("main.warehouse.scan.arrive.column.good.quantity"),field:"goods"},{title:(0,L._)("main.warehouse.scan.arrive.column.defective.quantity"),field:"defective"}
1,{title:(0,L._)("main.warehouse.scan.arrive.column.pending.inspection.quantity"),field:"unInspectNum"}],resizable:!0,resizeKey:e,drag:!0})])}},ey=(0,$.A)(eg,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"wrap"},[a("DynamicColumn",{staticClass:"wrap_ctrbtn",attrs:{controller:e.controller}}),e._v(" "),a("vxe-grid",{ref:"arrivedListTable",staticClass:"table_list vxe_table_row_height_32 vxe_table_v_a_middle",attrs:{columns:e.controller.table.state.columns,data:e.receiveList,"auto-resize":"",resizable:"",round:"","highlight-hover-row":"","highlight-current-row":"","row-class-name":"change_details_row","show-header-overflow":""},scopedSlots:e._u([{key:"mainImage",fn:function(e){return[a("ImgBox",{attrs:{src:e.row.mainImage,option:"dialog"}})]}},{key:"commodityName",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.commodityName,expression:"row.commodityName",arg:"light",modifiers:{isShow:!0}}],staticClass:"line_clamp"},[e._v("\n "+e._s(r.commodityName||"-")+"\n ")]),e._v(" "),a("ToolsLine",{attrs:{isCopy:"",f_blue:"",label:r.commoditySku||"-"},on:{click:function(t){return e.showWaresDetail(r)}}})]}},{key:"commodityCode",fn:function(t){var r=t.row;return[a("div",{staticClass:"line_clamp"},[e._v("\n "+e._s(r.commodityCode||"-")+"\n ")]),e._v(" "),a("div",{staticClass:"f_gray line_clamp"},[e._v("\n "+e._s(r.identificationCode||"-")+"\n ")])]}},{key:"shopName",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.shopName,expression:"row.shopName",arg:"light",modifiers:{isShow:!0}
1}],staticClass:"line_clamp"},[e._v("\n "+e._s(r.shopName||"-")+"\n ")]),e._v(" "),a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.fnSku,expression:"row.fnSku",arg:"light",modifiers:{isShow:!0}}],staticClass:"f_gray line_clamp"},[e._v("\n "+e._s(r.fnSku||"-")+"\n ")])]}},{key:"msku",fn:function(e){return[a("MskuList",{attrs:{list:e.row.msku}})]}}])})],1)},[],!1,null,"3d364cfe",null).exports,e_={name:"QualityList",components:{ImgBox:ep.A,DynamicColumn:ef.A,MskuList:ed.A,ToolsLine:d.A},props:{qualityList:{type:Array}},methods:{showWaresDetail:function(e){(0,k.h)({commodityId:null==e?void 0:e.commodityId,row:e,context:this})},getStatus:function(e){switch(e){case 1:return this.$t("main.warehouse.scan.arrive.purchase.quality.status.inspected");case 2:return this.$t("main.warehouse.scan.arrive.purchase.quality.status.exempted");default:return"-"}}},created:function(){var e=(0,eb.B)("\u5F85\u5230\u8D27>\u91C7\u8D2D\u5355\u626B\u63CF\u5230\u8D27>\u8D28\u68C0\u8BB0\u5F55");this.controller=new em.A(e,[new ev.A({id:"table",name:"Table",host:this,columns:[{title:this.$t("main.warehouse.scan.arrive.purchase.column.purchase.no"),field:"purchaseNo",minWidth:120},{title:this.$t("main.warehouse.scan.arrive.purchase.column.quality.completed.time"),field:"createTime",minWidth:150},{title:this.$t("main.warehouse.scan.arrive.purchase.column.quality.order"),field:"inspectionNo",minWidth:120},{title:this.$t("main.warehouse.scan.arrive.purchase.column.image"),field:"mainImage",slots:{default:"mainImage"}},{title:this.$t("main.warehouse.scan.arrive.purchase.column.name.sku"),field:"commodityName",slots:{default:"commodityName"}},{title:this.$t("main.warehouse.scan.arrive.purchase.column.product.code.identification.code"),field:"commodityCode",slots:{default:"commodityCode"}},{title:this.$t("main.warehouse.scan.arrive.purchase.column.shop.fnsku"),field:"shopName",slots:{default:"shopName"}},{title:"MSKU",field:"msku",slots:{default:"msku"}},{title:this.$t("main.warehouse.scan.arrive.purchase.column.status"),field:"inspectionType",slots:{default:"inspectionType"}},{title:this.$t("main.warehouse.scan.arrive.purchase.column.quality.quantity"),field:"inspectedNum"},{title:this.$t("main.warehouse.scan.arrive.purchase.column.good.quantity"),field:"goods"},{title:this.$t("main.warehouse.scan.arrive.purchase.column.defective.quantity"),field:"defectives"},{title:this.$t("main.warehouse.scan.arrive.purchase.column.abnormal.quantity"),field:"abnormalNum"},{title:this.$t("main.warehouse.scan.arrive.purchase.column.inspector"),field:"createName"}],resizable:!0,resizeKey:e,drag:!0})])}},ew=(0,$.A)(e_,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"wrap"},[a("DynamicColumn",{staticClass:"wrap_ctrbtn",attrs:{controller:e.controller}}),e._v(" "),a("vxe-grid",{ref:"QualityListTable",staticClass:"table_list vxe_table_row_height_32 vxe_table_v_a_middle",attrs:{columns:e.controller.table.state.columns,data:e.qualityList,"auto-resize":"",resizable:"",round:"","highlight-hover-row":"","highlight-current-row":"","row-class-name":"change_details_row","show-header-overflow":""},scopedSlots:e._u([{key:"mainImage",fn:function(e){return[a("ImgBox",{attrs:{src:e.row.mainImage,option:"dialog"}})]}},{key:"commodityName",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.commodityName,expression:"row.commodityName",arg:"light",modifiers:{isShow:!0}
1}],staticClass:"line_clamp"},[e._v("\n "+e._s(r.commodityName||"-")+"\n ")]),e._v(" "),a("ToolsLine",{attrs:{isCopy:"",f_blue:"",label:r.commoditySku||"-"},on:{click:function(t){return e.showWaresDetail(r)}}})]}},{key:"commodityCode",fn:function(t){var r=t.row;return[a("div",{staticClass:"line_clamp"},[e._v("\n "+e._s(r.commodityCode||"-")+"\n ")]),e._v(" "),a("div",{staticClass:"f_gray line_clamp"},[e._v("\n "+e._s(r.identificationCode||"-")+"\n ")])]}},{key:"shopName",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.shopName,expression:"row.shopName",arg:"light",modifiers:{isShow:!0}}],staticClass:"line_clamp"},[e._v("\n "+e._s(r.shopName||"-")+"\n ")]),e._v(" "),a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light.isShow",value:r.fnSku,expression:"row.fnSku",arg:"light",modifiers:{isShow:!0}}],staticClass:"f_gray line_clamp"},[e._v("\n "+e._s(r.fnSku||"-")+"\n ")])]}},{key:"msku",fn:function(e){return[a("MskuList",{attrs:{list:e.row.msku}})]}},{key:"inspectionType",fn:function(t){var r=t.row;return[a("span",[e._v(e._s(e.getStatus(r.inspectionType)))])]}}])})],1)},[],!1,null,"12aa3f20",null).exports;a(75038);var eS=a(85399),ek=a(39489),eN=a(47190),eC=a(9107),e$=a(95928);function eO(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r}var ex={data:function(){return{vxeGridTableColumnList:[]}},computed:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},(0,h.mapState)("Socket",{purchaseQualityStatus:function(e){return e.purchaseQualityStatus},shelfFlag:function(e){return e.shelfFlag},purchaseArrivalStatus:function(e){return e.purchaseArrivalStatus}})),methods:{initColumns:function(){var e=this,t=[{minWidth:140,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.purchase.no"),field:"purchaseNo",className:"column_header",showOverflow:!0,params:{columnName:"purchaseNo",fixedVisible:!0},slots:{default:"purchaseNo_default"}},{width:(0,b.n)("60"),title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.image"),field:"image",showOverflow:!0,resizable:!1,params:{columnName:"image"},slots:{default:"image_default"}},{minWidth:120,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.name.sku"),field:"nameAndSku",showOverflow:!0,params:{columnName:"nameAndSku",fixedVisible:!0},slots:{default:"nameAndSku_default"}},{minWidth:150,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.product.code.identification.code"),field:"code",showOverflow:!0,params:{columnName:"code",fixedVisible:!0},slots:{default:"code_default"}},{minWidth:150,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.expected.arrival.time"),field:"expectArrivalTime",showOverflow:!0,params:{columnName:"expectArrivalTime",fixedVisible:!0},slots:{default:"expectArrivalTime_default"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.shop.fnsku"),field:"shopName",showOverflow:!0,params:{columnName:"shopName",fixedVisible:!0},slots:{default:"shopName_default"}},{minWidth:140,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.exclusive.type"),field:"exclusiveType",showOverflow:!0,params:{columnName:"exclusiveType",fixedVisible:!0},slots:{default:"exclusiveType_default"}},{minWidth:140,title:"MSKU",field:"shopName",showOverflow:!0,params:{columnName:"msku",fixedVisible:!0},slots:{default:"msku_default"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.need.quality.inspection"),field:"isNeedQc",showOverflow:!0,visible:this.purchaseQualityStatus,params:{columnName:"isNeedQc",visibleNot:!this.purchaseQualityStatus},slots:{default:"isNeedQc_default"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.purchase.quantity"),field:"num",align:"right",showOverflow:!0,params:{columnName:"num"},slots:{default:"num_default"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.wait.arrival.quantity"),field:"waitNum",align:"right",showOverflow:!0,params:{columnName:"waitNum",fixedVisible:!0},slots:{default:"waitNum_default"}},{minWidth:120,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.purchase.unit.price"),field:"price",align:"right",showOverflow:!0,params:{columnName:"price"},slots:{default:"price_default"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.good.quantity.count"),field:"goods",showOverflow:!0,visible:!this.purchaseQualityStatus,params:{columnName:"goods",visibleNot:this.purchaseQualityStatus},slots:{default:"goods_default",header:"goods_header",footer:"goods_footer"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.defective.quantity.count"),field:"defective",showOverflow:!0,visible:!this.purchaseQualityStatus,params:{columnName:"defective",visibleNot:this.purchaseQualityStatus},slots:{default:"defective_default",header:"defective_header",footer:"defective_footer"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.current.arrival.quantity"),field:"arrivals",showOverflow:!0,visible:this.purchaseQualityStatus,params:{columnName:"arrivals",visibleNot:!this.purchaseQualityStatus},slots:{default:"arrivals_default",header:"arrivals_header",footer:"arrivals_footer"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.available.shelf.location"),field:"shelf
1NoAvailable",visible:this.shelfFlag,params:{columnName:"shelfNoAvailable",visibleNot:!this.shelfFlag},slots:{default:"shelfNoAvailable_default",header:"shelfNoAvailable_header"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.defective.shelf.location"),field:"shelfNoDefective",visible:this.shelfFlag&&!this.purchaseQualityStatus,params:{columnName:"shelfNoDefective",visibleNot:!this.shelfFlag},slots:{default:"shelfNoDefective_default",header:"shelfNoDefective_header"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.column.abnormal.quantity"),field:"errorNum",params:{columnName:"errorNum"},slots:{default:"errorNum_default",header:"errorNum_header"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.abnormal.type"),field:"errorType",params:{columnName:"errorType"},slots:{default:"errorType_default"}}],a=this.$dcopy(t);a.forEach(function(t,a){0!==a&&e.$set(t.params,"order",a)}),this.vxeGridTableColumnList=function(e){if(Array.isArray(e))return eO(e)}(a)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||function(e){if(e){if("string"==typeof e)return eO(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return eO(e,void 0)}}(a)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},created:function(){this.initColumns()}};function eP(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}var eT={name:"ShopList",mixins:[eS.A,ex,e$.A,ek.A],components:{ImgBox:ep.A,ShelfRemoteSelect:eN.A,MskuList:ed.A,PopoverContainer:m.A,ExclusiveTypeSelect:eC.A,ToolsLine:d.A},props:{shopList:Array},data:function(){return{contentTips:"",VTRefName:"shopListTable",ccVxeTableKey:this.getPageKeyByName("\u5F85\u5230\u8D27>\u91C7\u8D2D\u5355\u626B\u63CF\u5230\u8D27"),shelfNoAvailableBatch:{val:""},shelfNoDefectiveBatch:{val:""},shelfNoAvailableBatchList:[],shelfNoDefectiveBatchList:[],batchShelfOptionsLoaded:!1}},mounted:function(){this.initVTCConfig()},computed:(l=function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},(0,h.mapState)("Socket",{purchaseQualityStatus:function(e){return e.purchaseQualityStatus},shelfFlag:function(e){return e.shelfFlag},upShelfManage:function(e){return e.upShelfManage},purchaseArrivalStatus:function(e){return e.purchaseArrivalStatus}})),c=c={showBatchBtn:function(){return this.shelfFlag&&!this.upShelfManage&&!this.purchaseQualityStatus}},Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(c)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(c)).forEach(function(e){Object.defineProperty(l,e,Object.getOwnPropertyDescriptor(c,e))}),l),watch:{shopList:{handler:function(e){!this.batchShelfOptionsLoaded&&(null==e?void 0:e.length)&&(this.loadBatchShelfOptions(),this.batchShelfOptionsLoaded=!0)},immediate:!0}},methods:{showWaresDetail:function(e){(0,k.h)({commodityId:null==e?void 0:e.commodityId,commoditySku:null==e?void 0:e.sku,row:e,context:this})},arrivalNumHandle:function(e){this.shopList.map(function(t){var a=0;"goods"===e?((a=t.waitNum-Number(t.defective))<0&&(a=0),t.goods=a):"defective"===e?((a=t.waitNum-Number(t.goods))<0&&(a=0),t.defective=a):"arrivals"===e&&((a=t.waitNum)<0&&(a=0),t.arrivals=a)})},shelfNoAvailableBatchChange:function(){var e=this;this.shopList.forEach(function(t){t.shelfNoAvailable=e.shelfNoAvailableBatch.val,e.shelfNoAvailableChange(t.shelfNoAvailable,t)})}
1,shelfNoDefectiveBatchChange:function(){var e=this;this.shopList.forEach(function(t){t.shelfNoDefective=e.shelfNoDefectiveBatch.val,e.shelfNoDefectiveChange(t.shelfNoDefective,t)})},shelfNoAvailableChange:function(e,t){var a,r,i=null==(r=t.availableShelfOptions)||null==(a=r.options)?void 0:a.find(function(t){return t.value===e});t.shelfNoAvailableId=(null==i?void 0:i.shelfId)||""},shelfNoDefectiveChange:function(e,t){var a,r,i=null==(r=t.defectiveShelfOptions)||null==(a=r.options)?void 0:a.find(function(t){return t.value===e});t.shelfNoDefectiveId=(null==i?void 0:i.shelfId)||""},updateAvailableShelfOptions:function(e,t){this.$set(t.availableShelfOptions,"options",e||[])},updateDefectiveShelfOptions:function(e,t){this.$set(t.defectiveShelfOptions,"options",e||[])},buildShelfRemoteParams:function(e){return[{commodityId:e.commodityId,warehouseId:e.warehouseId,fnsku:e.fnsku||e.fnSku,shopId:e.shopId,platform:e.platform,exclusiveType:e.exclusiveType}]},buildBatchShelfRemoteParams:function(e){var t,a,r=e.shelfNo,i=e.shelfType;return[{warehouseId:null!=(t=null==(a=this.shopList[0])?void 0:a.warehouseId)?t:null,batch:!0,shelfNo:r,shelfType:i}]},loadBatchShelfOptions:function(){var e;return(e=function(){var e,t,a,r,i,s;return function(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}(this,function(n){switch(n.label){case 0:if(!(t=null==(e=this.shopList[0])?void 0:e.warehouseId))return[2];n.label=1;case 1:return n.trys.push([1,3,,4]),[4,this.$http.getRecommendShelfForStockIn([{warehouseId:t,batch:!0}])];case 2:return(r=null==(a=n.sent())?void 0:a[0])?(this.shelfNoAvailableBatchList=((null==(i=r.available)?void 0:i.related)||[]).map(function(e){return{label:e.shelfNo,value:e.shelfNo}}),this.shelfNoDefectiveBatchList=((null==(s=r.defective)?void 0:s.related)||[]).map(function(e){return{label:e.shelfNo,value:e.shelfNo}})):(this.shelfNoAvailableBatchList=[],this.shelfNoDefectiveBatchList=[]),[3,4];case 3:return n.sent(),[3,4];case 4:return[2]}})},function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){eP(s,r,i,n,o,"next",e)}function o(e){eP(s,r,i,n,o,"throw",e)}n(void 0)})}).call(this)},singleArrivalNumHandle:function(e,t){var a=0;"goods"===e?((a=t.waitNum-Number(t.defective))<0&&(a=0),t.goods=a):"defective"===e?((a=t.waitNum-Number(t.goods))<0&&(a=0),t.defective=a):"arrivals"===e&&((a=t.waitNum)<0&&(a=0),t.arrivals=a)},inputVerify:function(e,t){if(e[t]&&(e[t]=this.$utils.integerVerification(e[t])),!this.purchaseArrivalStatus){if(this.purchaseQualityStatus){e[t]>e.waitNum&&(e[t]=e.waitNum);return}var a={goods:function(){var a=e.waitNum-Number(e.defective);e[t]>a&&(e[t]=a)},defective:function(){var a=e.waitNum-Number(e.goods);e[t]>a&&(e[t]=a)},abnormal:function(){var a=e.waitNum;e[t]>a&&(e[t]=a)}};a[t]&&a[t]()}},handleArriveTime:function(e){return e?this.$utils.dateFormat(e,"yyyy-MM-dd"):"-"},showCustomColumnDL:function(){this.ccDLVisible=!0}}},eA=(0,$.A)(eT,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticStyle:{position:"relative"}}
1,[a("vxe-grid",{ref:"shopListTable",staticClass:"table_list vxe_table_row_height_32 vxe_table_v_a_middle",attrs:{data:e.shopList,columns:e.vxeGridTableColumnList,"auto-resize":"",resizable:"",round:"","highlight-hover-row":"","highlight-current-row":"","scroll-y":{gt:20},"row-class-name":"change_details_row","show-header-overflow":""},on:{"resizable-change":e.resizableChange},scopedSlots:e._u([{key:"purchaseNo_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"merge_info",class:{is_show:r.isCenter}},[a("span",[e._v(e._s(r.purchaseNo||"-"))]),e._v(" "),r.isExpediting?a("span",{staticClass:"expedited_cls"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.expedited")))]):e._e()])]}},{key:"image_default",fn:function(e){var t=e.row;return[a("ImgBox",{attrs:{src:t.mainImage,option:"dialog","icon-type":t.isGroup,"is-gift":t.isGift}})]}},{key:"nameAndSku_default",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light",value:r.commodityName,expression:"row.commodityName",arg:"light"}],staticClass:"line_clamp"},[e._v(e._s(r.commodityName||"-"))]),e._v(" "),r.commodityId||r.sku?a("ToolsLine",{staticClass:"f_gray",attrs:{isCopy:"",f_blue:"",label:r.sku||"-"},on:{click:function(t){return e.showWaresDetail(r)}}}):a("ToolsLine",{staticClass:"f_gray",attrs:{isCopy:"",label:r.sku||"-"}})]}},{key:"code_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"line_clamp"},[e._v("\n "+e._s(r.commodityCode||"-")+"\n ")]),e._v(" "),a("div",{staticClass:"f_gray line_clamp"},[e._v("\n "+e._s(r.identificationCode||"-")+"\n ")])]}},{key:"expectArrivalTime_default",fn:function(t){var r=t.row;return[a("span",[e._v(e._s(e.handleArriveTime(r.expectArrivalTime)))])]}},{key:"shopName_default",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light",value:r.shopName,expression:"row.shopName",arg:"light"}],staticClass:"line_clamp"},[e._v(e._s(r.shopName||"-"))]),e._v(" "),a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light",value:r.fnsku,expression:"row.fnsku",arg:"light"}],staticClass:"f_gray line_clamp"},[e._v(e._s(r.fnsku||"-"))])]}},{key:"exclusiveType_default",fn:function(t){var r=t.row;return[a("ExclusiveTypeSelect",{attrs:{type:r.exclusiveType,isDetail:"",data:r},on:{"update:type":function(t){return e.$set(r,"exclusiveType",t)}}})]}},{key:"msku_default",fn:function(e){return[a("MskuList",{attrs:{list:e.row.msku}})]}},{key:"isNeedQc_default",fn:function(t){var r=t.row;return[a("el-select",{staticClass:"quality_select",attrs:{placeholder:e.$t("main.warehouse.scan.arrive.purchase.please.select"),disabled:""},model:{value:r.isNeedQc,callback:function(t){e.$set(r,"isNeedQc",t)},expression:"row.isNeedQc"}},[a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.purchase.yes"),value:1}}),e._v(" "),a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.purchase.no"),value:0}})],1)]}},{key:"num_default",fn:function(t){var r=t.row;return[a("span",[e._v(e._s(r.num))])]}},{key:"waitNum_default",fn:function(t){var r=t.row;return[a("span",[e._v(e._s(r.waitNum))])]}},{key:"price_default",fn:function(t){var r=t.row;return[a("span",{directives:[{name:"field-right",rawName:"v-field-right",value:{permission:"purchaseCost"},expression:"{ permission: 'purchaseCost' }"}]},[e._v(e._s(r.perPurchase||"-"))])]}},{key:"goods_header",fn:function(){return[a("div",[a("span",{staticClass:"mr_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.good.quantity.count")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.arrivalNumHandle("goods")}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.remaining.all.arrive")))])],1
1)]},proxy:!0},{key:"goods_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex center_align"},[a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("main.warehouse.scan.arrive.purchase.please.enter")},on:{input:function(t){return e.inputVerify(r,"goods")}},model:{value:r.goods,callback:function(t){e.$set(r,"goods",t)},expression:"row.goods"}}),e._v(" "),a("el-popover",{attrs:{placement:"top",trigger:"hover",content:e.$t("main.warehouse.scan.arrive.purchase.remaining.all.arrive")}},[a("i",{staticClass:"icon_all_01 f_blue pointer f_14",attrs:{slot:"reference"},on:{click:function(t){return e.singleArrivalNumHandle("goods",r)}},slot:"reference"})])],1)]}},{key:"defective_header",fn:function(){return[a("div",[a("span",{staticClass:"mr_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.defective.quantity.count")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.arrivalNumHandle("defective")}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.remaining.all.arrive")))])],1
1)]},proxy:!0},{key:"defective_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex center_align"},[a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("main.warehouse.scan.arrive.purchase.please.enter")},on:{input:function(t){return e.inputVerify(r,"defective")}},model:{value:r.defective,callback:function(t){e.$set(r,"defective",t)},expression:"row.defective"}}),e._v(" "),a("el-popover",{attrs:{placement:"top",trigger:"hover",content:e.$t("main.warehouse.scan.arrive.purchase.remaining.all.arrive")}},[a("i",{staticClass:"icon_all_01 f_blue pointer f_14",attrs:{slot:"reference"},on:{click:function(t){return e.singleArrivalNumHandle("defective",r)}},slot:"reference"})])],1)]}},{key:"arrivals_header",fn:function(){return[a("div",[a("span",{staticClass:"mr_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.current.arrival.quantity")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.arrivalNumHandle("arrivals")}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.remaining.all.arrive")))])],1
1)]},proxy:!0},{key:"arrivals_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex center_align"},[a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("main.warehouse.scan.arrive.purchase.please.enter")},on:{input:function(t){return e.inputVerify(r,"arrivals")}},model:{value:r.arrivals,callback:function(t){e.$set(r,"arrivals",t)},expression:"row.arrivals"}}),e._v(" "),a("el-popover",{attrs:{placement:"top",trigger:"hover",content:e.$t("main.warehouse.scan.arrive.purchase.remaining.all.arrive")}},[a("i",{staticClass:"icon_all_01 f_blue pointer f_14",attrs:{slot:"reference"},on:{click:function(t){return e.singleArrivalNumHandle("arrivals",r)}},slot:"reference"})])],1)]}},{key:"shelfNoAvailable_header",fn:function(t){var r=t.column.title;return[a("span",[e._v(e._s(r))]),e._v(" "),e.showBatchBtn?a("PopoverContainer",{attrs:{"show-footer":""},on:{"on-change":e.shelfNoAvailableBatchChange},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("el-button",{attrs:{type:"text"}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.batch")))])]},proxy:!0}],null,!0)},[e._v(" "),a("ShelfRemoteSelect",{attrs:{width:"200","shelf-type":0,options:{options:e.shelfNoAvailableBatchList},"select-props":{placeholder:e.$t("common.select.placeholder")},"build-params":e.buildBatchShelfRemoteParams,"hide-stock":""},model:{value:e.shelfNoAvailableBatch.val,callback:function(t){e.$set(e.shelfNoAvailableBatch,"val",t)},expression:"shelfNoAvailableBatch.val"}})],1):e._e()]}},{key:"shelfNoAvailable_default",fn:function(t){var r=t.row;return[a("ShelfRemoteSelect",{attrs:{"shelf-type":0,options:r.availableShelfOptions&&r.availableShelfOptions.options,"select-props":r.availableShelfOptions,params:e.buildShelfRemoteParams(r),"format-options-config":{otherKey:"shelfId"},"use-new-shelf-select":"",disabled:r.isNeedQc&&e.purchaseQualityStatus||e.upShelfManage},on:{"on-change":function(t){return e.shelfNoAvailableChange(t,r)},"remote-options-change":function(t){return e.updateAvailableShelfOptions(t,r)}},model:{value:r.shelfNoAvailable,callback:function(t){e.$set(r,"shelfNoAvailable",t)},expression:"row.shelfNoAvailable"}})]}},{key:"shelfNoDefective_header",fn:function(t){var r=t.column.title;return[a("span",[e._v(e._s(r))]),e._v(" "),e.showBatchBtn?a("PopoverContainer",{attrs:{"show-footer":""},on:{"on-change":e.shelfNoDefectiveBatchChange},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("el-button",{attrs:{type:"text"}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.batch")))])]},proxy:!0}],null,!0)},[e._v(" "),a("ShelfRemoteSelect",{attrs:{width:"200","shelf-type":1,options:{options:e.shelfNoDefectiveBatchList},"select-props":{placeholder:e.$t("common.select.placeholder")},"build-params":e.buildBatchShelfRemoteParams,"hide-stock":""},model:{value:e.shelfNoDefectiveBatch.val,callback:function(t){e.$set(e.shelfNoDefectiveBatch,"val",t)},expression:"shelfNoDefectiveBatch.val"}})],1):e._e()]}},{key:"shelfNoDefective_default",fn:function(t){var r=t.row;return[a("ShelfRemoteSelect",{attrs:{"shelf-type":1,options:r.defectiveShelfOptions&&r.defectiveShelfOptions.options,"select-props":r.defectiveShelfOptions,params:e.buildShelfRemoteParams(r),"format-options-config":{otherKey:"shelfId"},"use-new-shelf-select":"",disabled:e.upShelfManage},on:{"on-change":function(t){return e.shelfNoDefectiveChange(t,r)},"remote-options-change":function(t){return e.updateDefectiveShelfOptions(t,r)}},model:{value:r.shelfNoDefective,callback:function(t){e.$set(r,"shelfNoDefective",t)},expression:"row.shelfNoDefective"}})]}},{key:"errorNum_header",fn:function(){return[a("span",[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.abnormal.quantity")))]),e._v(" "),a("i",{directives:[{name:"tooltip",rawName:"v-tooltip",value:e.$t("main.warehouse.scan.arrive.purchase.abnormal.quantity.tooltip"),expression:"$t('main.warehouse.scan.arrive.purchase.abnormal.quantity.tooltip')"}],staticClass:"icon_sf_help f_16"})]},proxy:!0},{key:"errorNum_default",fn:function(t){var r=t.row;return[r.isNeedQc&&e.purchaseQualityStatus?a("span",[e._v("-")]):a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("main.warehouse.scan.arrive.purchase.please.enter")},on:{input:function(t){return e.inputVerify(r,"abnormal")}},model:{value:r.abnormal,callback:function(t){e.$set(r,"abnormal",t)},expression:"row.abnormal"}})]}},{key:"errorType_default",fn:function(t){var r=t.row;return[r.isNeedQc&&e.purchaseQualityStatus?a("span",[e._v("-")]):a("el-select",{attrs:{value:"",placeholder:e.$t("main.warehouse.scan.arrive.purchase.please.select"),clearable:""},model:{value:r.abnormalType,callback:function(t){e.$set(r,"abnormalType",t)},expression:"row.abnormalType"}},[a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.purchase.over.arrival"),value:"1"}}),e._v(" "),a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.purchase.incoming.defective"),value:"2"}}),e._v(" "),a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.purchase.goods.not.match"),value:"3"}})],1)]}},{key:"empty",fn:function(){return[a("div",{staticClass:"f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.no.data")))])]},proxy:!0}])}),e._v(" "),a("CustomColumnsNew",{ref:"customColumnsNewDL",attrs:{fullColumn:e.ccFullColumn,visible:e.ccDLVisible,vxeTableKey:e.ccVxeTableKey,"draggable-sort":!0,showAllbt
1n:""},on:{"update:fullColumn":function(t){e.ccFullColumn=t},"update:full-column":function(t){e.ccFullColumn=t},"update:visible":function(t){e.ccDLVisible=t},"update:vxeTableKey":function(t){e.ccVxeTableKey=t},"update:vxe-table-key":function(t){e.ccVxeTableKey=t},"on-save-hide":e.customColumnSaveHandle}})],1)},[],!1,null,"7814afd0",null).exports;function eD(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r}function eL(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function eI(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){eL(s,r,i,n,o,"next",e)}function o(e){eL(s,r,i,n,o,"throw",e)}n(void 0)})}}function ej(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}function eB(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){ej(e,t,a[t])})}return e}function eE(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}function eV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var a,r,i=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var s=[],n=!0,o=!1;try{for(i=i.call(e);!(n=(a=i.next()).done)&&(s.push(a.value),!t||s.length!==t);n=!0);}catch(e){o=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(o)throw r}}return s}}(e,t)||eR(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function eR(e,t){if(e){if("string"==typeof e)return eD(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);if("Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a)return Array.from(a);if("Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a))return eD(e,t)}}function eF(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}var eQ={name:"ScanDetail",components:{PopoverContainer:m.A,ArrivedList:ey,QualityList:ew,ShopList:eA,PrintCommoditySku:ec.A,PrintTemplateDialog:eu.A,PrintTemplateReceipt:eh.A,RadioGroup:el.A},inject:["clearPurchaseNum","msgBox","messageVNode","tabListFnClose"],mixins:[f.A],props:{purchaseData:Object},computed:eE(eB({},(0,h.mapState)("Socket",{purchaseQualityStatus:function(e){return e.purchaseQualityStatus},purchaseArrivalStatus:function(e){return e.purchaseArrivalStatus},purchase1688OverArrivalType:function(e){return e.purchase1688OverArrivalType},purchaseOverArrivalType:function(e){return e.purchaseOverArrivalType},warehouseUpShelfOrderType:function(e){return e.warehouseUpShelfOrderType},shelfFlag:function(e){return e.shelfFlag},upShelfManage:function(e){return e.upShelfManage}})),{goodsTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.shopList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.goods)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},defectiveTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.shopList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.defective)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},arrivalsTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.shopList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.arrivals)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},inputPlaceholder:function(){switch(this.selectVal){case ei:return this.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.sku");case es:return this.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.fnsku");case en:return this.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.product.code");default:return""}}}),watch:{purchaseData:{handler:function(e){var t=this;this.$nextTick(function(){return eI(function(){var t,a,r,i,s;return eF(this,function(n){switch(n.label){case 0:if(t=this,this.$loading(),this.fnSkuList=e.fnSkuList,this.allPurchaseNoList=e.purchaseNoList,this.showExpand=this.allPurchaseNoList.length>1,this.purchaseNoList=[this.allPurchaseNoList[0]],a=new Map,!this.shelfFlag)return[3,2];return r=[],e.scanList.forEach(function(e){var t;r.push.apply(r,function(e){if(Array.isArray(e))return eD(e)}(t=(0,H.J_)(e.item))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||eR(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())}),[4,this.getRecommendShelfForStockIn(r)];case 1:i=n.sent()||[],a=(0,H.NN)(i),n.label=2;case 2:return s=[],e.scanList.forEach(function(e){e.purchaseId=e.id,e.item.forEach(function(r,i){if(["arrivals","goods","defective","abnormal","abnormalType"].forEach(function(e){t.$set(r,e,"")}),t.shelfFlag){var n,o,l,c,u,h,p=r.commodityId,f=r.fnsku,m=r.fnSku,v=r.shopId,d=r.platform,b=(0,H.LN)({commodityId:p,fnSku:m||f,shopId:v,warehouseId:r.warehouseId,platform:d}),g=(null==(n=a.get(b))?void 0:n.available)||{},y=(null==(o=a.get(b))?void 0:o.defective)||{};t.$set(r,"availableShelfOptions",{placeholder:t.$t("main.warehouse.scan.arrive.purchase.please.select"),clearable:!0,filterable:!0,includeAll:!0,options:t.$utils.setShelfSelectNew(g.related,{otherKey:"shelfId"})}),t.$set(r,"defectiveShelfOptions",{placeholder:t.$t("main.warehouse.scan.arrive.purchase.please.select"),clearable:!0,filterable:!0,includeAll:!0,options:t.$utils.setShelfSelectNew(y.related,{otherKey:"shelfId"})}),r.shelfNoAvailable||(e.isBatch||(l=g.related?null==(c=g.related[0])?void 0:c.shelfNo:""),t.$set(r,"shelfNoAvailable",r.isNeedQc&&t.purchaseQualityStatus||t.upShelfManage?"":l)),r.shelfNoDefective||(e.isBatch||(u=y.related?null==(h=y.related[0])?void 0:h.shelf
1No:""),t.$set(r,"shelfNoDefective",r.isNeedQc&&t.purchaseQualityStatus||t.upShelfManage?"":u))}s.push(eE(eB({},e,r),{isParentGroup:0===i,isCenter:Math.floor(e.item.length/2)===i}))})}),this.shopList=s,this.$loading().close(),[2]}})}).call(t)})},immediate:!0}},data:function(){return{activeName:"shopList",selectVal:ei,selectOptions:eo,searchValue:"",arriveNum:0,shopList:[],qualityList:[],arrivedList:[],fnSkuList:[],showExpand:!0,allPurchaseNoList:[],purchaseNoList:[],conversionSKUCacheForSaiHe:new Map,isSaiHeUser:!1,printAssembleSheetBtnOptions:{options:[{value:"batchPrintTemplate",label:this.$t("main.warehouse.scan.arrive.purchase.print.sku.label.by.template"),permission:"MOD_WAREHOUSE_TO_ARRIVE.PRINT_SKU_FNSKU_LABEL"},{value:"batchPrintTemplateFnSku",label:this.$t("main.warehouse.scan.arrive.purchase.print.fnsku.label.by.template"),permission:"MOD_WAREHOUSE_TO_ARRIVE.PRINT_SKU_FNSKU_LABEL"}],title:this.$t("main.warehouse.scan.arrive.purchase.print.operation"),btnType:"text"},printTemplateDialog:{visible:!1,value:null,groupData:null},printTemplateFnSkuDialog:{visible:!1,value:null},printTemplateByReceipt:{visible:!1,value:null},tabsOptions:{options:[{name:this.$t("main.warehouse.scan.arrive.purchase.product.info"),value:"shopList",num:"",hasNum:!1},{name:this.$t("main.warehouse.scan.arrive.purchase.arrival.record"),value:"arrivedList",num:"",hasNum:!1},{name:this.$t("main.warehouse.scan.arrive.purchase.quality.record"),value:"qualityList",num:"",hasNum:!1}]}}},methods:eE(eB({},(0,h.mapActions)("ScanArrive",["setPurPurchaseData"])),{updateShopList:function(){return eI(function(){var e,t;return eF(this,function(a){switch(a.label){case 0:e=this,a.label=1;case 1:return a.trys.push([1,3,,4]),[4,this.$http.purchaseSearchNew({purchaseNoTrackingNo:this.purchaseData.searchKey})];case 2:return t=a.sent(),this.setPurPurchaseData(t),this.$emit("update:purchaseData",t),[3,4];case 3:return a.sent(),this.msgBox({title:this.$t("main.warehouse.scan.arrive.purchase.all.arrived"),content:this.$t("main.warehouse.scan.arrive.purchase.current.order.all.arrived.scan.other"),icon:"el-icon-success",color:"#67C23A",showCancelButton:!1}).then(function(){e.clearPurchaseNum()}),[3,4];case 4:return[2]}})}).call(this)},handleChangePurchase:function(){var e=this;this.msgBox({title:this.$t("main.warehouse.scan.arrive.purchase.confirm.change.purchase.order"),content:this.$t("main.warehouse.scan.arrive.purchase.change.order.data.lost")}).then(function(){e.clearPurchaseNum(),e.arriveNum=0}).catch(function(){})},handleSubmit:function(){return eI(function(){var e,t,a,r,i,s,n,o,l,c,u,h,p,f,m,v,d,b,g,y,_;return eF(this,function(w){switch(w.label){case 0:if(e="",a=this.searchValue,r={},i=this.selectVal,!a)return this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.scan.or.enter.with.type",{type:e})),[2];if(!(this.isSaiHeUser&&i!==es))return[3,2];return[4,this.conversionToSFSku(a)];case 1:r=w.sent(),w.label=2;case 2:switch(i){case ei:e="SKU",t=this.findLastIndexBySkuOrIdentificationCode(r);break;case es:e="FNSKU",t=this.shopList.findLastIndex(function(e){return e.fnsku===a});break;case en:e=this.$t("main.warehouse.scan.arrive.purchase.product.code"),t=this.findLastIndexByCommodityCode(r)}this.$refs.scanInput.select(),s=r.sku,n=r.identificationCode,o=r.commodityCode,l=r.uniqueCode,c=!1,u=!0,h=!1,p=void 0;try{for(f=this.shopList.entries()[Symbol.iterator]();!(u=(m=f.next()).done);u=!0){switch(d=(v=eV(m.value,2))[0],b=v[1],i){case ei:if(this.isSaiHeUser&&(!n||n!==b.identificationCode)&&(!s||s!==b.sku)&&l!==b.identificationCode&&l!==b.sku||!this.isSaiHeUser&&a!==b.identificationCode&&a!==b.sku)continue;break;case es:if(a!==b.fnsku)continue;break;case en:if(this.isSaiHeUser&&(!o||o!==b.commodityCode)&&l!==b.commodityCode||!this.isSaiHeUser&&a!==b.commodityCode)continue}if(c=!0,g=this.purchaseQualityStatus?"arrivals":"goods",y="arrivals"===g?b.waitNum:b.waitNum-Number(b.defective),_=d===t,!(b[g]>=y)||_){if(b[g]>=y&&_&&!this.purchaseArrivalStatus){this.handleVideo(this.$t("main.warehouse.scan.arrive.purchase.failure")),this.msgBox({title:this.$t("main.warehouse.scan.arrive.purchase.over.arrival.forbidden"),content:this.messageVNode(),isVNode:!0,showCancelButton:!1}).then(function(){});break}this.arriveNum++,b[g]++,this.handleVideo(this.$t("main.warehouse.scan.arrive.purchase.success")),this.handleScrollEvent(d);break}}}catch(e){h=!0,p=e}finally{try{u||null==f.return||f.return()}finally{if(h)throw p}}return c||(this.handleVideo(this.$t("main.warehouse.scan.arrive.purchase.failure")),this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.scan.failed")),this.arriveNum+=1),[2]}})}).call(this)},handleScrollEvent:function(e){var t=this.$refs.shopList.$refs.shopListTable;t.scrollToRow(this.shopList[e]),t.setCurrentRow(this.shopList[e])},handleCancel:function(){this.tabListFnClose()},handleArrive:function(){var e=this;this.$utils.getButtonBuriedPoint.call(this,"purchase_purchaseOrder_scanArrival_purchaseArrival_confirm");var t=[],a=[],r={},i=!0,s=!1,n=void 0;try{for(var o,l=this.shopList.entries()[Symbol.iterator]();!(i=(o=l.next()).done);i=!0){var c=eV(o.value,2),u=c[0],h=c[1];if(!(h.arrivals<=0)||!(h.goods<=0)||!(h.defective<=0)||!(h.abnormal<=0)){if
1(h.arrivals>h.waitNum&&"1"!==h.abnormalType&&h.abnormalType){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.arrival.greater.wait.select.over.arrival")),this.handleScrollEvent(u);return}if((Number(h.goods)+Number(h.defective)>h.waitNum||h.arrivals>h.waitNum)&&h.isGift){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.gift.arrival.not.greater.wait")),this.handleScrollEvent(u);return}if(+h.abnormal&&!h.abnormalType){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.abnormal.quantity.select.type")),this.handleScrollEvent(u);return}if(h.abnormalType&&!+h.abnormal){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.abnormal.type.enter.quantity")),this.handleScrollEvent(u);return}var p=h.arrivals-h.abnormal!==h.waitNum,f=this.purchaseQualityStatus?+h.arrivals:+h.goods+ +h.defective+ +h.abnormal;if("1"===h.abnormalType){if(0==+h.waitNum){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.completed.arrival.no.abnormal.order")),this.handleScrollEvent(u);return}if(!this.purchaseQualityStatus&&+h.goods+ +h.defective!=+h.waitNum){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.over.arrival.good.defective.equal.wait")),this.handleScrollEvent(u);return}if(p&&this.purchaseQualityStatus){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.over.arrival.arrival.minus.abnormal.equal.wait")),this.handleScrollEvent(u);return}}else if(h.abnormal>f){this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.abnormal.quantity.less.equal.arrival")),this.handleScrollEvent(u);return}r[h.purchaseId]||(r[h.purchaseId]={purchaseId:h.purchaseId,warehouseId:h.warehouseId,shipFee:h.shipFee,otherFee:h.otherFee,purchaseNo:h.purchaseNo,items:[]}),h.arrivals>h.waitNum?a.push(h.sku):+h.goods+ +h.defective>h.waitNum&&a.push(h.sku),r[h.purchaseId].items.push({purchaseItemId:h.id,ids:h.ids,sku:h.sku,fnSku:h.fnsku,arrivals:h.arrivals||0,goods:h.goods||0,defective:h.defective||0,shelfNoAvailable:h.shelfNoAvailable,shelfNoAvailableId:h.shelfNoAvailableId,shelfNoDefective:h.shelfNoDefective,shelfNoDefectiveId:h.shelfNoDefectiveId,abnormal:h.abnormal||0,abnormalType:h.abnormalType,isGift:h.isGift})}}}catch(e){s=!0,n=e}finally{try{i||null==l.return||l.return()}finally{if(s)throw n}}if(a.length&&this.purchaseArrivalStatus){var m="<div>".concat(this.$t("main.warehouse.scan.arrive.purchase.sku.arrival.greater.wait.confirm",{sku:a.toString()}),"</div>");this.$sfMessage.confirm(m,this.$t("main.warehouse.scan.arrive.purchase.confirm.arrival"),{dangerouslyUseHTMLString:!0,type:"warning",confirmHandle:function(){e.doArrival(r,t)}})}else this.doArrival(r,t)},doArrival:function(e,t){return eI(function(){var a,r,i;return eF(this,function(s){switch(s.label){case 0:if(s.trys.push([0,7,,8]),Object.keys(e).forEach(function(a){t.push(e[a])}),!t.length)return this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.enter.at.least.one.arrival.quantity")),this.handleScrollEvent(0),[2];return this.$loading(),[4,this.$http.confirmArrival({list:t,skuOrPurchaseNo:this.purchaseData.searchKey,type:1,allocationVos:[{type:"OVER_ARRIVAL",value:this.purchaseArrivalStatus},{type:"COMMON_PURCHASE_OVER_ARRIVAL",value:this.purchaseOverArrivalType},{type:"ALIBABA_PURCHASE_OVER_ARRIVAL",value:this.purchase1688OverArrivalType},{type:"PURCHASE_QUALITY_INSPECTION",value:+!!this.purchaseQualityStatus},{type:"WAREHOUSE_UP_SHELF_ORDER",value:this.warehouseUpShelfOrderType}]})];case 1:if(null!==(a=s.sent()))return[3,3];return this.$message.success(this.$t("main.warehouse.scan.arrive.purchase.arrival.success")),[4,this.updateShopList()];case 2:case 4:return s.sent(),[3,6];case 3:if(!this.$isArray(a))return[3,5];return(null==a?void 0:a.length)?(r=a.length>5?"".concat(a.splice(0,5).join(),"..."):a,this.$message.warning(this.$t("main.warehouse.scan.arrive.purchase.sku.arrival.exceeds.review.free.range",{sku:r.join()}))):this.$message.success(this.$t("main.warehouse.scan.arrive.purchase.arrival.success")),[4,this.updateShopList()];case 5:this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.arrival.failed")),s.label=6;case 6:return this.$loading().close(),[3,8];case 7:return i=s.sent(),this.$message.handle(i),this.$loading().close(),[3,8];case 8:return[2]}})}).call(this)},handleTabChange:function(e){"shopList"===e&&this.updateShopList(),"arrivedList"===e&&this.getArrivedListByPurchaseIds(),"qualityList"===e&&this.getQualityListByPurchaseIds()},getQualityListByPurchaseIds:function(){return eI(function(){var e,t;return eF(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,this.$http.getQualityListByPurchaseIds({purchaseIds:this.purchaseData.purchaseId.join(",")})];case 1:return e=a.sent()||[],t=[],e.forEach(function(e){e.itemList.forEach(function(a){a=eB({},a,e),t.push(a)})}
1),this.qualityList=t,[3,3];case 2:return a.sent(),[3,3];case 3:return[2]}})}).call(this)},getArrivedListByPurchaseIds:function(){return eI(function(){var e,t;return eF(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,this.$http.getReceiveListByPurchaseIds({purchaseIds:this.purchaseData.purchaseId.join(",")})];case 1:return e=a.sent()||[],t=[],e.forEach(function(e){e.recordItemVos.forEach(function(a){a=eB({},a,e),t.push(a)})}),this.arrivedList=t,[3,3];case 2:return a.sent(),[3,3];case 3:return[2]}})}).call(this)},handleExpand:function(){this.showExpand=!1,this.purchaseNoList=this.allPurchaseNoList},handlePackUp:function(){this.showExpand=!0,this.purchaseNoList=[this.allPurchaseNoList[0]]},getRecommendShelfForStockIn:function(e){return eI(function(){var t;return eF(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,this.$http.getRecommendShelfForStockIn(e)];case 1:return t=a.sent(),[3,3];case 2:return a.sent(),[3,3];case 3:return[2,t]}})}).call(this)},showCustomColumnDL:function(){this.$refs.shopList.showCustomColumnDL()},checkSaiHeGrayscalePermission:function(){return this.$hasButtonPermission(U.j8.tripartiteToSf)},conversionToSFSku:function(e){return eI(function(){var t,a,r;return eF(this,function(i){switch(i.label){case 0:if(t=this.conversionSKUCacheForSaiHe.get(e))return[2,t];this.$loading(),i.label=1;case 1:return i.trys.push([1,3,4,5]),[4,this.$http.getConversionToSFSkuApi({uniqueCode:e})];case 2:return a=i.sent(),this.conversionSKUCacheForSaiHe.set(e,a),[2,a];case 3:return r=i.sent(),this.$message.error(r),[2,{}];case 4:return this.$loading().close(),[7];case 5:return[2]}})}).call(this)},findLastIndexBySkuOrIdentificationCode:function(e){var t=this,a=e.sku,r=e.identificationCode,i=e.uniqueCode;return this.shopList.findLastIndex(function(e){return t.isSaiHeUser?a&&e.sku===a||r&&e.identificationCode===r||e.sku===i||e.identificationCode===i:e.sku===t.searchValue||e.identificationCode===t.searchValue})},findLastIndexByCommodityCode:function(e){var t=this,a=e.commodityCode,r=e.uniqueCode;return this.shopList.findLastIndex(function(e){return t.isSaiHeUser?a&&e.commodityCode===a||e.commodityCode===r:e.commodityCode===t.searchValue})},disposeSelectIds:function(){return this.shopList.map(function(e){return e.id})},printPageName:function(e){if(0===this.disposeSelectIds().length)return void this.$message.error(this.$t("main.warehouse.scan.arrive.purchase.select.one.purchase.order"));switch(e){case"batchPrintTemplate":this.batchPrintTemplate("batch");break;case"batchPrintTemplateFnSku":this.batchPrintTemplate("batch",null,"fnsku");break;case"batchPrintTemplateReceipt":this.batchPrintTemplateReceipt()}},batchPrintTemplate:function(e,t,a){return eI(function(){var t,r,i,s,n,o,l,c;return eF(this,function(u){switch(u.label){case 0:t="fnsku"===a,u.label=1;case 1:return u.trys.push([1,3,4,5]),this.$loading(),r=[],i=[],s=ej({},{batch:"itemIdList"}[e],{batch:this.disposeSelectIds()}[e]),n={batch:this.$http.getInfoForPrintItemSku},[4,(t?this.$http.getDataForPrintFnsku:n[e])(s)];case 2:return o=u.sent(),l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"-",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"";null==t||t.forEach(function(t){"batchArrival"===e?a.push(eE(eB({},t),{printNum:t.arrivalNum,sn:r,supplierName:i})):a.push(eE(eB({},t),{printNum:t.waitNum,sn:r,supplierName:i}))})},o&&o.forEach(function(e){var a=t?"purchaseFnskus":"purchaseSkus";e[a]&&(l(e[a],r,e.purchaseNo,e.supplierName),l(e.assemblePurchaseSkus,i,e.purchaseNo,e.supplierName))}),t?(this.printTemplateFnSkuDialog.value=r,this.printTemplateFnSkuDialog.visible=!0):(this.printTemplateDialog.value=r,this.printTemplateDialog.groupData=i,this.printTemplateDialog.visible=!0),[3,5];case 3:return c=u.sent(),this.$message.handle(c),[3,5];case 4:return this.$loading().close(),[7];case 5:return[2]}})}).call(this)},batchPrintTemplateReceipt:function(){var e=[];this.purchaseNoList.map(function(t){return e.push({receipt:t.purchaseNo,id:t.id}),t}),this.printTemplateByReceipt.visible=!0,this.printTemplateByReceipt.value=e}}),mounted:function(){this.isSaiHeUser=this.checkSaiHeGrayscalePermission()}};function eq(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function eW(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t}
1)(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}var eU={name:"PurchaseArrive",components:{ScanPage:er,ScanDetail:(0,$.A)(eQ,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"scan_detail flex"},[a("div",{staticClass:"scan_left"},[a("div",{staticClass:"scan_detail_title flex center_align between mb_12"},[a("span",{staticClass:"title"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.info")))]),e._v(" "),a("el-button",{staticClass:"text_btn_f14",attrs:{type:"text"},on:{click:e.handleChangePurchase}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.change.purchase.order")))])],1),e._v(" "),a("div",{staticClass:"flex center_align purchaseNo"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.tracking.no")))]),e._v(" "),[e.purchaseData.trackingNoList&&e.purchaseData.trackingNoList.length>1?a("span",[a("el-popover",{attrs:{width:"150",trigger:"hover"}},[a("ul",e._l(e.purchaseData.trackingNoList,function(t){return a("li",{key:t},[a("span",{staticClass:"f_black fw_600 line_clamp"},[e._v(e._s(t))])])}),0),e._v(" "),a("div",{attrs:{slot:"reference"},slot:"reference"},[a("span",{staticClass:"f_black fw_600 line_clamp"},[e._v(e._s(e.purchaseData.trackingNoList[0]))]),e._v(" "),a("i",{staticClass:"el-icon-arrow-down"})])])],1):e.purchaseData.trackingNoList?a("span",{staticClass:"f_black fw_600 line_clamp"},[e._v("\n "+e._s(e.purchaseData.trackingNoList[0]||"-")+"\n ")]):a("span",[e._v("-")])]],2),e._v(" "),a("ul",{staticClass:"purchase_ul"},[e._l(e.purchaseNoList,function(t){return a("li",{key:t.purchaseNo,staticClass:"purchase_li"},[a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.purchase.no")))]),e._v(" "),a("span",{staticClass:"f_gold mr_4 fw_600"},[e._v(e._s(t.purchaseNo))]),e._v(" "),t.isExpediting?a("span",{staticClass:"expedited_cls"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.expedited")))]):e._e()]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.create.time")))]),e._v(" "),a("span",{staticStyle:{"white-space":"nowrap"}},[e._v(e._s(t.createTime))])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.tracking.no")))]),e._v(" "),[t.logisticsBillNoList&&t.logisticsBillNoList.length>1?a("div",[a("el-popover",{attrs:{width:"150",trigger:"hover"}},[a("ul",e._l(t.logisticsBillNoList,function(t){return a("li",{key:t},[e._v("\n "+e._s(t)+"\n ")])}),0),e._v(" "),a("div",{attrs:{slot:"reference"},slot:"reference"},[a("span",[e._v(e._s(t.logisticsBillNoList[0]))]),e._v(" "),a("i",{staticClass:"el-icon-arrow-down"})])])],1):t.logisticsBillNoList?a("span",[e._v(e._s(t.logisticsBillNoList[0]||"-"))]):a("span",[e._v("-")])]],2),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.purchase.warehouse")))]),e._v(" "),a("span",[e._v(e._s(t.warehouseName||"-"))])]),e._v(" "),a("div",{staticClass:"flex mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.supplier")))]),e._v(" "),a("span",{staticClass:"line_clamp_2"},[e._v(e._s(t.supplierName||"-"))])]),e._v(" "),a("div",{staticClass:"flex"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.column.remark")))]),e._v(" "),a("popover-container",{attrs:{data:t.remark,"show-empty":!1,trigger:"hover",placement:"right"},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("span",{staticClass:"line_clamp_2"},[e._v(e._s(t.remark||"-"))])]},proxy:!0}],null,!0)})],1)])}),e._v(" "),e.allPurchaseNoList.length>1?a("li",{staticClass:"mt_12"},[e.showExpand?a("el-button",{attrs:{type:"text"},on:{click:e.handleExpand}},[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.purchase.expand"))+"("+e._s(e.allPurchaseNoList.length-1)+")"),a("i",{staticClass:"el-icon-arrow-down el-icon--right"}
1)]):e._e(),e._v(" "),e.showExpand?e._e():a("el-button",{attrs:{type:"text"},on:{click:e.handlePackUp}},[e._v(" "+e._s(e.$t("main.warehouse.scan.arrive.purchase.collapse"))),a("i",{staticClass:"el-icon-arrow-up el-icon--right"})])],1):e._e()],2),e._v(" "),a("div",{staticClass:"msg_num_box"},[a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.sku.category")))]),e._v(" "),a("span",[e._v(e._s(e.purchaseData.skuCategoryCount)+" "+e._s(e.$t("main.warehouse.scan.arrive.purchase.unit.kind")))])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.total.purchase.quantity")))]),e._v(" "),a("span",[e._v(e._s(e.purchaseData.purchaseCount))])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.total.wait.quantity")))]),e._v(" "),a("span",[e._v(e._s(e.purchaseData.waitCount))])])])]),e._v(" "),a("div",{staticClass:"scan_right flex column"},[a("div",{staticClass:"input_box flex center_align mb_10"},[a("el-select",{model:{value:e.selectVal,callback:function(t){e.selectVal=t},expression:"selectVal"}},e._l(e.selectOptions,function(e){return a("el-option",{key:e.label,attrs:{label:e.label,value:e.value}})}),1),e._v(" "),a("input",{directives:[{name:"model",rawName:"v-model",value:e.searchValue,expression:"searchValue"}],ref:"scanInput",staticClass:"scan_right_input",attrs:{placeholder:e.inputPlaceholder},domProps:{value:e.searchValue},on:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSubmit.apply(null,arguments)},input:function(t){t.target.composing||(e.searchValue=t.target.value)}}}),e._v(" "),a("button",{staticClass:"submitBtn",on:{click:e.handleSubmit}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.confirm")))]),e._v(" "),a("div",{staticClass:"flex center_align"},[a("span",{staticClass:"f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.current.scan.input.count"))+":")]),e._v(" "),a("span",{class:{fw_600:e.arriveNum}},[e._v(e._s(e.arriveNum))])])],1),e._v(" "),a("div",{staticClass:"list_wrap"},[a("div",{staticClass:"scan_detail_title mb_8"},[a("span",{staticClass:"title"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.purchase.list")))])]),e._v(" "),"shopList"===e.activeName?a("ul",{staticClass:"sum"},[e.purchaseQualityStatus?e._e():a("li",[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.purchase.good.arrival.summary"))+":"),a("span",{class:{fw_600:e.goodsTotal}},[e._v(e._s(e.goodsTotal))])]),e._v(" "),e.purchaseQualityStatus?e._e():a("li",[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.purchase.defective.arrival.summary"))+":"),a("span",{class:{fw_600:e.defectiveTotal}},[e._v(e._s(e.defectiveTotal))])]),e._v(" "),e.purchaseQualityStatus?a("li",[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.purchase.current.arrival.summary"))+":"),a("span",{class:{fw_600:e.arrivalsTotal}},[e._v(e._s(e.arrivalsTotal))])]):e._e(),e._v(" "),a("li",[a("myj-button",{attrs:{options:e.printAssembleSheetBtnOptions,tagName:"UiDropdownBtn"},on:{command:function(t){return e.printPageName(t)}}})],1),e._v(" "),a("li",{staticClass:"btn_square_icon",attrs:{title:e.$t("main.warehouse.scan.arrive.purchase.configure.table.fields")},on:{click:e.showCustomColumnDL}},[a("i",{staticClass:"icon_sf_set"})])]):e._e(),e._v(" "),a("RadioGroup",{staticClass:"mb_8",attrs:{options:e.tabsOptions},on:{change:function(t){return e.handleTabChange(e.activeName)}},model:{value:e.activeName,callback:function(t){e.activeName=t},expression:"activeName"}}),e._v(" "),"shopList"===e.activeName?a("ShopList",{ref:"shopList",attrs:{shopList:e.shopList},on:{"update:shopList":function(t){e.shopList=t},"update:shop-list":function(t){e.shopList=t}}}):e._e(),e._v(" "),"arrivedList"===e.activeName?a("ArrivedList",{attrs:{receiveList:e.arrivedList}}):e._e(),e._v(" "),"qualityList"===e.activeName?a("QualityList",{attrs:{qualityList:e.qualityList}}
1):e._e()],1)]),e._v(" "),a("div",{staticClass:"arrive_btn"},[a("el-button",{on:{click:e.handleCancel}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.cancel")))]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.handleArrive}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.confirm.arrival")))])],1),e._v(" "),a("print-commodity-sku",{attrs:{data:e.printData,visible:e.printVisible,"bind-name":"waitNum","item-name":"purchaseSkus","page-type":"purchase",printGroup:""},on:{"update:visible":function(t){e.printVisible=t}}}),e._v(" "),a("PrintTemplateDialog",{attrs:{visible:e.printTemplateDialog.visible,groupData:e.printTemplateDialog.groupData,value:e.printTemplateDialog.value,templateType:"sku",printGroup:""},on:{"update:visible":function(t){return e.$set(e.printTemplateDialog,"visible",t)}}}),e._v(" "),a("PrintTemplateDialog",{attrs:{value:e.printTemplateFnSkuDialog.value,visible:e.printTemplateFnSkuDialog.visible,"template-type":"fnsku"},on:{"update:visible":function(t){return e.$set(e.printTemplateFnSkuDialog,"visible",t)}}}),e._v(" "),a("PrintTemplateReceipt",{attrs:{visible:e.printTemplateByReceipt.visible,value:e.printTemplateByReceipt.value,showNoPurchaseNum:"",templateType:"toBeDeliveredItem",oldTemplateType:"toBeDelivered"},on:{"update:visible":function(t){return e.$set(e.printTemplateByReceipt,"visible",t)}}})],1)},[],!1,null,"205248cc",null).exports},data:function(){return{purchaseData:null}},provide:function(){return{clearPurchaseNum:this.clearPurchaseNum}},computed:eW(eq({},(0,h.mapState)("ScanArrive",{purPurchaseData:function(e){return e.purPurchaseData}})),{currentComponent:function(){return this.purchaseData?"ScanDetail":"ScanPage"}}),created:function(){this.$utils.addVUEXModule("ScanArrive")},mounted:function(){var e=this;this.$nextTick(function(){e.purPurchaseData&&(e.purchaseData=e.purPurchaseData)})},methods:eW(eq({},(0,h.mapActions)("ScanArrive",["setPurPurchaseData","clearAllData"])),{setPurchaseData:function(e){this.purchaseData=e,this.setPurPurchaseData(this.purchaseData)},clearPurchaseNum:function(){this.purchaseData=null,this.clearAllData()}})},eM=(0,$.A)(eU,function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.currentComponent,{tag:"component",attrs:{purchaseData:e.purchaseData},on:{setPurchaseData:e.setPurchaseData,"update:purchaseData":function(t){e.purchaseData=t},"update:purchase-data":function(t){e.purchaseData=t}}})},[],!1,null,"bc2d14cc",null).exports;function eH(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}var ez="skuIdentificationCode",eG="fnsku",eK="commodityCode",eY=(eH(r={},ez,"SKU"),eH(r,eG,"FNSKU"),eH(r,eK,(0,g.Tl)("main.warehouse.scan.arrive.product.code")),r),eJ=[{label:"SKU",value:ez},{label:"FNSKU",value:eG},{label:(0,g.Tl)("main.warehouse.scan.arrive.product.code"),value:eK}],eX=a(82505);function eZ(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function e0(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){eZ(s,r,i,n,o,"next",e)}function o(e){eZ(s,r,i,n,o,"throw",e)}n(void 0)})}}function e1(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function e2(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}function e3(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}var e4={name:"ScanPage",mixins:[eS.A,f.A],components:{ImgBox:ep.A,SearchBar:D.A,Pagination:E.A,SinglePopover:eX.A,WarehouseSelectorNew:T.A},data:function(){return{skuOrFnsku:"",contentTips:"",selectVal:ez,selectOptions:eJ,warehouseId:"",dialogShopVisible:!1,shopData:null,searchOptions:{width:350,searchFiledOptions:[{label:(0,L._)("main.warehouse.scan.arrive.sku.product.name"),value:"commodityName"},{label:"SKU",value:"sku"},{label:(0,L._)("main.warehouse.scan.arrive.sku.identification.code"),value:"identificationCode"}],searchFiledWidth:90},sku:"",commodityName:"",identificationCode:"",paginator:{currentPage:1,pageSize:20,totalResult:0},alertVisible:!1,repeatData:null,radioResult:0,showSelectErr:!1}},computed:e2(e1({},(0,h.mapState)("Socket",{allowPurchaseToOverseasWarehouseStatus:function(e){return e.allowPurchaseToOverseasWarehouseStatus}})),{warehouseTypes:function(){return this.allowPurchaseToOverseasWarehouseStatus?[1,3]:[1]},inputPlaceholder:function(){switch(this.selectVal){case ez:return this.$t("main.warehouse.scan.arrive.sku.scan.or.enter.sku");case eG:return this.$t("main.warehouse.scan.arrive.sku.scan.or.enter.fnsku");case eK:return this.$t("main.warehouse.scan.arrive.sku.scan.or.enter.product.code")}}}),watch:{warehouseId:function(e){this.$router.push({query:e2(e1({},this.$route.query),{warehouse:e})}),this.$refs.scanInput.focus()},dialogShopVisible:function(e){e&&this.getCommoditySearch()}},created:function(){this.warehouseId=+this.$route.query.warehouse||""},methods:{getI18nColumnWidth:b.n,onWarehouseUpdate:function(){this.showSelectErr=!1},getCommoditySearch:function(){return e0(function(){var e;return e3(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),this.$loading(),[4,this.$http.commoditySearch({warehouseId:this.warehouseId,commodityName:this.commodityName,sku:this.sku,identificationCode:this.identificationCode,pageNo:this.paginator.currentPage,pageSize:this.paginator.pageSize})];case 1:return(e=t.sent())&&(this.paginator={currentPage:e.pageNo,pageSize:e.pageSize,totalResult:e.totalSize},this.shopData=e.rows),this.$loading().close(),[3,3];case 2:return t.sent(),this.$loading().close(),[3,3];case 3:return[2]}})}).call(this)},handleSubmit:function(){return e0(function(){var e,t;return e3(this,function(a){switch(a.label){case 0:if(!this.skuOrFnsku)switch(this.selectVal){case ez:return[2,this.$message.error(this.$t("main.warehouse.scan.arrive.sku.scan.or.enter.sku"))];case eG:return[2,this.$message.error(this.$t("main.warehouse.scan.arrive.sku.scan.or.enter.fnsku"))];case eK:return[2,this.$message.error(this.$t("main.warehouse.scan.arrive.sku.scan.or.enter.product.code"))]}a.label=1;case 1:return a.trys.push([1,3,,4]),this.$loading(),[4,this.$http.checkSku({warehouseId:this.warehouseId,searchContent:this.skuOrFnsku,searchType:this.selectVal})];case 2:return(e=a.sent())&&(1===e.length?this.$emit("setPurchaseData",e[0]):(this.alertVisible=!0,this.repeatData=e)),this.$loading().close(),[3,4];case 3:return t=a.sent(),this.$loading().close(),this.handleVideo("\u593
11\u8D25"),this.$message.handle(t),[3,4];case 4:return[2]}})}).call(this)},filterChange:function(e){this.commodityName="",this.sku="",this.identificationCode="",this[e.searchField]=e.searchValue,"noChange"!==e.changeType&&this.getCommoditySearch()},handleChoose:function(e){this.skuOrFnsku=e.sku,this.$emit("setPurchaseData",{sku:this.skuOrFnsku})},handleChooseSku:function(){this.$emit("setPurchaseData",this.repeatData[this.radioResult])},onPageChange:function(e){this.paginator.currentPage=e.currentPage,this.paginator.pageSize=e.pageSize,this.getCommoditySearch()}}},e6=(0,$.A)(e4,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"scan_wrap flex"},[a("div",{staticClass:"scan_left"},[a("span",{staticClass:"title mb_12"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.purchase.info")))]),e._v(" "),a("div",{staticClass:"flex center_align between"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.warehouse")))]),e._v(" "),a("div",{staticClass:"select_box"},[a("WarehouseSelectorNew",{ref:"warehouseSelect",class:{ipt_err:e.showSelectErr},attrs:{width:"100%",filterable:"",isPermission:!0,placeholder:e.$t("common.warehouse"),"warehouse-types":e.warehouseTypes},on:{"on-change":e.onWarehouseUpdate},model:{value:e.warehouseId,callback:function(t){e.warehouseId=t},expression:"warehouseId"}}),e._v(" "),e.showSelectErr?a("p",{staticClass:"err_text mt_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.select.warehouse")))]):e._e()],1)])]),e._v(" "),a("div",{staticClass:"scan_right"},[a("div",{staticClass:"input_box flex center_align"},[a("el-select",{model:{value:e.selectVal,callback:function(t){e.selectVal=t},expression:"selectVal"}},e._l(e.selectOptions,function(e){return a("el-option",{key:e.label,attrs:{label:e.label,value:e.value}})}),1),e._v(" "),a("input",{directives:[{name:"model",rawName:"v-model",value:e.skuOrFnsku,expression:"skuOrFnsku"}],ref:"scanInput",staticClass:"scan_right_input",attrs:{placeholder:e.inputPlaceholder},domProps:{value:e.skuOrFnsku},on:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSubmit.apply(null,arguments)},input:function(t){t.target.composing||(e.skuOrFnsku=t.target.value)}}}),e._v(" "),a("button",{staticClass:"submitBtn",on:{click:e.handleSubmit}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.confirm")))]),e._v(" "),a("el-button",{staticClass:"text_btn_f16",attrs:{type:"text"},on:{click:function(t){e.dialogShopVisible=!0}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.select.product")))])],1),e._v(" "),a("div",{staticClass:"model_data_no"},[a("div",[a("div",{staticClass:"f_12 f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.select.product.first")))])])])]),e._v(" "),a("el-dialog",{attrs:{title:e.$t("main.warehouse.scan.arrive.sku.select.product"),visible:e.dialogShopVisible,"close-on-click-modal":!1,"append-to-body":!1,modal:!1,"custom-class":"dialog_small"},on:{"update:visible":function(t){e.dialogShopVisible=t}}},[a("SearchBar",{ref:"searchBar",staticClass:"mb_12",attrs:{options:e.searchOptions},on:{"on-change":e.filterChange}}),e._v(" "),e.shopData?a("vxe-table",{attrs:{data:e.shopData,"sync-resize":"",height:"340px",round:""},scopedSlots:e._u([{key:"empty",fn:function(){return[a("div",{staticClass:"model_data_no"},[a("div",[a("div",{staticClass:"f_14 f_gray"},[e._v(e._s(e.$t("main.fba.scan.packing.common.no.data")))])])])]},proxy:!0}],null,!1,0x822d64da)},[a("vxe-table-column",{attrs:{title:e.$t("common.image"),width:e.getI18nColumnWidth("70")},scopedSlots:e._u([{key:"default",fn:function(e){var t=e.row;return[a("ImgBox",{attrs:{src:t.mainImage,option:"dialog",iconType:t.isGroup}})]}}],null,!1,0xf1af2b6a)}),e._v(" "),a("vxe-table-column",{attrs:{title:e.$t("main.warehouse.scan.arrive.sku.product.name"),"min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row;return[a("div",{staticClass:"line_clamp"},[a("span",{directives:[{name:"single-popover",rawName:"v-single-popover",value:{refName:"tipsPopoverRef",data:r.commodityName,dataName:"contentTips"},expression:"{ refName: 'tipsPopoverRef', data: row.commodityName, dataName: 'contentTips' }"}]},[e._v("\n "+e._s(r.commodityName||"-")+"\n ")])])]}}],null,!1,0x1514333a)}),e._v(" "),a("vxe-table-column",{attrs:{title:"SKU","min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row;return[a("div",{staticClass:"f_gray line_clamp"},[a("span",{directives:[{name:"single-popover",rawName:"v-single-popover",value:{refName:"tipsPopoverRef",data:r.sku,dataName:"
1contentTips"},expression:"{ refName: 'tipsPopoverRef', data: row.sku, dataName: 'contentTips' }"}]},[e._v("\n "+e._s(r.sku||"-")+"\n ")])])]}}],null,!1,0xd1a4b187)}),e._v(" "),a("vxe-table-column",{attrs:{title:e.$t("main.warehouse.scan.arrive.sku.identification.code"),"min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row;return[a("div",{staticClass:"f_gray line_clamp"},[a("span",{directives:[{name:"single-popover",rawName:"v-single-popover",value:{refName:"tipsPopoverRef",data:r.identificationCode,dataName:"contentTips"},expression:"{ refName: 'tipsPopoverRef', data: row.identificationCode, dataName: 'contentTips' }"}]},[e._v("\n "+e._s(r.identificationCode||"-")+"\n ")])])]}}],null,!1,0xbcedbfad)}),e._v(" "),a("vxe-table-column",{attrs:{title:e.$t("common.category"),"min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row;return[a("span",[e._v(e._s(r.fullName||"-"))])]}}],null,!1,0xf3309dbd)}),e._v(" "),a("vxe-table-column",{attrs:{title:e.$t("common.operation"),width:e.getI18nColumnWidth("56")},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row;return[a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.handleChoose(r)}}},[e._v(e._s(e.$t("common.select")))])]}}],null,!1,0x72128a13)})],1):e._e(),e._v(" "),a("div",{staticClass:"page_paging"},[a("Pagination",{attrs:{paginator:e.paginator},on:{"page-change":e.onPageChange}})],1),e._v(" "),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.dialogShopVisible=!1}}},[e._v(e._s(e.$t("common.close")))])],1)],1),e._v(" "),a("el-dialog",{attrs:{title:e.$t("main.warehouse.scan.arrive.sku.select.sku"),width:"600px",visible:e.alertVisible,"close-on-click-modal":!1,"append-to-body":!1,modal:!1},on:{"update:visible":function(t){e.alertVisible=t}}},[a("div",{staticClass:"alert_text mb_12"},[a("i",{staticClass:"el-icon-info"}),e._v(" "),a("p",[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.multiple.match.prefix"))+" "),a("span",[e._v(e._s(e.skuOrFnsku))]),e._v(" "+e._s(e.$t("main.warehouse.scan.arrive.sku.multiple.match.suffix")))])]),e._v(" "),a("vxe-table",{attrs:{data:e.repeatData,round:""}},[a("vxe-table-column",{attrs:{title:e.$t("common.image"),width:e.getI18nColumnWidth("70")},scopedSlots:e._u([{key:"default",fn:function(e){return[a("ImgBox",{attrs:{src:e.row.mainImage,option:"dialog"}})]}}])}),e._v(" "),a("vxe-table-column",{attrs:{title:e.$t("main.warehouse.scan.arrive.sku.product.name"),"min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row;return[a("div",{staticClass:"line_clamp"},[e._v("\n "+e._s(r.commodityName||"-")+"\n ")])]}}])}),e._v(" "),a("vxe-table-column",{attrs:{title:"SKU","min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.row,i=t.rowIndex;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:r.sku,expression:"row.sku"}],staticClass:"f_gray line_clamp"},[a("el-radio",{attrs:{label:i},model:{value:e.radioResult,callback:function(t){e.radioResult=t},expression:"radioResult"}},[e._v(e._s(r.sku||"-"))])],1)]}}])})],1),e._v(" "),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.alertVisible=!1}}},[e._v(e._s(e.$t("common.close")))]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.handleChooseSku}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.sku.confirm")))])],1)],1),e._v(" "),a("SinglePopover",{ref:"tipsPopoverRef",attrs:{content:e.contentTips,options:{placement:"top",trigger:"hover",className:"popover_max_width_350"}}})],1)},[],!1,null,"71ebe2f6",null).exports;a(47424),a(59622);var e5=a(72717);function e7(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r}var e8={data:function(){return{vxeGridTableColumnList:[]}},computed:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},(0,h.mapState)("Socket",{purchaseQualityStatus:function(e){return e.purchaseQualityStatus},shelfFlag:function(e){return e.shelfFlag},purchaseArrivalStatus:function(e){return e.purchaseArrivalStatus}})),methods:{initColumns:function(){var e=this,t=[{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.order.no"),field:"purchaseNo",showOverflow:!0,params:{columnName:"purchaseNo",fixedVisible:!0},slots:{default:"purchaseNo_default"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.waybill.no"),field:"logisticsBillNoList",showOverflow:!0,params:{columnName:"logisticsBillNoList",fixedVisible:!0},slots:{default:"logisticsBillNoList_default"}},{minWidth:150,title:(0,g.Tl)("common.create.time"),field:"createTime",showOverflow:!0,className:"column_header",headerClassName:"column_header",params:{columnName:"createTime",fixedVisible:!0},slots:{default:"createTime_default"}},{minWidth:150,title:(0,g.Tl)("main.warehouse.scan.arrive.expected.arrival.time"),field:"expectArrivalTime",showOverflow:!0,params:{columnName:"expectArrivalTime"},slots:{default:"expectArrivalTime_default"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.shop.fnsku"),field:"shopName",showOverflow:!0,params:{columnName:"shopName",fixedVisible:!0},slots:{default:"shopName_default"}},{minWidth:140,title:"MSKU",field:"shopName",showOverflow:!0,params:{columnName:"msku",fixedVisible:!0},slots:{default:"msku_default"}},{minWidth:80,title:(0,g.Tl)("main.warehouse.scan.arrive.purchase.quantity"),field:"num",align:"right",showOverflow:!0,params:{columnName:"num"},slots:{default:"num_default"}},{minWidth:80,title:(0,g.Tl)("main.warehouse.scan.arrive.pending.arrival.quantity"),field:"waitNum",align:"right",showOverflow:!0,params:{columnName:"waitNum",fixedVisible:!0},slots:{default:"waitNum_default"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.good.quantity"),field:"goods",showOverflow:!0,visible:!this.purchaseQualityStatus,params:{columnName:"goods",visibleNot:this.purchaseQualityStatus},slots:{default:"goods_default",header:"goods_header",footer:"goods_footer"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.defective.quantity"),field:"defective",showOverflow:!0,visible:!this.purchaseQualityStatus,params:{columnName:"defective",visibleNot:this.purchaseQualityStatus},slots:{default:"defective_default",header:"defective_header",footer:"defective_footer"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.current.arrival.quantity"),field:"arrivals",showOverflow:!0,visible:this.purchaseQualityStatus,params:{columnName:"arrivals",visibleNot:!this.purchaseQualityStatus},slots:{default:"arrivals_default",header:"arrivals_header",footer:"arrivals_footer"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.available.shelf.location"),field:"shelf
1NoAvailable",visible:this.shelfFlag,resizable:!0,params:{columnName:"shelfNoAvailable",visibleNot:!this.shelfFlag},slots:{default:"shelfNoAvailable_default",header:"shelfNoAvailable_header"}},{minWidth:160,title:(0,g.Tl)("main.warehouse.scan.arrive.defective.shelf.location"),field:"shelfNoDefective",visible:this.shelfFlag&&!this.purchaseQualityStatus,resizable:!0,params:{columnName:"shelfNoDefective",visibleNot:!this.shelfFlag},slots:{default:"shelfNoDefective_default",header:"shelfNoDefective_header"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.abnormal.quantity"),field:"errorNum",params:{columnName:"errorNum"},slots:{default:"errorNum_default",header:"errorNum_header"}},{minWidth:100,title:(0,g.Tl)("main.warehouse.scan.arrive.abnormal.type"),field:"errorType",params:{columnName:"errorType"},slots:{default:"errorType_default"}}],a=this.$dcopy(t);a.forEach(function(t,a){0!==a&&e.$set(t.params,"order",a)}),this.vxeGridTableColumnList=function(e){if(Array.isArray(e))return e7(e)}(a)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||function(e){if(e){if("string"==typeof e)return e7(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return e7(e,void 0)}}(a)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},created:function(){this.initColumns()}};function e9(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function te(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){e9(s,r,i,n,o,"next",e)}function o(e){e9(s,r,i,n,o,"throw",e)}n(void 0)})}}function tt(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}function ta(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){tt(e,t,a[t])})}return e}function tr(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}function ti(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}var ts={name:"SkuArriveList",mixins:[eS.A,e8,e$.A],components:{ShelfRemoteSelect:eN.A,MskuList:ed.A,PrintCommoditySku:ec.A,PrintTemplateDialog:eu.A,PrintTemplateReceipt:eh.A,PopoverContainer:m.A},props:{purchaseList:Array,isNeedQc:Number},data:function(){return{contentTips:"",VTRefName:"purchaseList",ccVxeTableKey:this.getPageKeyByName("\u5F85\u5230\u8D27>SKU\u626B\u63CF\u5230\u8D27"),printAssembleSheetBtnOptions:{options:[{value:"batchPrintTemplate",label:this.$t("main.warehouse.scan.arrive.print.sku.label.by.template"),permission:"MOD_WAREHOUSE_TO_ARRIVE.PRINT_SKU_FNSKU_LABEL"},{value:"batchPrintTemplateFnSku",label:this.$t("main.warehouse.scan.arrive.print.fnsku.label.by.template"),permission:"MOD_WAREHOUSE_TO_ARRIVE.PRINT_SKU_FNSKU_LABEL"}],title:this.$t("main.warehouse.scan.arrive.print.operation"),btnType:"text"},printTemplateDialog:{visible:!1,value:null,groupData:null},printTemplateFnSkuDialog:{visible:!1,value:null},printTemplateByReceipt:{visible:!1,value:null},shelfNoAvailableBatch:{val:""},shelfNoDefectiveBatch:{val:""},shelfNoAvailableBatchList:[],shelfNoDefectiveBatchList:[],batchShelfOptionsLoaded:!1}},computed:tr(ta({},(0,h.mapState)("Socket",{purchaseQualityStatus:function(e){return e.purchaseQualityStatus},purchaseArrivalStatus:function(e){return e.purchaseArrivalStatus},shelfFlag:function(e){return e.shelfFlag},upShelfManage:function(e){return e.upShelfManage}})),{goodsTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.purchaseList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.goods)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},defectiveTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.purchaseList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.defective)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},arrivalsTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.purchaseList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.arrivals)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},showBatchBtn:function(){return this.shelfFlag&&!this.upShelfManage&&!this.purchaseQualityStatus}}
1),mounted:function(){this.initVTCConfig()},watch:{purchaseList:{handler:function(e){!this.batchShelfOptionsLoaded&&(null==e?void 0:e.length)&&e.some(function(e){return!e.isQuickRow})&&(this.loadBatchShelfOptions(),this.batchShelfOptionsLoaded=!0)},immediate:!0}},methods:{colspanMethod:function(e){var t=e.row,a=e.rowIndex,r=e.columnIndex,i=t.item.length,s=t.isParentGroup&&a;return a===s&&r<3?{rowspan:i,colspan:1}:r<3?{rowspan:0,colspan:0}:void 0},arrivalNumHandle:function(e){this.purchaseList.map(function(t){var a=0;"goods"===e?((a=t.waitNum-Number(t.defective))<0&&(a=0),t.goods=a):"defective"===e?((a=t.waitNum-Number(t.goods))<0&&(a=0),t.defective=a):"arrivals"===e&&((a=t.waitNum)<0&&(a=0),t.arrivals=a)})},shelfNoAvailableChange:function(e,t){var a,r,i=null==(r=t.availableShelfOptions)||null==(a=r.options)?void 0:a.find(function(t){return t.value===e});t.shelfNoAvailableId=(null==i?void 0:i.shelfId)||""},shelfNoDefectiveChange:function(e,t){var a,r,i=null==(r=t.defectiveShelfOptions)||null==(a=r.options)?void 0:a.find(function(t){return t.value===e});t.shelfNoDefectiveId=(null==i?void 0:i.shelfId)||""},updateAvailableShelfOptions:function(e,t){this.$set(t.availableShelfOptions,"options",e||[])},updateDefectiveShelfOptions:function(e,t){this.$set(t.defectiveShelfOptions,"options",e||[])},buildShelfRemoteParams:function(e){return[{commodityId:e.commodityId,warehouseId:e.warehouseId,fnsku:e.fnsku||e.fnSku,shopId:e.shopId,platform:e.platform,exclusiveType:e.exclusiveType}]},buildBatchShelfRemoteParams:function(e){var t,a,r=e.shelfNo,i=e.shelfType;return[{warehouseId:null!=(t=null==(a=this.purchaseList[0])?void 0:a.warehouseId)?t:null,batch:!0,shelfNo:r,shelfType:i}]},loadBatchShelfOptions:function(){return te(function(){var e,t,a,r,i,s;return ti(this,function(n){switch(n.label){case 0:if(!(t=null==(e=this.purchaseList[0])?void 0:e.warehouseId))return[2];n.label=1;case 1:return n.trys.push([1,3,,4]),[4,this.$http.getRecommendShelfForStockIn([{warehouseId:t,batch:!0}])];case 2:return(r=null==(a=n.sent())?void 0:a[0])?(this.shelfNoAvailableBatchList=((null==(i=r.available)?void 0:i.related)||[]).map(function(e){return{label:e.shelfNo,value:e.shelfNo}}),this.shelfNoDefectiveBatchList=((null==(s=r.defective)?void 0:s.related)||[]).map(function(e){return{label:e.shelfNo,value:e.shelfNo}})):(this.shelfNoAvailableBatchList=[],this.shelfNoDefectiveBatchList=[]),[3,4];case 3:return n.sent(),[3,4];case 4:return[2]}})}).call(this)},singleArrivalNumHandle:function(e,t){var a=0;"goods"===e?((a=t.waitNum-Number(t.defective))<0&&(a=0),t.goods=a):"defective"===e?((a=t.waitNum-Number(t.goods))<0&&(a=0),t.defective=a):"arrivals"===e&&((a=t.waitNum)<0&&(a=0),t.arrivals=a)},inputVerify:function(e,t){if(e[t]&&(e[t]=this.$utils.integerVerification(e[t])),!this.purchaseArrivalStatus){if(this.purchaseQualityStatus){e[t]>e.waitNum&&(e[t]=e.waitNum);return}if("goods"===t){var a=e.waitNum-Number(e.defective);e[t]>a&&(e[t]=a)}else{var r=e.waitNum-Number(e.goods);e[t]>r&&(e[t]=r)}}},disposeSelectIds:function(){return this.purchaseList.map(function(e){return e.id})},printPageName:function(e){if(0===this.disposeSelectIds().length)return void this.$message.error(this.$t("main.warehouse.scan.arrive.select.purchase.order"));switch(e){case"batchPrintTemplate":this.batchPrintTemplate("batch");break;case"batchPrintTemplateFnSku":this.batchPrintTemplate("batch",null,"fnsku");break;case"batchPrintTemplateReceipt":this.batchPrintTemplateReceipt()}},batchPrintTemplate:function(e,t,a){return te(function(){var t,r,i,s,n,o,l,c;return ti(this,function(u){switch(u.label){case 0:t="fnsku"===a,u.label=1;case 1:return u.trys.push([1,3,4,5]),this.$loading(),r=[],i=[],s=tt({},{batch:"itemIdList"}[e],{batch:this.disposeSelectIds()}[e]),n={batch:this.$http.getInfoForPrintItemSku},[4,(t?this.$http.getDataForPrintFnsku:n[e])(s)];case 2:return o=u.sent(),l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"-",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"";null==t||t.forEach(function(t){"batchArrival"===e?a.push(tr(ta({},t),{printNum:t.arrivalNum,sn:r,supplierName:i})):a.push(tr(ta({},t),{printNum:t.waitNum,sn:r,supplierName:i}))})},o&&o.forEach(function(e){var a=t?"purchaseFnskus":"purchaseSkus";e[a]&&(l(e[a],r,e.purchaseNo,e.supplierName),l(e.assemblePurchaseSkus,i,e.purchaseNo,e.supplierName))}),t?(this.printTemplateFnSkuDialog.value=r,this.printTemplateFnSkuDialog.visible=!0):(this.printTemplateDialog.value=r,this.printTemplateDialog.groupData=i,this.printTemplateDialog.visible=!0),[3,5];case 3:return c=u.sent(),this.$message.handle(c),[3,5];case 4:return this.$loading().close(),[7];case 5:return[2]}})}).call(this)},batchPrintTemplateReceipt:function(){var e=[];this.purchaseNoList.map(function(t){return e.push({receipt:t.purchaseNo,id:t.id}),t}),this.printTemplateByReceipt.visible=!0,this.printTemplateByReceipt.value=e},shelfNoAvailableBatchChange:function(){var e=this;this.purchaseList.forEach(function(t){t.shelfNoAvailable=e.shelfNoAvailableBatch.val,e.shelfNoAvailableChange(t.shelfNoAvailable,t)})}
1,shelfNoDefectiveBatchChange:function(){var e=this;this.purchaseList.forEach(function(t){t.shelfNoDefective=e.shelfNoDefectiveBatch.val,e.shelfNoDefectiveChange(t.shelfNoDefective,t)})}}},tn=(0,$.A)(ts,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"table_wrap"},[a("div",{staticClass:"scan_detail_title flex between mb_12"},[a("span",{staticClass:"title"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.list")))]),e._v(" "),a("ul",{staticClass:"sum"},[e.purchaseQualityStatus?e._e():a("li",[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.good.quantity.arrival.summary"))),a("span",{class:{fw_600:e.goodsTotal}},[e._v(e._s(e.goodsTotal))])]),e._v(" "),e.purchaseQualityStatus?e._e():a("li",[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.defective.quantity.arrival.summary"))),a("span",{class:{fw_600:e.defectiveTotal}},[e._v(e._s(e.defectiveTotal))])]),e._v(" "),e.purchaseQualityStatus?a("li",[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.current.arrival.quantity.summary"))),a("span",{class:{fw_600:e.arrivalsTotal}},[e._v(e._s(e.arrivalsTotal))])]):e._e(),e._v(" "),a("li",[a("myj-button",{attrs:{options:e.printAssembleSheetBtnOptions,tagName:"UiDropdownBtn"},on:{command:function(t){return e.printPageName(t)}}})],1),e._v(" "),a("li",{staticClass:"btn_square_icon",attrs:{title:e.$t("main.warehouse.scan.arrive.configure.table.fields")},on:{click:e.showCustomColumnDL}},[a("i",{staticClass:"icon_sf_set"})])])]),e._v(" "),a("vxe-grid",{ref:"purchaseList",attrs:{data:e.purchaseList,columns:e.vxeGridTableColumnList,round:"","auto-resize":"",resizable:"","highlight-hover-row":"","highlight-current-row":"","show-header-overflow":"title","span-method":e.colspanMethod},scopedSlots:e._u([{key:"purchaseNo_default",fn:function(t){var r=t.row;return[a("span",[e._v(e._s(r.purchaseNo))]),e._v(" "),r.isExpediting?a("span",{staticClass:"expedited_cls"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.urgent")))]):e._e()]}},{key:"logisticsBillNoList_default",fn:function(t){var r=t.row;return[r.logisticsBillNoList&&r.logisticsBillNoList.length>1?a("div",[a("el-popover",{attrs:{width:"150",trigger:"hover"}},[a("ul",e._l(r.logisticsBillNoList,function(t){return a("li",{key:t},[e._v(e._s(t))])}),0),e._v(" "),a("div",{attrs:{slot:"reference"},slot:"reference"},[a("span",[e._v(e._s(r.logisticsBillNoList[0]))]),e._v(" "),a("i",{staticClass:"el-icon-arrow-down"})])])],1):r.logisticsBillNoList?a("span",[e._v(e._s(r.logisticsBillNoList[0]))]):a("span",[e._v("-")])]}},{key:"createTime_default",fn:function(t){var a=t.row;return[e._v("\n "+e._s(a.createTime||"-")+"\n ")]}},{key:"expectArrivalTime_default",fn:function(t){var a=t.row;return[e._v("\n "+e._s(a.expectArrivalTime||"-")+"\n ")]}},{key:"shopName_default",fn:function(t){var r=t.row;return[a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light",value:r.shopName,expression:"row.shopName",arg:"light"}],staticClass:"line_clamp"},[e._v(e._s(r.shopName||"-"))]),e._v(" "),a("div",{directives:[{name:"tooltip",rawName:"v-tooltip:light",value:r.fnsku,expression:"row.fnsku",arg:"light"}],staticClass:"f_gray line_clamp"},[e._v(e._s(r.fnsku||"-"))])]}},{key:"msku_default",fn:function(e){return[a("MskuList",{attrs:{list:e.row.msku}})]}},{key:"num_default",fn:function(t){var r=t.row;return[a("span",{staticStyle:{"vertical-align":"text-bottom"}},[r.isGift?a("i",{staticClass:"icon_zeng"}):e._e()]),e._v(" "),a("span",[e._v(e._s(r.num||"-"))])]}},{key:"waitNum_default",fn:function(t){var a=t.row;return[e._v("\n "+e._s(a.waitNum)+"\n ")]}},{key:"goods_header",fn:function(){return[a("div",[a("span",{staticClass:"mr_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.good.quantity")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.arrivalNumHandle("goods")}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.remaining.all.arrived")))])],1)]},proxy:!0},{key:"goods_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex center_align"},[a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("common.please.input")},on:{input:function(t){return e.inputVerify(r,"goods")}},model:{value:r.goods,callback:function(t){e.$set(r,"goods",t)},expression:"row.goods"}}),e._v(" "),a("el-popover",{attrs:{placement:"top",trigger:"hover",content:e.$t("main.warehouse.scan.arrive.remaining.all.arrived")}}
1,[a("i",{staticClass:"icon_all_01 f_blue pointer f_14",attrs:{slot:"reference"},on:{click:function(t){return e.singleArrivalNumHandle("goods",r)}},slot:"reference"})])],1)]}},{key:"defective_header",fn:function(){return[a("div",[a("span",{staticClass:"mr_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.defective.quantity")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.arrivalNumHandle("defective")}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.remaining.all.arrived")))])],1)]},proxy:!0},{key:"defective_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex center_align"},[a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("common.please.input")},on:{input:function(t){return e.inputVerify(r,"defective")}},model:{value:r.defective,callback:function(t){e.$set(r,"defective",t)},expression:"row.defective"}}),e._v(" "),a("el-popover",{attrs:{placement:"top",trigger:"hover",content:e.$t("main.warehouse.scan.arrive.remaining.all.arrived")}},[a("i",{staticClass:"icon_all_01 f_blue pointer f_14",attrs:{slot:"reference"},on:{click:function(t){return e.singleArrivalNumHandle("defective",r)}},slot:"reference"})])],1)]}},{key:"arrivals_header",fn:function(){return[a("div",[a("span",{staticClass:"mr_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.current.arrival.quantity")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:function(t){return e.arrivalNumHandle("arrivals")}}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.remaining.all.arrived")))])],1)]},proxy:!0},{key:"arrivals_default",fn:function(t){var r=t.row;return[a("div",{staticClass:"flex center_align"},[a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("common.please.input")},on:{input:function(t){return e.inputVerify(r,"arrivals")}},model:{value:r.arrivals,callback:function(t){e.$set(r,"arrivals",t)},expression:"row.arrivals"}}),e._v(" "),a("el-popover",{attrs:{placement:"top",trigger:"hover",content:e.$t("main.warehouse.scan.arrive.remaining.all.arrived")}},[a("i",{staticClass:"icon_all_01 f_blue pointer f_14",attrs:{slot:"reference"},on:{click:function(t){return e.singleArrivalNumHandle("arrivals",r)}},slot:"reference"})])],1)]}},{key:"shelfNoAvailable_header",fn:function(t){var r=t.column.title;return[a("span",[e._v(e._s(r))]),e._v(" "),e.showBatchBtn?a("PopoverContainer",{attrs:{"show-footer":""},on:{"on-change":e.shelfNoAvailableBatchChange},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("el-button",{attrs:{type:"text"}},[e._v(e._s(e.$t("common.batch")))])]},proxy:!0}],null,!0)},[e._v(" "),a("ShelfRemoteSelect",{attrs:{width:"200","shelf-type":0,options:{options:e.shelfNoAvailableBatchList},"select-props":{placeholder:e.$t("common.select.placeholder")},"build-params":e.buildBatchShelfRemoteParams,"hide-stock":""},model:{value:e.shelfNoAvailableBatch.val,callback:function(t){e.$set(e.shelfNoAvailableBatch,"val",t)},expression:"shelfNoAvailableBatch.val"}})],1):e._e()]}},{key:"shelfNoAvailable_default",fn:function(t){var r=t.row;return[a("ShelfRemoteSelect",{attrs:{"shelf-type":0,options:r.availableShelfOptions&&r.availableShelfOptions.options,"select-props":r.availableShelfOptions,params:e.buildShelfRemoteParams(r),"format-options-config":{otherKey:"shelfId"},"use-new-shelf-select":"",disabled:r.isNeedQc&&e.purchaseQualityStatus||e.upShelfManage},on:{"on-change":function(t){return e.shelfNoAvailableChange(t,r)},"remote-options-change":function(t){return e.updateAvailableShelfOptions(t,r)}},model:{value:r.shelfNoAvailable,callback:function(t){e.$set(r,"shelfNoAvailable",t)},expression:"row.shelfNoAvailable"}})]}},{key:"shelfNoDefective_header",fn:function(t){var r=t.column.title;return[a("span",[e._v(e._s(r))]),e._v(" "),e.showBatchBtn?a("PopoverContainer",{attrs:{"show-footer":""},on:{"on-change":e.shelfNoDefectiveBatchChange},scopedSlots:e._u([{key:"trigger",fn:function(){return[a("el-button",{attrs:{type:"text"}},[e._v(e._s(e.$t("common.batch")))])]},proxy:!0}],null,!0)},[e._v(" "),a("ShelfRemoteSelect",{attrs:{width:"200","shelf-type":1,options:{options:e.shelfNoDefectiveBatchList},"select-props":{placeholder:e.$t("common.select.placeholder")},"build-params":e.buildBatchShelfRemoteParams,"hide-stock":""},model:{value:e.shelfNoDefectiveBatch.val,callback:function(t){e.$set(e.shelfNoDefectiveBatch,"val",t)}
1,expression:"shelfNoDefectiveBatch.val"}})],1):e._e()]}},{key:"shelfNoDefective_default",fn:function(t){var r=t.row;return[a("ShelfRemoteSelect",{attrs:{"shelf-type":1,options:r.defectiveShelfOptions&&r.defectiveShelfOptions.options,"select-props":r.defectiveShelfOptions,params:e.buildShelfRemoteParams(r),"format-options-config":{otherKey:"shelfId"},"use-new-shelf-select":"",disabled:e.upShelfManage},on:{"on-change":function(t){return e.shelfNoDefectiveChange(t,r)},"remote-options-change":function(t){return e.updateDefectiveShelfOptions(t,r)}},model:{value:r.shelfNoDefective,callback:function(t){e.$set(r,"shelfNoDefective",t)},expression:"row.shelfNoDefective"}})]}},{key:"errorNum_header",fn:function(){return[a("span",[e._v(e._s(e.$t("main.warehouse.scan.arrive.abnormal.quantity")))]),e._v(" "),a("i",{directives:[{name:"tooltip",rawName:"v-tooltip",value:e.$t("main.warehouse.scan.arrive.abnormal.quantity.tip"),expression:"$t('main.warehouse.scan.arrive.abnormal.quantity.tip')"}],staticClass:"icon_sf_help f_16"})]},proxy:!0},{key:"errorNum_default",fn:function(t){var r=t.row;return[r.isNeedQc&&e.purchaseQualityStatus?a("span",[e._v("-")]):a("el-input",{staticClass:"mr_4",attrs:{placeholder:e.$t("common.please.input")},on:{input:function(t){return e.inputVerify(r,"abnormal")}},model:{value:r.abnormal,callback:function(t){e.$set(r,"abnormal",t)},expression:"row.abnormal"}})]}},{key:"errorType_default",fn:function(t){var r=t.row;return[r.isNeedQc&&e.purchaseQualityStatus?a("span",[e._v("-")]):a("el-select",{attrs:{value:"",placeholder:e.$t("common.please.select"),clearable:""},model:{value:r.abnormalType,callback:function(t){e.$set(r,"abnormalType",t)},expression:"row.abnormalType"}},[a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.over.arrival"),value:"1"}}),e._v(" "),a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.incoming.defective"),value:"2"}}),e._v(" "),a("el-option",{attrs:{label:e.$t("main.warehouse.scan.arrive.goods.not.match.sample"),value:"3"}})],1)]}},{key:"empty",fn:function(){return[a("div",{staticClass:"model_data_no"},[a("div",[a("div",{staticClass:"f_14 f_gray"},[e._v(e._s(e.$t("common.no.data")))])])])]},proxy:!0}])}),e._v(" "),a("CustomColumnsNew",{ref:"customColumnsNewDL",attrs:{fullColumn:e.ccFullColumn,visible:e.ccDLVisible,vxeTableKey:e.ccVxeTableKey,"draggable-sort":!0,showAllbtn:""},on:{"update:fullColumn":function(t){e.ccFullColumn=t},"update:full-column":function(t){e.ccFullColumn=t},"update:visible":function(t){e.ccDLVisible=t},"update:vxeTableKey":function(t){e.ccVxeTableKey=t},"update:vxe-table-key":function(t){e.ccVxeTableKey=t},"on-save-hide":e.customColumnSaveHandle}}),e._v(" "),a("print-commodity-sku",{attrs:{data:e.printData,visible:e.printVisible,"bind-name":"waitNum","item-name":"purchaseSkus","page-type":"purchase",printGroup:""},on:{"update:visible":function(t){e.printVisible=t}}}),e._v(" "),a("PrintTemplateDialog",{attrs:{visible:e.printTemplateDialog.visible,groupData:e.printTemplateDialog.groupData,value:e.printTemplateDialog.value,templateType:"sku",printGroup:""},on:{"update:visible":function(t){return e.$set(e.printTemplateDialog,"visible",t)}}}),e._v(" "),a("PrintTemplateDialog",{attrs:{value:e.printTemplateFnSkuDialog.value,visible:e.printTemplateFnSkuDialog.visible,"template-type":"fnsku"},on:{"update:visible":function(t){return e.$set(e.printTemplateFnSkuDialog,"visible",t)}}}),e._v(" "),a("PrintTemplateReceipt",{attrs:{visible:e.printTemplateByReceipt.visible,value:e.printTemplateByReceipt.value,showNoPurchaseNum:"",templateType:"toBeDeliveredItem",oldTemplateType:"toBeDelivered"},on:{"update:visible":function(t){return e.$set(e.printTemplateByReceipt,"visible",t)}}})],1)},[],!1,null,"2140dbcc",null).exports;function to(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,r=Array(t);a<t;a++)r[a]=e[a];return r}function tl(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function tc(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var s=e.apply(t,a);function n(e){tl(s,r,i,n,o,"next",e)}function o(e){tl(s,r,i,n,o,"throw",e)}n(void 0)})}}function tu(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function th(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t}
1)(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}function tp(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}var tf={name:"ScanDetail",inject:["clearPurchaseNum","msgBox","messageVNode","tabListFnClose"],components:{ImgBox:ep.A,SkuArriveList:tn,Selector:e5.A,WarehouseSelectorNew:T.A},mixins:[f.A],props:{purchaseData:Object},data:function(){return{dialogSupplierVisible:!1,supplierOptions:{filterable:!0,placeholder:this.$t("main.warehouse.scan.arrive.select.supplier")},supplierFrom:{supplier:"",showSelectErr:!1},supplier:"",supplierReal:"",showSelectErr:!1,supplierArr:[],warehouseId:"",searchValue:"",selectVal:ez,selectOptions:eJ,arriveNum:0,commodityData:{},purchaseList:[],fnskuList:[],conversionSKUCacheForSaiHe:new Map}},computed:th(tu({},(0,h.mapState)("Socket",{allowPurchaseToOverseasWarehouseStatus:function(e){return e.allowPurchaseToOverseasWarehouseStatus},purchaseQualityStatus:function(e){return e.purchaseQualityStatus},purchaseArrivalStatus:function(e){return e.purchaseArrivalStatus},purchase1688OverArrivalType:function(e){return e.purchase1688OverArrivalType},purchaseOverArrivalType:function(e){return e.purchaseOverArrivalType},warehouseUpShelfOrderType:function(e){return e.warehouseUpShelfOrderType},shelfFlag:function(e){return e.shelfFlag},upShelfManage:function(e){return e.upShelfManage}}),(0,h.mapState)("ScanArrive",{skuSupplierArr:function(e){return e.skuSupplierArr},skuSupplierId:function(e){return e.skuSupplierId},skuArriveNum:function(e){return e.skuArriveNum}})),{goodsTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.purchaseList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.goods)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},defectiveTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.purchaseList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.defective)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},arrivalsTotal:function(){var e=0,t=!0,a=!1,r=void 0;try{for(var i,s=this.purchaseList[Symbol.iterator]();!(t=(i=s.next()).done);t=!0){var n=i.value;e+=Number(n.arrivals)}}catch(e){a=!0,r=e}finally{try{t||null==s.return||s.return()}finally{if(a)throw r}}return e},distributionDisable:function(){return this.purchaseQualityStatus?this.arriveNum&&this.arriveNum>this.arrivalsTotal:this.arriveNum&&this.arriveNum>Number(this.goodsTotal)+Number(this.defectiveTotal)},warehouseTypes:function(){return this.allowPurchaseToOverseasWarehouseStatus?[1,3]:[1]},inputPlaceholder:function(){switch(this.selectVal){case ez:return this.$t("main.warehouse.scan.arrive.scan.or.enter.sku");case eG:return this.$t("main.warehouse.scan.arrive.scan.or.enter.fnsku");case eK:return this.$t("main.warehouse.scan.arrive.scan.or.enter.product.code")}},isNeedQc:function(){return this.commodityData.isNeedQc}}
1),watch:{supplierReal:function(e){this.getWaitSearch(),this.setSupplierIdData(e)},arriveNum:function(e){this.setSkuArriveNum(e)},dialogSupplierVisible:function(e){e||""!==this.supplierReal||(this.showSelectErr=!0)},"supplierFrom.supplier":{handler:function(e){""!==e&&(this.supplierFrom.showSelectErr=!1)}}},created:function(){this.$utils.addVUEXModule("ScanArrive"),this.getSupplier(),this.warehouseId=+this.$route.query.warehouse||""},mounted:function(){this.skuArriveNum&&(this.arriveNum=this.skuArriveNum)},methods:th(tu({},(0,h.mapActions)("ScanArrive",["setSkuSupplierArrData","setSupplierIdData","setSkuArriveNum"])),{getSupplier:function(){return tc(function(){var e,t;return tp(this,function(a){switch(a.label){case 0:if(a.trys.push([0,2,,3]),this.skuSupplierArr&&this.skuSupplierId)return this.supplierArr=this.skuSupplierArr,this.supplier=this.skuSupplierId,this.supplierReal=this.skuSupplierId,this.supplierOptions=th(tu({},this.supplierOptions),{options:this.supplierArr,value:this.supplierReal}),[2];return this.$loading(),[4,this.$http.supplierSearch({warehouseId:this.$route.query.warehouse,sku:this.purchaseData.sku})];case 1:for(var r in e=a.sent(),t=[],e)e.hasOwnProperty(r)&&t.push({label:e[r],value:r});return this.supplierArr=t,this.setSkuSupplierArrData(this.supplierArr),this.supplierOptions=th(tu({},this.supplierOptions),{options:this.supplierArr}),1===this.supplierArr.length?(this.supplier=this.supplierArr[0].value,this.supplierReal=this.supplier,this.$refs.supplierSelect.setData(this.supplierReal)):this.dialogSupplierVisible=!0,this.$loading().close(),[3,3];case 2:return a.sent(),this.$loading().close(),[3,3];case 3:return[2]}})}).call(this)},onSupplierUpdate:function(e){this.supplierFrom.supplier=e},getWaitSearch:function(){return tc(function(){var e,t,a,r,i,s,n;return tp(this,function(o){switch(o.label){case 0:e=this,o.label=1;case 1:return o.trys.push([1,6,,7]),this.$loading(),[4,this.$http.waitSearch({supplierId:this.supplierReal,warehouseId:this.warehouseId,sku:this.purchaseData.sku})];case 2:if(!(t=o.sent()))return[2];if(this.commodityData=t.commodity,this.fnskuList=t.fnskuList,a=new Map,!this.shelfFlag)return[3,5];return r=[],t.list.forEach(function(t){t.item.forEach(function(t){(0,H.IZ)(r,th(tu({},t),{commodityId:e.commodityData.id}),e.warehouseId)})}),[4,this.$http.getWarehouseManageData({id:this.warehouseId})];case 3:return i=o.sent().isBatch,this.isBatch=i,[4,this.getRecommendShelfForStockIn(r)];case 4:s=o.sent(),a=(0,H.Hg)(s),o.label=5;case 5:return n=[],t.list.forEach(function(t){t.purchaseId=t.id,t.item.forEach(function(r,i){if(["arrivals","goods","defective","abnormal","abnormalType"].forEach(function(t){e.$set(r,t,"")}),e.shelfFlag){var s,o,l,c,u,h,p=(0,H.zx)({commodityId:e.commodityData.id,fnSku:r.fnsku||r.fnSku,shopId:r.shopId,platform:r.platform}),f=(null==(s=a.get(p))?void 0:s.available)||{},m=(null==(o=a.get(p))?void 0:o.defective)||{};e.$set(r,"availableShelfOptions",{placeholder:e.$t("common.please.select"),clearable:!0,filterable:!0,includeAll:!0,options:e.$utils.setShelfSelectNew(f.related,{otherKey:"shelfId"})}),e.$set(r,"defectiveShelfOptions",{placeholder:e.$t("common.please.select"),clearable:!0,filterable:!0,includeAll:!0,options:e.$utils.setShelfSelectNew(m.related,{otherKey:"shelfId"})}),t.shelfNoAvailable||(e.isBatch||(l=f.related?null==(c=f.related[0])?void 0:c.shelfNo:""),e.$set(r,"shelfNoAvailable",r.isNeedQc&&e.purchaseQualityStatus||e.upShelfManage?"":l)),t.shelfNoDefective||(e.isBatch||(u=m.related?null==(h=m.related[0])?void 0:h.shelfNo:""),e.$set(r,"shelfNoDefective",r.isNeedQc&&e.purchaseQualityStatus||e.upShelfManage?"":u))}n.push(th(tu({},t,r),{isParentGroup:0===i}))})}),this.purchaseList=n,this.$loading().close(),[3,7];case 6:return o.sent(),this.$loading().close(),this.msgBox({title:this.$t("main.warehouse.scan.arrive.all.arrived"),content:this.$t("main.warehouse.scan.arrive.current.sku.purchase.orders.all.arrived"),icon:"el-icon-success",color:"#67C23A",showCancelButton:!1}).then(function(){e.clearPurchaseNum()}),[3,7];case 7:return[2]}})}).call(this)},handleChangePurchase:function(){var e=this;this.msgBox({title:this.$t("main.warehouse.scan.arrive.confirm.change.product"),content:this.$t("main.warehouse.scan.arrive.change.product.data.lost")}).then(function(){e.clearPurchaseNum()}).catch(function(){})},formatValidVal:function(){return tc(function(){var e,t,a,r,i,s,n,o,l,c,u;return tp(this,function(h){switch(h.label){case 0:if(e=!1,t={},a=this,r=a.searchValue,s=eY[i=a.selectVal],o=(n=this.commodityData).sku,l=n.identificationCode,c=n.commodityCode,u=this.checkSaiHeGrayscalePermission(),!r)throw Error(this.$t("main.warehouse.scan.arrive.scan.or.enter.field",{field:s}));if(!(u&&i!==eG))return[3,2];return[4,this.getConversionSku(r)];case 1:t=h.sent(),h.label=2;case 2:switch(i){case ez:e=u?!(t.identificationCode&&l===t.identificationCode||t.sku&&o===t.sku||l===t.uniqueCode||o===t.uniqueCode):r!==l&&r!==o;break;case eG:e=!this.fnskuList.includes(r);break;case eK:e=u?t.commodityCode&&t.commodityCode!==c||!t.commodityCode&&t.uniqueCode!==c:r!==c}
1return[2,{validTypeFailed:e,msg:s,searchValue:r}]}})}).call(this)},handleSubmit:function(){return tc(function(){var e,t;return tp(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,this.formatValidVal()];case 1:return e=a.sent().validTypeFailed,this.$refs.scanInput.select(),e?(this.handleVideo(this.$t("main.warehouse.scan.arrive.fail")),this.$message.error(this.$t("main.warehouse.scan.arrive.scan.failed"))):this.arriveNumChange(),[3,3];case 2:return t=a.sent(),this.handleVideo(this.$t("main.warehouse.scan.arrive.fail")),this.$message.handle(t),[3,3];case 3:return[2]}})}).call(this)},arriveNumChange:function(e){this.arriveNum<this.commodityData.waitCount||this.purchaseArrivalStatus?(this.arriveNum++,e||this.handleVideo(this.$t("main.warehouse.scan.arrive.success"))):(e||this.handleVideo(this.$t("main.warehouse.scan.arrive.fail")),this.msgBox({title:this.$t("main.warehouse.scan.arrive.over.arrival.forbidden"),content:this.$t("main.warehouse.scan.arrive.scan.quantity.reached.pending.total"),showCancelButton:!1}).then(function(){}))},handleDistribution:function(){var e=this.arriveNum,t=this.purchaseQualityStatus?"arrivals":"goods",a=!0,r=!1,i=void 0;try{for(var s,n=this.purchaseList[Symbol.iterator]();!(a=(s=n.next()).done);a=!0){var o=s.value,l="arrivals"===t?o.waitNum:o.waitNum-Number(o.defective);if(l<0&&(l=0),e<l){o[t]=e,e=0;break}if(o[t]=l,(e-=o.waitNum)<=0)break}}catch(e){r=!0,i=e}finally{try{a||null==n.return||n.return()}finally{if(r)throw i}}if(this.purchaseArrivalStatus&&e){var c=this.purchaseList[this.purchaseList.length-1];c[t]=+c[t]+e}},handleCancel:function(){this.tabListFnClose()},handleScrollEvent:function(e){var t=this.$refs.purchaseList.$refs.purchaseList;t.scrollToRow(this.purchaseList[e]),t.setCurrentRow(this.purchaseList[e])},handleArrive:function(){var e=this;this.$utils.getButtonBuriedPoint.call(this,"purchase_purchaseOrder_scanArrival_SKUArrival_confirm");var t=[],a=[],r={},i=!0,s=!1,n=void 0;try{for(var o,l=this.purchaseList.entries()[Symbol.iterator]();!(i=(o=l.next()).done);i=!0){var c,u=(c=o.value,function(e){if(Array.isArray(e))return e}(c)||function(e){var t,a,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var i=[],s=!0,n=!1;try{for(r=r.call(e);!(s=(t=r.next()).done)&&(i.push(t.value),2!==i.length);s=!0);}catch(e){n=!0,a=e}finally{try{s||null==r.return||r.return()}finally{if(n)throw a}}return i}}(c)||function(e){if(e){if("string"==typeof e)return to(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return to(e,2)}}(c)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),h=u[0],p=u[1];if(!(p.arrivals<=0)||!(p.goods<=0)||!(p.defective<=0)||!(p.abnormal<=0)){if((Number(p.goods)+Number(p.defective)>p.waitNum||p.arrivals>p.waitNum)&&p.isGift){this.$message.error(this.$t("main.warehouse.scan.arrive.gift.arrival.not.greater.pending")),this.handleScrollEvent(h);return}if(p.arrivals>p.waitNum&&"1"!==p.abnormalType&&p.abnormalType){this.$message.error(this.$t("main.warehouse.scan.arrive.arrival.greater.pending.select.over.arrival")),this.handleScrollEvent(h);return}if(+p.abnormal&&!p.abnormalType){this.$message.error(this.$t("main.warehouse.scan.arrive.abnormal.quantity.select.type")),this.handleScrollEvent(h);return}if(p.abnormalType&&!+p.abnormal){this.$message.error(this.$t("main.warehouse.scan.arrive.abnormal.type.enter.quantity")),this.handleScrollEvent(h);return}var f=p.arrivals-p.abnormal!==p.waitNum,m=this.purchaseQualityStatus?+p.arrivals:+p.goods+ +p.defective+ +p.abnormal;if("1"===p.abnormalType){if(0==+p.waitNum){this.$message.error(this.$t("main.warehouse.scan.arrive.completed.not.support.abnormal.order")),this.handleScrollEvent(h);return}if(!this.purchaseQualityStatus&&+p.goods+ +p.defective!=+p.waitNum){this.$message.error(this.$t("main.warehouse.scan.arrive.over.arrival.goods.defective.equal.pending")),this.handleScrollEvent(h);return}if(f&&this.purchaseQualityStatus){this.$message.error(this.$t("main.warehouse.scan.arrive.over.arrival.quantity.minus.abnormal.equal.pending")),this.handleScrollEvent(h);return}}else if(p.abnormal>m){this.$message.error(this.$t("main.warehouse.scan.arrive.abnormal.quantity.less.equal.arrival")),this.handleScrollEvent(h);return}r[p.purchaseId]||(r[p.purchaseId]={purchaseId:p.purchaseId,warehouseId:p.warehouseId,shipFee:p.shipFee,otherFee:p.otherFee,purchaseNo:p.purchaseNo,items:[]}),p.arrivals>p.waitNum?a.push(p.sku):+p.goods+ +p.defective>p.waitNum&&a.push(p.sku),r[p.purchaseId].items.push({purchaseItemId:p.id,ids:p.ids,sku:p.sku,fnSku:p.fnsku,arrivals:p.arrivals||0,goods:p.goods||0,defective:p.defective||0,shelfNoAvailable:p.shelfNoAvailable,shelfNoAvailableId:p.shelf
1NoAvailableId,shelfNoDefective:p.shelfNoDefective,shelfNoDefectiveId:p.shelfNoDefectiveId,abnormal:p.abnormal||0,abnormalType:p.abnormalType,isGift:p.isGift})}}}catch(e){s=!0,n=e}finally{try{i||null==l.return||l.return()}finally{if(s)throw n}}if(a.length&&this.purchaseArrivalStatus){var v=this.$t("main.warehouse.scan.arrive.sku.arrival.greater.pending.confirm",{sku:a.toString()});this.$sfMessage.confirm(v,this.$t("main.warehouse.scan.arrive.confirm.arrival"),{dangerouslyUseHTMLString:!0,type:"warning",confirmHandle:function(){e.doArrival(r,t)}})}else this.doArrival(r,t)},doArrival:function(e,t){return tc(function(){var a,r,i;return tp(this,function(s){switch(s.label){case 0:for(var n in s.trys.push([0,7,,8]),e)e.hasOwnProperty(n)&&t.push(e[n]);if(!t.length)return this.$message.error(this.$t("main.warehouse.scan.arrive.enter.arrival.quantity")),[2];return this.$loading(),[4,this.$http.confirmArrival({list:t,skuOrPurchaseNo:this.commodityData.sku,type:2,allocationVos:[{type:"OVER_ARRIVAL",value:this.purchaseArrivalStatus},{type:"COMMON_PURCHASE_OVER_ARRIVAL",value:this.purchaseOverArrivalType},{type:"ALIBABA_PURCHASE_OVER_ARRIVAL",value:this.purchase1688OverArrivalType},{type:"PURCHASE_QUALITY_INSPECTION",value:+!!this.purchaseQualityStatus},{type:"WAREHOUSE_UP_SHELF_ORDER",value:this.warehouseUpShelfOrderType}]})];case 1:if(null!==(a=s.sent()))return[3,3];return this.$message.success(this.$t("main.warehouse.scan.arrive.arrival.success")),[4,this.getWaitSearch()];case 2:case 4:return s.sent(),[3,6];case 3:if(!this.$isArray(a))return[3,5];return(null==a?void 0:a.length)?(r=a.length>5?"".concat(a.splice(0,5).join(),"..."):a,this.$message.warning(this.$t("main.warehouse.scan.arrive.sku.cumulative.arrival.exceed.exemption",{sku:r.join()}))):this.$message.success(this.$t("main.warehouse.scan.arrive.arrival.success")),[4,this.getWaitSearch()];case 5:this.$message.error(this.$t("main.warehouse.scan.arrive.arrival.failed")),s.label=6;case 6:return this.$loading().close(),[3,8];case 7:return i=s.sent(),this.$message.handle(i),this.$loading().close(),[3,8];case 8:return[2]}})}).call(this)},handleChooseSupplier:function(){if(""===this.supplierFrom.supplier){this.supplierFrom.showSelectErr=!0;return}this.dialogSupplierVisible=!1,this.supplier=this.supplierFrom.supplier,this.supplierReal=this.supplier,this.$refs.supplierSelect.setData(this.supplierReal)},handleChangeSupplier:function(e){var t=this;if(""===this.supplierReal){this.supplier=e,this.supplierReal=this.supplier,this.showSelectErr=!1;return}this.msgBox({title:this.$t("main.warehouse.scan.arrive.confirm.switch.supplier"),content:this.$t("main.warehouse.scan.arrive.switch.supplier.data.refresh")}).then(function(){t.supplier=e,t.supplierReal=t.supplier,t.arriveNum=0,t.$refs.supplierSelect.setData(t.supplierReal)}).catch(function(){t.supplier=t.supplierReal,t.$refs.supplierSelect.setData(t.supplierReal)})},inputVerify:function(){this.arriveNum=this.$utils.integerVerification(this.arriveNum),this.arriveNum>this.commodityData.waitCount&&!this.purchaseArrivalStatus&&(this.msgBox({title:this.$t("main.warehouse.scan.arrive.over.arrival.forbidden"),content:this.messageVNode(),isVNode:!0,showCancelButton:!1}).then(function(){}),this.arriveNum=this.commodityData.waitCount)},getRecommendShelfForStockIn:function(e){return tc(function(){var t;return tp(this,function(a){switch(a.label){case 0:return a.trys.push([0,2,,3]),[4,this.$http.getRecommendShelfForStockIn(e)];case 1:return[2,a.sent()];case 2:return t=a.sent(),this.$message.error(t),[3,3];case 3:return[2]}})}).call(this)},getConversionSku:function(e){return tc(function(){var t,a,r;return tp(this,function(i){switch(i.label){case 0:if(t=this.conversionSKUCacheForSaiHe.get(e))return[2,t];this.$loading(),i.label=1;case 1:return i.trys.push([1,3,4,5]),[4,this.$http.getConversionToSFSkuApi({uniqueCode:e})];case 2:return a=i.sent(),this.conversionSKUCacheForSaiHe.set(e,a),[2,a];case 3:return r=i.sent(),this.$message.error(r),[2,{}];case 4:return this.$loading().close(),[7];case 5:return[2]}})}).call(this)},checkSaiHeGrayscalePermission:function(){return this.$hasButtonPermission(U.j8.tripartiteToSf)}})};function tm(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function tv(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t}
1)(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}var td={name:"SkuArrive",components:{ScanPage:e6,ScanDetail:(0,$.A)(tf,function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"scan_detail flex"},[a("div",{staticClass:"scan_left"},[a("div",{staticClass:"scan_detail_title flex center_align between mb_12"},[a("span",{staticClass:"title"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.info")))]),e._v(" "),a("el-button",{attrs:{type:"text"},on:{click:e.handleChangePurchase}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.change.product")))])],1),e._v(" "),a("div",{staticClass:"flex center_align between mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.warehouse")))]),e._v(" "),a("WarehouseSelectorNew",{ref:"warehouseSelect",attrs:{disabled:"",width:"100%",isPermission:!0,"warehouse-types":e.warehouseTypes},model:{value:e.warehouseId,callback:function(t){e.warehouseId=t},expression:"warehouseId"}})],1),e._v(" "),a("div",{staticClass:"flex center_align between mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.supplier")))]),e._v(" "),a("div",{staticClass:"select_box"},[a("Selector",{ref:"supplierSelect",class:{ipt_err:e.showSelectErr},attrs:{options:e.supplierOptions},on:{"on-change":e.handleChangeSupplier}}),e._v(" "),e.showSelectErr?a("p",{staticClass:"err_text mt_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.select.supplier")))]):e._e()],1)]),e._v(" "),a("div",{staticClass:"flex mb_16"},[a("ImgBox",{staticClass:"mr_8",attrs:{src:e.commodityData.mainImage,option:"dialog"}}),e._v(" "),a("span",{staticClass:"line_clamp_2"},[e._v(e._s(e.commodityData.commodityName||"-"))])],1),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v("SKU")]),e._v(" "),a("span",{staticClass:"f_gold fw_600"},[e._v(e._s(e.commodityData.sku||"-"))])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.product.code")))]),e._v(" "),e.commodityData.commodityCode?a("span",{staticClass:"f_gold fw_600"},[e._v(e._s(e.commodityData.commodityCode))]):a("span",{staticClass:"f_gray fw_600"},[e._v("-")])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.identification.code")))]),e._v(" "),e.commodityData.identificationCode?a("span",{staticClass:"f_gold fw_600"},[e._v(e._s(e.commodityData.identificationCode))]):a("span",{staticClass:"f_gray fw_600"},[e._v("-")])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.order.count")))]),e._v(" "),a("span",[e._v(e._s(e.commodityData.purchaseCount||"-"))])]),e._v(" "),a("div",{staticClass:"flex center_align mb_16"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.purchase.total.quantity")))]),e._v(" "),a("span",[e._v(e._s(e.commodityData.purchaseTotalCount||"-"))])]),e._v(" "),a("div",{staticClass:"flex center_align mb_12"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.pending.total.quantity")))]),e._v(" "),a("span",[e._v(e._s(e.commodityData.waitCount||"-"))])]),e._v(" "),e.purchaseQualityStatus?a("div",{staticClass:"flex center_align mb_12"},[a("span",{staticClass:"label f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.quality.inspection")))]),e._v(" "),a("el-select",{staticClass:"quality_select",attrs:{placeholder:"",disabled:""},model:{value:e.commodityData.isNeedQc,callback:function(t){e.$set(e.commodityData,"isNeedQc",t)},expression:"commodityData.isNeedQc"}},[a("el-option",{attrs:{label:e.$t("common.yes"),value:1}}),e._v(" "),a("el-option",{attrs:{label:e.$t("common.no"),value:0}})],1)],1):e._e()]),e._v(" "),a("div",{staticClass:"scan_right flex column"},[a("div",{staticClass:"input_box flex center_align mb_10"},[a("el-select",{model:{value:e.selectVal,callback:function(t){e.selectVal=t},expression:"selectVal"}},e._l(e.selectOptions,function(e){return a("el-option",{key:e.label,attrs:{label:e.label,value:e.value}})}),1),e._v(" "),a("input",{directives:[{name:"model",rawName:"v-model",value:e.searchValue,expression:"searchValue"}],ref:"scanInput",staticClass:"scan_right_input",attrs:{placeholder:e.inputPlaceholder},domProps:{value:e.searchValue},on:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSubmit.apply(null,arguments)},input:function(t){t.target.composing||(e.searchValue=t.target.value)}}}),e._v(" "),a("button",{staticClass:"submitBtn",on:{click:e.handleSubmit}},[e._v(e._s(e.$t("common.confirm")))]),e._v(" "),a("div",{staticClass:"line"}),e._v(" "),a("div",{staticClass:"flex center_align"},[a("span",{staticClass:"f_14 f_gray"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.current.scan.input.count")))]),e._v(" "),a("input",{directives:[{name:"model",rawName:"v-model",value:e.arriveNum,expression:"arriveNum"}],staticClass:"scan_right_input arrive_input",attrs:{placeholder:""},domProps:{value:e.arriveNum},on:{input:[function(t){t.target.composing||(e.arriveNum=t.target.value)},e.inputVerify]}})]),e._v(" "),a("el-button",{staticClass:"text_btn_f16",attrs:{type:"text",disabled:!e.distributionDisable},on:{click:e.handleDistribution}},[e._v("\n "+e._s(e.$t("main.warehouse.scan.arrive.one.click.allocate"))+"\n ")])],1),e._v(" "),a("SkuArriveList",{ref:"purchaseList",attrs:{purchaseList:e.purchaseList},on:{"update:purchaseList":function(t){e.purchaseList=t},"update:purchase-list":function(t){e.purchaseList=t}}})],1),e._v(" "),a("div",{staticClass:"arrive_btn"},[a("el-button",{on:{click:e.handleCancel}},[e._v(e._s(e.$t("common.cancel")))]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.handleArrive}},[e._v(e._s(e.$t("main.warehouse.scan.arrive.confirm.arrival")))])],1
1),e._v(" "),a("el-dialog",{attrs:{title:e.$t("main.scan.arrive.sku.detail.scan.arrive.select"),visible:e.dialogSupplierVisible,"close-on-click-modal":!1,"append-to-body":!1,modal:!1,"custom-class":"dialog_mini"},on:{"update:visible":function(t){e.dialogSupplierVisible=t}}},[a("el-form",{attrs:{model:e.supplierFrom,"label-width":"70px"}},[a("el-form-item",{attrs:{label:e.$t("main.warehouse.scan.arrive.supplier")}},[a("Selector",{class:{ipt_err:e.supplierFrom.showSelectErr},staticStyle:{width:"180px"},attrs:{options:e.supplierOptions},on:{"on-change":e.onSupplierUpdate}}),e._v(" "),e.supplierFrom.showSelectErr?a("p",{staticClass:"f_red mt_2"},[e._v(e._s(e.$t("main.warehouse.scan.arrive.select.supplier")))]):e._e()],1)],1),e._v(" "),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.dialogSupplierVisible=!1}}},[e._v(e._s(e.$t("common.cancel")))]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.handleChooseSupplier}},[e._v(e._s(e.$t("common.confirm")))])],1)],1)],1)},[],!1,null,"066778f4",null).exports},data:function(){return{purchaseData:null}},provide:function(){return{clearPurchaseNum:this.clearPurchaseNum}},computed:tv(tm({},(0,h.mapState)("ScanArrive",{skuPurchaseData:function(e){return e.skuPurchaseData}})),{currentComponent:function(){return this.purchaseData?"ScanDetail":"ScanPage"}}),created:function(){this.$utils.addVUEXModule("ScanArrive")},mounted:function(){var e=this;this.$nextTick(function(){e.skuPurchaseData&&(e.purchaseData=e.skuPurchaseData)})},methods:tv(tm({},(0,h.mapActions)("ScanArrive",["setSkuPurchaseData","clearAllData"])),{setPurchaseData:function(e){this.purchaseData=e,this.setSkuPurchaseData(this.purchaseData)},clearPurchaseNum:function(){this.purchaseData=null,this.clearAllData()}})},tb=(0,$.A)(td,function(){var e=this.$createElement;return(this._self._c||e)(this.currentComponent,{tag:"component",attrs:{purchaseData:this.purchaseData},on:{setPurchaseData:this.setPurchaseData}})},[],!1,null,null,null).exports;function tg(e,t,a,r,i,s,n){try{var o=e[s](n),l=o.value}catch(e){a(e);return}o.done?t(l):Promise.resolve(l).then(r,i)}function ty(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{},r=Object.keys(a);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(a).filter(function(e){return Object.getOwnPropertyDescriptor(a,e).enumerable}))),r.forEach(function(t){var r;r=a[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function t_(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t.push.apply(t,a)}return t})(Object(t)).forEach(function(a){Object.defineProperty(e,a,Object.getOwnPropertyDescriptor(t,a))}),e}var tw={name:"ScanArrive",components:{Layout:u.A,PurchaseArrive:eM,SkuArrive:tb},provide:function(){return{msgBox:this.msgBox,tabListFnClose:this.tabListFnClose,messageVNode:this.messageVNode}},data:function(){return{currentComponent:"PurchaseArrive",warehouse:"",fromPage:"",componentName:""}},computed:t_(ty({},(0,h.mapState)("ScanArrive",{cachePageObj:function(e){return e.cachePageObj}})),{arriveType:function(){return this.$route.query.arriveType},fromPage:function(){return this.$route.query.fromPage}}),created:function(){this.getPurchaseQualityStatus(),this.getPurchaseArrivalStatus(),this.getAllowPurchaseToOverseasWarehouseStatus()},methods:t_(ty({},(0,h.mapActions)("Socket",["getPurchaseQualityStatus","getPurchaseArrivalStatus","getAllowPurchaseToOverseasWarehouseStatus"]),(0,h.mapActions)("ScanArrive",["setCachePageObj"])),{msgBox:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},a=this.$createElement,r=void 0!==t.color?t.color:"#FFA91E",i=void 0===t.showCancelButton||t.cancelButtonText,s=t.cancelButtonText?t.cancelButtonText:this.$t("common.cancel"),n=t.confirmButtonText?t.confirmButtonText:this.$t("main.warehouse.scan.arrive.confirm"),o=void 0!==t.icon?t.icon:"el-icon-warning",l=Array.isArray(t.content)&&!t.isVNode?a("div",null,[a("p",{style:"padding-left:36px;"},[a("span",{style:"font-size: 14px"},t.content[0]),a("span",{style:"font-size: 14px;color:#FFA91E"},t.content[1]),a("span",{style:"font-size: 14px"},t.content[2])])]):a("p",{style:"padding-left:36px;font-size: 14px;"},"function"==typeof t.content?t.content():t.content);return new Promise(function(c,u){e.$msgbox({title:"",customClass:"scanMessageBox",message:a("div",null,[a("p",{style:"margin-bottom: 10px",class:"flex center_align"},[a("i",{style:"color: ".concat(r,";margin-right:13px;font-size:22px"),class:o}),a("span",{style:"font-size: 16px;font-weight: bold;"},t.title)]),l]),closeOnClickModal:!1,closeOnPressEscape:!1,closeOnHashChange:!0,showClose:!1,showCancelButton:i,cancelButtonText:s,confirmButtonText:n}).then(function(){c()}).catch(function(){u()})})},tabListFnClose:function(){var e=this,t="arrive"===this.fromPage?"/web/v3/arrival-manage/index.html":"/web/v3/purchaseManage/index.html";this.msgBox({title:this.$t("main.warehouse.scan.arrive.confirm.cancel.title"),content:this.$t("main.warehouse.scan.arrive.confirm.cancel.content")}).then(function(){p.A.bus.$emit("thirdPartyCloseTab",null,{id:"scanArrive",name:e.$t("main.warehouse.arrival.manage.scan.arrival"),pageName:"ScanArrive",url:"/web/warehouse/scanArrive/index.html",navSingle:!0,navNot:!0},"getUrl"),e.$router.push(t)}
1).catch(function(){})},messageVNode:function(){var e=this.$createElement;return[e("div",{style:"margin: 0"},[e("span",this.$t("main.warehouse.scan.arrive.over.arrival.setting.prefix")),e("span",{class:"f_blue ml_4 mr_4 pointer",on:{click:this.toSettingPage}},this.$t("main.warehouse.scan.arrive.setting")),e("span",this.$t("main.warehouse.scan.arrive.over.arrival.setting.suffix"))])]},toSettingPage:function(){var e=document.querySelector(".scanMessageBox.scanMessageBox .el-button");e&&"function"==typeof e.click&&e.click(),this.$router.push({name:"BusinessSetting",query:{navActive:"Purchase"}})},changeHandle:function(){"purchase"===this.arriveType&&(this.componentName="PurchaseArrive",this.warehouse=""),"sku"===this.arriveType&&(this.componentName="SkuArrive",this.warehouse=+this.$route.query.warehouse||""),this.fromPage=this.$route.query.fromPage},currentHandle:function(){"purchase"===this.arriveType&&(this.currentComponent="PurchaseArrive"),"sku"===this.arriveType&&(this.currentComponent="SkuArrive")},addChangeHandle:function(){var e=this;this.$sfMessage.confirm(this.$t("main.warehouse.scan.arrive.confirm.cover.editing"),this.$t("main.warehouse.scan.arrive.cover"),{type:"warning",dangerouslyUseHTMLString:!0,beforeClose:function(t,a,r){var i;return(i=function(){var e;return function(e,t){var a,r,i,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},n=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),o=Object.defineProperty;return o(n,"next",{value:l(0)}),o(n,"throw",{value:l(1)}),o(n,"return",{value:l(2)}),"function"==typeof Symbol&&o(n,Symbol.iterator,{value:function(){return this}}),n;function l(o){return function(l){var c=[o,l];if(a)throw TypeError("Generator is already executing.");for(;n&&(n=0,c[0]&&(s=0)),s;)try{if(a=1,r&&(i=2&c[0]?r.return:c[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,c[1])).done)return i;switch(r=0,i&&(c=[2&c[0],i.value]),c[0]){case 0:case 1:i=c;break;case 4:return s.label++,{value:c[1],done:!1};case 5:s.label++,r=c[1],c=[0];continue;case 7:c=s.ops.pop(),s.trys.pop();continue;default:if(!(i=(i=s.trys).length>0&&i[i.length-1])&&(6===c[0]||2===c[0])){s=0;continue}if(3===c[0]&&(!i||c[1]>i[0]&&c[1]<i[3])){s.label=c[1];break}if(6===c[0]&&s.label<i[1]){s.label=i[1],i=c;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(c);break}i[2]&&s.ops.pop(),s.trys.pop();continue}c=t.call(e,s)}catch(e){c=[6,e],r=0}finally{a=i=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}(this,function(a){switch(a.label){case 0:if(e=this,"confirm"!==t)return[3,2];return[4,this.$refs.componentRef.clearPurchaseNum()];case 1:return a.sent(),"SkuArrive"===this.componentName&&(this.$router.push({query:{arriveType:"sku",fromPage:this.fromPage,warehouse:this.warehouse}}),setTimeout(function(){e.$refs.componentRef.getWarehouse()},50)),this.currentHandle(),r(),[3,3];case 2:this.fromPage=this.cachePageObj.fromPage,"SkuArrive"===this.cachePageObj.name?(this.warehouse=this.cachePageObj.warehouse,this.$router.push({query:{arriveType:"sku",fromPage:this.cachePageObj.fromPage,warehouse:this.cachePageObj.warehouse}})):this.$router.push({query:{arriveType:"purchase",fromPage:this.cachePageObj.fromPage}}),this.$nextTick(function(){e.currentHandle()}),r(),a.label=3;case 3:return[2]}})},function(){var e=this,t=arguments;return new Promise(function(a,r){var s=i.apply(e,t);function n(e){tg(s,a,r,n,o,"next",e)}function o(e){tg(s,a,r,n,o,"throw",e)}n(void 0)})}).call(e)}})}}),activated:function(){this.changeHandle(),this.cachePageObj&&("SkuArrive"===this.cachePageObj.name&&"SkuArrive"===this.componentName&&this.cachePageObj.warehouse!==this.warehouse||this.cachePageObj.name!==this.componentName)?this.addChangeHandle():this.currentHandle()},deactivated:function(){this.setCachePageObj({name:this.currentComponent,fromPage:this.fromPage,warehouse:this.warehouse})}},tS=(0,$.A)(tw,function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"page_content layout_main_body"},[t(this.currentComponent,{ref:"componentRef",tag:"component"})],1)},[],!1,null,"70238e86",null).exports},41534:function(e,t,a){a.d(t,{A:function(){return l}}),a(77949);var r=a.p+"61a0c09e56d1e415.mp3",i=a.p+"8d2e50bbd01204d5.mp3",s=a.p+"f5d6d906a096c9b8.mp3",n=a.p+"dc9c0d0e7205ea63.mp3",o=a.p+"efdc6ed08b6cd1d2.mp3",l={name:"VoiceBoadcastMixin",data:function(){return{audioText:""}}
1,methods:{handleVideo:function(e){switch(e){case"\u6210\u529F":t=n;break;case"\u5931\u8D25":t=o;break;case"\u79F0\u91CD\u5931\u8D25":t=s;break;case"\u626B\u63CF\u5931\u8D25":t=r;break;case"\u53D1\u8D27\u5931\u8D25":t=i;break;default:t="".concat(this.$utils.getVoiceBoadcastUrl(e))}var t,a=new Audio(t);setTimeout(function(){a.play()},1)}}}},24782:function(e,t,a){t.A=a(74943).qVh?"sellfox-private-temp":"sellfox-private-test-temp"}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.