1
This commit is contained in:
parent
7e9deef790
commit
9b0f14c613
@ -22,7 +22,8 @@
|
||||
<el-date-picker v-model="queryParams.timeRange" type="daterange" range-separator="到" start-placeholder="开始时间" end-placeholder="结束时间" placeholder="请选择日期区间" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button icon="search" type="primary" @click="handleQuery">{{ $t('btn.search') }}</el-button>
|
||||
<el-button icon="search" type="primary" @click="handleQuery(0)">{{ $t('btn.search') }}全部</el-button>
|
||||
<el-button icon="search" type="primary" @click="handleQuery(1)">{{ $t('btn.search') }}仓库确认数大于0</el-button>
|
||||
<el-button icon="refresh" @click="resetQuery">{{ $t('btn.reset') }}</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
@ -192,13 +193,13 @@
|
||||
<!-- 打印工单 -->
|
||||
<ZrDialog v-model="PrintDialogShow" :fullScreen="true" append-to-body draggable :close-on-click-modal="false">
|
||||
<div id="printTable">
|
||||
<div v-for="(printTableData, printTableIndex) in printList" :key="printTableIndex">
|
||||
<div>
|
||||
<div class="company-box">上海干巷车镜实业有限公司</div>
|
||||
<div class="title-box">每日报工清单</div>
|
||||
<div class="time-box">日期:{{ dayjs().format('YYYY-MM-DD') }}</div>
|
||||
<div class="header-box">
|
||||
<!-- <div class="header-box">
|
||||
<div>{{ `组别: ${printTableData[0].groupCode}` }}</div>
|
||||
</div>
|
||||
</div> -->
|
||||
<table class="printTableClass" border="1">
|
||||
<thead>
|
||||
<th style="width: 30px">序号</th>
|
||||
@ -214,7 +215,7 @@
|
||||
<th style="min-width: 100px">备注</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(item, index) in printTableData" :key="index">
|
||||
<tr v-for="(item, index) in printList" :key="printTableIndex">
|
||||
<td>{{ index + 1 }}</td>
|
||||
<td>{{ item.fkWorkorder }}</td>
|
||||
<td>{{ item.productionCode }}</td>
|
||||
@ -251,6 +252,7 @@ const queryParams = reactive({
|
||||
fkWorkorder: '',
|
||||
groupCode: '',
|
||||
lineCode: '',
|
||||
warehouseconfirmationNum: 0,
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
sort: '',
|
||||
@ -340,8 +342,9 @@ function getList() {
|
||||
}
|
||||
|
||||
// 查询
|
||||
function handleQuery() {
|
||||
function handleQuery(warehouseconfirmationNum = 0) {
|
||||
queryParams.pageNum = 1
|
||||
queryParams.warehouseconfirmationNum = warehouseconfirmationNum
|
||||
getList()
|
||||
}
|
||||
|
||||
@ -393,8 +396,9 @@ function reset() {
|
||||
form.value = {
|
||||
id: null,
|
||||
fkWorkorder: null,
|
||||
dispatchNum: null,
|
||||
finishedNum: null,
|
||||
dispatchNum: 0,
|
||||
finishedNum: 0,
|
||||
qualifiedNumber:0,
|
||||
groupCode: null,
|
||||
lineCode: null,
|
||||
createdBy: null,
|
||||
@ -623,15 +627,17 @@ function handlePrint() {
|
||||
}
|
||||
function getPrintList() {
|
||||
const _list = allList.value
|
||||
const groupedData = _list.reduce((acc, item) => {
|
||||
const key = item.groupCode
|
||||
if (!acc[key]) {
|
||||
acc[key] = []
|
||||
}
|
||||
acc[key].push(item)
|
||||
return acc
|
||||
}, {})
|
||||
return Object.values(groupedData)
|
||||
|
||||
return _list
|
||||
// const groupedData = _list.reduce((acc, item) => {
|
||||
// const key = item.groupCode
|
||||
// if (!acc[key]) {
|
||||
// acc[key] = []
|
||||
// }
|
||||
// acc[key].push(item)
|
||||
// return acc
|
||||
// }, {})
|
||||
// return Object.values(groupedData)
|
||||
}
|
||||
/// ================================================
|
||||
|
||||
|
||||
@ -469,7 +469,7 @@
|
||||
<th style="width: 40px">缺陷描述</th>
|
||||
<th style="width: 30px">返工</th>
|
||||
<th style="width: 30px">报废</th>
|
||||
<th style="min-width: 260px">手动标签留样确认</th>
|
||||
<th style="min-width: 260px">首件标签留样确认</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(item, index) in printTableData" :key="index">
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user