This commit is contained in:
‘937886381’
2025-12-12 16:52:45 +08:00
parent 6d367b121c
commit 7661dc5691
4 changed files with 93 additions and 69 deletions

View File

@@ -401,6 +401,7 @@ export default {
activeLabel: 'table', // 当班数据tab activeLabel: 'table', // 当班数据tab
activeLabelDay: 'table', // 当天数据tab activeLabelDay: 'table', // 当天数据tab
fileName: '', fileName: '',
headFormValue:{},
dataListLoading: false, dataListLoading: false,
tableProps, tableProps,
factoryColumns: [], factoryColumns: [],
@@ -571,6 +572,7 @@ export default {
prop: 'processType', prop: 'processType',
label: '产品类型', label: '产品类型',
filter: (val) => (val != 1 ? '面板' : '背板'), filter: (val) => (val != 1 ? '面板' : '背板'),
sortable: true,
fixed: true fixed: true
}, },
{ {
@@ -967,33 +969,34 @@ export default {
}, },
// 搜索/导出按钮点击 // 搜索/导出按钮点击
buttonClick(val) { buttonClick(val) {
this.headFormValue = val
if (this.activeName === 'productLine') { if (this.activeName === 'productLine') {
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 10;
this.listQuery.factoryId = val.factoryId || undefined; this.listQuery.factoryId = this.headFormValue.factoryId || undefined;
this.listQuery.process = val.process ? val.process : []; this.listQuery.process = this.headFormValue.process ? this.headFormValue.process : [];
this.listQuery.lineId = val.lineId ? val.lineId : []; this.listQuery.lineId = this.headFormValue.lineId ? this.headFormValue.lineId : [];
this.listQuery.processType = val.processType ? val.processType : []; this.listQuery.processType = this.headFormValue.processType ? this.headFormValue.processType : [];
this.listQuery.reportType = val.reportType || undefined; this.listQuery.reportType = this.headFormValue.reportType || undefined;
this.listQuery.timeType = val.timeType || undefined; this.listQuery.timeType = this.headFormValue.timeType || undefined;
this.listQuery.searchType = val.searchType || undefined; this.listQuery.searchType = this.headFormValue.searchType || undefined;
// 处理不同时间选择类型 // 处理不同时间选择类型
if (val.timeVal) { if (this.headFormValue.timeVal) {
this.listQuery.startTime = val.timeVal[0]; this.listQuery.startTime = this.headFormValue.timeVal[0];
this.listQuery.endTime = val.timeVal[1]; this.listQuery.endTime = this.headFormValue.timeVal[1];
} else if (val.timeValWeek) { } else if (this.headFormValue.timeValWeek) {
// 周选择器 // 周选择器
const { startTime, endTime } = this.getWeekTimeRange(val.timeValWeek); const { startTime, endTime } = this.getWeekTimeRange(this.headFormValue.timeValWeek);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else if (val.timeValMonth) { } else if (this.headFormValue.timeValMonth) {
// 月选择器 // 月选择器
this.listQuery.startTime = val.timeValMonth[0]; this.listQuery.startTime = this.headFormValue.timeValMonth[0];
this.listQuery.endTime = val.timeValMonth[1]; this.listQuery.endTime = this.headFormValue.timeValMonth[1];
} else if (val.timeValYear) { } else if (this.headFormValue.timeValYear) {
// 年选择器 // 年选择器
const { startTime, endTime } = this.getYearTimeRange(val.timeValYear); const { startTime, endTime } = this.getYearTimeRange(this.headFormValue.timeValYear);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else { } else {
@@ -1003,30 +1006,30 @@ export default {
} else { } else {
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 10;
this.listQuery.factoryId = val.factoryId || [] this.listQuery.factoryId = this.headFormValue.factoryId || []
this.listQuery.process = val.process ? val.process : []; this.listQuery.process = this.headFormValue.process ? this.headFormValue.process : [];
this.listQuery.lineId = undefined; this.listQuery.lineId = undefined;
this.listQuery.processType = val.processType ? val.processType : []; this.listQuery.processType = this.headFormValue.processType ? this.headFormValue.processType : [];
this.listQuery.reportType = val.reportType || undefined; this.listQuery.reportType = this.headFormValue.reportType || undefined;
this.listQuery.timeType = val.timeType || undefined; this.listQuery.timeType = this.headFormValue.timeType || undefined;
this.listQuery.searchType = val.searchType || undefined; this.listQuery.searchType = this.headFormValue.searchType || undefined;
// 处理不同时间选择类型 // 处理不同时间选择类型
if (val.timeVal) { if (this.headFormValue.timeVal) {
this.listQuery.startTime = val.timeVal[0]; this.listQuery.startTime = this.headFormValue.timeVal[0];
this.listQuery.endTime = val.timeVal[1]; this.listQuery.endTime = this.headFormValue.timeVal[1];
} else if (val.timeValWeek) { } else if (this.headFormValue.timeValWeek) {
// 周选择器 // 周选择器
const { startTime, endTime } = this.getWeekTimeRange(val.timeValWeek); const { startTime, endTime } = this.getWeekTimeRange(this.headFormValue.timeValWeek);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else if (val.timeValMonth) { } else if (this.headFormValue.timeValMonth) {
// 月选择器 // 月选择器
this.listQuery.startTime = val.timeValMonth[0]; this.listQuery.startTime = this.headFormValue.timeValMonth[0];
this.listQuery.endTime = val.timeValMonth[1]; this.listQuery.endTime = this.headFormValue.timeValMonth[1];
} else if (val.timeValYear) { } else if (this.headFormValue.timeValYear) {
// 年选择器 // 年选择器
const { startTime, endTime } = this.getYearTimeRange(val.timeValYear); const { startTime, endTime } = this.getYearTimeRange(this.headFormValue.timeValYear);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else { } else {
@@ -1140,7 +1143,15 @@ export default {
}, },
async getProductList() { async getProductList() {
console.log('resGroup'); this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10;
this.listQuery.factoryId = this.headFormValue.factoryId || []
this.listQuery.process = this.headFormValue.process ? this.headFormValue.process : [];
this.listQuery.lineId = undefined;
this.listQuery.processType = this.headFormValue.processType ? this.headFormValue.processType : [];
this.listQuery.reportType = this.headFormValue.reportType || undefined;
this.listQuery.timeType = this.headFormValue.timeType || undefined;
this.listQuery.searchType = this.headFormValue.searchType || undefined
if (this.listQuery.timeType === 2) { if (this.listQuery.timeType === 2) {
const resGroup = await getProcessAutoReportNew(this.listQuery); const resGroup = await getProcessAutoReportNew(this.listQuery);
console.log('resGroup', resGroup); console.log('resGroup', resGroup);

View File

@@ -406,6 +406,7 @@ export default {
factoryColumns: [], factoryColumns: [],
factoryColumnsDay: [], factoryColumnsDay: [],
activeName: 'product', activeName: 'product',
headFormValue:{},
tableBtn: [], tableBtn: [],
showData: [], showData: [],
tableData: [], tableData: [],
@@ -535,6 +536,7 @@ export default {
prop: 'processType', prop: 'processType',
label: '产品类型', label: '产品类型',
filter: (val) => (val != 1 ? '面板' : '背板'), filter: (val) => (val != 1 ? '面板' : '背板'),
sortable: true,
fixed: true fixed: true
}, },
{ {
@@ -557,6 +559,7 @@ export default {
prop: 'processType', prop: 'processType',
label: '产品类型', label: '产品类型',
filter: (val) => (val != 1 ? '面板' : '背板'), filter: (val) => (val != 1 ? '面板' : '背板'),
sortable: true,
fixed: true fixed: true
}, },
{ {
@@ -938,33 +941,34 @@ export default {
// 搜索/导出按钮点击 // 搜索/导出按钮点击
buttonClick(val) { buttonClick(val) {
this.headFormValue = val
if (this.activeName === 'productLine') { if (this.activeName === 'productLine') {
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 10;
this.listQuery.factoryId = val.factoryId || undefined; this.listQuery.factoryId = this.headFormValue.factoryId || undefined;
this.listQuery.process = val.process ? val.process : []; this.listQuery.process = this.headFormValue.process ? this.headFormValue.process : [];
this.listQuery.lineId = val.lineId ? val.lineId : []; this.listQuery.lineId = this.headFormValue.lineId ? this.headFormValue.lineId : [];
this.listQuery.processType = val.processType ? val.processType : []; this.listQuery.processType = this.headFormValue.processType ? this.headFormValue.processType : [];
this.listQuery.reportType = val.reportType || undefined; this.listQuery.reportType = this.headFormValue.reportType || undefined;
this.listQuery.timeType = val.timeType || undefined; this.listQuery.timeType = this.headFormValue.timeType || undefined;
this.listQuery.searchType = val.searchType || undefined; this.listQuery.searchType = this.headFormValue.searchType || undefined;
// 处理不同时间选择类型 // 处理不同时间选择类型
if (val.timeVal) { if (this.headFormValue.timeVal) {
this.listQuery.startTime = val.timeVal[0]; this.listQuery.startTime = this.headFormValue.timeVal[0];
this.listQuery.endTime = val.timeVal[1]; this.listQuery.endTime = this.headFormValue.timeVal[1];
} else if (val.timeValWeek) { } else if (this.headFormValue.timeValWeek) {
// 周选择器 // 周选择器
const { startTime, endTime } = this.getWeekTimeRange(val.timeValWeek); const { startTime, endTime } = this.getWeekTimeRange(this.headFormValue.timeValWeek);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else if (val.timeValMonth) { } else if (this.headFormValue.timeValMonth) {
// 月选择器 // 月选择器
this.listQuery.startTime = val.timeValMonth[0]; this.listQuery.startTime = this.headFormValue.timeValMonth[0];
this.listQuery.endTime = val.timeValMonth[1]; this.listQuery.endTime = this.headFormValue.timeValMonth[1];
} else if (val.timeValYear) { } else if (this.headFormValue.timeValYear) {
// 年选择器 // 年选择器
const { startTime, endTime } = this.getYearTimeRange(val.timeValYear); const { startTime, endTime } = this.getYearTimeRange(this.headFormValue.timeValYear);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else { } else {
@@ -974,30 +978,30 @@ export default {
} else { } else {
this.listQuery.pageNo = 1; this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10; this.listQuery.pageSize = 10;
this.listQuery.factoryId = val.factoryId || [] this.listQuery.factoryId = this.headFormValue.factoryId || []
this.listQuery.process = val.process ? val.process : []; this.listQuery.process = this.headFormValue.process ? this.headFormValue.process : [];
this.listQuery.lineId = undefined; this.listQuery.lineId = undefined;
this.listQuery.processType = val.processType ? val.processType : []; this.listQuery.processType = this.headFormValue.processType ? this.headFormValue.processType : [];
this.listQuery.reportType = val.reportType || undefined; this.listQuery.reportType = this.headFormValue.reportType || undefined;
this.listQuery.timeType = val.timeType || undefined; this.listQuery.timeType = this.headFormValue.timeType || undefined;
this.listQuery.searchType = val.searchType || undefined; this.listQuery.searchType = this.headFormValue.searchType || undefined;
// 处理不同时间选择类型 // 处理不同时间选择类型
if (val.timeVal) { if (this.headFormValue.timeVal) {
this.listQuery.startTime = val.timeVal[0]; this.listQuery.startTime = this.headFormValue.timeVal[0];
this.listQuery.endTime = val.timeVal[1]; this.listQuery.endTime = this.headFormValue.timeVal[1];
} else if (val.timeValWeek) { } else if (this.headFormValue.timeValWeek) {
// 周选择器 // 周选择器
const { startTime, endTime } = this.getWeekTimeRange(val.timeValWeek); const { startTime, endTime } = this.getWeekTimeRange(this.headFormValue.timeValWeek);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else if (val.timeValMonth) { } else if (this.headFormValue.timeValMonth) {
// 月选择器 // 月选择器
this.listQuery.startTime = val.timeValMonth[0]; this.listQuery.startTime = this.headFormValue.timeValMonth[0];
this.listQuery.endTime = val.timeValMonth[1]; this.listQuery.endTime = this.headFormValue.timeValMonth[1];
} else if (val.timeValYear) { } else if (this.headFormValue.timeValYear) {
// 年选择器 // 年选择器
const { startTime, endTime } = this.getYearTimeRange(val.timeValYear); const { startTime, endTime } = this.getYearTimeRange(this.headFormValue.timeValYear);
this.listQuery.startTime = startTime; this.listQuery.startTime = startTime;
this.listQuery.endTime = endTime; this.listQuery.endTime = endTime;
} else { } else {
@@ -1109,7 +1113,15 @@ export default {
}, },
async getProductList() { async getProductList() {
console.log('resGroup'); this.listQuery.pageNo = 1;
this.listQuery.pageSize = 10;
this.listQuery.factoryId = this.headFormValue.factoryId || []
this.listQuery.process = this.headFormValue.process ? this.headFormValue.process : [];
this.listQuery.lineId = undefined;
this.listQuery.processType = this.headFormValue.processType ? this.headFormValue.processType : [];
this.listQuery.reportType = this.headFormValue.reportType || undefined;
this.listQuery.timeType = this.headFormValue.timeType || undefined;
this.listQuery.searchType = this.headFormValue.searchType || undefined
if (this.listQuery.timeType === 2) { if (this.listQuery.timeType === 2) {
const resGroup = await getProcessAutoReportNew(this.listQuery); const resGroup = await getProcessAutoReportNew(this.listQuery);
console.log('resGroup', resGroup); console.log('resGroup', resGroup);

View File

@@ -210,7 +210,7 @@
</template> </template>
<script> <script>
import moment from 'moment'; import moment from 'moment';
import JDatePickerScript from './JDatePicker.js' // import JDatePickerScript from './JDatePicker.js'
export default { export default {
props: { props: {

View File

@@ -121,6 +121,7 @@ export default {
type: 'select', type: 'select',
label: '产线', label: '产线',
selectOptions: [], selectOptions: [],
multiple: true,
param: 'lineId', param: 'lineId',
}, },
{ {