This commit is contained in:
bb_pan 2025-03-31 16:07:11 +08:00
parent e8c14c01d8
commit b264c3d060
2 changed files with 30 additions and 19 deletions

View File

@ -866,6 +866,9 @@ export default {
//
async GetViewByApply(params) {
const res = await getBackApplyInfo(this.rowId)
if (res.msg) {
this.$message.warning(res.msg)
}
console.log(res)
const data = res.data
this.queryParams.unitId = data.backApplyInfo.unitId
@ -1103,6 +1106,7 @@ export default {
typeId: typeId
}
await getMachineById(param).then(res => {
console.log('🚀 ~ awaitgetMachineById ~ res.data:', res.data)
this.machineList = res.data
this.machineList.forEach(item => {
item.bmFileInfos = []
@ -1119,20 +1123,16 @@ export default {
console.log(this.maCodeList)
console.log(this.machineList)
if (this.rowId != '') {
// //
this.rowData.tempMaCodeList.forEach(item => {
this.machineList.unshift(item) //
// this.$nextTick(() => {
// this.$refs.codeTableList.toggleRowSelection(item, true)
// })
})
this.maCodeList = this.rowData.maCodeList
console.log('🚀 ~ 编辑 ~ this.maCodeList:', this.maCodeList)
this.machineList.forEach(item => {
this.maCodeList.forEach(sub => {
if (sub.maId == item.maId) {
this.$nextTick(() => {
this.$refs.codeTableList.toggleRowSelection(item, true)
item.apDetection = sub.apDetection
setTimeout(() => {
this.$refs.codeTableList.toggleRowSelection(item, true)
item.apDetection = sub.apDetection
}, 200)
})
}
})

View File

@ -42,31 +42,42 @@
<span v-else>{{ (queryParams.pageNum - 1) * 10 + scope.$index }}</span>
</template>
</el-table-column>
<el-table-column label="单位名称" align="center" prop="" show-overflow-tooltip />
<el-table-column label="工程名称" align="center" prop="" show-overflow-tooltip />
<el-table-column label="单位名称" align="center" prop="backUnit" show-overflow-tooltip />
<el-table-column label="工程名称" align="center" prop="backPro" show-overflow-tooltip />
<el-table-column label="物资名称" align="center" prop="typeName" show-overflow-tooltip />
<el-table-column label="规格型号" align="center" prop="typeModelName" show-overflow-tooltip />
<el-table-column label="计量单位" align="center" prop="unitName" show-overflow-tooltip />
<el-table-column label="设备编号" align="center" prop="" show-overflow-tooltip />
<el-table-column label="设备编号" align="center" prop="maCode" show-overflow-tooltip />
<el-table-column label="报废数量" align="center" prop="scrapNum" show-overflow-tooltip>
<template slot-scope="scope">
<!-- manageType '编码' 使用可点击的 span -->
<!-- <template slot-scope="scope">
<span class="clickText" v-if="scope.row.manageType == '0'" @click="openRecords(scope.row)">
{{ scope.row.scrapNum }}
</span>
<!-- 否则直接显示数字 -->
<span v-else>
{{ scope.row.scrapNum }}
</span>
</template> -->
</el-table-column>
<el-table-column label="报废费用" align="center" prop="scrapPrice" show-overflow-tooltip />
<el-table-column label="报废原因" align="center" prop="scrapReason" show-overflow-tooltip />
<el-table-column label="报废图片" align="center" prop="fileList" show-overflow-tooltip>
<template slot-scope="{ row }">
<div style="width: 30; height: 30px;">
<el-image
v-for="(item, index) in row.fileList"
:key="index"
:src="item.url"
style="width: 30px; height: 30px; margin-right: 10px"
fit="cover"
:preview-src-list="[item.url]"
/>
</div>
</template>
</el-table-column>
<el-table-column label="报废费用" align="center" prop="" show-overflow-tooltip />
<el-table-column label="报废原因" align="center" prop="" show-overflow-tooltip />
<el-table-column label="报废图片" align="center" prop="" show-overflow-tooltip />
<el-table-column label="报废类型" align="center" prop="scrapType" show-overflow-tooltip />
<el-table-column label="报废单号" align="center" prop="scrapCode" show-overflow-tooltip />
<el-table-column label="报废人员" align="center" prop="scrapPersonName" show-overflow-tooltip />
<el-table-column label="报废时间" align="center" prop="" show-overflow-tooltip />
<el-table-column label="报废时间" align="center" prop="scrapTime" show-overflow-tooltip />
</el-table>
<pagination