(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-01031345"],{"1f21":function(t,e,a){},5597:function(t,e,a){"use strict";a.r(e);var n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("a-card",[a("a-row",{attrs:{align:"middle"}},[a("a-col",{staticClass:"operate",staticStyle:{"padding-right":"25px",display:"flex","align-items":"center"},attrs:{sm:24,xs:24,md:15,xl:11}},[a("a-form",{attrs:{layout:t.formLayout}},[a("a-form-item",[a("label",{staticStyle:{"font-size":"20px",color:"#000000d9",width:"90px"}},[t._v("柜"+t._s("　")+"号:")]),a("a-input",{ref:"input",attrs:{placeholder:"柜号"},on:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.InspectContainer.apply(null,arguments)}},model:{value:t.container,callback:function(e){t.container=e},expression:"container"}})],1)],1)],1),a("a-col",{staticStyle:{display:"flex","align-items":"center",height:"40px"},attrs:{sm:24,md:13,xl:5}},[a("a-button",{staticStyle:{"margin-right":"20px"},attrs:{type:"primary",icon:"search"},on:{click:t.searchInspectContainer}},[t._v("查询")]),a("a-popconfirm",{attrs:{title:"是否确认出货该柜号","ok-text":"是","cancel-text":"否"},on:{confirm:t.confirm,cancel:t.cancel}},[a("a-button",{staticStyle:{"background-color":"#1890ff","border-color":"#1890ff"},attrs:{type:"danger",icon:"delete"}},[t._v("出货")])],1)],1)],1)],1),a("a-card",[a("a-form-model",{ref:"formRef",attrs:{model:t.submitModel,"label-col":{span:6},"wrapper-col":{span:16}}},[a("a-row",[a("a-col",{attrs:{span:6}},[a("a-form-model-item",{attrs:{label:"客户名称"}},[a("a-input",{attrs:{disabled:!0},model:{value:t.submitModel.Customer,callback:function(e){t.$set(t.submitModel,"Customer",e)},expression:"submitModel.Customer"}})],1)],1),a("a-col",{attrs:{span:9}},[a("a-form-model-item",{staticStyle:{"margin-left":"1%"},attrs:{label:"发货地址:",layout:"inline"}},[a("a-input",{staticStyle:{width:"240%"},attrs:{disabled:!0},model:{value:t.submitModel.address,callback:function(e){t.$set(t.submitModel,"address",e)},expression:"submitModel.address"}})],1)],1),a("a-col",{attrs:{span:5}},[a("a-form-model-item",{staticStyle:{"margin-left":"1%"},attrs:{label:"发货订单:",layout:"inline"}},[a("a-input",{attrs:{disabled:!0},model:{value:t.submitModel.order,callback:function(e){t.$set(t.submitModel,"order",e)},expression:"submitModel.order"}})],1)],1)],1)],1),a("a-divider",{staticStyle:{margin:"0"}}),a("a-tabs",{attrs:{"default-active-key":"1"}},[a("a-tab-pane",{key:"1",attrs:{tab:"出货托盘信息"}},[a("a-table",{staticClass:"main-table",attrs:{"data-source":t.tableData,columns:t.columns,loading:t.tableLoading,pagination:!1,scroll:{x:"1500",y:"calc("+t.tableHeight+"px)"},rowKey:"pallet",size:"small"}})],1)],1)],1)],1)},i=[],o=a("b775"),s={name:"DeliverGoods",data:function(){return{formLayout:"inline",areaList:[],tableData:[],tableHeight:560,tableLoading:!1,columns:[{title:"托盘号",align:"center",dataIndex:"pallet_nbr",width:150},{title:"产品编码",align:"center",dataIndex:"product_code",width:100},{title:"工单号",align:"center",dataIndex:"workorder",width:100},{title:"功率档",align:"center",dataIndex:"power_grade",width:70},{title:"电流档",align:"center",dataIndex:"current_grade",width:70},{title:"最终等级",align:"center",dataIndex:"final_grade",width:70}],container:"",submitModel:{Container:"",Customer:"",address:"",order:""}}},methods:{submit:function(){var t=this;0!==this.tableData.length?this.$refs.formRef.validate((function(e){e&&o["b"].post("/api/deliver/delivergoods",t.submitModel).then((function(e){1===e.status?(t.$notification.success({message:e.msg}),t.tableData=[]):t.$notification.warn({message:e.msg})}))})):this.$notification.warn({message:"柜号明细为空，出货失败！"})},InspectContainer:function(){var t=this;this.submitModel.Container=this.container,this.container="",this.tableLoading=!0,o["b"].get("/api/deliver/containerslist?container=".concat(encodeURIComponent(this.submitModel.Container))).then((function(e){if(1===e.status){if(0===e.data.container)return t.$notification.warn({message:"柜号"+t.submitModel.Container+"数据不存在"}),t.tableData=[],void(t.tableLoading=!1);t.submitModel.Customer=e.data.container.customer_name,t.submitModel.address=e.data.container.address,t.submitModel.order=e.data.container.saleorder,t.tableData=e.data.packInfo,t.tableLoading=!1}else t.$notification.warn({message:e.msg}),t.tableLoading=!1}))},searchInspectContainer:function(){this.InspectContainer()},selectedItems:function(t,e){this.submitModel.FactoryId=parseInt(e.data.key)},confirm:function(t){this.submit()},cancel:function(t){this.$message.error("出货操作已取消")}},mounted:function(){this.$refs.input.focus()}},r=s,l=(a("ebfc"),a("2877")),c=Object(l["a"])(r,n,i,!1,null,null,null);e["default"]=c.exports},ebfc:function(t,e,a){"use strict";a("1f21")}}]);