commit
744e5d80be
@ -72,9 +72,11 @@
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="工段排序" prop="sort">
|
||||
<el-input
|
||||
<el-input-number
|
||||
v-model="dataForm.sort"
|
||||
filterable
|
||||
min="0"
|
||||
max="100"
|
||||
@change="$emit('update', dataForm)"
|
||||
placeholder="请输入工段排序" />
|
||||
</el-form-item>
|
||||
|
@ -134,6 +134,8 @@ export default {
|
||||
label: '工段',
|
||||
placeholder: '请选择工段',
|
||||
param: 'workshopSectionId',
|
||||
selectOptions: [],
|
||||
filterable: true
|
||||
},
|
||||
{
|
||||
type: 'input',
|
||||
@ -239,8 +241,24 @@ export default {
|
||||
},
|
||||
created() {
|
||||
this.getList();
|
||||
this.initWorksection();
|
||||
},
|
||||
methods: {
|
||||
/** 准备工段数据 */
|
||||
async initWorksection() {
|
||||
const { code, data } = await this.$axios({
|
||||
url: '/base/workshop-section/listAll',
|
||||
method: 'get',
|
||||
});
|
||||
if (code == 0) {
|
||||
this.searchBarFormConfig[0].selectOptions = data.map((item) => {
|
||||
return {
|
||||
name: item.name,
|
||||
id: item.id,
|
||||
};
|
||||
});
|
||||
}
|
||||
},
|
||||
/** 查询列表 */
|
||||
getList() {
|
||||
this.loading = true;
|
||||
@ -323,7 +341,7 @@ export default {
|
||||
handleDelete(row) {
|
||||
const id = row.id;
|
||||
this.$modal
|
||||
.confirm('是否确认删除工段设备绑定编号为"' + id + '"的数据项?')
|
||||
.confirm('是否确认删除工段设备绑定设备名称为"' + row.equipment + '"的数据项?')
|
||||
.then(function () {
|
||||
return deleteEquipmentBindSection(id);
|
||||
})
|
||||
|
@ -1,8 +1,8 @@
|
||||
<!--
|
||||
* @Author: zwq
|
||||
* @Date: 2023-08-02 15:12:42
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2023-08-03 14:24:36
|
||||
* @LastEditors: DY
|
||||
* @LastEditTime: 2023-10-10 16:49:03
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
@ -81,6 +81,7 @@ export default {
|
||||
};
|
||||
getProductPage(params).then((response) => {
|
||||
this.tableProps[1].list = response.data.list;
|
||||
console.log('打印', this.tableProps[1].list)
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
|
@ -1,8 +1,8 @@
|
||||
<!--
|
||||
* @Author: zwq
|
||||
* @Date: 2023-08-03 14:09:18
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2023-08-03 14:51:16
|
||||
* @LastEditors: DY
|
||||
* @LastEditTime: 2023-10-10 16:54:09
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
@ -48,6 +48,9 @@ export default {
|
||||
visible: false,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
console.log('hello', this.list)
|
||||
},
|
||||
methods: {
|
||||
changeInput() {
|
||||
const data = {
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: Do not edit
|
||||
* @Date: 2023-08-29 14:59:29
|
||||
* @LastEditTime: 2023-09-27 16:19:56
|
||||
* @LastEditTime: 2023-10-09 09:08:08
|
||||
* @LastEditors: DY
|
||||
* @Description:
|
||||
-->
|
||||
@ -308,8 +308,8 @@ export default {
|
||||
this.listQuery.pageSize = 10;
|
||||
this.listQuery.lineId = val.line ? val.line : undefined;
|
||||
this.listQuery.reportType = val.reportType ? val.reportType : undefined;
|
||||
this.listQuery.reportStartTime = [new Date(val.timeVal[0]).getTime()];
|
||||
this.listQuery.reportEndTime = [new Date(val.timeVal[1]).getTime()];
|
||||
this.listQuery.reportStartTime = val.timeVal ? [new Date(val.timeVal[0]).getTime()] : undefined;
|
||||
this.listQuery.reportEndTime = val.timeVal ? [new Date(val.timeVal[1]).getTime()] : undefined;
|
||||
this.getDataList();
|
||||
break;
|
||||
case 'export':
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: Do not edit
|
||||
* @Date: 2023-08-29 14:59:29
|
||||
* @LastEditTime: 2023-09-27 16:23:44
|
||||
* @LastEditTime: 2023-10-09 15:14:42
|
||||
* @LastEditors: DY
|
||||
* @Description:
|
||||
-->
|
||||
@ -110,6 +110,7 @@ export default {
|
||||
showData: [],
|
||||
tableData: [],
|
||||
selectedList: [],
|
||||
fileName: [],
|
||||
formConfig: [
|
||||
{
|
||||
type: 'select',
|
||||
@ -155,13 +156,14 @@ export default {
|
||||
}
|
||||
// const time = new Date()
|
||||
// this.formConfig[1].defaultSelect = [time, time]
|
||||
this.getDataList()
|
||||
// this.getDataList()
|
||||
this.getPdLineList()
|
||||
},
|
||||
methods: {
|
||||
test() {
|
||||
var target = document.getElementsByClassName("right-aside")[0]
|
||||
target.style.background = '#FFFFFF'
|
||||
var that = this
|
||||
setTimeout(() => {
|
||||
html2canvas(target).then(function(canvas) {
|
||||
var contentWidth = canvas.width
|
||||
@ -197,7 +199,7 @@ export default {
|
||||
}
|
||||
}
|
||||
|
||||
pdf.save('产线统计数据查询报表.pdf')
|
||||
pdf.save(that.fileName[0] + '-' + that.fileName[1] + '_产线产量.pdf')
|
||||
})
|
||||
}, 300)
|
||||
},
|
||||
@ -220,7 +222,7 @@ export default {
|
||||
try {
|
||||
FileSaver.saveAs(new Blob([exportTableOut], {
|
||||
type: 'application/octet-stream'
|
||||
}), '产线统计数据查询报表.xlsx')
|
||||
}), this.fileName[0] + '-' + this.fileName[1] + '_产线产量.xlsx')
|
||||
} catch (e) {
|
||||
if (typeof console !== 'undefined') console.log(e, exportTableOut)
|
||||
}
|
||||
@ -263,7 +265,17 @@ export default {
|
||||
this.listQuery.proLineId = val.line ? val.line : undefined;
|
||||
this.listQuery.startTime = val.timeVal ? new Date(val.timeVal[0]).getTime() : undefined;
|
||||
this.listQuery.endTime = val.timeVal ? new Date(val.timeVal[1]).getTime() : undefined;
|
||||
console.log('nihc 你好', val.timeVal)
|
||||
if (val.timeVal && val.timeVal.length > 0) {
|
||||
this.fileName[0] = val.timeVal[0].slice(0, 10)
|
||||
this.fileName[1] = val.timeVal[1].slice(0, 10)
|
||||
this.getDataList();
|
||||
} else {
|
||||
this.$message({
|
||||
message: '请选择时间',
|
||||
type: 'warning'
|
||||
});
|
||||
}
|
||||
break;
|
||||
case 'export':
|
||||
this.handleExport();
|
||||
|
@ -7,7 +7,7 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<SearchBar
|
||||
:formConfigs="[{ label: '设备近24小时产线生产数据', type: 'title' }]"
|
||||
:formConfigs="[{ label: '近24小时产线生产数据', type: 'title' }]"
|
||||
ref="search-bar" />
|
||||
<el-skeleton v-if="initing" :rows="6" animated />
|
||||
<!-- :span-method="mergeColumnHandler" -->
|
||||
@ -150,11 +150,13 @@ export default {
|
||||
prop: 'proLineName',
|
||||
label: '生产线',
|
||||
align: 'center',
|
||||
fixed: 'left'
|
||||
},
|
||||
{
|
||||
prop: 'spec',
|
||||
label: '产品规格',
|
||||
align: 'center',
|
||||
fixed: 'left'
|
||||
}
|
||||
]
|
||||
this.buildProps(res.data.nameData);
|
||||
|
@ -96,9 +96,11 @@ export default {
|
||||
sectionId: undefined,
|
||||
startTime: undefined,
|
||||
endTime: undefined,
|
||||
total: 0
|
||||
},
|
||||
dataListLoading: false,
|
||||
dialogVisible: false,
|
||||
fileName: [],
|
||||
optionArrUrl: [getProductionLinePage, getWorkshopSectionPage],
|
||||
formConfig: [
|
||||
{
|
||||
@ -146,7 +148,7 @@ export default {
|
||||
},
|
||||
created() {
|
||||
this.getArr();
|
||||
this.getDataList()
|
||||
// this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
test() {
|
||||
@ -291,7 +293,17 @@ export default {
|
||||
this.listQuery.sectionId = val.sectionId ? val.sectionId : undefined
|
||||
this.listQuery.startTime = val.timeSlot ? new Date(val.timeSlot[0]).getTime() : undefined
|
||||
this.listQuery.endTime = val.timeSlot ? new Date(val.timeSlot[1]).getTime() : undefined
|
||||
this.getDataList();
|
||||
this.fileName[0] = val.timeSlot[0]
|
||||
this.fileName[1] = val.timeSlot[1]
|
||||
console.log('wfjmmki文件名称', this.fileName)
|
||||
if (val.timeSlot) {
|
||||
this.getDataList()
|
||||
} else {
|
||||
this.$message({
|
||||
message: '请选择时间',
|
||||
type: 'warning'
|
||||
});
|
||||
}
|
||||
break;
|
||||
case 'reset':
|
||||
this.$refs.searchBarForm.resetForm();
|
||||
|
Loading…
Reference in New Issue
Block a user