Merge remote-tracking branch 'origin/master'
commit
17d3a8f639
@ -0,0 +1,269 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<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-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-->
|
||||
<!-- v-model="queryParams.MATERIAL_NAME"-->
|
||||
<!-- placeholder="请输入产品名称"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="SAP订单编号" prop="ORDER_CODE">-->
|
||||
<!-- <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
|
||||
v-model="daterangeBeginTime"
|
||||
style="width: 340px"
|
||||
value-format="yyyy-MM-dd"
|
||||
type="datetimerange"
|
||||
range-separator="-"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
></el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<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-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<!-- <el-col :span="1.5">-->
|
||||
<!-- <el-button-->
|
||||
<!-- type="warning"-->
|
||||
<!-- plain-->
|
||||
<!-- icon="el-icon-download"-->
|
||||
<!-- size="mini"-->
|
||||
<!-- @click="handleExport"-->
|
||||
<!-- >导出-->
|
||||
<!-- </el-button>-->
|
||||
<!-- </el-col>-->
|
||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="reportList" @selection-change="handleSelectionChange">
|
||||
<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="PRODUCT_LINE_CODE" v-if="columns[1].visible"/>
|
||||
<el-table-column label="夹具箱型" align="center" prop="FIXTUREBOXTYPE" v-if="columns[2].visible"/>
|
||||
<el-table-column label="夹具状态" align="center" prop="FIXTURESTATUS" v-if="columns[3].visible">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ parseTime(scope.row.BEGIN_DATE, '{y}-{m}-{d}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产量" align="center" prop="PRODUCTION" v-if="columns[4].visible"/>
|
||||
<el-table-column label="固化时间" align="center" prop="CURINGTIMESETTINGVALUE" v-if="columns[5].visible"/>
|
||||
<el-table-column label="1小时" align="center" prop="ANHOUR" v-if="columns[6].visible"/>
|
||||
<el-table-column label="2小时" align="center" prop="TWOHOUR" v-if="columns[7].visible"/>
|
||||
<el-table-column label="3小时" align="center" prop="THREEHOUR" v-if="columns[8].visible"/>
|
||||
<el-table-column label="4小时" align="center" prop="FOURHOUR" v-if="columns[9].visible"/>
|
||||
<el-table-column label="5小时" align="center" prop="FIVEHOUR" v-if="columns[10].visible"/>
|
||||
<el-table-column label="6小时" align="center" prop="SIXHOUR" v-if="columns[11].visible"/>
|
||||
<el-table-column label="7小时" align="center" prop="SEVENHOUR" v-if="columns[12].visible"/>
|
||||
<el-table-column label="8小时" align="center" prop="EIGHTHOUR" v-if="columns[13].visible"/>
|
||||
<el-table-column label="9小时" align="center" prop="NINEHOUR" v-if="columns[14].visible"/>
|
||||
<el-table-column label="10小时" align="center" prop="TENHOUR" v-if="columns[15].visible"/>
|
||||
<el-table-column label="11小时" align="center" prop="ELEVENHOUR" v-if="columns[16].visible"/>
|
||||
<el-table-column label="12小时" align="center" prop="TWELVEHOUR" v-if="columns[17].visible"/>
|
||||
<el-table-column label="班组开始时间" align="center" prop="STARTTIME" v-if="columns[18].visible"/>
|
||||
<el-table-column label="班组结束时间" align="center" prop="ENDTIME" v-if="columns[19].visible"/>
|
||||
|
||||
</el-table>
|
||||
<!-- <pagination-->
|
||||
<!-- v-show="total>0"-->
|
||||
<!-- :total="total"-->
|
||||
<!-- :page.sync="queryParams.pageNum"-->
|
||||
<!-- :limit.sync="queryParams.pageSize"-->
|
||||
<!-- @pagination="getList"-->
|
||||
<!-- />-->
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
foamFillingRecordReportList
|
||||
} from '@/api/report/reportAPI'
|
||||
import { findProductLineList } from '@//api/base/productLine'
|
||||
import { parseTime } from '@//utils/ruoyi'
|
||||
|
||||
export default {
|
||||
name: 'ReportInfo',
|
||||
dicts: ['is_flag'],
|
||||
data() {
|
||||
return {
|
||||
// 遮罩层
|
||||
loading: true,
|
||||
// 选中数组
|
||||
ids: [],
|
||||
// 非单个禁用
|
||||
single: true,
|
||||
// 非多个禁用
|
||||
multiple: true,
|
||||
// 显示搜索条件
|
||||
showSearch: true,
|
||||
// 总条数
|
||||
total: 0,
|
||||
// 报表表格数据
|
||||
reportList: [],
|
||||
// 弹出层标题
|
||||
title: '',
|
||||
// 是否显示弹出层
|
||||
open: false,
|
||||
// 更新时间时间范围
|
||||
daterangeBeginTime: [],
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
// pageNum: 1,
|
||||
// pageSize: 10,
|
||||
beginBeginTime: null,
|
||||
endBeginTime: null,
|
||||
WORK_CENTER_CODE: null,
|
||||
PRODUCT_LINE_NAME: null,
|
||||
ORDER_CODE: null,
|
||||
MATERIAL_CODE: null,
|
||||
MATERIAL_NAME: null,
|
||||
BEGIN_DATE: null
|
||||
},
|
||||
// 表单参数
|
||||
form: {},
|
||||
// 表单校验
|
||||
rules: {},
|
||||
columns: [
|
||||
{ key: 0, label: `主键标识`, visible: false },
|
||||
{ key: 1, label: `产线`, visible: true },
|
||||
{ key: 2, label: `夹具箱型`, visible: true },
|
||||
{ key: 3, label: `夹具状态`, visible: true },
|
||||
{ key: 4, label: `产量`, visible: true },
|
||||
{ key: 5, label: `固化时间`, visible: true },
|
||||
{ key: 6, label: `1小时`, visible: true },
|
||||
{ key: 7, label: `2小时`, visible: true },
|
||||
{ key: 8, label: `3小时`, visible: true },
|
||||
{ key: 9, label: `4小时`, visible: true },
|
||||
{ key: 10, label: `5小时`, visible: true },
|
||||
{ key: 11, label: `6小时`, visible: true },
|
||||
{ key: 12, label: `7小时`, visible: true },
|
||||
{ key: 13, label: `8小时`, visible: true },
|
||||
{ key: 14, label: `9小时`, visible: true },
|
||||
{ key: 15, label: `10小时`, visible: true },
|
||||
{ key: 16, label: `11小时`, visible: true },
|
||||
{ key: 17, label: `12小时`, visible: true },
|
||||
{ key: 18, label: `班组开始时间`, visible: true },
|
||||
{ key: 19, label: `班组结束时间`, visible: true },
|
||||
],
|
||||
// 产线选项
|
||||
productLineList: [],
|
||||
// 工位选项
|
||||
findStationList: []
|
||||
}
|
||||
},
|
||||
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}')
|
||||
this.daterangeBeginTime[0] = nowDate
|
||||
this.daterangeBeginTime[1] = nowDate
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
/** 查询工单信息列表 */
|
||||
getList() {
|
||||
this.loading = true
|
||||
if (null != this.daterangeBeginTime && '' != this.daterangeBeginTime) {
|
||||
this.queryParams.beginBeginTime = this.daterangeBeginTime[0]
|
||||
this.queryParams.endBeginTime = this.daterangeBeginTime[1]
|
||||
} else {
|
||||
this.queryParams.beginBeginTime = null
|
||||
this.queryParams.endBeginTime = null
|
||||
}
|
||||
foamFillingRecordReportList(this.queryParams).then(response => {
|
||||
this.reportList = response.data
|
||||
this.total = response.total;
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 取消按钮
|
||||
cancel() {
|
||||
this.open = false
|
||||
this.reset()
|
||||
},
|
||||
// 表单重置
|
||||
reset() {
|
||||
this.daterangeBeginTime = []
|
||||
this.form = {
|
||||
WORK_CENTER_CODE: null,
|
||||
PRODUCT_LINE_NAME: null,
|
||||
ORDER_CODE: null,
|
||||
MATERIAL_CODE: null,
|
||||
MATERIAL_NAME: null,
|
||||
BEGIN_DATE: null
|
||||
}
|
||||
this.resetForm('form')
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
// this.queryParams.pageNum = 1;
|
||||
this.getList()
|
||||
},
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.resetForm('queryForm')
|
||||
this.handleQuery()
|
||||
},
|
||||
|
||||
// 多选框选中数据
|
||||
handleSelectionChange(selection) {
|
||||
this.ids = selection.map(item => item.objId)
|
||||
this.single = selection.length !== 1
|
||||
this.multiple = !selection.length
|
||||
},
|
||||
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
this.download('/report/productionReport/export', {
|
||||
...this.queryParams
|
||||
}, `report_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
Loading…
Reference in New Issue