全局数字验证

This commit is contained in:
Vergil
2020-02-24 15:20:42 +08:00
parent 6c08cd2ea8
commit a4e5f22b95
7 changed files with 256 additions and 211 deletions

View File

@@ -2,13 +2,12 @@
<div class="app-container">
<el-card>
<el-row>
<el-input v-model="workerName" placeholder="操作者" size="small" clearable style="width:200px;margin:0px 10px"/>
<!-- <span class="demonstration">完成加工时间:</span>-->
<el-input v-model="workerName" placeholder="操作者" size="small" clearable style="width: 150px;margin:10px 10px 3px 0"/>
<el-date-picker
v-model="startTime"
value-format="yyyy-MM-dd"
size="small"
style="width: 170px;margin:0px 10px"
style="width: 150px"
type="date"
placeholder="选择开始加工日期"/>
<span class="demonstration">~</span>
@@ -16,188 +15,159 @@
v-model="endTime"
value-format="yyyy-MM-dd"
size="small"
style="width: 170px;margin:0px 10px"
style="width: 150px"
type="date"
placeholder="选择加工完成日期"/>
<el-button type="primary" plain class="el-icon-search" size="small" style="margin:0px 10px" @click="pageCurrent=1;total = 0;searchTable();">查询</el-button>
<el-button type="primary" plain class="el-icon-search" size="small" style="margin-left: 20px" @click="pageCurrent=1;total = 0;searchTable();">查询</el-button>
<el-tooltip :open-delay="1000" content="导出人员工时统计表" placement="right">
<el-button type="primary" plain size="small" icon="el-icon-download" style="margin:0px 10px" @click="exportUninquirySheet1()">导出</el-button>
</el-tooltip>
</el-row>
<el-row>
<el-col :span="6">
<el-table v-loading="loading" :data="tableData" highlight-current-row height="370" size="mini" stripe style="width: 100%;" border element-loading-text="拼命加载中" @row-click="searchTable2">
<el-table-column label="操作者" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
</el-table>
<div class="block">
<el-pagination
v-if="!loading"
:current-page="pageCurrent"
:page-size="pageSize"
:total="total"
layout="total"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-col>
<el-col :span="17">
<el-table v-loading="loading2" :data="tableData2" height="370" size="mini" highlight-current-row style="width: 100%;" border element-loading-text="拼命加载中">
<el-table-column label="零件图号" align="center" width="150px">
<template slot-scope="scope">
{{ scope.row.零件图号 }}
</template>
</el-table-column>
<el-table-column label="零件名称" align="center" width="130px">
<template slot-scope="scope">
{{ scope.row.零件名称 }}
</template>
</el-table-column>
<el-table-column label="工艺名称" align="center" width="120px">
<template slot-scope="scope">
{{ scope.row.工艺名称 }}
</template>
</el-table-column>
<el-table-column label="完成数量" align="center" width="100px">
<template slot-scope="scope">
{{ scope.row.完成数量 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center" width="100px">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center" width="100px">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
<el-table-column label="完成时间" align="center">
<template slot-scope="scope">
{{ scope.row.加工完成时间 }}
</template>
</el-table-column>
</el-table>
<div class="block">
<el-pagination
v-if="!loading2"
:current-page="pageCurrent2"
:page-size="pageSize2"
:total="total2"
layout="total, prev, pager, next, jumper"
@size-change="handleSizeChange2"
@current-change="handleCurrentChange2"/>
</div>
</el-col>
</el-row>
</el-card>
<el-card>
<el-col :span="6">
<el-table
v-loading="loading"
:data="tableData"
highlight-current-row
height="380"
size="mini"
stripe
style="width: 100%;"
border
element-loading-text="拼命加载中"
@row-click="searchTable2">
<el-table-column label="操作者" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
</el-table>
<div style="margin: 10px">
<el-pagination
v-if="!loading"
:current-page="pageCurrent"
:page-size="pageSize"
:total="total"
layout="total"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-col>
<el-col :span="17" style="margin-left: 30px;">
<el-table v-loading="loading2" :data="tableData2" height="380" size="mini" highlight-current-row style="width: 100%;" border element-loading-text="拼命加载中">
<el-table-column label="零件图号" align="center" width="150px">
<template slot-scope="scope">
{{ scope.row.零件图号 }}
</template>
</el-table-column>
<el-table-column label="零件名称" align="center" width="130px">
<template slot-scope="scope">
{{ scope.row.零件名称 }}
</template>
</el-table-column>
<el-table-column label="工艺名称" align="center" width="120px">
<template slot-scope="scope">
{{ scope.row.工艺名称 }}
</template>
</el-table-column>
<el-table-column label="完成数量" align="center" width="100px">
<template slot-scope="scope">
{{ scope.row.完成数量 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center" width="100px">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center" width="100px">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
<el-table-column label="完成时间" align="center">
<template slot-scope="scope">
{{ scope.row.加工完成时间 }}
</template>
</el-table-column>
</el-table>
<div style="margin: 10px">
<el-pagination
v-if="!loading2"
:current-page="pageCurrent2"
:page-size="pageSize2"
:total="total2"
layout="total, prev, pager, next, jumper"
@size-change="handleSizeChange2"
@current-change="handleCurrentChange2"/>
</div>
</el-col>
</el-card>
<el-card>
<!-- <span style="margin-left: 10px">机床编号:</span>-->
<el-select v-model="machineNumberValue" filterable placeholder="机床编号" size="small" style="margin:0px 10px" clearable @change="searchTable4();searchTable6()">
<el-option
v-for="item in machineNumber"
:key="item.value"
:label="item.label"
:value="item.value">
<div style="float: left">{{ item.label }}</div>
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>
</el-option>
</el-select>
<el-tooltip :open-delay="1000" content="导出机床工时统计明细表" placement="top">
<el-button type="primary" size="mini" icon="el-icon-download" plain style="margin-left:10px" @click="exportUninquirySheet2()">机床导出</el-button>
</el-tooltip>
<el-tooltip :open-delay="1000" content="导出组件工时统计明细表" placement="top">
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left:10px" plain @click="exportUninquirySheet3()">组件导出</el-button>
</el-tooltip>
</el-card>
<el-card>
<el-col :span="6">
<el-table v-loading="loading3" :data="tableData3" stripe size="mini" highlight-current-row height="380" style="width: 100%;" border element-loading-text="拼命加载中" @row-click="searchTable5">
<el-table-column label="机床编号" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
</el-table>
<!-- <div style="margin: 10px">-->
<!-- <el-pagination-->
<!-- v-if="!loading3"-->
<!-- :current-page="pageCurrent3"-->
<!-- :page-size="pageSize3"-->
<!-- :total="total3"-->
<!-- layout="total"-->
<!-- @size-change="handleSizeChange3"-->
<!-- @current-change="handleCurrentChange3"/>-->
<!-- </div>-->
</el-col>
<el-col :span="17" style="margin-left: 30px;">
<el-table v-loading="loading4" :data="tableData4" size="mini" height="380" highlight-current-row style="width: 100%;" border element-loading-text="拼命加载中">
<el-table-column label="机床编号" align="center">
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="组号" align="center">
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center" width="120px">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
</el-table>
<!-- <div style="margin: 10px">-->
<!-- <el-pagination-->
<!-- v-if="!loading4"-->
<!-- :current-page="pageCurrent4"-->
<!-- :page-size="pageSize4"-->
<!-- :total="total4"-->
<!-- layout="total"-->
<!-- @size-change="handleSizeChange4"-->
<!-- @current-change="handleCurrentChange4"/>-->
<!-- </div>-->
</el-col>
<el-row>
<el-select v-model="machineNumberValue" filterable placeholder="机床编号" size="small" style="width: 150px;margin:10px 0px 3px 0" clearable @change="searchTable4();searchTable6()">
<el-option
v-for="item in machineNumber"
:key="item.value"
:label="item.label"
:value="item.value">
<div style="float: left">{{ item.label }}</div>
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>
</el-option>
</el-select>
<el-tooltip :open-delay="1000" content="导出机床工时统计明细表" placement="top">
<el-button type="primary" size="mini" icon="el-icon-download" plain style="margin-left:20px" @click="exportUninquirySheet2()">机床导出</el-button>
</el-tooltip>
<el-tooltip :open-delay="1000" content="导出组件工时统计明细表" placement="top">
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left:10px" plain @click="exportUninquirySheet3()">组件导出</el-button>
</el-tooltip>
</el-row>
<el-row>
<el-col :span="6">
<el-table v-loading="loading3" :data="tableData3" stripe size="mini" highlight-current-row height="335" style="width: 100%;" border element-loading-text="拼命加载中" @row-click="searchTable5">
<el-table-column label="机床编号" align="center" width="110px">
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
</el-table>
</el-col>
<el-col :span="17">
<el-table v-loading="loading4" :data="tableData4" size="mini" height="335" highlight-current-row style="width: 100%;" border element-loading-text="拼命加载中">
<el-table-column label="机床编号" align="center">
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="组号" align="center">
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column label="理论工时" align="center">
<template slot-scope="scope">
{{ scope.row.理论加工时间段 }}
</template>
</el-table-column>
<el-table-column label="实际工时" align="center" width="120px">
<template slot-scope="scope">
{{ scope.row.实际加工时间段 }}
</template>
</el-table-column>
</el-table>
</el-col>
</el-row>
</el-card>
</div>
</template>
@@ -207,6 +177,7 @@ import { searchtable, searchtable2, searchtable4, searchtable5, initProject, sea
export default {
data() {
return {
AmountInputBox: 231,
workerName: '',
startTime: '',
endTime: '',