From f71832a6389efa2f851b8b7bd7a615ed2d3250e4 Mon Sep 17 00:00:00 2001
From: licp <lichunping@guanfang.com.cn>
Date: 星期四, 28 三月 2024 13:16:16 +0800
Subject: [PATCH] 完成模具页面
---
src/views/product/workbench/feed-form.vue | 79 ++++++++++++++++++++++++++++-----------
1 files changed, 57 insertions(+), 22 deletions(-)
diff --git a/src/views/product/workbench/feed-form.vue b/src/views/product/workbench/feed-form.vue
index 95816f1..484bf96 100644
--- a/src/views/product/workbench/feed-form.vue
+++ b/src/views/product/workbench/feed-form.vue
@@ -1,6 +1,7 @@
<template>
<el-dialog
- width="40%"
+ width="60%"
+ top="5vh"
title="鎶曟枡"
:visible.sync="innerVisible"
append-to-body
@@ -15,17 +16,20 @@
:key="tableKey"
:data="dataList"
border
- style="width: 100%;"
+ height="400"
+ style="width: 100%;overflow-y: scroll;"
@cell-dblclick="dblhandleCurrentChange"
show-summary
:span-method="objectSpanMethod"
:summary-method="getSummaries"
>
+ <el-table-column header-align="center" align="center" type="index" label="搴忓彿"></el-table-column>
<el-table-column
prop="partNo"
header-align="center"
align="center"
label="闆朵欢缂栧彿"
+ show-overflow-tooltip
>
</el-table-column>
<el-table-column
@@ -33,22 +37,24 @@
header-align="center"
align="center"
label="闆朵欢"
+ show-overflow-tooltip
>
</el-table-column>
<el-table-column
- prop="partBatchNo"
+ prop="ifsBatchNo"
header-align="center"
align="center"
- label="闆朵欢鎵瑰彿"
+ label="鎵瑰彿"
+ show-overflow-tooltip
>
</el-table-column>
- <el-table-column
+ <!-- <el-table-column
prop="specs"
header-align="center"
align="center"
label="瑙勬牸鍨嬪彿"
>
- </el-table-column>
+ </el-table-column> -->
<el-table-column
prop="suppliedQuantity"
header-align="center"
@@ -72,7 +78,13 @@
header-align="center"
align="center"
label="鍗曚綅"
+ show-overflow-tooltip
>
+ </el-table-column>
+ <el-table-column prop="menu" label="鎿嶄綔" header-align="center" align="center">
+ <template scope="scope">
+ <el-button type="text" icon="el-icon-circle-close" @click="cancelFeed(scope.$index,scope.row)">鍙栨秷</el-button>
+ </template>
</el-table-column>
</el-table>
</div>
@@ -142,6 +154,12 @@
password: null
}
},
+ beforeUpdate(){
+ this.$nextTick(()=>{
+ this.objectSpanMethod()
+ this.$refs.table.doLayout()
+ })
+ },
directives: {
focus: {
inserted: function(el, option) {
@@ -162,6 +180,10 @@
}
},
methods: {
+ //鎶曞叆鍙栨秷鎸夐挳
+ cancelFeed(index,row){
+ this.dataList.splice(index,1)
+ },
confirmData() {
if (this.password != null) {
checkSubmitPassword({ password: this.password }).then((response) => {
@@ -197,22 +219,20 @@
pullFeed() {
var partNoList = []
var partNoLists
- console.log('this.dataList', this.dataList)
for (var i = 0; i < this.dataList.length; i++) {
partNoLists = this.dataList[i].partNo
partNoList.push(partNoLists)
}
getCheckRawPart(partNoList).then((response) => {
- console.log(response)
if (response.data.code === 0) {
// 闇�瑕佸瘑鐮佺‘璁ゆ儏鍐�
- if (response.data.data.success === false) {
- this.messages = response.data.data.message
- this.onnerVisible = true
- } else {
+ //if (response.data.data.success === false) {
+ // this.messages = response.data.data.message
+ // this.onnerVisible = true
+ //} else {
// 涓嶉渶瑕佸瘑鐮� 鐩存帴鎶曟枡
this.saveFeed()
- }
+ //}
}
})
},
@@ -243,7 +263,15 @@
partBatchNo: this.dataList[i].partBatchNo,
systemNo: this.dataList[i].systemNo,
partName: this.dataList[i].partName,
- unit: this.dataList[i].unit ? this.dataList[i].unit : ''
+ unit: this.dataList[i].unit ? this.dataList[i].unit : '',
+ partNo: this.dataList[i].partNo,
+ ifsBatchNo: this.dataList[i].ifsBatchNo,
+ ifsWdr: this.dataList[i].ifsWdr,
+ locationNo: this.dataList[i].locationNo,
+ serialNo:this.dataList[i].serialNo,
+ engChgLevel:this.dataList[i].engChgLevel,
+ configurationId:this.dataList[i].configurationId,
+ activitySeq:this.dataList[i].activitySeq
}
feeds.push(feed)
}
@@ -279,16 +307,16 @@
return reg.test(value)
},
objectSpanMethod() {
- setTimeout(() => {
+ this.$nextTick(()=>{
if (this.$refs.table.$el) {
const current = this.$refs.table.$el
.querySelector('.el-table__footer-wrapper')
.querySelector('.el-table__footer')
const cell = current.rows[0].cells
// cell[1].style.display = 'none'
- cell[0].colSpan = '4'
+ cell[0].colSpan = '6'
}
- }, 50)
+ })
},
getSummaries(param) {
const { columns, data } = param
@@ -318,12 +346,19 @@
},
watch: {
currshowlist() {
- this.innerVisible = this.currshowlist
- this.password = null
- if (this.currshowlist) {
- this.$nextTick(() => {})
+ const _than = this
+ _than.innerVisible = _than.currshowlist
+ _than.password = null
+ if (!_than.currshowlist) {
+ _than.$nextTick(() => {
+ })
}
- }
+ },
+ },
+ created(){
+ this.$nextTick(()=>{
+ this.objectSpanMethod()
+ })
},
mounted() {}
}
--
Gitblit v1.9.3