1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([[17],{"286c":function(t,e){},4813:function(t,e,a){},"90d5":function(t,e,a){"use strict";var o=a("286c"),n=a.n(o);e["default"]=n.a},"986ad":function(t,e,a){"use strict";a.r(e);var o=function(){var t=this,e=t._self._c;return e("div",[e("transition",{attrs:{appear:"","enter-active-class":"animated fadeIn"}},[e("q-table",{staticClass:"my-sticky-header-column-table shadow-24",attrs:{data:t.table_list,"row-key":"id",separator:t.separator,loading:t.loading,columns:t.columns,"hide-bottom":"",pagination:t.pagination,"no-data-label":"No data","no-results-label":"No data you want","table-style":{height:t.height},flat:"",bordered:""},on:{"update:pagination":function(e){t.pagination=e}},scopedSlots:t._u([{key:"top",fn:function(){return[e("q-btn-group",{attrs:{push:""}},[e("q-btn",{attrs:{label:t.$t("new"),icon:"add"},on:{click:function(e){t.newForm=!0,t.newFormData.creater=t.login_name}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v(t._s(t.$t("newtip")))])],1),e("q-btn",{attrs:{label:t.$t("refresh"),icon:"refresh"},on:{click:function(e){return t.reFresh()}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v(t._s(t.$t("refreshtip")))])],1)],1),e("q-space"),e("div",{staticClass:"flex items-center"},[e("q-input",{attrs:{outlined:"",rounded:"",dense:"",debounce:"200",color:"primary",placeholder:"输入名称搜索"},on:{input:function(e){return t.getSearchList()},keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.getSearchList()}},scopedSlots:t._u([{key:"append",fn:function(){return[e("q-icon",{attrs:{name:"search"}})]},proxy:!0}]),model:{value:t.filter,callback:function(e){t.filter=e},expression:"filter"}})],1)]},proxy:!0},{key:"body",fn:function(a){return[e("q-tr",{attrs:{props:a}},[a.row.id===t.editid||a.row.id!==t.editid?[e("q-td",{key:"detail",attrs:{props:a}},[e("q-btn",{attrs:{round:"",flat:"",push:"",color:"black",icon:"description"},on:{click:function(e){return t.detailData(a.row)}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v(t._s("查看批次详情"))])],1)],1)]:t._e(),a.row.id===t.editid||a.row.id!==t.editid?[e("q-td",{key:"bound_date",attrs:{props:a}},[t._v(t._s(a.row.bound_date))])]:t._e(),a.row.id===t.editid||a.row.id!==t.editid?[e("q-td",{key:"bound_code",attrs:{props:a}},[t._v(t._s(a.row.bound_code))])]:t._e(),a.row.id===t.editid?[e("q-td",{key:"bound_code_type",attrs:{props:a}},[e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"单据类型",autofocus:"",options:t.bound_code_type_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.editFormData.bound_code_type,callback:function(e){t.$set(t.editFormData,"bound_code_type",e)},expression:"editFormData.bound_code_type"}})],1)]:a.row.id!==t.editid?[e("q-td",{key:"bound_code_type",attrs:{props:a}},[t._v("\n "+t._s(t.bound_code_type_map[a.row.bound_code_type]||a.row.bound_code_type))])]:t._e(),a.row.id===t.editid?[e("q-td",{key:"bound_bs_type",attrs:{props:a}},[e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"单据类型",options:t.bound_bs_type_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.editFormData.bound_bs_type,callback:function(e){t.$set(t.editFormData,"bound_bs_type",e)},expression:"editFormData.bound_bs_type"}})],1)]:a.row.id!==t.editid?[e("q-td",{key:"bound_bs_type",attrs:{props:a}},[t._v("\n "+t._s(t.bound_bs_type_map[a.row.bound_bs_type]||a.row.bound_bs_type))])]:t._e(),a.row.id===t.editid?[e("q-td",{key:"bound_desc",attrs:{props:a}},[e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"出入库类别",options:t.bound_desc_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.editFormData.bound_desc,callback:function(e){t.$set(t.editFormData,"bound_desc",e)},expression:"editFormData.bound_desc"}})],1)]:a.row.id!==t.editid?[e("q-td",{key:"bound_desc",attrs:{props:a}},[t._v("\n "+t._s(t.bound_desc_map[a.row.bound_desc]||a.row.bound_desc))])]:t._e(),a.row.id===t.editid?[e("q-td",{key:"bound_department",attrs:{props:a}},[e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"部门",options:t.bound_department_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.editFormData.bound_department,callback:function(e){t.$set(t.editFormData,"bound_department",e)},expression:"editFormData.bound_department"}})],1)]:a.row.id!==t.editid?[e("q-td",{key:"bound_department",attrs:{props:a}},[t._v("\n "+t._s(t.bound_department_map[a.row.bound_department]||a.row.bound_department))])]:t._e(),a.row.id===t.editid?[e("q-td",{key:"creater",attrs:{props:a}},[e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"经办人",rules:[e=>e&&e>0||t.error1]},model:{value:t.editFormData.creater,callback:function(e){t.$set(t.editFormData,"creater",t._n(e))},expression:"editFormData.creater"}})],1)]:a.row.id!==t.editid?[e("q-td",{key:"creater",attrs:{props:a}},[t._v(t._s(a.row.creater))])]:t._e(),a.row.id===t.editid||a.row.id!==t.editid?[e("q-td",{key:"bound_status",attrs:{props:a}},[t._v("\n "+t._s(t.bound_status_map[a.row.bound_status]||a.row.bound_status))])]:t._e(),t.editMode?t.editMode?[a.row.id===t.editid?[e("q-td",{key:"action",staticStyle:{width:"100px"},attrs:{props:a}},[e("q-btn",{attrs:{round:"",flat:"",push:"",color:"secondary",icon:"check"},on:{click:function(e){return t.editDataSubmit()}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v(t._s(t.$t("confirmedit")))])],1),e("q-btn",{attrs:{round:"",flat:"",push:"",color:"red",icon:"close"},on:{click:function(e){return t.editDataCancel()}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v(t._s(t.$t("canceledit")))])],1)],1)]:a.row.id!==t.editid?void 0:t._e()]:t._e():[e("q-td",{key:"action",staticStyle:{width:"100px"},attrs:{props:a}},[e("q-btn",{attrs:{round:"",flat:"",push:"",color:"dark",icon:"trolley"},on:{click:function(e){return t.change_status(a.row)}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v("确认出库")])],1),e("q-btn",{attrs:{round:"",flat:"",push:"",color:"dark",icon:"delete"},on:{click:function(e){return t.deleteData(a.row.id)}}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[t._v(t._s(t.$t("delete")))])],1)],1)]],2)]}}])})],1),[e("div",{directives:[{name:"show",rawName:"v-show",value:0!==t.max,expression:"max !== 0"}],staticClass:"q-pa-lg flex flex-center"},[e("div",[t._v(t._s(t.total))]),e("q-pagination",{attrs:{color:"black",max:t.max,"max-pages":6,"boundary-links":""},on:{click:function(e){t.getSearchList(t.current),t.paginationIpt=t.current}},model:{value:t.current,callback:function(e){t.current=e},expression:"current"}}),e("div",[e("input",{directives:[{name:"model",rawName:"v-model",value:t.paginationIpt,expression:"paginationIpt"}],staticStyle:{width:"60px","text-align":"center"},domProps:{value:t.paginationIpt},on:{blur:t.changePageEnter,keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.changePageEnter.apply(null,arguments)},input:function(e){e.target.composing||(t.paginationIpt=e.target.value)}}})])],1),e("div",{directives:[{name:"show",rawName:"v-show",value:0===t.max,expression:"max === 0"}],staticClass:"q-pa-lg flex flex-center"},[e("q-btn",{attrs:{flat:"",push:"",color:"dark",label:t.$t("no_data")}})],1)],e("q-dialog",{model:{value:t.newForm,callback:function(e){t.newForm=e},expression:"newForm"}},[e("q-card",{staticClass:"shadow-24"},[e("q-bar",{staticClass:"bg-light-blue-10 text-white rounded-borders",staticStyle:{height:"50px"}},[e("div",[t._v(t._s(t.$t("newtip")))]),e("q-space"),e("q-btn",{directives:[{name:"close-popup",rawName:"v-close-popup"}],attrs:{dense:"",flat:"",icon:"close"}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4"}},[t._v(t._s(t.$t("index.close")))])],1)],1),e("q-card-section",{staticClass:"scroll",staticStyle:{"max-height":"325px",width:"400px"}},[e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"单据类型",autofocus:"",options:t.bound_code_type_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newFormData.bound_code_type,callback:function(e){t.$set(t.newFormData,"bound_code_type",e)},expression:"newFormData.bound_code_type"}}),e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"业务类型",options:t.bound_bs_type_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newFormData.bound_bs_type,callback:function(e){t.$set(t.newFormData,"bound_bs_type",e)},expression:"newFormData.bound_bs_type"}}),e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"出入库类别",options:t.bound_desc_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newFormData.bound_desc,callback:function(e){t.$set(t.newFormData,"bound_desc",e)},expression:"newFormData.bound_desc"}}),e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"部门",options:t.bound_department_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newFormData.bound_department,callback:function(e){t.$set(t.newFormData,"bound_department",e)},expression:"newFormData.bound_department"}}),e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"经办人",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newFormData.creater,callback:function(e){t.$set(t.newFormData,"creater",e)},expression:"newFormData.creater"}})],1),e("div",{staticStyle:{float:"right",padding:"15px 15px 15px 0"}},[e("q-btn",{staticStyle:{"margin-right":"25px"},attrs:{color:"white","text-color":"black"},on:{click:function(e){return t.newDataCancel()}}},[t._v(t._s(t.$t("cancel")))]),e("q-btn",{attrs:{color:"primary"},on:{click:function(e){return t.newDataSubmit()}}},[t._v(t._s(t.$t("submit")))])],1)],1)],1),e("q-dialog",{model:{value:t.deleteForm,callback:function(e){t.deleteForm=e},expression:"deleteForm"}},[e("q-card",{staticClass:"shadow-24"},[e("q-bar",{staticClass:"bg-light-blue-10 text-white rounded-borders",staticStyle:{height:"50px"}},[e("div",[t._v(t._s(t.$t("delete")))]),e("q-space"),e("q-btn",{directives:[{name:"close-popup",rawName:"v-close-popup"}],attrs:{dense:"",flat:"",icon:"close"}},[e("q-tooltip",[t._v(t._s(t.$t("index.close")))])],1)],1),e("q-card-section",{staticClass:"scroll",staticStyle:{"min-height":"325px",width:"550px"}},[t._v(t._s(t.$t("deletetip")))]),e("div",{staticStyle:{float:"right",padding:"15px 15px 15px 0"}},[e("q-btn",{staticStyle:{"margin-right":"25px"},attrs:{color:"white","text-color":"black"},on:{click:function(e){return t.deleteDataCancel()}}},[t._v(t._s(t.$t("cancel")))]),e("q-btn",{attrs:{color:"primary"},on:{click:function(e){return t.deleteDataSubmit()}}},[t._v(t._s(t.$t("submit")))])],1)],1)],1),e("q-dialog",{model:{value:t.newBatchForm,callback:function(e){t.newBatchForm=e},expression:"newBatchForm"}},[e("q-card",{staticClass:"shadow-24"},[e("q-bar",{staticClass:"bg-light-blue-10 text-white rounded-borders",staticStyle:{height:"50px"}},[e("div",[t._v(t._s("新建出库批次"))]),e("q-space"),e("q-btn",{directives:[{name:"close-popup",rawName:"v-close-popup"}],attrs:{dense:"",flat:"",icon:"close"}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4"}},[t._v(t._s(t.$t("index.close")))])],1)],1),e("q-card-section",{staticClass:"scroll",staticStyle:{"min-height":"325px",width:"550px"}},[e("div",{staticClass:"text-h6 q-mb-md"},[t._v("\n "+t._s("目标批次信息")+"\n "),e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"物料",options:t.out_type_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newBatchFormData.out_type,callback:function(e){t.$set(t.newBatchFormData,"out_type",e)},expression:"newBatchFormData.out_type"}}),e("div",{staticClass:"row q-gutter-x-md"},[e("div",{staticClass:"col column q-gutter-y-md"},[e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"物料编码",options:t.product_list,"option-label":"value","option-value":"value","emit-value":"","map-options":"","transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.target_batch,callback:function(e){t.target_batch=e},expression:"target_batch"}})],1),e("div",{staticClass:"col column q-gutter-y-md"},[e("q-input",{attrs:{outlined:"",dense:"",color:"primary",placeholder:"搜索批次号",autofocus:""},on:{input:function(e){return t.getProductSearchList()},keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.getProductSearchList()}},scopedSlots:t._u([{key:"append",fn:function(){return[e("q-icon",{attrs:{name:"search"}})]},proxy:!0}]),model:{value:t.product_filter,callback:function(e){t.product_filter=e},expression:"product_filter"}})],1)]),e("q-select",{attrs:{dense:"",outlined:"",square:"",label:"物料",options:t.product_list,"option-label":"label","option-value":"value","emit-value":"","map-options":"",readonly:!0,"transition-show":"scale","transition-hide":"scale",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newBatchFormData.goods_code,callback:function(e){t.$set(t.newBatchFormData,"goods_code",e)},expression:"newBatchFormData.goods_code"}}),e("div",{staticClass:"q-mb-md"},[t._v("\n "+t._s("已有批次信息")+"\n "),e("div",{staticStyle:{float:"right",padding:"15px 15px 15px 0"}},[e("q-btn",{attrs:{color:"primary"},on:{click:function(e){return t.get_refresh_data()}}},[t._v(t._s("刷新"))])],1)]),e("q-card",{staticClass:"q-mb-md",attrs:{bordered:""}},[e("q-card-section",{staticClass:"q-pt-md"},[e("div",{staticClass:"row q-gutter-x-md"},[e("div",{staticClass:"col column q-gutter-y-md"},[e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"单重",type:"number",rules:[e=>e&&e>0||t.error1],readonly:!0},model:{value:t.newBatchFormData.goods_weight,callback:function(e){t.$set(t.newBatchFormData,"goods_weight",t._n(e))},expression:"newBatchFormData.goods_weight"}}),e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"当前数量",type:"number",readonly:!0,rules:[e=>e&&e>0||t.error1]},model:{value:t.newBatchFormData.goods_qty,callback:function(e){t.$set(t.newBatchFormData,"goods_qty",t._n(e))},expression:"newBatchFormData.goods_qty"}})],1),e("div",{staticClass:"col column q-gutter-y-md"},[e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"单位",rules:[e=>e&&e.length>0||t.error1],readonly:!0},model:{value:t.newBatchFormData.goods_unit,callback:function(e){t.$set(t.newBatchFormData,"goods_unit",e)},expression:"newBatchFormData.goods_unit"}}),e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"规格/备注",rules:[e=>e&&e.length>0||t.error1],readonly:!0},model:{value:t.newBatchFormData.goods_std,callback:function(e){t.$set(t.newBatchFormData,"goods_std",e)},expression:"newBatchFormData.goods_std"}})],1)])])],1)],1),e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"名称",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newBatchFormData.goods_desc,callback:function(e){t.$set(t.newBatchFormData,"goods_desc",e)},expression:"newBatchFormData.goods_desc"}}),e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"出库数量",type:"number",rules:[e=>e&&e>0||t.error1]},model:{value:t.newBatchFormData.goods_out_qty,callback:function(e){t.$set(t.newBatchFormData,"goods_out_qty",t._n(e))},expression:"newBatchFormData.goods_out_qty"}}),e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"经办人",rules:[e=>e&&e.length>0||t.error1]},model:{value:t.newBatchFormData.creater,callback:function(e){t.$set(t.newBatchFormData,"creater",e)},expression:"newBatchFormData.creater"}})],1),e("div",{staticStyle:{float:"right",padding:"15px 15px 15px 0"}},[e("q-btn",{staticStyle:{"margin-right":"25px"},attrs:{color:"white","text-color":"black"},on:{click:function(e){return t.newBatchCancel()}}},[t._v(t._s(t.$t("cancel")))]),e("q-btn",{attrs:{color:"primary"},on:{click:function(e){return t.newBatchSubmit()}}},[t._v(t._s(t.$t("submit")))])],1)],1)],1),e("q-dialog",{attrs:{"transition-show":"jump-down","transition-hide":"jump-up"},model:{value:t.detailForm,callback:function(e){t.detailForm=e},expression:"detailForm"}},[e("q-card",{staticStyle:{"min-width":"900px"}},[e("q-bar",{staticClass:"bg-light-blue-10 text-white rounded-borders",staticStyle:{height:"50px"}},[e("div",[t._v("\n "+t._s("出库信息")+"\n ")]),e("q-space"),e("q-btn",{directives:[{name:"close-popup",rawName:"v-close-popup"}],attrs:{dense:"",flat:"",icon:"close"}},[e("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[20,20],"content-style":"font-size: 12px"}},[t._v("\n "+t._s(t.$t("index.close")))])],1)],1),e("q-card-section",{staticClass:"q-pt-md"},[e("q-tabs",{model:{value:t.activeTab,callback:function(e){t.activeTab=e},expression:"activeTab"}},[e("q-tab",{attrs:{name:"tab1",label:"出库信息"}})],1)],1),e("q-tab-panels",{attrs:{animated:""},model:{value:t.activeTab,callback:function(e){t.activeTab=e},expression:"activeTab"}},[e("q-tab-panel",{staticStyle:{height:"70px"},attrs:{name:"tab1"}},[e("div",{staticClass:"row q-gutter-x-md"},[e("div",{staticClass:"col column q-gutter-y-md"},[e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"单据时间",readonly:!0},model:{value:t.table_detail.bound_date,callback:function(e){t.$set(t.table_detail,"bound_date",e)},expression:"table_detail.bound_date"}})],1),e("div",{staticClass:"col column q-gutter-y-md"},[e("q-input",{attrs:{dense:"",outlined:"",square:"",label:"单据编码",readonly:!0},model:{value:t.table_detail.bound_code,callback:function(e){t.$set(t.table_detail,"bound_code",e)},expression:"table_detail.bound_code"}})],1)])])],1),e("div",{staticStyle:{float:"right",padding:"15px 15px 50px 15px","min-width":"100%"},attrs:{flow:"row wrap"}},[e("q-card",{staticClass:"q-mb-md",attrs:{bordered:""}},[e("q-card-actions",{staticClass:"q-px-none",staticStyle:{position:"absolute",right:"20px",top:"10px","z-index":"100"}},[e("q-btn",{attrs:{icon:"add",flat:"",dense:"",color:"primary",label:t.$t("stock.add")},on:{click:function(e){return t.addbatch(t.table_detail.id)}}})],1),e("q-card-section",[[e("div",{staticClass:"text-h6 q-mb-md"},[t._v(t._s("批次信息"))]),t.batch_detail.length>0?t._l(t.batch_detail,(function(a,o){return e("div",{key:o,staticClass:"row q-col-gutter-md q-mb-sm"},[e("div",{staticClass:"col",staticStyle:{"min-width":"150px"}},[e("q-input",{attrs:{label:"批次",readonly:t.onlyread,dense:"",outlined:""},model:{value:a.bound_batch.out_number,callback:function(e){t.$set(a.bound_batch,"out_number",e)},expression:"item.bound_batch.out_number"}})],1),e("div",{staticClass:"col"},[e("q-input",{attrs:{label:"货物",readonly:t.onlyread,dense:"",outlined:""},model:{value:a.bound_batch.goods_desc,callback:function(e){t.$set(a.bound_batch,"goods_desc",e)},expression:"item.bound_batch.goods_desc"}})],1),e("div",{staticClass:"col"},[e("q-input",{attrs:{label:"单重",readonly:t.onlyread,dense:"",outlined:""},model:{value:a.bound_batch.goods_weight,callback:function(e){t.$set(a.bound_batch,"goods_weight",e)},expression:"item.bound_batch.goods_weight"}})],1),e("div",{staticClass:"col"},[e("q-input",{attrs:{label:"出库数量",readonly:t.onlyread,dense:"",outlined:""},model:{value:a.bound_batch.goods_out_qty,callback:function(e){t.$set(a.bound_batch,"goods_out_qty",e)},expression:"item.bound_batch.goods_out_qty"}})],1)])})):t._e()]],2)],1)],1)],1)],1)],2)},n=[],s=(a("ddb0"),a("9861"),a("a79d"),a("5319"),a("3004")),i=a("bd4c"),r=a("a357"),d=a("18d6"),l={name:"Pagednlist",data(){return{createDate1:"",createDate2:"",date_range:"",proxyDate:"",date:"",goods_code:"",goods_desc:"",openid:"",login_name:"",authin:"0",warehouse_code:"",warehouse_name:"",searchUrl:"",pathname:"bound/list/",pathfilename:"bound/file/",pathname_previous:"",pathname_next:"",separator:"cell",loading:!1,height:"",printObj:{id:"printMe",popTitle:this.$t("inbound.asn")},table_list:[],table_detail:{},batch_detail:[],bound_code_type_list:[],bound_code_type_map:[],bound_bs_type_list:[],bound_bs_type_map:[],bound_desc_list:[],bound_desc_map:[],bound_department_list:[],bound_department_map:[],bound_status_list:[],bound_status_map:[],product_list:[],product_map:[],out_type_list:[{label:"销售出库",value:"0"},{label:"其他出库",value:"4"}],columns:[{name:"detail",label:"详情",field:"detail",align:"center"},{name:"bound_date",label:"单据日期",field:"bound_date",align:"center"},{name:"bound_code",label:"单据编号",field:"bound_code",align:"center"},{name:"bound_code_type",label:"单据类型",field:"bound_code_type",align:"center"},{name:"bound_bs_type",label:"业务类型",field:"bound_bs_type",align:"center"},{name:"bound_desc",label:"出入库类别",field:"bound_desc",align:"center"},{name:"bound_department",label:"部门",field:"bound_department",align:"center"},{name:"creater",label:"经办人",field:"creater",align:"center"},{name:"bound_status",label:"状态",field:"bound_status",align:"center"},{name:"action",label:"操作",align:"center"}],filter:"",product_filter:"",pagination:{page:1,rowsPerPage:11},newForm:!1,newBatchForm:!1,newFormData:{},newBatchFormData:{goods_code:"",goods_desc:"",goods_weight:0,goods_qty:0,goods_unit:"",goods_out_qty:0,creater:"",out_number:"",out_type:"0",bound_list_id:0,goods_std:"",goods_batch:""},newDetailFormData:{},editid:0,editFormData:{},editMode:!1,deleteForm:!1,detailForm:!1,deleteid:0,detailid:0,bar_code:"",error1:this.$t("goods.view_goodslist.error1"),max:0,total:0,paginationIpt:1,current:1,onlyread:!0,bound_batch_list:[],activeTab:"tab1",target_batch:""}},computed:{interval(){return this.$t("download_center.start")+" - "+this.$t("download_center.end")}},methods:{getList(t={}){var e=this;e.loading=!0;const a={page:e.current,base_type:"1",page_size:e.pagination.rowsPerPage},o=new URLSearchParams({...a,...t});console.log(o),Array.from(o.entries()).forEach((([t,e])=>{""!==e&&null!==e&&void 0!==e||o.delete(t)})),Object(s["e"])(`${e.pathname}?${o}`).then((t=>{e.table_list=t.results,e.total=t.count,e.max=Math.ceil(t.count/e.pagination.rowsPerPage)||0,e.pathname_previous=t.previous,e.pathname_next=t.next})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})})).finally((()=>{e.loading=!1}))},changePageEnter(){Number(this.paginationIpt)<1?(this.current=1,this.paginationIpt=1):Number(this.paginationIpt)>this.max?(this.current=this.max,this.paginationIpt=this.max):this.current=Number(this.paginationIpt),this.getSearchList(this.current)},get_refresh_data(){Object(s["e"])("bound/batch/?bound_number="+this.target_batch).then((t=>{console.log("当前长度",t.results.length),console.log("当前值",t.results[0]),t.results.length>0?(this.newBatchFormData.goods_qty=t.results[0].goods_qty,console.log("当前数目",this.newBatchFormData.goods_qty),this.newBatchFormData.goods_weight=t.results[0].goods_weight,this.newBatchFormData.goods_std=t.results[0].goods_std,this.newBatchFormData.goods_unit=t.results[0].goods_unit):(this.newBatchFormData.goods_qty="",this.newBatchFormData.goods_weight="",this.newBatchFormData.goods_std="",this.newBatchFormData.goods_unit="")})).catch((t=>{this.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},getProductSearchList(){var t=this;t.loading=!0;const e={bound_number__icontains:t.product_filter,max_page:1e3},a=new URLSearchParams({...e});console.log(a),Array.from(a.entries()).forEach((([t,e])=>{""!==e&&null!==e&&void 0!==e||a.delete(t)})),Object(s["e"])(`bound/batch/?${a}`).then((e=>{t.product_list=e.results.map((t=>({label:t.goods_desc,value:t.bound_number}))),t.product_map=e.results.reduce(((t,e)=>(t[e.bound_number]=e.goods_desc,t)),{})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})).finally((()=>{t.loading=!1}))},getSearchList(t=1){this.current=t,this.paginationIpt=t,this.getList({goods_desc__icontains:this.filter,document_date__range:this.date_range})},downloadlistData(){this.getfileList()},getfileList(){var t=this;t.loading=!0;const e={goods_desc__icontains:t.filter,document_date__range:t.date_range},a=new URLSearchParams({...e});console.log(a),Array.from(a.entries()).forEach((([t,e])=>{""!==e&&null!==e&&void 0!==e||a.delete(t)})),console.log(`${t.pathfilename}?${a}`),Object(s["e"])(`${t.pathfilename}?${a}`).then((e=>{var a=Date.now(),o=i["b"].formatDate(a,"YYYYMMDDHHmmss");const n=Object(r["a"])(t.pathfilename+"list"+o+".csv","\ufeff"+e,"text/csv");!0!==n&&t.$q.notify({message:"Browser denied file download...",color:"negative",icon:"warning"})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})).finally((()=>{t.loading=!1}))},getListPrevious(){var t=this;d["a"].has("auth")&&Object(s["e"])(t.pathname_previous,{}).then((e=>{t.table_list=e.results,t.pathname_previous=e.previous,t.pathname_next=e.next})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})}))},getListNext(){var t=this;d["a"].has("auth")&&Object(s["e"])(t.pathname_next,{}).then((e=>{t.table_list=e.results,t.pathname_previous=e.previous,t.pathname_next=e.next})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})}))},reFresh(){var t=this;t.getSearchList()},newDataSubmit(){var t=this;t.newFormData.bound_type="out",t.newFormData.openid=t.openid,t.newFormData.base_type=1,Object(s["h"])(t.pathname,t.newFormData).then((e=>{t.getSearchList(),t.newDataCancel(),500!==e.status_code&&t.$q.notify({message:"成功新增数据",icon:"check",color:"green"})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})}))},newBatchSubmit(){var t=this;t.newBatchFormData.openid=t.openid,t.newBatchFormData.warehouse_code=t.warehouse_code,t.newBatchFormData.warehouse_name=t.warehouse_name,t.newBatchFormData.bound_list_id=t.detailid,Object(s["h"])("bound/outbatch/",t.newBatchFormData).then((e=>{500!==e.status_code&&(t.newDetailFormData.bound_batch=e.id,t.newDetailFormData.creater=t.login_name,Object(s["h"])("bound/outdetail/",t.newDetailFormData).then((e=>{500!==e.status_code&&(t.detailData(t.newDetailFormData),t.$q.notify({message:"成功新增数据",icon:"check",color:"green"}))}),(e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})))})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})),Object(s["e"])("bound/batch/?bound_number="+this.target_batch).then((t=>{console.log("当前长度",t.results.length),console.log("当前值",t.results[0]),t.results.length>0?(this.newBatchFormData.goods_qty=t.results[0].goods_qty,console.log("当前数目",this.newBatchFormData.goods_qty),this.newBatchFormData.goods_weight=t.results[0].goods_weight,this.newBatchFormData.goods_std=t.results[0].goods_std,this.newBatchFormData.goods_unit=t.results[0].goods_unit):(this.newBatchFormData.goods_qty="",this.newBatchFormData.goods_weight="",this.newBatchFormData.goods_std="",this.newBatchFormData.goods_unit="")})).catch((t=>{this.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},newDataCancel(){var t=this;t.newForm=!1,t.newFormData={bound_code_type:"",bound_bs_type:"",bound_desc:"",bound_department:"",creater:""}},addbatch(t){var e=this;e.newBatchForm=!0,e.newDetailFormData={id:t,bound_list:t}},editData(t){var e=this;e.editMode=!0,e.editid=t.id,e.editFormData={bound_date:t.bound_date,bound_code:t.bound_code,bound_code_type:t.bound_code_type,bound_bs_type:t.bound_bs_type,bound_desc:t.bound_desc,bound_department:t.bound_department,creater:e.login_name}},change_status(t){var e=this,a={bound_list_id:t.id};Object(s["h"])("container/out_task/",a).then((t=>{e.getSearchList(),500!==t.status_code&&e.$q.notify({message:"开始出库",icon:"check",color:"green"})})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},editDataSubmit(){var t=this;t.editFormData.bound_type="in",Object(s["i"])(t.pathname+t.editid+"/",t.editFormData).then((e=>{t.editDataCancel(),t.getSearchList(),500!==e.status_code&&t.$q.notify({message:"成功编辑数据",icon:"check",color:"green"})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})}))},editDataCancel(){var t=this;t.editMode=!1,t.editid=0,t.editFormData={bound_date:"",bound_code:"",bound_code_type:"",bound_bs_type:"",bound_desc:"",bound_department:"",creater:""}},deleteData(t){var e=this;e.deleteForm=!0,e.deleteid=t},detailData(t){var e=this;e.detailForm=!0,e.detailid=t.id,console.log("detail查询的id是:",e.detailid),Object(s["e"])(e.pathname+e.detailid+"/").then((t=>{e.table_detail=t})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})})),console.log("detail查询的结果是:",e.table_detail),Object(s["e"])("bound/outdetail/?bound_list="+e.detailid).then((t=>{e.batch_detail=t.results})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},deleteDataSubmit(){var t=this;Object(s["c"])(t.pathname+t.deleteid+"/").then((e=>{t.deleteDataCancel(),t.getSearchList(),t.$q.notify({message:"成功删除数据",icon:"check",color:"green"})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})}))},deleteDataCancel(){var t=this;t.deleteForm=!1,t.deleteid=0},updateProxy(){var t=this;t.proxyDate=t.date}},created(){var t=this;if(d["a"].has("openid")?t.openid=d["a"].getItem("openid"):(t.openid="",d["a"].set("openid","")),d["a"].has("warehouse_code")&&(t.warehouse_code=d["a"].getItem("warehouse_code")),d["a"].has("warehouse_name")&&(t.warehouse_name=d["a"].getItem("warehouse_name")),d["a"].has("login_name")?t.login_name=d["a"].getItem("login_name"):(t.login_name="",d["a"].set("login_name","")),d["a"].has("auth")){const e=Date.now(),a=i["b"].formatDate(e,"YYYY/MM/DD");t.date=a,console.log(t.date),t.authin="1",t.getList()}else t.authin="0";Object(s["e"])("warehouse/boundcodetype/",{}).then((e=>{t.bound_code_type_list=e.results.map((t=>({label:t.bound_code_type_name,value:t.bound_code_type_code}))),t.bound_code_type_map=e.results.reduce(((t,e)=>(t[e.bound_code_type_code]=e.bound_code_type_name,t)),{})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})),Object(s["e"])("warehouse/boundtype/",{}).then((e=>{t.bound_desc_list=e.results.map((t=>({label:t.bound_type_name,value:t.bound_type_code}))),t.bound_desc_map=e.results.reduce(((t,e)=>(t[e.bound_type_code]=e.bound_type_name,t)),{})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})),Object(s["e"])("warehouse/department/",{}).then((e=>{t.bound_department_list=e.results.map((t=>({label:t.department_name,value:t.department_code}))),t.bound_department_map=e.results.reduce(((t,e)=>(t[e.department_code]=e.department_name,t)),{})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})),Object(s["e"])("warehouse/boundbusiness/",{}).then((e=>{t.bound_bs_type_list=e.results.map((t=>({label:t.bound_bs_name,value:t.bound_bs_code}))),t.bound_bs_type_map=e.results.reduce(((t,e)=>(t[e.bound_bs_code]=e.bound_bs_name,t)),{})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})})),Object(s["e"])("warehouse/status/",{}).then((e=>{t.bound_status_list=e.results.map((t=>({label:t.bound_status_name,value:t.bound_status_code}))),t.bound_status_map=e.results.reduce(((t,e)=>(t[e.bound_status_code]=e.bound_status_name,t)),{})})).catch((e=>{t.$q.notify({message:e.detail,icon:"close",color:"negative"})}))},mounted(){var t=this;t.$q.platform.is.electron?t.height=String(t.$q.screen.height-290)+"px":t.height=t.$q.screen.height-290+"px",t.newFormData.creater=t.login_name},updated(){},destroyed(){},watch:{target_batch(t){t?(this.newBatchFormData.goods_code=t.split("-")[0],this.newBatchFormData.out_number=t,this.newBatchFormData.goods_desc=this.product_map[t]):(this.newBatchFormData.goods_code="",this.newBatchFormData.out_number="",this.newBatchFormData.goods_desc=""),Object(s["e"])("bound/batch/?bound_number="+t).then((t=>{console.log("当前长度",t.results.length),console.log("当前值",t.results[0]),t.results.length>0?(this.newBatchFormData.goods_qty=t.results[0].goods_qty,console.log("当前数目",this.newBatchFormData.goods_qty),this.newBatchFormData.goods_weight=t.results[0].goods_weight,this.newBatchFormData.goods_std=t.results[0].goods_std,this.newBatchFormData.goods_unit=t.results[0].goods_unit):(this.newBatchFormData.goods_qty="",this.newBatchFormData.goods_weight="",this.newBatchFormData.goods_std="",this.newBatchFormData.goods_unit="")})).catch((t=>{this.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},createDate1(t){t?(t.to?(this.createDate2=`${t.from} - ${t.to}`,this.date_range=`${t.from},${t.to} `):(this.createDate2=`${t}`,this.dateArray=t.split("/"),this.searchUrl=this.pathname+"?document_date__year="+this.dateArray[0]+"&document_date__month="+this.dateArray[1]+"&document_date__day="+this.dateArray[2]),this.date_range=this.date_range.replace(/\//g,"-"),this.getSearchList(),this.$refs.qDateProxy.hide()):(this.createDate2="",this.date_range="",this.getSearchList())}}},c=l,u=(a("bf2a"),a("42e1")),_=a("90d5"),b=a("eaac"),p=a("e7a9"),h=a("9c40"),m=a("05c0"),g=a("2c91"),w=a("27f9"),y=a("0016"),v=a("bd08"),f=a("db86"),q=a("ddd8"),D=a("3b16"),x=a("24e8"),F=a("f09f"),k=a("d847"),$=a("a370"),B=a("429b"),S=a("7460"),C=a("adad"),O=a("823b"),j=a("4b7e"),L=a("52ee"),P=a("8572"),Q=a("7f67"),I=a("eebe"),T=a.n(I),N=Object(u["a"])(c,o,n,!1,null,"6bac0e87",null);"function"===typeof _["default"]&&Object(_["default"])(N);e["default"]=N.exports;T()(N,"components",{QTable:b["a"],QBtnGroup:p["a"],QBtn:h["a"],QTooltip:m["a"],QSpace:g["a"],QInput:w["a"],QIcon:y["a"],QTr:v["a"],QTd:f["a"],QSelect:q["a"],QPagination:D["a"],QDialog:x["a"],QCard:F["a"],QBar:k["a"],QCardSection:$["a"],QTabs:B["a"],QTab:S["a"],QTabPanels:C["a"],QTabPanel:O["a"],QCardActions:j["a"],QDate:L["a"],QField:P["a"]}),T()(N,"directives",{ClosePopup:Q["a"]})},bf2a:function(t,e,a){"use strict";a("4813")}}]);
|