rfid报表

yangwl
zhaoxiaolin 1 year ago
parent 3d4c4318d0
commit 79d9409097

@ -1,28 +0,0 @@
@echo off
echo --------------------------------自定义参数,启动前先修改--------------------------------------
set imageURI=140.249.53.142:30002/op-lanju/ld-op-front
::echo 获取当前日期字符串
for /f "tokens=1,2,3 delims=/- " %%a in ("%date%") do @set D=%%a%%b%%c
::echo 获取当前时间字符串
for /f "tokens=1,2 delims=:." %%a in ("%time%") do @set T=%%a%%b
::echo 如当前小时小于10将空格替换为0
set T=%T: =0%
::echo 显示输出日期时间字符串
set imageVersion=%D%%T%
::输出发版信息
echo 镜像库地址:%imageURI%
echo 镜像版本:%imageVersion%
echo --------------------------------执行打包--------------------------------
call npm run build:prod
dir
echo --------------------------------docker login...-------------------------------
docker logout 140.249.53.142:30002
docker login 140.249.53.142:30002 -u deploy -p Deploy@2022
echo --------------------------------docker build...-------------------------------
docker build -t %imageURI%:%imageVersion% .
echo --------------------------------docker push...--------------------------------
docker push %imageURI%:%imageVersion%
@pause
::docker pull 192.168.3.157:8001/library/nginx:1.20-alpine

@ -1,27 +0,0 @@
@echo off
echo --------------------------------自定义参数,启动前先修改--------------------------------------
set imageURI=192.168.202.36:30002/op-lanju/op-ui
::echo 获取当前日期字符串
for /f "tokens=1,2,3 delims=/- " %%a in ("%date%") do @set D=%%a%%b%%c
::echo 获取当前时间字符串
for /f "tokens=1,2 delims=:." %%a in ("%time%") do @set T=%%a%%b
::echo 如当前小时小于10将空格替换为0
set T=%T: =0%
::echo 显示输出日期时间字符串
set imageVersion=%D%%T%
::输出发版信息
echo 镜像库地址:%imageURI%
echo 镜像版本:%imageVersion%
echo --------------------------------执行打包--------------------------------
call npm run build:prod
dir
echo --------------------------------docker login...-------------------------------
docker login 192.168.202.36:30002 -u deploy -p Deploy@2023
echo --------------------------------docker build...-------------------------------
docker build -t %imageURI%:%imageVersion% .
echo --------------------------------docker push...--------------------------------
docker push %imageURI%:%imageVersion%
@pause
::docker pull 192.168.3.157:8001/library/nginx:1.20-alpine

@ -40,9 +40,9 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="规格型号" prop="productSpc">
<el-form-item label="设备名称" prop="equName">
<el-input
v-model="queryParams.productSpc"
v-model="queryParams.equName"
placeholder="请输入规格型号"
clearable
@keyup.enter.native="handleQuery"
@ -69,10 +69,13 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="prepareList">
<el-table v-loading="loading" :data="prepareList"
:summary-method="getSummaries"
show-summary
>
<el-table-column type="selection" width="55" align="center" />
<!-- 序号 -->
<el-table-column type="index" align="center" :index="indexMethod" label="序号"/>
<!-- 序号
<el-table-column type="index" align="center" :index="indexMethod" label="序号"/> -->
<el-table-column label="工单生产日期" align="center" prop="productDate" width="120">
<!--<template slot-scope="scope"><span>{{ parseTime(scope.row.productDate, '{y}-{m}-{d}') }}</span></template>-->
</el-table-column>
@ -80,9 +83,11 @@
<el-table-column label="工单编号" align="center" prop="workorderCode" width="130"/>
<el-table-column label="产品编码" align="center" prop="productCode" width="130"/>
<el-table-column label="产品名称" align="center" prop="productName" width="160"/>
<el-table-column label="规格型号" align="center" prop="productSpc" />
<!--<el-table-column label="规格型号" align="center" prop="productSpc" />-->
<el-table-column label="工序编码" align="center" prop="processCode" />
<el-table-column label="工序名称" align="center" prop="processName" width="90"/>
<el-table-column label="设备编码" align="center" prop="equCode" />
<el-table-column label="设备名称" align="center" prop="equName" width="90"/>
<el-table-column label="工单排产数量" align="center" prop="quantity" width="100"/>
<el-table-column label="已生产数量" align="center" prop="quantityFeedback" width="100"/>
<el-table-column label="单位" align="center" prop="unit" />
@ -232,6 +237,35 @@ export default {
this.download('mes/reportWork/processFinishExport', {
...this.queryParams
}, `processFinish_${new Date().getTime()}.xlsx`)
},
getSummaries(param) {
const { columns, data } = param;
const sums = [];
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '合计';
return;
}
const values = data.map(item => Number(item[column.property]));
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr);
if (!isNaN(value)) {
return prev + curr;
} else {
return prev;
}
}, 0);
sums[index] += '';
if(sums[index] > 1000000){
sums[index] = '';
}
} else {
sums[index] = '';//N/A
}
});
return sums;
}
}
};

Loading…
Cancel
Save