生产工艺参数查询新增下拉

This commit is contained in:
17630416519 2026-01-31 10:20:57 +08:00
parent 9ccc2eaa07
commit 425cce7bb7
3 changed files with 300 additions and 233 deletions

View File

@ -7,7 +7,7 @@
// eslintvue
"eslint.validate": ["javascript", "typescript", "vue"],
"[vue]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
"editor.defaultFormatter": "Vue.volar"
},
"[scss]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"

View File

@ -55,3 +55,11 @@ export function delPlcProductionData(pid) {
method: 'POST'
})
}
//工站下拉
export function getWorkstationList() {
return request({
url: 'MasterDataManagement/Plant/PlantWorkstation/getWorkstationPulldown',
method: 'get'
})
}

View File

@ -8,12 +8,15 @@
<el-input v-model="queryParams.productName" placeholder="请输入产品名称" clearable />
</el-form-item>
<el-form-item label="工站名称" prop="workstationName">
<el-input v-model="queryParams.workstationName" placeholder="请输入工站名称" clearable />
<el-select v-model="queryParams.workstationName" placeholder="请选择工站名称" clearable>
<el-option v-for="item in workstationList" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
</el-form-item>
<el-form-item label="筛选日期" prop="timeRange">
<el-date-picker :clearable="false" v-model="queryParams.timeRange" type="daterange" range-separator=""
start-placeholder="开始时间" end-placeholder="结束时间" placeholder="请选择日期区间" />
</el-form-item>
<el-form-item label="筛选日期" prop="timeRange">
<el-date-picker :clearable="false" v-model="queryParams.timeRange" type="daterange" range-separator=""
start-placeholder="开始时间" end-placeholder="结束时间" placeholder="请选择日期区间" />
</el-form-item>
<el-form-item label="产品编码" prop="productCode">
<el-input v-model="queryParams.productCode" placeholder="请输入产品编码" clearable />
</el-form-item>
@ -32,125 +35,172 @@
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
</el-row>
<el-table
:data="dataList"
v-loading="loading"
ref="table"
border
header-cell-class-name="el-table-header-cell"
highlight-current-row
@sort-change="sortChange"
>
<el-table-column label="序号" fixed="left" type="index" width="70" align="center" />
<el-table :data="dataList" v-loading="loading" ref="table" border header-cell-class-name="el-table-header-cell"
highlight-current-row @sort-change="sortChange">
<el-table-column label="序号" fixed="left" type="index" width="70" align="center" />
<el-table-column prop="lineCode" label="产线编号" min-width="100" align="center" :show-overflow-tooltip="true" />
<!-- <el-table-column prop="plcIp" label="PLC IP地址" min-width="130" align="center" :show-overflow-tooltip="true" /> -->
<el-table-column prop="productCode" label="产品编码" min-width="100" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="productName" label="产品名称"min-width="100" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="workstationName" label="工站名称"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="workstationCode" label="工站编码"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="productName" label="产品名称" min-width="100" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="workstationName" label="工站名称" min-width="120" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="workstationCode" label="工站编码" min-width="120" align="center"
:show-overflow-tooltip="true" />
<!-- <el-table-column prop="paramName" label="参数名称"min-width="100" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="paramValue" label="参数值"min-width="100" align="center" :show-overflow-tooltip="true" /> -->
<el-table-column prop="occurTime" label="数据发生时间"min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="qualificationFlag" label="合格标志"min-width="100" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="reworkFlag" label="返工标志" min-width="100"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="productionCycle" label="生产节拍(秒)"min-width="120" align="center" />
<el-table-column prop="remark" label="备注" align="center" min-width="100":show-overflow-tooltip="true" />
<el-table-column prop="occurTime" label="数据发生时间" min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="qualificationFlag" label="合格标志" min-width="100" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="reworkFlag" label="返工标志" min-width="100" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="productionCycle" label="生产节拍(秒)" min-width="120" align="center" />
<el-table-column prop="remark" label="备注" align="center" min-width="100" :show-overflow-tooltip="true" />
<el-table-column prop="createdBy" label="创建人" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="createdTime" label="创建时间" min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="createdTime" label="创建时间" min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="updatedBy" label="更新人" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="updatedTime" label="更新时间"min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="automanual" label="设备模式"min-width="120" align="center" />
<el-table-column prop="runstatus" label="运行状态" min-width="100"align="center" >
<el-table-column prop="updatedTime" label="更新时间" min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="automanual" label="设备模式" min-width="120" align="center" />
<el-table-column prop="runstatus" label="运行状态" min-width="100" align="center">
<template #default="scope">
<dict-tag :options=" options.runstatusOptions" :value="scope.row.runstatus" />
<dict-tag :options="options.runstatusOptions" :value="scope.row.runstatus" />
</template>
</el-table-column>
<el-table-column prop="trayNo" label="托盘号" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="produceModel" label="生产模式模式" min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="onlineStatus" label="设备在线状态"min-width="120" align="center" >
<el-table-column prop="produceModel" label="生产模式模式" min-width="120" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="onlineStatus" label="设备在线状态" min-width="120" align="center">
<!-- <template #default="scope">
<dict-tag :options=" options.onlineStatusOptions" :value="scope.row.onlineStatus" />
</template> -->
</el-table-column>
<el-table-column prop="productModel" label="产品型号"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="sn1" label="条码查询" align="center"min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="sn2" label="结果上传条码" align="center"min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="cameraResult" label="相机结果"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="assemblyHousingSN" label="合装位机壳 SN"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="assemblyPCBSN" label="合装位 PCB SN"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="tightenHousingSN" label="拧紧位机壳 SN"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="tightenPCBSN" label="拧紧位 PCB SN" min-width="150"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="assemblyTrayNo" label="合装位托盘号"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="tightenTrayNo" label="拧紧位托盘号"min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw1Result" label="1 号螺钉拧紧结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw1Torque" label="1 号螺钉扭矩Nm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw1Depth" label="1 号螺钉深度mm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw1Angle" label="1 号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw1TightenTime" label="1 号螺钉拧紧时间秒"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw2Result" label="2 号螺钉拧紧结果"min-width="140"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw2Torque" label="2 号螺钉扭矩Nm"min-width="140" align="center" :show-overflow-tooltip="true"/>
<el-table-column prop="screw2Depth" label="2号螺钉深度mm" min-width="140"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw2Angle" label="2号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw2TightenTime" label="2 号螺钉拧紧时间秒"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw3Result" label="3 号螺钉拧紧结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw3Torque" label="3 号螺钉扭矩Nm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw3Depth" label="3 号螺钉深度mm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw3Angle" label="3 号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw3TightenTime" label="3号螺钉拧紧时间秒"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw4Result" label="4号螺钉拧紧结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw4Torque" label="4号螺钉扭矩Nm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw4Depth" label="4号螺钉深度mm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw4Angle" label="4 号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw4TightenTime" label="4号螺钉拧紧时间秒"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw5Result" label="5 号螺钉拧紧结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw5Torque" label="5号螺钉扭矩Nm" min-width="140"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw5Depth" label="5号螺钉深度mm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw5Angle" label="5 号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw5TightenTime" label="5号螺钉拧紧时间秒"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw6Result" label="6 号螺钉拧紧结果"min-width="140" align="center" :show-overflow-tooltip="true"/>
<el-table-column prop="screw6Torque" label="6号螺钉扭矩Nm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw6Depth" label="6 号螺钉深度mm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw6Angle" label="6 号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw6TightenTime" label="6号螺钉拧紧时间秒"min-width="150" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw7Result" label="7号螺钉拧紧结果" min-width="140"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw7Torque" label="7 号螺钉扭矩Nm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw7Depth" label="7号螺钉深度mm"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw7Angle" label="7号螺钉角度°"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="screw7TightenTime" label="7 号螺钉拧紧时间秒" min-width="150"align="center" :show-overflow-tooltip="true" />
<el-table-column prop="chipSN" label="芯片"min-width="180" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product1SN" label="产品1SN"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product2SN" label="产品2SN"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product3SN" label="产品3SN"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product4SN" label="产品4SN"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product1Result" label="产品1结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product2Result" label="产品2结果"min-width="140" align="center" :show-overflow-tooltip="true"/>
<el-table-column prop="product3Result" label="产品3结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product4Result" label="产品4结果"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pinPressure1" label="1# 销压力"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pinStroke1" label="1# 销行程"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pinPressure2" label="2# 销压力"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pinStroke2" label="2# 销行程"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pressHoldTime" label="保压时间"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="trayBarcode" label="波峰焊托盘条码"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="actualOutQty" label="实际产量"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="qualifiedQty" label="合格数量"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="failedQty" label="失败数量"min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="productModel" label="产品型号" min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="sn1" label="条码查询" align="center" min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="sn2" label="结果上传条码" align="center" min-width="120" :show-overflow-tooltip="true" />
<el-table-column prop="cameraResult" label="相机结果" min-width="120" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="assemblyHousingSN" label="合装位机壳 SN" min-width="120" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="assemblyPCBSN" label="合装位 PCB SN" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="tightenHousingSN" label="拧紧位机壳 SN" min-width="120" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="tightenPCBSN" label="拧紧位 PCB SN" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="assemblyTrayNo" label="合装位托盘号" min-width="120" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="tightenTrayNo" label="拧紧位托盘号" min-width="120" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw1Result" label="1 号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw1Torque" label="1 号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw1Depth" label="1 号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw1Angle" label="1 号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw1TightenTime" label="1 号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw2Result" label="2 号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw2Torque" label="2 号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw2Depth" label="2号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw2Angle" label="2号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw2TightenTime" label="2 号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw3Result" label="3 号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw3Torque" label="3 号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw3Depth" label="3 号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw3Angle" label="3 号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw3TightenTime" label="3号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw4Result" label="4号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw4Torque" label="4号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw4Depth" label="4号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw4Angle" label="4 号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw4TightenTime" label="4号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw5Result" label="5 号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw5Torque" label="5号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw5Depth" label="5号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw5Angle" label="5 号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw5TightenTime" label="5号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw6Result" label="6 号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw6Torque" label="6号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw6Depth" label="6 号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw6Angle" label="6 号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw6TightenTime" label="6号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw7Result" label="7号螺钉拧紧结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw7Torque" label="7 号螺钉扭矩Nm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw7Depth" label="7号螺钉深度mm" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw7Angle" label="7号螺钉角度°" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="screw7TightenTime" label="7 号螺钉拧紧时间秒" min-width="150" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="chipSN" label="芯片" min-width="180" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product1SN" label="产品1SN" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product2SN" label="产品2SN" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product3SN" label="产品3SN" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product4SN" label="产品4SN" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="product1Result" label="产品1结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="product2Result" label="产品2结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="product3Result" label="产品3结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="product4Result" label="产品4结果" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="pinPressure1" label="1# 销压力" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="pinStroke1" label="1# 销行程" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pinPressure2" label="2# 销压力" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="pinStroke2" label="2# 销行程" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="pressHoldTime" label="保压时间" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="trayBarcode" label="波峰焊托盘条码" min-width="140" align="center"
:show-overflow-tooltip="true" />
<el-table-column prop="actualOutQty" label="实际产量" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="qualifiedQty" label="合格数量" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column prop="failedQty" label="失败数量" min-width="140" align="center" :show-overflow-tooltip="true" />
<el-table-column label="操作" width="100" fixed="right" align="center">
<template #default="scope">
<!-- <el-button type="success" size="small" icon="edit" title="编辑" v-hasPermi="['plcproductiondata:edit']" @click="handleUpdate(scope.row)"></el-button> -->
<el-button type="danger" size="small" icon="delete" title="删除" v-hasPermi="['plcproductiondata:delete']" @click="handleDelete(scope.row)"></el-button>
<el-button type="danger" size="small" icon="delete" title="删除" v-hasPermi="['plcproductiondata:delete']"
@click="handleDelete(scope.row)"></el-button>
</template>
</el-table-column>
</el-table>
<pagination :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
<pagination :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize"
@pagination="getList" />
<el-dialog :title="title" :lock-scroll="false" v-model="open" >
<el-dialog :title="title" :lock-scroll="false" v-model="open">
<el-form ref="formRef" :model="form" :rules="rules" label-width="140px">
<el-row :gutter="20">
<el-col :lg="12">
<el-form-item label="产线编号" prop="lineCode">
@ -190,10 +240,7 @@
<el-col :lg="12">
<el-form-item label="数据发生时间" prop="occurTime">
<el-date-picker
v-model="form.occurTime"
type="datetime"
placeholder="选择日期时间"
<el-date-picker v-model="form.occurTime" type="datetime" placeholder="选择日期时间"
value-format="YYYY-MM-DD HH:mm:ss">
</el-date-picker>
</el-form-item>
@ -210,7 +257,7 @@
<el-input v-model="form.reworkFlag" placeholder="请输入返工标志" />
</el-form-item>
</el-col>
<el-col :lg="12">
<el-form-item label="生产节拍(秒)" prop="productionCycle">
<el-input v-model.number="form.productionCycle" placeholder="请输入生产节拍(秒)" />
@ -231,10 +278,7 @@
<el-col :lg="12">
<el-form-item label="创建时间" prop="createdTime">
<el-date-picker
v-model="form.createdTime"
type="datetime"
placeholder="选择日期时间"
<el-date-picker v-model="form.createdTime" type="datetime" placeholder="选择日期时间"
value-format="YYYY-MM-DD HH:mm:ss">
</el-date-picker>
</el-form-item>
@ -248,26 +292,24 @@
<el-col :lg="12">
<el-form-item label="更新时间" prop="updatedTime">
<el-date-picker
v-model="form.updatedTime"
type="datetime"
placeholder="选择日期时间"
<el-date-picker v-model="form.updatedTime" type="datetime" placeholder="选择日期时间"
value-format="YYYY-MM-DD HH:mm:ss">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :lg="12">
<el-form-item label="设备模式" prop="automanual">
<el-input v-model.number="form.automanual" placeholder="请输入设备模式" />
</el-form-item>
</el-col>
<el-col :lg="12">
<el-form-item label="运行状态" prop="runstatus">
<el-radio-group v-model="form.runstatus">
<el-radio v-for="item in options.runstatusOptions" :key="item.dictValue" :value="parseInt(item.dictValue)">
{{item.dictLabel}}
<el-radio v-for="item in options.runstatusOptions" :key="item.dictValue"
:value="parseInt(item.dictValue)">
{{ item.dictLabel }}
</el-radio>
</el-radio-group>
</el-form-item>
@ -289,7 +331,7 @@
<el-form-item label="设备在线状态" prop="onlineStatus">
<el-radio-group v-model="form.onlineStatus">
<el-radio v-for="item in options.onlineStatusOptions" :key="item.dictValue" :value="item.dictValue">
{{item.dictLabel}}
{{ item.dictLabel }}
</el-radio>
</el-radio-group>
</el-form-item>
@ -695,22 +737,24 @@
</template>
<script setup name="plcproductiondata">
import { listPlcProductionData,
addPlcProductionData, delPlcProductionData,
updatePlcProductionData,getPlcProductionData,
}
from '@/api/mes/plcproductiondata.js'
import {
listPlcProductionData,
addPlcProductionData, delPlcProductionData,
updatePlcProductionData, getPlcProductionData,
getWorkstationList
}
from '@/api/mes/plcproductiondata.js'
import { start } from 'nprogress';
const { proxy } = getCurrentInstance()
const ids = ref([])
const loading = ref(false)
const showSearch = ref(true)
function getCurrentDate() {
const now = new Date();
const year = now.getFullYear();
const month = String(now.getMonth() + 1).padStart(2, '0');
const day = String(now.getDate()).padStart(2, '0');
return new Date(`${year}-${month}-${day}`);
const now = new Date();
const year = now.getFullYear();
const month = String(now.getMonth() + 1).padStart(2, '0');
const day = String(now.getDate()).padStart(2, '0');
return new Date(`${year}-${month}-${day}`);
}
const queryParams = reactive({
timeRange: [getCurrentDate(), getCurrentDate()],
@ -720,92 +764,92 @@ const queryParams = reactive({
sortType: 'asc',
})
const columns = ref([
{ visible: true, align: 'center', type: '', prop: 'id', label: '主键ID' },
{ visible: true, align: 'center', type: '', prop: 'lineCode', label: '产线编号如line2' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'plcIp', label: 'PLC IP地址' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'productCode', label: '产品编码' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'productName', label: '产品名称' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'paramName', label: '参数名称' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'paramValue', label: '参数值' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'occurTime', label: '数据发生时间' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'qualificationFlag', label: '合格标志' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'reworkFlag', label: '返工标志' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'productionCycle', label: '生产节拍(秒)' },
{ visible: false, align: 'center', type: '', prop: 'remark', label: '备注' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'createdBy', label: '创建人' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'createdTime', label: '创建时间' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'updatedBy', label: '更新人' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'updatedTime', label: '更新时间' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'automanual', label: '设备模式' },
{ visible: false, align: 'center', type: 'dict', prop: 'runstatus', label: '运行状态' },
{ visible: false, align: 'center', type: '', prop: 'trayNo', label: '托盘号' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'produceModel', label: '生产模式模式' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: 'dict', prop: 'onlineStatus', label: '设备在线状态' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'workstationCode', label: '工站编码' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'productModel', label: '产品型号' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'workstationName', label: '工站名称' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'sn1', label: '条码查询' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'sn2', label: '结果上传条码' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'cameraResult', label: '相机结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'assemblyHousingSN', label: '合装位机壳 SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'assemblyPCBSN', label: '合装位 PCB SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'tightenHousingSN', label: '拧紧位机壳 SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'tightenPCBSN', label: '拧紧位 PCB SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'assemblyTrayNo', label: '合装位托盘号' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'tightenTrayNo', label: '拧紧位托盘号' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Result', label: '1 号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Torque', label: '1 号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Depth', label: '1 号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Angle', label: '1 号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1TightenTime', label: '1 号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Result', label: '2 号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Torque', label: '2 号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Depth', label: '2号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Angle', label: '2号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2TightenTime', label: '2 号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Result', label: '3 号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Torque', label: '3 号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Depth', label: '3 号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Angle', label: '3 号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3TightenTime', label: '3号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Result', label: '4号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Torque', label: '4号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Depth', label: '4号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Angle', label: '4 号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4TightenTime', label: '4号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Result', label: '5 号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Torque', label: '5号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Depth', label: '5号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Angle', label: '5 号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5TightenTime', label: '5号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Result', label: '6 号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Torque', label: '6号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Depth', label: '6 号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Angle', label: '6 号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6TightenTime', label: '6号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Result', label: '7号螺钉拧紧结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Torque', label: '7 号螺钉扭矩Nm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Depth', label: '7号螺钉深度mm' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Angle', label: '7号螺钉角度°' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7TightenTime', label: '7 号螺钉拧紧时间秒' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'chipSN', label: '芯片' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product1SN', label: '产品1SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product2SN', label: '产品2SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product3SN', label: '产品3SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product4SN', label: '产品4SN' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product1Result', label: '产品1结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product2Result', label: '产品2结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product3Result', label: '产品3结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product4Result', label: '产品4结果' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinPressure1', label: '1# 销压力' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinStroke1', label: '1# 销行程' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinPressure2', label: '2# 销压力' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinStroke2', label: '2# 销行程' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pressHoldTime', label: '保压时间' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'trayBarcode', label: '波峰焊托盘条码' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'actualOutQty', label: '实际产量' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'qualifiedQty', label: '合格数量' ,showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'failedQty', label: '失败数量' ,showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'id', label: '主键ID' },
{ visible: true, align: 'center', type: '', prop: 'lineCode', label: '产线编号如line2', showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'plcIp', label: 'PLC IP地址', showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'productCode', label: '产品编码', showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'productName', label: '产品名称', showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'paramName', label: '参数名称', showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'paramValue', label: '参数值', showOverflowTooltip: true },
{ visible: true, align: 'center', type: '', prop: 'occurTime', label: '数据发生时间', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'qualificationFlag', label: '合格标志', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'reworkFlag', label: '返工标志', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'productionCycle', label: '生产节拍(秒)' },
{ visible: false, align: 'center', type: '', prop: 'remark', label: '备注', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'createdBy', label: '创建人', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'createdTime', label: '创建时间', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'updatedBy', label: '更新人', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'updatedTime', label: '更新时间', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'automanual', label: '设备模式' },
{ visible: false, align: 'center', type: 'dict', prop: 'runstatus', label: '运行状态' },
{ visible: false, align: 'center', type: '', prop: 'trayNo', label: '托盘号', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'produceModel', label: '生产模式模式', showOverflowTooltip: true },
{ visible: false, align: 'center', type: 'dict', prop: 'onlineStatus', label: '设备在线状态', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'workstationCode', label: '工站编码', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'productModel', label: '产品型号', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'workstationName', label: '工站名称', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'sn1', label: '条码查询', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'sn2', label: '结果上传条码', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'cameraResult', label: '相机结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'assemblyHousingSN', label: '合装位机壳 SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'assemblyPCBSN', label: '合装位 PCB SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'tightenHousingSN', label: '拧紧位机壳 SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'tightenPCBSN', label: '拧紧位 PCB SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'assemblyTrayNo', label: '合装位托盘号', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'tightenTrayNo', label: '拧紧位托盘号', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Result', label: '1 号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Torque', label: '1 号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Depth', label: '1 号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1Angle', label: '1 号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw1TightenTime', label: '1 号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Result', label: '2 号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Torque', label: '2 号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Depth', label: '2号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2Angle', label: '2号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw2TightenTime', label: '2 号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Result', label: '3 号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Torque', label: '3 号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Depth', label: '3 号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3Angle', label: '3 号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw3TightenTime', label: '3号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Result', label: '4号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Torque', label: '4号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Depth', label: '4号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4Angle', label: '4 号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw4TightenTime', label: '4号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Result', label: '5 号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Torque', label: '5号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Depth', label: '5号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5Angle', label: '5 号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw5TightenTime', label: '5号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Result', label: '6 号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Torque', label: '6号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Depth', label: '6 号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6Angle', label: '6 号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw6TightenTime', label: '6号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Result', label: '7号螺钉拧紧结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Torque', label: '7 号螺钉扭矩Nm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Depth', label: '7号螺钉深度mm', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7Angle', label: '7号螺钉角度°', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'screw7TightenTime', label: '7 号螺钉拧紧时间秒', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'chipSN', label: '芯片', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product1SN', label: '产品1SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product2SN', label: '产品2SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product3SN', label: '产品3SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product4SN', label: '产品4SN', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product1Result', label: '产品1结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product2Result', label: '产品2结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product3Result', label: '产品3结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'product4Result', label: '产品4结果', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinPressure1', label: '1# 销压力', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinStroke1', label: '1# 销行程', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinPressure2', label: '2# 销压力', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pinStroke2', label: '2# 销行程', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'pressHoldTime', label: '保压时间', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'trayBarcode', label: '波峰焊托盘条码', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'actualOutQty', label: '实际产量', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'qualifiedQty', label: '合格数量', showOverflowTooltip: true },
{ visible: false, align: 'center', type: '', prop: 'failedQty', label: '失败数量', showOverflowTooltip: true },
//{ visible: false, prop: 'actions', label: '', type: 'slot', width: '160' }
])
const total = ref(0)
@ -824,7 +868,7 @@ function getList() {
const year = d.getFullYear();
const month = String(d.getMonth() + 1).padStart(2, '0');
const day = String(d.getDate()).padStart(2, '0');
return `${year}-${month}-${day}`;
};
@ -833,20 +877,35 @@ function getList() {
startTime: queryParams.timeRange && queryParams.timeRange[0] ? formatDateTime(queryParams.timeRange[0]) : '',
endTime: queryParams.timeRange && queryParams.timeRange[1] ? formatDateTime(queryParams.timeRange[1]) : ''
};
delete params.timeRange;
loading.value = true,
listPlcProductionData(params).then(res => {
const { code, data } = res
if (code == 200) {
dataList.value = data.result
total.value = data.totalNum
loading.value = false
listPlcProductionData(params).then(res => {
const { code, data } = res
if (code == 200) {
dataList.value = data.result
total.value = data.totalNum
loading.value = false
}
})
}
const workstationList = ref([])
function getWorkstationListData() {
getWorkstationList().then(res => {
if (res.code == 200) {
workstationList.value = res.data.map(item => {
return {
label: item.workstationName,
value: item.workstationCode
}
})
}
})
}
getWorkstationListData()
//
function handleQuery() {
queryParams.pageNum = 1
@ -854,7 +913,7 @@ function handleQuery() {
}
//
function resetQuery(){
function resetQuery() {
proxy.resetForm("queryRef")
handleQuery()
}
@ -888,14 +947,14 @@ const state = reactive({
},
options: {
// eg:{ dictLabel: '', dictValue: '0'}
runstatusOptions: [],
runstatusOptions: [],
}
})
const { form, rules, options, single, multiple } = toRefs(state)
// dialog
function cancel(){
function cancel() {
open.value = false
reset()
}
@ -1032,15 +1091,15 @@ function submitForm() {
open.value = false
getList()
})
.finally(() => {
state.submitLoading = false
})
.finally(() => {
state.submitLoading = false
})
} else {
addPlcProductionData(form.value).then((res) => {
proxy.$modal.msgSuccess("新增成功")
open.value = false
getList()
})
proxy.$modal.msgSuccess("新增成功")
open.value = false
getList()
})
.finally(() => {
setTimeout(() => {
state.submitLoading = false