不良品问题单据 和入库单 加到货日期

This commit is contained in:
杰 朱
2021-10-06 13:38:11 +08:00
parent 275e23ad2e
commit f63848d323
6 changed files with 168 additions and 1 deletions

View File

@@ -0,0 +1,160 @@
<template>
<div>
<h4>不良品处理问题单据</h4>
<Table style="margin-top: 20px" size="small" border :columns="columns" :data="pagedData"> </Table>
<Page
style="margin-top: 20px"
:current="pageNo"
:page-size="pageSize"
:total="total"
:page-size-opts="PageSizeOpts"
@on-change="handlePagechange"
@on-page-size-change="handlePageSize"
show-elevator
show-sizer
show-total
size="small"
/>
</div>
</template>
<script>
import { QmError } from '@/api/pmc'
import { pageingData, export_col_to_excel, dateFormatFull, dateFormat, sortByKey } from '@/libs/tools'
export default {
data() {
return {
PageSizeOpts: [10, 15, 20, 30],
pageNo: 1,
strfilter: '',
multiple: false,
pageSize: 15,
datas: [],
filter: {
inv_codes: '',
inv_std: '',
so_code: '',
dates: [],
by_finish: false
},
columns: [
{
title: '应退存货编码',
align: 'center',
key: 'qminvcode',
},
{
title: '存货名称',
align: 'center',
key: 'CINVNAME',
},
{
title: '被错误关联存货',
align: 'center',
key: 'poinvcode',
},
{
title: '不良品处理单',
align: 'center',
key: 'CREJECTCODE'
},
{
title: '退货单号',
align: 'center',
key: 'cCode',
className: 'demo-table-info-new'
},
{
title: '红字入库单号',
align: 'center',
key: 'rkcCode'
},
]
}
},
computed: {
total() {
return this.datas.length
},
pagedData() {
return pageingData(this.datas, this.pageSize, this.pageNo)
}
},
mounted() {
this.loadData()
},
methods: {
handelExport() {
export_col_to_excel(this.columns, this.datas)
},
handleClick() {
this.loadData()
},
async loadData() {
let resp = await QmError({})
this.pageNo = 1
this.datas = resp.data.data
},
handlePagechange(page) {
this.pageNo = page
},
handlePageSize(pageSize) {
this.pageSize = pageSize
}
}
}
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style >
h3 {
margin: 40px 0 0;
}
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
.ivu-table .demo-table-info-row td {
background-color: #2db7f5;
color: #fff;
}
.ivu-table .demo-table-error-row td {
background-color: #ff6600;
color: #fff;
}
.ivu-table td.demo-table-info-old {
color: #2db7f5;
}
.ivu-table td.demo-table-info-new {
color: #ff6600;
}
.ivu-table td.demo-table-info-ex {
color: #187;
font-weight: 600;
}
body {
padding: 10px 1;
}
</style>