chunk-dee62854.e4969278.js 4.7 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-dee62854"],{a5d5:function(t,e,a){},b7ba:function(t,e,a){"use strict";a.r(e);var o=function(){var t=this,e=t._self._c;return e("div",{staticClass:"body"},[e("div",{staticClass:"table-page-search-box"},[e("a-form",{attrs:{layout:"inline"}},[e("a-row",{attrs:{gutter:24}},[e("a-col",{attrs:{md:8,sm:24}},[e("a-form-item",{attrs:{label:"供货商"}},[e("a-select",{staticStyle:{width:"215px"},attrs:{showSearch:!0,"filter-option":t.filterOption,allowClear:"",placeholder:"请选择"},model:{value:t.queryParam.supplier_id,callback:function(e){t.$set(t.queryParam,"supplier_id",e)},expression:"queryParam.supplier_id"}},t._l(t.supplierList,(function(a){return e("a-select-option",{key:a.id,attrs:{value:a.id}},[t._v(t._s(a.name))])})),1)],1)],1),e("a-col",{attrs:{md:8,sm:24}},[e("a-form-item",{attrs:{label:"出库单号"}},[e("a-input",{attrs:{"allow-clear":"",placeholder:"请输入出库单号"},model:{value:t.queryParam.order_no,callback:function(e){t.$set(t.queryParam,"order_no",e)},expression:"queryParam.order_no"}})],1)],1),e("a-col",{attrs:{md:8,sm:24}},[e("a-form-item",{attrs:{label:"商品名称"}},[e("a-input",{attrs:{"allow-clear":"",placeholder:"请输入商品名称"},model:{value:t.queryParam.goods_name,callback:function(e){t.$set(t.queryParam,"goods_name",e)},expression:"queryParam.goods_name"}})],1)],1),e("a-col",{attrs:{md:24,sm:24}},[e("div",{staticClass:"titleStyle",staticStyle:{"margin-top":"16px"}},[e("a-form-item",{attrs:{label:"操作人员"}},[e("a-input",{attrs:{"allow-clear":"",placeholder:"请输入操作人员"},model:{value:t.queryParam.operator,callback:function(e){t.$set(t.queryParam,"operator",e)},expression:"queryParam.operator"}})],1),e("a-button",{attrs:{type:"primary"},on:{click:function(e){return t.getList()}}},[t._v("搜索出库")])],1)])],1)],1)],1),e("div",{staticClass:"table-operator",staticStyle:{display:"flex","justify-content":"space-between",margin:"10px 0px"}},[e("div"),e("div",{staticStyle:{display:"flex"}},[e("div"),e("a-dropdown",[e("a-menu",{attrs:{slot:"overlay"},slot:"overlay"},[e("a-menu-item",[e("a-popconfirm",{attrs:{title:"是否批量导出?","ok-text":"确定"},on:{confirm:function(e){return t.handleAll("export")}}},[t._v(" 批量导出 ")])],1)],1),e("a-button",[t._v(" 批量操作 ")])],1)],1)]),e("a-table",{staticStyle:{width:"100%","overflow-x":"auto"},attrs:{rowSelection:{selectedRowKeys:t.selectedRowKeys,onChange:t.onSelectChange},size:"default",columns:t.columns,"data-source":t.list,"row-key":t=>t.id,scroll:{x:1500,y:550},pagination:{current:t.pageNo,total:t.total,pageSize:t.pageSize,onShowSizeChange:t.onShowSizeChange,showSizeChanger:!1,onChange:t.tablePageChange}},scopedSlots:t._u([{key:"action",fn:function(a,o){return e("span",{},[e("a-button",{attrs:{type:"link",size:"small"},on:{click:function(e){return t.handle("see",o)}}},[t._v("查看详情")])],1)}}])})],1)},r=[],s=(a("14d9"),a("0fc4"));const i=[{title:"ID",dataIndex:"id",width:80},{title:"出库单号",dataIndex:"order_no"},{title:"商品数量",dataIndex:"num"},{title:"操作人员",dataIndex:"operator"},{title:"添加时间",dataIndex:"created_at"},{title:"操作",scopedSlots:{customRender:"action"},width:180,fixed:"right"}];var l={components:{},data(){return{total:0,pageNo:1,pageSize:10,columns:i,queryParam:{supplier_id:"",order_no:"",goods_name:"",operator:""},list:[],selectedRowKeys:[],categoryInfo:[],statusList:[{id:"-1",title:"全部"},{id:"1",title:"已打印"},{id:"0",title:"未打印"}],supplierList:[]}},mounted(){this.getList(),Object(s["I"])().then(t=>{0==t.code&&(this.supplierList=t.data)})},computed:{getStatus(){return t=>{let e,a;switch(String(t)){case"0":e="未打印",a="rgba(0, 0, 0, 0.25)";break;case"1":e="已打印",a="#65C817";break}return[e,a]}}},methods:{filterOption(t,e){return e.componentOptions.children[0].text.toLowerCase().indexOf(t.toLowerCase())>=0},onSelectChange(t){this.selectedRowKeys=t},handleAll(t){const{selectedRowKeys:e}=this;if(e.length)switch(t){case"export":this.export(e.join(","));break}else this.$message.error("请至少选择一条数据~")},async getList(t=1){const{queryParam:e,pageSize:a}=this,o=await Object(s["C"])({...e,pageSize:a,pageNo:t});if(0==o.code){this.pageNo=t,this.selectedRowKeys=[];const{totalCount:e,list:a}=o.data;this.total=e,this.list=a}},tablePageChange(t){this.getList(t)},onShowSizeChange(t,e){this.pageSize=e,this.getList(t)},handle(t,e,a){switch(t){case"see":this.$router.push({path:"/productStorageOutItem?id="+e.id});break;case"edit":break}},async export(t){try{await Object(s["h"])(t)}catch(e){}}}},n=l,c=(a("d31f"),a("2877")),d=Object(c["a"])(n,o,r,!1,null,"27e1d4dc",null);e["default"]=d.exports},d31f:function(t,e,a){"use strict";a("a5d5")}}]);