更新
This commit is contained in:
@@ -1,25 +1,26 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<span>项目名称:</span>
|
||||
<el-select
|
||||
v-model="entryNameValue"
|
||||
placeholder="项目名称"
|
||||
style="width:200px"
|
||||
size="small"
|
||||
clearable
|
||||
filterable
|
||||
@change="empty">
|
||||
<el-select v-model="Machine" filterable clearable size="small" style="margin:0px 10px 0px 10px;width: 185px;" placeholder="机床号" @change="searchGroupList">
|
||||
<el-option
|
||||
v-for="item in entryName"
|
||||
v-for="item in Machines"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
:value="item.value">
|
||||
<div style="float: left">{{ item.label }}</div>
|
||||
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.value2 }}</div>
|
||||
</el-option>
|
||||
</el-select>
|
||||
<el-select v-model="Group" size="small" clearable placeholder="组号" style="margin:0px 10px;width: 100px;" @change="total=0;pageSize=1000;pageCurrent=1;searchData();searchTable()">
|
||||
<el-option
|
||||
v-for="item in Groups"
|
||||
: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.value2 }}</div>
|
||||
</el-option>
|
||||
</el-select>
|
||||
<span>机床号:</span>
|
||||
<el-input v-model="machineToolNumber" placeholder="请双击选择" size="small" clearable style="width:200px" @change="empty1" @dblclick.native="SearchMachine"/>
|
||||
<span>组号:</span>
|
||||
<el-input v-model="groupNumber" placeholder="请双击选择" size="small" clearable style="width:200px" @dblclick.native="searchGroupList"/>
|
||||
<el-button type="success" icon="el-icon-search" size="small" style="margin-top: 15px;margin-left: 10px" @click="total=0;pageSize=1000;pageCurrent=1;searchData();searchTable()">查询</el-button>
|
||||
</el-card>
|
||||
<el-card>
|
||||
@@ -317,117 +318,6 @@
|
||||
@current-change="handleCurrentChange5"/>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible2" title="选择机床" center style="min-height: 300px">
|
||||
<el-table
|
||||
:data="tableData6"
|
||||
style="width:100%;max-height: 300px;display: inline-block"
|
||||
height="300"
|
||||
highlight-current-row
|
||||
border
|
||||
@row-click="selectMachine">
|
||||
<el-table-column align="center" label="机床图号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="机床名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="机床开始时间">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床开始时间 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="机床结束时间">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床结束时间 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="工位属性">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.工位属性 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="机床主管">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床主管 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="装配状态">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.装配状态===null || scope.row.装配状态===0" type="success" size="small">未装配</el-tag>
|
||||
<el-tag v-else-if="scope.row.装配状态===1" type="danger" size="small" >装配中</el-tag>
|
||||
<el-tag v-else type="info" size="small" >装配完成</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="block" style="margin-top: 10px;">
|
||||
<el-pagination
|
||||
:current-page="pageCurrent1"
|
||||
:page-sizes="[10, 20, 30, 40, 50]"
|
||||
:page-size="pageSize1"
|
||||
:total="total1"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@size-change="handleSizeChange1"
|
||||
@current-change="handleCurrentChange1"/>
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitName">提交</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible3" title="选择组号" center style="min-height: 300px">
|
||||
<el-table
|
||||
:data="tableData7"
|
||||
style="width:100%;max-height: 300px;display: inline-block"
|
||||
height="300"
|
||||
highlight-current-row
|
||||
border
|
||||
@row-click="selectGroup">
|
||||
<el-table-column align="center" label="机床图号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="机床名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="组号">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.组号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="组件名称">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.组件名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="装配状态">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.组件是否完成===null || scope.row.组件是否完成===0" type="success" size="small">未装配</el-tag>
|
||||
<el-tag v-else-if="scope.row.组件是否完成===1" type="danger" size="small" >装配中</el-tag>
|
||||
<el-tag v-else type="info" size="small" >装配完成</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="block" style="margin-top: 10px;">
|
||||
<el-pagination
|
||||
:current-page="pageCurrent2"
|
||||
:page-sizes="[10, 20, 30, 40, 50]"
|
||||
:page-size="pageSize2"
|
||||
:total="total2"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@size-change="handleSizeChange3"
|
||||
@current-change="handleCurrentChange3"/>
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitGroup">提交</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible4" :title="titleaa" center style="min-height: 300px">
|
||||
<el-table
|
||||
@@ -477,12 +367,16 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { initProject, searchTable, searchmachine, searchgroup, searchPurchaseTable, searchTable1, processingStatus, searchTable22, searchTable01, searchTable02 } from '@/api/ManufacturingCenter/GroupMatching'
|
||||
import { searchTable, searchmachine, searchgroup, searchTable1, processingStatus, searchTable22, searchTable01, searchTable02 } from '@/api/ManufacturingCenter/GroupMatching'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
titleaa: '',
|
||||
零件图号: '',
|
||||
Machines: [],
|
||||
Machine: '',
|
||||
Groups: [],
|
||||
Group: '',
|
||||
entryNameValue: null, // 项目流水号
|
||||
entryName: [], // 项目数组
|
||||
machineToolNumber: '', // 机床图号
|
||||
@@ -519,8 +413,6 @@ export default {
|
||||
tableData01: [],
|
||||
tableData02: [],
|
||||
state: null,
|
||||
listLoading1: false,
|
||||
listLoading2: false,
|
||||
total00: 0,
|
||||
total01: 0,
|
||||
total02: 0,
|
||||
@@ -586,78 +478,39 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
this.SearchMachine()
|
||||
},
|
||||
methods: {
|
||||
searchData() {
|
||||
this.totalNum = 0
|
||||
this.loading = true
|
||||
this.listLoading1 = true
|
||||
this.listLoading2 = true
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
searchTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].入库时间 !== '') {
|
||||
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
|
||||
}
|
||||
if (response.data.rows[i].计划完成时间 !== '') {
|
||||
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
|
||||
}
|
||||
this.Machine ? this.check1 = 1 : this.check1 = 0
|
||||
this.Group ? this.check2 = 1 : this.check2 = 0
|
||||
searchTable(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].入库时间 !== '') {
|
||||
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
|
||||
}
|
||||
this.tableData = response.data.rows
|
||||
this.total = parseInt(response.data.total)
|
||||
this.loading = false
|
||||
})
|
||||
searchTable22(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
console.log(response.data[i].入库时间, 123)
|
||||
if (response.data[i].入库时间 !== null) {
|
||||
this.totalNum += 1
|
||||
}
|
||||
if (response.data.rows[i].计划完成时间 !== '') {
|
||||
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
|
||||
}
|
||||
})
|
||||
searchPurchaseTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].到货时间 !== '' || response.data.rows[i].到货时间 !== null) {
|
||||
response.data.rows[i].到货时间 = response.data.rows[i].到货时间.split(' ', 2)[0]
|
||||
}
|
||||
}
|
||||
this.tableDataPurchase = response.data.rows
|
||||
this.total4 = parseInt(response.data.total)
|
||||
})
|
||||
searchTable1(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.pageCurrent, this.pageSize).then(response => {
|
||||
this.tableData1 = response.data.rows
|
||||
this.total5 = parseInt(response.data.total)
|
||||
})
|
||||
} else {
|
||||
}
|
||||
this.tableData = response.data.rows
|
||||
this.total = parseInt(response.data.total)
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
},
|
||||
getList() { // 初始化项目名称
|
||||
initProject().then(response => {
|
||||
})
|
||||
searchTable22(this.check1, this.Machine, this.check2, this.Group, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.entryName.push({
|
||||
label: response.data[i].项目名称,
|
||||
value: response.data[i].项目流水号
|
||||
})
|
||||
console.log(response.data[i].入库时间, 123)
|
||||
if (response.data[i].入库时间 !== null) {
|
||||
this.totalNum += 1
|
||||
}
|
||||
}
|
||||
})
|
||||
searchTable1(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => {
|
||||
this.tableData1 = response.data.rows
|
||||
this.total5 = parseInt(response.data.total)
|
||||
})
|
||||
},
|
||||
processingStatus(row) {
|
||||
this.dialogFormVisible4 = true
|
||||
@@ -671,62 +524,32 @@ export default {
|
||||
this.tableData5 = response.data
|
||||
})
|
||||
},
|
||||
empty() {
|
||||
this.machineToolNumber = ''
|
||||
this.groupNumber = ''
|
||||
},
|
||||
SearchMachine() { // 查询机床
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.dialogFormVisible2 = true
|
||||
this.check6 = 1
|
||||
searchmachine(this.entryNameValue, this.check6, this.pageCurrent1, this.pageSize1).then(response => {
|
||||
for (let i = 0; i < response.data.result; i++) {
|
||||
if (response.data.result[i].机床开始时间 !== '') {
|
||||
response.data.result[i].机床开始时间 = response.data.result[i].机床开始时间.substr(0, 10)
|
||||
}
|
||||
if (response.data.result[i].机床结束时间 !== '') {
|
||||
response.data.result[i].机床结束时间 = response.data.result[i].机床结束时间.substr(0, 10)
|
||||
}
|
||||
}
|
||||
this.tableData6 = response.data.result
|
||||
this.total1 = parseInt(response.data.output[0].ItemCount)
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
},
|
||||
selectMachine(row) { // 选择机床号
|
||||
this.machine = row.机床流水号
|
||||
this.machineNumber = row.机床图号
|
||||
},
|
||||
submitName() { // 提交机床号
|
||||
this.machineToolNumber = this.machineNumber
|
||||
this.dialogFormVisible2 = false
|
||||
},
|
||||
empty1() {
|
||||
this.groupNumber = ''
|
||||
searchmachine().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.Machines.push({
|
||||
label: response.data[i].机床图号,
|
||||
value: response.data[i].机床流水号,
|
||||
value2: response.data[i].装配状态
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
searchGroupList() { // 查询组号
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.dialogFormVisible3 = true
|
||||
searchgroup(this.machine, this.pageCurrent2, this.pageSize2).then(response => {
|
||||
this.tableData7 = response.data.result
|
||||
this.total2 = parseInt(response.data.output[0].ItemCount)
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('请先选择机床')
|
||||
}
|
||||
},
|
||||
selectGroup(row) { // 选择组号
|
||||
this.groupNumber1 = row.组号
|
||||
this.groupNum = row.组件流水号
|
||||
},
|
||||
submitGroup() { // 提交组号
|
||||
this.groupNumber = this.groupNumber1
|
||||
this.dialogFormVisible3 = false
|
||||
this.Group = ''
|
||||
this.Groups = []
|
||||
searchgroup(this.Machine).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.Groups.push({
|
||||
label: response.data[i].组号,
|
||||
value: response.data[i].组件流水号,
|
||||
value2: response.data[i].装配状态
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
searchTable() {
|
||||
if (this.machine === '' || this.machine === null) {
|
||||
if (this.Machine === '' || this.Machine === null) {
|
||||
this.$message.warning('请先选择机床组号')
|
||||
} else {
|
||||
if (this.PartType === '标准件') {
|
||||
@@ -740,28 +563,27 @@ export default {
|
||||
},
|
||||
searchTable0() { // 查询标准件
|
||||
let check1, check2
|
||||
this.machine ? check1 = 1 : check1 = 0
|
||||
this.groupNum ? check2 = 1 : check2 = 0
|
||||
searchTable01(check1, this.machine, check2, this.groupNum, this.pageCurrent00, this.pageSize00, 1).then(response => {
|
||||
this.Machine ? check1 = 1 : check1 = 0
|
||||
this.Group ? check2 = 1 : check2 = 0
|
||||
searchTable01(check1, this.Machine, check2, this.Group, this.pageCurrent00, this.pageSize00, 1).then(response => {
|
||||
this.tableData00 = response.data.rows
|
||||
this.total00 = response.data.total
|
||||
})
|
||||
},
|
||||
searchTable1() { // 查询外购件
|
||||
let check1, check2
|
||||
this.machine ? check1 = 1 : check1 = 0
|
||||
this.groupNum ? check2 = 1 : check2 = 0
|
||||
searchTable01(check1, this.machine, check2, this.groupNum, this.pageCurrent01, this.pageSize01, 2).then(response => {
|
||||
this.Machine ? check1 = 1 : check1 = 0
|
||||
this.Group ? check2 = 1 : check2 = 0
|
||||
searchTable01(check1, this.Machine, check2, this.Group, this.pageCurrent01, this.pageSize01, 2).then(response => {
|
||||
this.tableData01 = response.data.rows
|
||||
this.total01 = response.data.total
|
||||
})
|
||||
},
|
||||
searchTable2() { // 查询基本件
|
||||
let check1, check2, check3
|
||||
this.machine ? check1 = 1 : check1 = 0
|
||||
this.groupNum ? check2 = 1 : check2 = 0
|
||||
this.entryNameValue ? check3 = 1 : check3 = 0
|
||||
searchTable02(check3, this.entryNameValue, check1, this.machine, check2, this.groupNum, this.pageCurrent02, this.pageSize02).then(response => {
|
||||
let check1, check2
|
||||
this.Machine ? check1 = 1 : check1 = 0
|
||||
this.Group ? check2 = 1 : check2 = 0
|
||||
searchTable02(check1, this.Machine, check2, this.Group, this.pageCurrent02, this.pageSize02).then(response => {
|
||||
this.tableData02 = response.data.rows
|
||||
this.total02 = response.data.total
|
||||
})
|
||||
@@ -769,303 +591,60 @@ export default {
|
||||
handleSizeChange(val) {
|
||||
this.pageCurrent = 1
|
||||
this.pageSize = val
|
||||
console.log(val)
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
if (this.year !== null && this.year !== '') {
|
||||
this.check3 = 1
|
||||
} else {
|
||||
this.check3 = 0
|
||||
}
|
||||
if (this.month !== null && this.month !== '') {
|
||||
this.check4 = 1
|
||||
} else {
|
||||
this.check4 = 0
|
||||
}
|
||||
if (this.time !== '' && this.time !== null) {
|
||||
this.check5 = 1
|
||||
} else {
|
||||
this.check5 = 0
|
||||
}
|
||||
searchTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.pageCurrent, this.pageSize).then(response => {
|
||||
console.log(response)
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].入库时间 !== '') {
|
||||
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
|
||||
}
|
||||
if (response.data.rows[i].计划完成时间 !== '') {
|
||||
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
|
||||
}
|
||||
this.loading = true
|
||||
this.Machine ? this.check1 = 1 : this.check1 = 0
|
||||
this.Group ? this.check2 = 1 : this.check2 = 0
|
||||
searchTable(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].入库时间 !== '') {
|
||||
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
|
||||
}
|
||||
this.tableData = response.data.rows
|
||||
this.total = parseInt(response.data.total)
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
if (response.data.rows[i].计划完成时间 !== '') {
|
||||
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
|
||||
}
|
||||
}
|
||||
this.tableData = response.data.rows
|
||||
this.total = parseInt(response.data.total)
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
})
|
||||
},
|
||||
handleCurrentChange(val) {
|
||||
this.pageCurrent = val
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
if (this.year !== null && this.year !== '') {
|
||||
this.check3 = 1
|
||||
} else {
|
||||
this.check3 = 0
|
||||
}
|
||||
if (this.month !== null && this.month !== '') {
|
||||
this.check4 = 1
|
||||
} else {
|
||||
this.check4 = 0
|
||||
}
|
||||
if (this.time !== '' && this.time !== null) {
|
||||
this.check5 = 1
|
||||
} else {
|
||||
this.check5 = 0
|
||||
}
|
||||
searchTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].入库时间 !== '') {
|
||||
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
|
||||
}
|
||||
if (response.data.rows[i].计划完成时间 !== '') {
|
||||
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
|
||||
}
|
||||
this.loading = true
|
||||
this.Machine ? this.check1 = 1 : this.check1 = 0
|
||||
this.Group ? this.check2 = 1 : this.check2 = 0
|
||||
searchTable(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => {
|
||||
for (let i = 0; i < response.data.rows.length; i++) {
|
||||
if (response.data.rows[i].入库时间 !== '') {
|
||||
response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0]
|
||||
}
|
||||
this.tableData = response.data.rows
|
||||
this.total = parseInt(response.data.total)
|
||||
this.loading = false
|
||||
})
|
||||
} else {
|
||||
if (response.data.rows[i].计划完成时间 !== '') {
|
||||
response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0]
|
||||
}
|
||||
}
|
||||
this.tableData = response.data.rows
|
||||
this.total = parseInt(response.data.total)
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
},
|
||||
handleSizeChange1(val) {
|
||||
this.pageCurrent1 = 1
|
||||
this.pageSize1 = val
|
||||
this.SearchMachine()
|
||||
},
|
||||
handleCurrentChange1(val) {
|
||||
this.pageCurrent1 = val
|
||||
this.SearchMachine()
|
||||
},
|
||||
handleSizeChange3(val) {
|
||||
this.pageCurrent2 = 1
|
||||
this.pageSize2 = val
|
||||
this.searchGroupList()
|
||||
},
|
||||
handleCurrentChange3(val) {
|
||||
this.pageCurrent2 = val
|
||||
this.searchGroupList()
|
||||
},
|
||||
handleSizeChange4(val) {
|
||||
this.pageCurrent4 = 1
|
||||
this.pageSize4 = val
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
if (this.year !== null && this.year !== '') {
|
||||
this.check3 = 1
|
||||
} else {
|
||||
this.check3 = 0
|
||||
}
|
||||
if (this.month !== null && this.month !== '') {
|
||||
this.check4 = 1
|
||||
} else {
|
||||
this.check4 = 0
|
||||
}
|
||||
if (this.time !== '' && this.time !== null) {
|
||||
this.check5 = 1
|
||||
} else {
|
||||
this.check5 = 0
|
||||
}
|
||||
searchPurchaseTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent4, this.pageSize4).then(response => {
|
||||
console.log(response)
|
||||
this.tableDataPurchase = response.data.rows
|
||||
this.listLoading1 = false
|
||||
this.total4 = parseInt(response.data.total)
|
||||
})
|
||||
} else {
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
},
|
||||
handleCurrentChange4(val) {
|
||||
this.pageCurrent4 = val
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
if (this.year !== null && this.year !== '') {
|
||||
this.check3 = 1
|
||||
} else {
|
||||
this.check3 = 0
|
||||
}
|
||||
if (this.month !== null && this.month !== '') {
|
||||
this.check4 = 1
|
||||
} else {
|
||||
this.check4 = 0
|
||||
}
|
||||
if (this.time !== '' && this.time !== null) {
|
||||
this.check5 = 1
|
||||
} else {
|
||||
this.check5 = 0
|
||||
}
|
||||
searchPurchaseTable(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent4, this.pageSize4).then(response => {
|
||||
console.log(response)
|
||||
this.tableDataPurchase = response.data.rows
|
||||
this.listLoading1 = false
|
||||
this.total4 = parseInt(response.data.total)
|
||||
})
|
||||
} else {
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
})
|
||||
},
|
||||
handleSizeChange5(val) {
|
||||
this.pageCurrent5 = 1
|
||||
this.pageSize5 = val
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
if (this.year !== null && this.year !== '') {
|
||||
this.check3 = 1
|
||||
} else {
|
||||
this.check3 = 0
|
||||
}
|
||||
if (this.month !== null && this.month !== '') {
|
||||
this.check4 = 1
|
||||
} else {
|
||||
this.check4 = 0
|
||||
}
|
||||
if (this.time !== '' && this.time !== null) {
|
||||
this.check5 = 1
|
||||
} else {
|
||||
this.check5 = 0
|
||||
}
|
||||
searchTable1(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent5, this.pageSize5).then(response => {
|
||||
console.log(response)
|
||||
this.tableData1 = response.data.rows
|
||||
this.listLoading2 = false
|
||||
this.total5 = parseInt(response.data.total)
|
||||
})
|
||||
} else {
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
this.Machine ? this.check1 = 1 : this.check1 = 0
|
||||
this.Group ? this.check2 = 1 : this.check2 = 0
|
||||
searchTable1(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => {
|
||||
this.tableData1 = response.data.rows
|
||||
this.total5 = parseInt(response.data.total)
|
||||
})
|
||||
},
|
||||
handleCurrentChange5(val) {
|
||||
this.pageCurrent5 = val
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
if (this.entryNameValue !== null && this.entryNameValue !== '') {
|
||||
this.check = 1
|
||||
} else {
|
||||
this.check = 0
|
||||
}
|
||||
if (this.machineToolNumber !== '') {
|
||||
this.check1 = 1
|
||||
} else {
|
||||
this.check1 = 0
|
||||
}
|
||||
if (this.groupNumber !== '') {
|
||||
this.check2 = 1
|
||||
} else {
|
||||
this.check2 = 0
|
||||
}
|
||||
if (this.year !== null && this.year !== '') {
|
||||
this.check3 = 1
|
||||
} else {
|
||||
this.check3 = 0
|
||||
}
|
||||
if (this.month !== null && this.month !== '') {
|
||||
this.check4 = 1
|
||||
} else {
|
||||
this.check4 = 0
|
||||
}
|
||||
if (this.time !== '' && this.time !== null) {
|
||||
this.check5 = 1
|
||||
} else {
|
||||
this.check5 = 0
|
||||
}
|
||||
searchTable1(this.check, this.entryNameValue, this.check1, this.machine, this.check2, this.groupNum, this.check3, this.year, this.check4, this.month, this.check5, this.time, this.pageCurrent5, this.pageSize5).then(response => {
|
||||
console.log(response)
|
||||
this.tableData1 = response.data.rows
|
||||
this.listLoading2 = false
|
||||
this.total5 = parseInt(response.data.total)
|
||||
})
|
||||
} else {
|
||||
this.loading = false
|
||||
this.$message.warning('请先选择项目')
|
||||
}
|
||||
this.Machine ? this.check1 = 1 : this.check1 = 0
|
||||
this.Group ? this.check2 = 1 : this.check2 = 0
|
||||
searchTable1(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => {
|
||||
this.tableData1 = response.data.rows
|
||||
this.total5 = parseInt(response.data.total)
|
||||
})
|
||||
},
|
||||
handleSizeChange00(val) {
|
||||
this.pageCurrent00 = 1
|
||||
|
||||
Reference in New Issue
Block a user