Merge remote-tracking branch 'origin/master'

master
夜笙歌 9 months ago
commit 2d7439f0b1

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询灌注记录列表
export function listPerfusionRecord(query) {
return request({
url: '/report/perfusionRecord/list',
method: 'get',
params: query
})
}
// 查询灌注记录详细
export function getPerfusionRecord(objId) {
return request({
url: '/report/perfusionRecord/' + objId,
method: 'get'
})
}
// 新增灌注记录
export function addPerfusionRecord(data) {
return request({
url: '/report/perfusionRecord',
method: 'post',
data: data
})
}
// 修改灌注记录
export function updatePerfusionRecord(data) {
return request({
url: '/report/perfusionRecord',
method: 'put',
data: data
})
}
// 删除灌注记录
export function delPerfusionRecord(objId) {
return request({
url: '/report/perfusionRecord/' + objId,
method: 'delete'
})
}

@ -90,6 +90,15 @@ export function productTraceabilityReportList(query) {
}) })
} }
// 产品追溯明细
export function productTraceabilityDetailList(query) {
return request({
url: '/report/qualityReport/productTraceabilityDetailList',
method: 'get',
params: query
})
}
// 测温记录报表 // 测温记录报表
export function temperatureRecordReportList(query) { export function temperatureRecordReportList(query) {
return request({ return request({

@ -1,6 +1,6 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="90px">
<!-- <el-form-item label="测试总结果" prop="result">--> <!-- <el-form-item label="测试总结果" prop="result">-->
<!-- <el-input--> <!-- <el-input-->
<!-- v-model="queryParams.result"--> <!-- v-model="queryParams.result"-->
@ -28,6 +28,16 @@
end-placeholder="结束日期" end-placeholder="结束日期"
></el-date-picker> ></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label="测试总结果" prop="result">
<el-select v-model="queryParams.result" placeholder="请选择测试总结果" clearable>
<el-option
v-for="dict in dict.type.electrical_result"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button> <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button> <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
@ -224,6 +234,7 @@ import { parseTime } from '@//utils/ruoyi'
export default { export default {
name: 'ElectricalInspection', name: 'ElectricalInspection',
dicts: ['electrical_result'],
data() { data() {
return { return {
// //

@ -1,61 +1,35 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="产线" prop="PRODUCT_LINE_NAME"> <el-form-item label="箱体码" prop="perfusionBoxcode">
<el-select v-model="queryParams.WORK_CENTER_CODE" placeholder="请选择产线">
<el-option
v-for="item in productLineList"
:key="item.workCenterCode"
:label="item.workCenterName"
:value="item.workCenterCode"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="产品编码" prop="MATERIAL_CODE">
<el-input
v-model="queryParams.MATERIAL_CODE"
placeholder="请输入产品编码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="产品名称" prop="MATERIAL_NAME">
<el-input <el-input
v-model="queryParams.MATERIAL_NAME" v-model="queryParams.perfusionBoxcode"
placeholder="请输入产品名称" placeholder="请输入箱体码"
clearable clearable
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="SAP订单编号" prop="ORDER_CODE"> <el-form-item label="灌注时间">
<el-input
v-model="queryParams.ORDER_CODE"
placeholder="请输入SAP计划编号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="工位">
<el-select v-model="queryParams.stationCode" placeholder="请选择工位">
<el-option
v-for="item in findStationList"
:key="item.productLineCode"
:label="item.productLineName"
:value="item.productLineCode"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="起止时间">
<el-date-picker <el-date-picker
v-model="daterangeBeginTime" v-model="daterangeCreatedTime"
style="width: 340px" style="width: 340px"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange" type="datetimerange"
range-separator="-" range-separator="-"
start-placeholder="开始时间" start-placeholder="开始时间"
end-placeholder="结束时间" end-placeholder="结束时间"
></el-date-picker> ></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label="灌注结果" prop="perfusionResult">
<el-select v-model="queryParams.perfusionResult" placeholder="请选择灌注结果" clearable>
<el-option
v-for="dict in dict.type.perfusion_result"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button> <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button> <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
@ -63,70 +37,74 @@
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<!-- <el-col :span="1.5">--> <el-col :span="1.5">
<!-- <el-button--> <el-button
<!-- type="warning"--> type="warning"
<!-- plain--> plain
<!-- icon="el-icon-download"--> icon="el-icon-download"
<!-- size="mini"--> size="mini"
<!-- @click="handleExport"--> @click="handleExport"
<!-- >导出--> >导出
<!-- </el-button>--> </el-button>
<!-- </el-col>--> </el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
</el-row> </el-row>
<el-table v-loading="loading" :data="reportList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="perfusionRecordList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/> <el-table-column type="selection" width="55" align="center"/>
<el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/> <el-table-column label="主键" align="center" prop="objId" v-if="columns[0].visible"/>
<el-table-column label="箱体码" align="center" prop="PERFUSION_BOXCODE" v-if="columns[1].visible"/> <el-table-column label="箱体码" align="center" prop="perfusionBoxcode" v-if="columns[1].visible" width="120"/>
<el-table-column label="左侧冷媒型号" align="center" prop="PERFUSION_REFRIGERANTTYPELEFT" v-if="columns[2].visible"/> <el-table-column label="左侧冷媒型号" align="center" prop="perfusionRefrigeranttypeleft" v-if="columns[2].visible"/>
<el-table-column label="右侧侧冷媒型号" align="center" prop="PERFUSION_REFRIGERANTTYPERIGHT" v-if="columns[3].visible"/> <el-table-column label="右侧侧冷媒型号" align="center" prop="perfusionRefrigeranttyperight" v-if="columns[3].visible"/>
<el-table-column label="设置灌注量" align="center" prop="PERFUSION_SETVOLUME" v-if="columns[4].visible"/> <el-table-column label="设置灌注量" align="center" prop="perfusionSetvolume" v-if="columns[4].visible" width="100"/>
<el-table-column label="实际灌注量" align="center" prop="PERFUSION_ACTUALVOLUME" v-if="columns[5].visible"/> <el-table-column label="实际灌注量" align="center" prop="perfusionActualvolume" v-if="columns[5].visible" width="100"/>
<el-table-column label="灌注压力_R" align="center" prop="PERFUSION_R" v-if="columns[6].visible"/> <el-table-column label="灌注压力_R" align="center" prop="perfusionR" v-if="columns[6].visible" width="120"/>
<el-table-column label="灌注压力_L" align="center" prop="PERFUSION_L" v-if="columns[7].visible"/> <el-table-column label="灌注压力_L" align="center" prop="perfusionL" v-if="columns[7].visible" width="100"/>
<el-table-column label="灌注时长" align="center" prop="PERFUSION_DURATION" v-if="columns[7].visible"/> <el-table-column label="灌注时长" align="center" prop="perfusionDuration" v-if="columns[8].visible"/>
<el-table-column label="系统" align="center" prop="PERFUSION_SYSTEM" v-if="columns[7].visible"/> <el-table-column label="系统" align="center" prop="perfusionSystem" v-if="columns[9].visible"/>
<el-table-column label="灌注结果" align="center" prop="PERFUSION_RESULT" v-if="columns[7].visible"/> <el-table-column label="创建人" align="center" prop="createdBy" v-if="columns[10].visible"/>
<el-table-column label="记录时间" align="center" prop="CREATED_TIME" v-if="columns[7].visible"> <el-table-column label="灌注时间" align="center" prop="createdTime" width="180" v-if="columns[11].visible">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.BEGIN_DATE, '{y}-{m}-{d} {h}:{i}:{s}') }}</span> <span>{{ parseTime(scope.row.createdTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column label="操作" align="center" class-name="small-padding fixed-width">--> <el-table-column label="更新人" align="center" prop="updatedBy" v-if="columns[12].visible"/>
<!-- <template slot-scope="scope">--> <el-table-column label="更新时间" align="center" prop="updatedTime" width="180" v-if="columns[13].visible">
<!-- <el-button--> <template slot-scope="scope">
<!-- size="mini"--> <span>{{ parseTime(scope.row.updatedTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
<!-- type="text"--> </template>
<!-- icon="el-icon-search"--> </el-table-column>
<!-- @click="handleOrderDetails(scope.row)"--> <el-table-column label="灌注结果" align="center" prop="perfusionResult" v-if="columns[14].visible" width="120">
<!-- v-hasPermi="['report:pointDnb:edit']"--> <template slot-scope="scope">
<!-- >检验详情</el-button>--> <dict-tag :options="dict.type.perfusion_result" :value="scope.row.perfusionResult"/>
<!-- </template>--> </template>
<!-- </el-table-column>--> </el-table-column>
<el-table-column label="产量" align="center" prop="yield" v-if="columns[15].visible"/>
<el-table-column label="灌注完成状态字" align="center" prop="finishStatus" v-if="columns[16].visible" width="120"/>
</el-table> </el-table>
<!-- <pagination-->
<!-- v-show="total>0"--> <pagination
<!-- :total="total"--> v-show="total>0"
<!-- :page.sync="queryParams.pageNum"--> :total="total"
<!-- :limit.sync="queryParams.pageSize"--> :page.sync="queryParams.pageNum"
<!-- @pagination="getList"--> :limit.sync="queryParams.pageSize"
<!-- />--> @pagination="getList"
/>
</div> </div>
</template> </template>
<script> <script>
import { import {
pourRecordReportList listPerfusionRecord,
} from '@/api/report/reportAPI' getPerfusionRecord
import { findProductLineList } from '@//api/base/productLine' } from '@/api/report/perfusionRecord'
import { parseTime } from '@//utils/ruoyi' import { parseTime } from '@//utils/ruoyi'
export default { export default {
name: 'ReportInfo', name: 'PerfusionRecord',
dicts: ['is_flag'], dicts: ['perfusion_result'],
data() { data() {
return { return {
// //
@ -141,73 +119,78 @@ export default {
showSearch: true, showSearch: true,
// //
total: 0, total: 0,
// //
reportList: [], perfusionRecordList: [],
// //
title: '', title: '',
// //
open: false, open: false,
// //
daterangeBeginTime: [], daterangeCreatedTime: [],
// //
queryParams: { queryParams: {
// pageNum: 1, pageNum: 1,
// pageSize: 10, pageSize: 10,
beginBeginTime: null, perfusionBoxcode: null,
endBeginTime: null, perfusionRefrigeranttypeleft: null,
WORK_CENTER_CODE: null, perfusionRefrigeranttyperight: null,
PRODUCT_LINE_NAME: null, perfusionSetvolume: null,
ORDER_CODE: null, perfusionActualvolume: null,
MATERIAL_CODE: null, perfusionR: null,
MATERIAL_NAME: null, perfusionL: null,
BEGIN_DATE: null perfusionDuration: null,
perfusionSystem: null,
createdBy: null,
createdTime: null,
updatedBy: null,
updatedTime: null,
perfusionResult: null,
yield: null,
finishStatus: null
}, },
// //
form: {}, form: {},
// //
rules: {}, rules: {},
columns: [ columns: [
{ key: 0, label: `主键标识`, visible: false }, { key: 0, label: `主键`, visible: false },
{ key: 1, label: `工位`, visible: true }, { key: 1, label: `箱体码`, visible: true },
{ key: 2, label: `订单编号`, visible: true }, { key: 2, label: `左侧冷媒型号`, visible: false },
{ key: 3, label: `物料编码`, visible: true }, { key: 3, label: `右侧侧冷媒型号`, visible: false },
{ key: 4, label: `物料名称`, visible: true }, { key: 4, label: `设置灌注量`, visible: true },
{ key: 5, label: `产品编码`, visible: true }, { key: 5, label: `实际灌注量`, visible: true },
{ key: 6, label: `产品型号`, visible: true }, { key: 6, label: `灌注压力_R`, visible: true },
{ key: 7, label: `数量`, visible: true }, { key: 7, label: `灌注压力_L`, visible: true },
], { key: 8, label: `灌注时长`, visible: true },
// 线 { key: 9, label: `系统`, visible: true },
productLineList: [], { key: 10, label: `创建人`, visible: false },
// { key: 11, label: `灌注时间`, visible: true },
findStationList: [] { key: 12, label: `更新人`, visible: false },
{ key: 13, label: `更新时间`, visible: true },
{ key: 14, label: `灌注结果`, visible: true },
{ key: 15, label: `产量`, visible: true },
{ key: 16, label: `灌注完成状态字`, visible: false }
]
} }
}, },
created() { created() {
findProductLineList({ productLineType: 1 }).then(response => {
this.productLineList = response.data
})
findProductLineList({productLineType: 2}).then(response => {
this.findStationList = response.data;
});
const nowDate = parseTime(new Date(), '{y}-{m}-{d}') const nowDate = parseTime(new Date(), '{y}-{m}-{d}')
this.daterangeBeginTime[0] = nowDate this.daterangeCreatedTime[0] = nowDate + ' 00:00:00'
this.daterangeBeginTime[1] = nowDate this.daterangeCreatedTime[1] = nowDate + ' 23:59:59'
this.getList() this.getList()
}, },
methods: { methods: {
/** 查询工单信息列表 */ /** 查询灌注记录列表 */
getList() { getList() {
this.loading = true this.loading = true
if (null != this.daterangeBeginTime && '' != this.daterangeBeginTime) { this.queryParams.params = {}
this.queryParams.beginBeginTime = this.daterangeBeginTime[0] if (null != this.daterangeCreatedTime && '' != this.daterangeCreatedTime) {
this.queryParams.endBeginTime = this.daterangeBeginTime[1] this.queryParams.params['beginCreatedTime'] = this.daterangeCreatedTime[0]
} else { this.queryParams.params['endCreatedTime'] = this.daterangeCreatedTime[1]
this.queryParams.beginBeginTime = null
this.queryParams.endBeginTime = null
} }
pourRecordReportList(this.queryParams).then(response => { listPerfusionRecord(this.queryParams).then(response => {
this.reportList = response.data this.perfusionRecordList = response.rows
this.total = response.total; this.total = response.total
this.loading = false this.loading = false
}) })
}, },
@ -218,46 +201,97 @@ export default {
}, },
// //
reset() { reset() {
this.daterangeBeginTime = []
this.form = { this.form = {
WORK_CENTER_CODE: null, objId: null,
PRODUCT_LINE_NAME: null, perfusionBoxcode: null,
ORDER_CODE: null, perfusionRefrigeranttypeleft: null,
MATERIAL_CODE: null, perfusionRefrigeranttyperight: null,
MATERIAL_NAME: null, perfusionSetvolume: null,
BEGIN_DATE: null perfusionActualvolume: null,
perfusionR: null,
perfusionL: null,
perfusionDuration: null,
perfusionSystem: null,
createdBy: null,
createdTime: null,
updatedBy: null,
updatedTime: null,
perfusionResult: null,
yield: null,
finishStatus: null
} }
this.resetForm('form') this.resetForm('form')
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery() { handleQuery() {
// this.queryParams.pageNum = 1; this.queryParams.pageNum = 1
this.getList() this.getList()
}, },
/** 重置按钮操作 */ /** 重置按钮操作 */
resetQuery() { resetQuery() {
this.daterangeCreatedTime = []
this.resetForm('queryForm') this.resetForm('queryForm')
this.handleQuery() this.handleQuery()
}, },
/** 查看明细 */
handleOrderDetails(row) {
this.$tab.openPage("SAP订单信息","/order/orderInfo" , {ORDER_CODE: row.ORDER_CODE});
},
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map(item => item.objId) this.ids = selection.map(item => item.objId)
this.single = selection.length !== 1 this.single = selection.length !== 1
this.multiple = !selection.length this.multiple = !selection.length
}, },
/** 新增按钮操作 */
handleAdd() {
this.reset()
this.open = true
this.title = '添加灌注记录'
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset()
const objId = row.objId || this.ids
getPerfusionRecord(objId).then(response => {
this.form = response.data
this.open = true
this.title = '修改灌注记录'
})
},
/** 提交按钮 */
submitForm() {
this.$refs['form'].validate(valid => {
if (valid) {
if (this.form.objId != null) {
updatePerfusionRecord(this.form).then(response => {
this.$modal.msgSuccess('修改成功')
this.open = false
this.getList()
})
} else {
addPerfusionRecord(this.form).then(response => {
this.$modal.msgSuccess('新增成功')
this.open = false
this.getList()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete(row) {
const objIds = row.objId || this.ids
this.$modal.confirm('是否确认删除灌注记录编号为"' + objIds + '"的数据项?').then(function() {
return delPerfusionRecord(objIds)
}).then(() => {
this.getList()
this.$modal.msgSuccess('删除成功')
}).catch(() => {
})
},
/** 导出按钮操作 */ /** 导出按钮操作 */
handleExport() { handleExport() {
this.download('/report/productionReport/export', { this.download('report/perfusionRecord/export', {
...this.queryParams ...this.queryParams
}, `report_${new Date().getTime()}.xlsx`) }, `perfusionRecord_${new Date().getTime()}.xlsx`)
} }
} }
} }
</script> </script>

@ -2,12 +2,12 @@
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="产线" prop="PRODUCT_LINE_NAME"> <el-form-item label="产线" prop="PRODUCT_LINE_NAME">
<el-select v-model="queryParams.WORK_CENTER_CODE" placeholder="请选择产线"> <el-select v-model="queryParams.PRODUCT_LINE_CODE" placeholder="请选择产线">
<el-option <el-option
v-for="item in productLineList" v-for="item in productLineList"
:key="item.workCenterCode" :key="item.productLineCode"
:label="item.workCenterName" :label="item.productLineName"
:value="item.workCenterCode" :value="item.productLineCode"
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
@ -35,21 +35,27 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="工位"> <el-form-item label="MES条码" prop="BOX_CODE">
<el-select v-model="queryParams.stationCode" placeholder="请选择工位"> <el-input
<el-option v-model="queryParams.BOX_CODE"
v-for="item in findStationList" placeholder="请输入MES条码"
:key="item.productLineCode" clearable
:label="item.productLineName" @keyup.enter.native="handleQuery"
:value="item.productLineCode" />
></el-option> </el-form-item>
</el-select> <el-form-item label="成品条码" prop="PRODUCT_SNCODE">
<el-input
v-model="queryParams.PRODUCT_SNCODE"
placeholder="请输入SAP成品条码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item> </el-form-item>
<el-form-item label="起止时间"> <el-form-item label="起止时间">
<el-date-picker <el-date-picker
v-model="daterangeBeginTime" v-model="daterangeBeginTime"
style="width: 340px" style="width: 340px"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange" type="datetimerange"
range-separator="-" range-separator="-"
start-placeholder="开始时间" start-placeholder="开始时间"
@ -77,20 +83,17 @@
</el-row> </el-row>
<el-table v-loading="loading" :data="reportList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="reportList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center"/> <!-- <el-table-column type="selection" width="55" align="center"/>-->
<el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/> <el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/>
<el-table-column label="工厂" align="center" prop="PRODUCT_STATION" v-if="columns[1].visible"/> <!-- <el-table-column label="工厂" align="center" prop="PRODUCT_STATION" v-if="columns[1].visible"/>-->
<el-table-column label="产线" align="center" prop="ORDER_CODE" v-if="columns[2].visible"/> <el-table-column label="产线" align="center" prop="PRODUCT_LINE_NAME" v-if="columns[2].visible" width="70"/>
<el-table-column label="SAP订单编号" align="center" prop="MATERIAL_CODE" v-if="columns[3].visible"> <el-table-column label="SAP订单编号" align="center" prop="ORDER_CODE" v-if="columns[3].visible"/>
<template slot-scope="scope"> <el-table-column label="销售订单号" align="center" prop="SALEORDER_CODE" v-if="columns[4].visible"/>
<span>{{ parseTime(scope.row.BEGIN_DATE, '{y}-{m}-{d}') }}</span> <el-table-column label="销售订单行号" align="center" prop="SALEORDER_LINENUMBER" v-if="columns[5].visible"/>
</template> <el-table-column label="产品编码" align="center" prop="MATERIAL_CODE" v-if="columns[6].visible"/>
</el-table-column> <el-table-column label="产品名称" align="center" prop="MATERIAL_NAME" v-if="columns[7].visible" width="250"/>
<el-table-column label="销售订单号" align="center" prop="MATERIAL_NAME" v-if="columns[4].visible"/> <el-table-column label="MES条码" align="center" prop="BOX_CODE" v-if="columns[8].visible" width="200"/>
<el-table-column label="销售订单行号" align="center" prop="PRODUCT_CODE" v-if="columns[5].visible"/> <el-table-column label="成品条码" align="center" prop="PRODUCT_SNCODE" v-if="columns[9].visible" width="200"/>
<el-table-column label="物料编码" align="center" prop="PRODUCT_NAME" v-if="columns[6].visible"/>
<el-table-column label="MES条码" align="center" prop="COMPLETE_AMOUNT" v-if="columns[7].visible"/>
<el-table-column label="成品条码" align="center" prop="COMPLETE_AMOUNT" v-if="columns[7].visible"/>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
@ -98,32 +101,82 @@
type="text" type="text"
icon="el-icon-search" icon="el-icon-search"
@click="handleOrderDetails(scope.row)" @click="handleOrderDetails(scope.row)"
v-hasPermi="['report:pointDnb:edit']" >检验详情
>检验详情</el-button> </el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 详情信息对话框 -->
<el-dialog :title="title" :visible.sync="open" width="1000px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-row gutter="15">
<el-col :span="11">
<el-form-item label="SAP订单编号" prop="ORDER_CODE">
<el-input v-model="form.ORDER_CODE" placeholder="请输入SAP订单编号" :disabled="true"/>
</el-form-item>
</el-col>
<el-col :span="11">
<el-form-item label="MES条码" prop="BOX_CODE">
<el-input v-model="form.BOX_CODE" placeholder="请输入MES条码" :disabled="true"/>
</el-form-item>
</el-col>
</el-row>
<el-divider content-position="center">产品检验详情信息</el-divider>
<el-table :data="reportDetailList" :row-class-name="rowDetailIndex"
ref="reportDetailRef"
>
<!-- <el-table-column type="selection" width="50" align="center"/>-->
<el-table-column label="序号" prop="index" width="150">
</el-table-column>
<el-table-column label="质检工位" prop="PRODUCT_LINE_NAME" width="150">
</el-table-column>
<el-table-column label="处理措施" prop="TREATMENT_MEASURE" width="150">
<template slot-scope="scope">
<dict-tag :options="dict.type.treatment_measures" :value="scope.row.TREATMENT_MEASURE"/>
</template>
</el-table-column>
<el-table-column label="返修结果" prop="PROCESS_RESULT" width="150">
</el-table-column>
<el-table-column label="检验时间" prop="INSPECTOR_TIME" width="150">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.INSPECTOR_TIME, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="检验人" prop="USER_NAME" width="150">
</el-table-column>
</el-table> </el-table>
<!-- <pagination--> </el-form>
<!-- v-show="total>0"--> <div slot="footer" class="dialog-footer">
<!-- :total="total"--> <el-button @click="cancel"> </el-button>
<!-- :page.sync="queryParams.pageNum"--> </div>
<!-- :limit.sync="queryParams.pageSize"--> </el-dialog>
<!-- @pagination="getList"-->
<!-- />-->
</div> </div>
</template> </template>
<script> <script>
import { import {
productionExecutionReportList productTraceabilityDetailList,
productTraceabilityReportList
} from '@/api/report/reportAPI' } from '@/api/report/reportAPI'
import { findProductLineList } from '@//api/base/productLine' import { findProductLineList } from '@//api/base/productLine'
import { parseTime } from '@//utils/ruoyi' import { parseTime } from '@//utils/ruoyi'
export default { export default {
name: 'ReportInfo', name: 'ReportInfo',
dicts: ['is_flag'], dicts: ['is_flag', 'treatment_measures'],
data() { data() {
return { return {
// //
@ -152,26 +205,29 @@ export default {
// pageSize: 10, // pageSize: 10,
beginBeginTime: null, beginBeginTime: null,
endBeginTime: null, endBeginTime: null,
WORK_CENTER_CODE: null, BOX_CODE: null,
PRODUCT_LINE_NAME: null, PRODUCT_LINE_CODE: 'CX_02',
ORDER_CODE: null, ORDER_CODE: null,
MATERIAL_CODE: null, MATERIAL_CODE: null,
MATERIAL_NAME: null, MATERIAL_NAME: null,
BEGIN_DATE: null PRODUCT_SNCODE: null
}, },
// //
form: {}, form: {},
// //
rules: {}, rules: {},
reportDetailList: [],
columns: [ columns: [
{ key: 0, label: `主键标识`, visible: false }, { key: 0, label: `主键标识`, visible: false },
{ key: 1, label: `工位`, visible: true }, { key: 1, label: `工位`, visible: true },
{ key: 2, label: `订单编号`, visible: true }, { key: 2, label: `产线`, visible: true },
{ key: 3, label: `物料编码`, visible: true }, { key: 3, label: `SAP订单编号`, visible: true },
{ key: 4, label: `物料名称`, visible: true }, { key: 4, label: `销售订单号`, visible: false },
{ key: 5, label: `产品编码`, visible: true }, { key: 5, label: `销售订单行号`, visible: false },
{ key: 6, label: `产品型号`, visible: true }, { key: 6, label: `产品编码`, visible: true },
{ key: 7, label: `数量`, visible: true }, { key: 7, label: `产品名称`, visible: true },
{ key: 8, label: `MES条码`, visible: true },
{ key: 9, label: `成品条码`, visible: true }
], ],
// 线 // 线
productLineList: [], productLineList: [],
@ -183,12 +239,12 @@ export default {
findProductLineList({ productLineType: 1 }).then(response => { findProductLineList({ productLineType: 1 }).then(response => {
this.productLineList = response.data this.productLineList = response.data
}) })
findProductLineList({productLineType: 2}).then(response => { // findProductLineList({productLineType: 2}).then(response => {
this.findStationList = response.data; // this.findStationList = response.data;
}); // });
const nowDate = parseTime(new Date(), '{y}-{m}-{d}') const nowDate = parseTime(new Date(), '{y}-{m}-{d}')
this.daterangeBeginTime[0] = nowDate this.daterangeBeginTime[0] = nowDate + ' 00:00:00'
this.daterangeBeginTime[1] = nowDate this.daterangeBeginTime[1] = nowDate + ' 23:59:59'
this.getList() this.getList()
}, },
methods: { methods: {
@ -202,9 +258,9 @@ export default {
this.queryParams.beginBeginTime = null this.queryParams.beginBeginTime = null
this.queryParams.endBeginTime = null this.queryParams.endBeginTime = null
} }
productionExecutionReportList(this.queryParams).then(response => { productTraceabilityReportList(this.queryParams).then(response => {
// this.reportList = response.data this.reportList = response.rows
// this.total = response.total; this.total = response.total
this.loading = false this.loading = false
}) })
}, },
@ -213,6 +269,10 @@ export default {
this.open = false this.open = false
this.reset() this.reset()
}, },
/** 数据明细序号 */
rowDetailIndex({ row, rowIndex }) {
row.index = rowIndex + 1
},
// //
reset() { reset() {
this.daterangeBeginTime = [] this.daterangeBeginTime = []
@ -220,6 +280,7 @@ export default {
WORK_CENTER_CODE: null, WORK_CENTER_CODE: null,
PRODUCT_LINE_NAME: null, PRODUCT_LINE_NAME: null,
ORDER_CODE: null, ORDER_CODE: null,
BOX_CODE: null,
MATERIAL_CODE: null, MATERIAL_CODE: null,
MATERIAL_NAME: null, MATERIAL_NAME: null,
BEGIN_DATE: null BEGIN_DATE: null
@ -238,7 +299,16 @@ export default {
}, },
/** 查看明细 */ /** 查看明细 */
handleOrderDetails(row) { handleOrderDetails(row) {
this.$tab.openPage("SAP订单信息","/order/orderInfo" , {ORDER_CODE: row.ORDER_CODE}); // this.$tab.openPage("SAP","/order/orderInfo" , {ORDER_CODE: row.ORDER_CODE})
console.log(row)
this.form.BOX_CODE= row.BOX_CODE
this.form.ORDER_CODE= row.ORDER_CODE
productTraceabilityDetailList({ BOX_CODE: row.BOX_CODE }).then(response => {
this.reportDetailList = response.data
this.open = true
this.title = '产品检验详情'
})
}, },
// //

@ -108,14 +108,14 @@
<el-table v-loading="loading" :data="qualityInspectionList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="qualityInspectionList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/> <el-table-column label="主键标识" align="center" prop="objId" v-if="columns[0].visible"/>
<el-table-column label="箱体码" align="center" prop="barCode" v-if="columns[1].visible"/> <el-table-column label="箱体码" align="center" prop="barCode" v-if="columns[1].visible" width="120"/>
<el-table-column label="物料名称" align="center" prop="materialName" v-if="columns[2].visible"/> <el-table-column label="物料名称" align="center" prop="materialName" v-if="columns[2].visible" width="150"/>
<el-table-column label="工序编号" align="center" prop="processCode" v-if="columns[3].visible"/> <el-table-column label="工序编号" align="center" prop="processCode" v-if="columns[3].visible"/>
<el-table-column label="工序名称" align="center" prop="processName" v-if="columns[18].visible"/> <el-table-column label="工序名称" align="center" prop="processName" v-if="columns[18].visible"/>
<el-table-column label="工位名称" align="center" prop="productLineName" v-if="columns[21].visible"/> <el-table-column label="工位名称" align="center" prop="productLineName" v-if="columns[21].visible" width="120"/>
<el-table-column label="检测项编号" align="center" prop="testItemCode" v-if="columns[4].visible"/> <el-table-column label="检测项编号" align="center" prop="testItemCode" v-if="columns[4].visible"/>
<el-table-column label="质量缺陷编码" align="center" prop="qualityDefectCode" v-if="columns[5].visible"/> <el-table-column label="质量缺陷编码" align="center" prop="qualityDefectCode" v-if="columns[5].visible" width="100"/>
<el-table-column label="质量缺陷名称" align="center" prop="qualityDefectName" v-if="columns[6].visible"/> <el-table-column label="质量缺陷名称" align="center" prop="qualityDefectName" v-if="columns[6].visible" width="120"/>
<el-table-column label="处理措施" align="center" prop="treatmentMeasure" v-if="columns[7].visible"> <el-table-column label="处理措施" align="center" prop="treatmentMeasure" v-if="columns[7].visible">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.treatment_measures" :value="scope.row.treatmentMeasure"/> <dict-tag :options="dict.type.treatment_measures" :value="scope.row.treatmentMeasure"/>
@ -128,16 +128,16 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="班组编号" align="center" prop="groupCode" v-if="columns[10].visible"/> <el-table-column label="班组编号" align="center" prop="groupCode" v-if="columns[10].visible"/>
<el-table-column label="班组名称" align="center" prop="groupName" v-if="columns[10].visible"/> <el-table-column label="班组名称" align="center" prop="groupName" v-if="columns[10].visible" width="120"/>
<el-table-column label="检测人员编号" align="center" prop="inspectorCode" v-if="columns[11].visible"/> <el-table-column label="检测人员编号" align="center" prop="inspectorCode" v-if="columns[11].visible" width="100"/>
<el-table-column label="检测人员名称" align="center" prop="inspectorName" v-if="columns[20].visible"/> <el-table-column label="检测人员名称" align="center" prop="inspectorName" v-if="columns[20].visible" width="120"/>
<el-table-column label="检测时间" align="center" prop="inspectorTime" width="180" v-if="columns[12].visible"> <el-table-column label="检测时间" align="center" prop="inspectorTime" width="180" v-if="columns[12].visible">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.inspectorTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span> <span>{{ parseTime(scope.row.inspectorTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="返修次数" align="center" prop="reworkNumber" v-if="columns[13].visible"/> <el-table-column label="返修次数" align="center" prop="reworkNumber" v-if="columns[13].visible"/>
<el-table-column label="完成时间" align="center" prop="finishTime" width="180" v-if="columns[14].visible"> <el-table-column label="返修完成时间" align="center" prop="finishTime" width="180" v-if="columns[14].visible">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.finishTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span> <span>{{ parseTime(scope.row.finishTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template> </template>
@ -236,12 +236,12 @@
<el-form-item label="返修次数" prop="reworkNumber"> <el-form-item label="返修次数" prop="reworkNumber">
<el-input v-model="form.reworkNumber" placeholder="请输入返修次数" /> <el-input v-model="form.reworkNumber" placeholder="请输入返修次数" />
</el-form-item> </el-form-item>
<el-form-item label="完成时间" prop="finishTime"> <el-form-item label="返修完成时间" prop="finishTime">
<el-date-picker clearable <el-date-picker clearable
v-model="form.finishTime" v-model="form.finishTime"
type="date" type="date"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
placeholder="请选择完成时间"> placeholder="请选择返修完成时间">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label="是否标识" prop="isFlag"> <el-form-item label="是否标识" prop="isFlag">
@ -331,11 +331,11 @@ export default {
{ key: 7, label: `处理措施`, visible: true }, { key: 7, label: `处理措施`, visible: true },
{ key: 8, label: `处理结果`, visible: true }, { key: 8, label: `处理结果`, visible: true },
{ key: 9, label: `是否下静态线`, visible: false }, { key: 9, label: `是否下静态线`, visible: false },
{ key: 10, label: `班组编号`, visible: true }, { key: 10, label: `班组编号`, visible: false },
{ key: 11, label: `检测人员编号`, visible: true }, { key: 11, label: `检测人员编号`, visible: false },
{ key: 12, label: `检测时间`, visible: true }, { key: 12, label: `检测时间`, visible: true },
{ key: 13, label: `返修次数`, visible: true }, { key: 13, label: `返修次数`, visible: true },
{ key: 14, label: `完成时间`, visible: true }, { key: 14, label: `返修完成时间`, visible: true },
{ key: 15, label: `是否标识`, visible: false }, { key: 15, label: `是否标识`, visible: false },
{ key: 16, label: `更新人`, visible: false }, { key: 16, label: `更新人`, visible: false },
{ key: 17, label: `更新时间`, visible: false }, { key: 17, label: `更新时间`, visible: false },

@ -1,6 +1,6 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="90px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="产线" prop="productLineCode"> <el-form-item label="产线" prop="productLineCode">
<el-select v-model="queryParams.productLineCode" placeholder="请选择产线" clearable> <el-select v-model="queryParams.productLineCode" placeholder="请选择产线" clearable>
<el-option <el-option

@ -43,6 +43,16 @@
start-placeholder="开始时间" start-placeholder="开始时间"
end-placeholder="结束时间" end-placeholder="结束时间"
></el-date-picker> ></el-date-picker>
<el-form-item label="测试结果" prop="cpresult">
<el-select v-model="queryParams.cpresult" placeholder="请选择测试结果" clearable>
<el-option
v-for="dict in dict.type.cp_result"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button> <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
@ -132,6 +142,7 @@ import { parseTime } from '@//utils/ruoyi'
export default { export default {
name: 'TemperatureHistory', name: 'TemperatureHistory',
dicts: ['cp_result'],
data() { data() {
return { return {
// //

Loading…
Cancel
Save