出库增加loading

This commit is contained in:
bb_pan 2025-07-28 16:39:36 +08:00
parent 68d7fe22e8
commit bf5a19217f
1 changed files with 31 additions and 11 deletions

View File

@ -165,7 +165,7 @@
<el-button icon="el-icon-refresh" size="mini" @click="resetQueryOutInfo">重置</el-button> <el-button icon="el-icon-refresh" size="mini" @click="resetQueryOutInfo">重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table :data="getListOutInfo" width="600px" height="450"> <el-table v-loading="loadingView" :data="getListOutInfo" width="600px" height="450">
<el-table-column label="类型名称" align="center" prop="maTypeName" :show-overflow-tooltip="true" /> <el-table-column label="类型名称" align="center" prop="maTypeName" :show-overflow-tooltip="true" />
<el-table-column label="规格型号" align="center" prop="typeName" :show-overflow-tooltip="true" /> <el-table-column label="规格型号" align="center" prop="typeName" :show-overflow-tooltip="true" />
<el-table-column label="计量单位" align="center" prop="unitName" :show-overflow-tooltip="true" /> <el-table-column label="计量单位" align="center" prop="unitName" :show-overflow-tooltip="true" />
@ -233,7 +233,7 @@
size="mini" size="mini"
type="danger" type="danger"
@click="handleReject(scope.row)" @click="handleReject(scope.row)"
v-if="scope.row.alNum == 0" v-if="scope.row.alNum == 0 && taskType == '19'"
> >
驳回 驳回
</el-button> </el-button>
@ -409,7 +409,7 @@
<!-- 领料单弹窗 --> <!-- 领料单弹窗 -->
<el-dialog :visible.sync="open" width="1090px" :title="title" append-to-body> <el-dialog :visible.sync="open" width="1090px" :title="title" append-to-body>
<div style="height: 500px; overflow-y: scroll; padding: 0 20px"> <div style="height: 500px; overflow-y: scroll; padding: 0 20px" v-loading="leaseLoading">
<vue-easy-print tableShow ref="remarksPrintRef" class="print"> <vue-easy-print tableShow ref="remarksPrintRef" class="print">
<div class="title" style="text-align: center; font-weight: 600; font-size: 16px">领料单</div> <div class="title" style="text-align: center; font-weight: 600; font-size: 16px">领料单</div>
<div class="info" style="margin-top: 10px; display: flex; flex-wrap: wrap"> <div class="info" style="margin-top: 10px; display: flex; flex-wrap: wrap">
@ -779,7 +779,9 @@ export default {
kgSignList: [], kgSignList: [],
outSignList: [], outSignList: [],
approveSignList: [], approveSignList: [],
currentRowData: null // currentRowData: null, //
leaseLoading: false,
taskType: ''
} }
}, },
created() { created() {
@ -892,7 +894,10 @@ export default {
/** 查看按钮操作 */ /** 查看按钮操作 */
handleView(row) { handleView(row) {
const { id, publishTask } = row console.log('🚀 ~ handleView ~ row:', row.taskType)
this.getListOutInfo = []
const { id, publishTask, taskType } = row
this.taskType = taskType
this.publishTask = publishTask this.publishTask = publishTask
this.currentRowData = row // taskId this.currentRowData = row // taskId
this.title = '查看' this.title = '查看'
@ -952,14 +957,19 @@ export default {
/** 出库按钮操作 */ /** 出库按钮操作 */
handleOut(row) { handleOut(row) {
this.getListOutInfo = []
const { id, publishTask } = row const { id, publishTask } = row
this.publishTask = publishTask this.publishTask = publishTask
this.title = '出库' this.title = '出库'
this.showOutInfo = true this.showOutInfo = true
this.queryOutInfo.id = row.id this.queryOutInfo.id = row.id
this.loadingView = true
outInfoList(id, { keyWord: this.queryOutInfo.keyWord, publishTask }).then(response => { outInfoList(id, { keyWord: this.queryOutInfo.keyWord, publishTask }).then(response => {
this.getListOutInfo = response.data.leaseApplyDetailsList this.getListOutInfo = response.data.leaseApplyDetailsList
// this.loading = false; // this.loading = false;
this.loadingView = false
}).catch(() => {
this.loadingView = false
}) })
}, },
@ -1110,12 +1120,19 @@ export default {
// var ids = row.id // var ids = row.id
const { id, publishTask } = row const { id, publishTask } = row
this.publishTask = publishTask this.publishTask = publishTask
const res = await getApplyInfo(id, { keyWord: this.queryOutView.keyWord, publishTask }) this.leaseLoading = true
this.leaseApplyDetails = res.data.leaseApplyDetailsList try {
this.leaseApplyData = res.data.leaseApplyInfo const res = await getApplyInfo(id, { keyWord: this.queryOutView.keyWord, publishTask })
this.kgSignList = res.data.kgSignList || [] this.leaseApplyDetails = res.data.leaseApplyDetailsList
this.outSignList = res.data.outSignList || [] this.leaseApplyData = res.data.leaseApplyInfo
this.approveSignList = res.data.approveSignList || [] this.kgSignList = res.data.kgSignList || []
this.outSignList = res.data.outSignList || []
this.approveSignList = res.data.approveSignList || []
} catch (error) {
console.log('🚀 ~ handleLld ~ error:', error)
} finally {
this.leaseLoading = false
}
}, },
// //
@ -1340,4 +1357,7 @@ export default {
border-collapse: collapse; border-collapse: collapse;
} }
} }
.my-loading {
z-index: 99999 !important;
}
</style> </style>