巡检报告

yangwl
zhaoxiaolin 9 months ago
parent 98d72af284
commit 82de7503d3

@ -43,3 +43,13 @@ export function delProduce(recordId) {
});
}
export function getProduceReportXJ(orderNo) {
const data = {
orderNo
}
return request({
url: '/quality/qcProduceReport/getProduceReportXJ',
method: 'post',
data: data
});
}

@ -1,18 +1,18 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">
<el-form-item label="任务编号" prop="checkNo">
<el-form-item label="订单编码" prop="orderNo">
<el-input
v-model="queryParams.checkNo"
placeholder="请输入检验任务编号"
v-model="queryParams.orderNo"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料名称" prop="materialName">
<el-form-item label="物料编码" prop="materialCode">
<el-input
v-model="queryParams.materialName"
placeholder="请输入物料名称"
v-model="queryParams.materialCode"
placeholder="请输入物料编码"
clearable
@keyup.enter.native="handleQuery"
/>
@ -72,6 +72,7 @@
<el-table v-loading="loading" :data="incomeList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="recordId" align="center" prop="recordId" v-if="false"/>
<el-table-column label="任务日期" align="center" prop="createTimeStr" width="100"/>
<el-table-column label="检验任务编号" align="center" prop="checkNo" width="120"/>
<el-table-column label="订单号" align="center" prop="orderNo" width="150"/>
<el-table-column label="物料名称" align="center" prop="materialName" width="150"/>
@ -124,8 +125,8 @@
</el-col>
</el-row>
<!-- 打印整个printFrom区域 -->
<div id="printFrom">
<el-form :ref="formRef" :model="form" :rules="validateRules">
<div id="printForm">
<el-form :ref="formRef" :model="form">
<!-- 表头-工单信息 -->
<el-row>
<el-col :offset="7" :span="10" class="center-text">
@ -139,11 +140,11 @@
</el-row>
<!-- 导航栏 -->
<el-row class="my-print-nav">
<el-col :span="4">生成车间:{{printData.workCenter}}</el-col>
<el-col :span="4">生成线体:{{printData.workCenter}}</el-col>
<el-col :span="4">检查日期:{{printData.productDate}}</el-col>
<el-col :span="4">产品名称:{{printData.printDate}}</el-col>
<el-col :span="4">批次号:{{printData.printDate}}</el-col>
<el-col :span="3">生成车间:{{form.supplierName}}</el-col>
<el-col :span="3">生成线体:{{form.lineName}}</el-col>
<el-col :span="3">检查日期:{{form.checkTimeStart}}</el-col>
<el-col :span="4">产品名称:{{form.materialName}}</el-col>
<el-col :span="6">批次号:{{form.incomeBatchNo}}</el-col>
<el-col :span="4">生产类型:
<el-checkbox-group v-model="checkList">
<el-checkbox label="正常"></el-checkbox>
@ -157,7 +158,7 @@
v-if="refreshNewWorkerTable"
v-loading="newWorkerLoading"
class="my-print-table"
:data="printData.workTable"
:data="form.checkInfos"
border
style="width: 100%">
<el-table-column label="id" align="center" prop="recordId" v-if="false"/>
@ -213,12 +214,9 @@
</el-row>
<!-- 打印整个firstReportPrint区域 -->
<div id="firstReportPrint">
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form ref="form" :model="form" label-width="100px">
<el-row>
<el-col :span="7">
<img src="@/assets/logo/lanjv.png" class="report-logo"/>
</el-col>
<el-col :span="10" class="center-text">
<el-col :offset="7" :span="10" class="center-text">
<h1>中山榄菊日化实业有限公司</h1>
</el-col>
</el-row>
@ -323,7 +321,7 @@
</template>
<script>
import { listProduce, getProduce, delProduce, addProduce, updateIncome} from "@/api/quality/produceReport";
import { listProduce, getProduce, delProduce, addProduce, updateIncome,getProduceReportXJ} from "@/api/quality/produceReport";
import { getCkeckProjectList} from "@/api/quality/incomeReport";
import { getCheckTypes } from "@/api/quality/qcProduce";
import moment from 'moment';
@ -351,7 +349,7 @@ export default {
validateRules: [],
checkList: [],
printData: {
printable: 'printFrom',
printable: 'printForm',
ignore: ['no-print'],
workCenter: "暂无数据",
SAPNo: null,
@ -360,7 +358,12 @@ export default {
printDate: null,
factory: null,
productDate: null,
workTable: [],
supplierName:null,
lineName:null,
checkTimeStart:null,
materialName:null,
incomeBatchNo:null,
checkInfos:[]
},
printDialogVisible: false,
//
@ -432,7 +435,7 @@ export default {
getDate() {
let start = this.Fungetdate (0)
let end = this.Fungetdate (1)
this.queryParams.incomeTimeArray.push(start,end)
//this.queryParams.incomeTimeArray.push(start,end)
this.queryParams.checkTimeArray.push(start,end)
},
Fungetdate (num) {
@ -538,19 +541,17 @@ export default {
this.queryParams.recordId = recordId;
this.getCheckedProjectList();
}else {
const orderNo = row.orderNo;
getProduceReportXJ(orderNo).then(response => {
this.form = response;
//
this.form.printable = 'printForm'; //
this.form.ignore = ['no-print'];//
this.open = true;
this.title = "巡检检验报告";
const orderNo = row.orderNo;
getProduceXJ(orderNo).then(response => {
this.form = response.data;
//
this.form.printable = 'firstReportPrint'; //
this.form.ignore = ['no-print'];//
this.firstReportOpen = true;
this.title = "首检检验报告";
this.refreshNewWorkerTable = true // refreshProTabletrue
this.newWorkerLoading = false // false
})
}
@ -602,9 +603,9 @@ export default {
},
// -
handlePrint(params) {
console.log(this.form);
printJS({
printable: params.printable, // 'printFrom', // id
printable: params.printable, // id
type: params.type || 'html',
maxWidth: 1500, //
font_size: "",//
@ -630,11 +631,6 @@ export default {
.center-text {
text-align: center;
}
.report-logo {
margin-top: 15px;
margin-left: 15px;
height: 38px;
}
.my-print-nav {
margin-top: 15px;
margin-bottom: 15px;

Loading…
Cancel
Save